Spotter-VM/lxc-apps/decidim/lxcfile

50 lines
1.0 KiB
Plaintext

IMAGE decidim_0.0.1-191113
LAYER alpine3.9_3.9.4-190620
LAYER alpine3.9-ruby2.6_2.6.3-190620
LAYER alpine3.9-nodejs10_10.14.2-190620
LAYER alpine3.9-nginx_1.14.2-191115
MERGE /usr/bin/lxcmerge
ENV RAILS_ENV production
RUN EOF
# Install runtime dependencies
apk --no-cache add libpq tzdata
# Install build dependencies
apk --no-cache add --virtual .deps build-base icu-dev libxml2-dev libxslt-dev postgresql-dev zlib-dev
# Install passenger
gem install passenger --no-rdoc --no-ri
# Install Decidim
bundle config build.nokogiri --use-system-libraries
gem install decidim
cd /srv
decidim decidim-app
EOF
COPY lxc
RUN EOF
# Install gems required by decidim
cd /srv/decidim-app
bundle install
# Setup delayed job for mail sending
bin/rails generate delayed_job:active_record
# Precompile static assets
bin/rails assets:precompile
# Change ownership
chown -R www-data:www-data /srv/decidim-app
# Cleanup
apk --no-cache del .deps
EOF
CMD s6-svscan /etc/services.d