Future-proof Decidim passenger + nginx some more
This commit is contained in:
parent
bbc669d2a7
commit
d532d087fe
@ -15,6 +15,7 @@ RUN EOF
|
||||
|
||||
# Install passenger
|
||||
gem install passenger --no-document
|
||||
ln -s /usr/local/lib/ruby/gems/2.6.0/gems/passenger-* /usr/local/lib/passenger
|
||||
|
||||
# Create OS user
|
||||
addgroup -S -g 8080 decidim
|
||||
@ -22,7 +23,7 @@ RUN EOF
|
||||
|
||||
# Compile nginx
|
||||
# Minimized version of /usr/local/bin/passenger-install-nginx-module
|
||||
NGINX_VERSION=$(grep ' PREFERRED_NGINX_VERSION' /usr/local/lib/ruby/gems/2.6.0/gems/passenger-*/src/ruby_supportlib/phusion_passenger.rb | grep -Eo '([0-9\.]+)')
|
||||
NGINX_VERSION=$(grep ' PREFERRED_NGINX_VERSION' /usr/local/lib/passenger/src/ruby_supportlib/phusion_passenger.rb | grep -Eo '([0-9\.]+)')
|
||||
cd /tmp
|
||||
wget https://nginx.org/download/nginx-${NGINX_VERSION}.tar.gz
|
||||
tar xf nginx-*.tar.gz
|
||||
@ -44,7 +45,7 @@ RUN EOF
|
||||
--with-http_stub_status_module \
|
||||
--with-http_addition_module \
|
||||
--with-cc-opt=-Wno-error \
|
||||
--add-module=/usr/local/lib/ruby/gems/2.6.0/gems/passenger-*/src/nginx_module
|
||||
--add-module=/usr/local/lib/passenger/src/nginx_module
|
||||
make -j $(getconf _NPROCESSORS_ONLN)
|
||||
make install
|
||||
rm -f /etc/nginx/*.default
|
||||
|
@ -18,7 +18,7 @@ http {
|
||||
tcp_nodelay on;
|
||||
send_timeout 300;
|
||||
|
||||
passenger_root /usr/local/lib/ruby/gems/2.6.0/gems/passenger-6.0.4;
|
||||
passenger_root /usr/local/lib/passenger;
|
||||
passenger_ruby /usr/local/bin/ruby;
|
||||
|
||||
server {
|
||||
|
Loading…
Reference in New Issue
Block a user