Commit 11f0b6c4 authored by Michał 'rysiek' Woźniak's avatar Michał 'rysiek' Woźniak
Browse files

asset precompilation has to happen after db is setup, because reasons I guess. eh.

parent b0d698fe
......@@ -17,9 +17,6 @@ RUN git clone https://0xacab.org/schleuder/schleuder-web.git /opt/schleuder-web
# remove the default config files
RUN rm /opt/schleuder-web/config/schleuder-web.yml /opt/schleuder-web/config/secrets.yml /opt/schleuder-web/config/database.yml
# precompile assets
RUN cd /opt/schleuder-web && RAILS_ENV=production bundle exec rake assets:precompile
COPY entrypoint.sh /sbin/entrypoint.sh
RUN chmod a+x /sbin/entrypoint.sh
......
......@@ -245,6 +245,9 @@ else
su -p -c "env PATH=\"$PATH\" bundle exec rake db:setup RAILS_ENV=production" "$WEBSCHLOCKER_USER"
fi
# precompile assets
su -p -c "env PATH=\"$PATH\" bundle exec rake assets:precompile RAILS_ENV=production" "$WEBSCHLOCKER_USER"
# make sure the envvars are available within su
export WEBSCHLOCKER_BIND_ADDRESS WEBSCHLOCKER_BIND_PORT
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment