diff --git a/1.17.2/Dockerfile b/1.17.2/Dockerfile index 3277915..790718d 100644 --- a/1.17.2/Dockerfile +++ b/1.17.2/Dockerfile @@ -4,12 +4,12 @@ LABEL maintainer="Adam W Zheng " ENV S6_RELEASE 1.22.1.0 ENV SIMPLESAMLPHP_RELEASE 1.17.2 -#Add S6 Overlay +#Add s6-overlay ADD https://github.com/just-containers/s6-overlay/releases/download/v$S6_RELEASE/s6-overlay-amd64.tar.gz /tmp/ RUN tar xzf /tmp/s6-overlay-amd64.tar.gz -C / --exclude="./bin" \ && tar xzf /tmp/s6-overlay-amd64.tar.gz -C /usr ./bin -#Install SimpleSAMLphp Requirements +#Install simplesamlphp requirements RUN yum -y install centos-release-scl \ && yum -y install rh-nginx114 rh-php72 rh-php72-php-fpm rh-php72-php-mbstring rh-php72-php-pdo rh-php72-php-ldap sclo-php72-php-pecl-memcached postfix \ && sed -i 's/user = apache/user = nginx/' /etc/opt/rh/rh-php72/php-fpm.d/www.conf \ @@ -24,37 +24,37 @@ RUN echo -e 'server {\n listen 80 default_server;\n listen [:: && chown -Rv nginx:nginx /var/lib/php/session/ \ && chmod a+t /var/lib/php/session/ -#Download SimpleSAMLphp, Archive must remain present for seeding post install. +#Download simplesamlphp and retain archive for seeding RUN curl -Lo /var/simplesamlphp.tar.gz https://github.com/simplesamlphp/simplesamlphp/releases/download/v$SIMPLESAMLPHP_RELEASE/simplesamlphp-$SIMPLESAMLPHP_RELEASE.tar.gz \ && tar xzf /var/simplesamlphp.tar.gz --directory /var \ && mv /var/simplesamlphp-* /var/simplesamlphp \ && touch /var/simplesamlphp/cert/breadcrumb \ && touch /var/simplesamlphp/log/breadcrumb -#Redirect NGINX Logs +#Redirect nginx logs RUN ln -sf /dev/stdout /var/opt/rh/rh-nginx114/log/nginx/access.log \ && ln -sf /dev/stderr /var/opt/rh/rh-nginx114/log/nginx/error.log -#Add Service NGINX to be Monitored by S6 +#Add service nginx to s6-supervisor RUN mkdir -p /etc/services.d/nginx/ \ && touch /etc/services.d/nginx/run \ && echo '#!/usr/bin/execlineb -P' > /etc/services.d/nginx/run \ && echo '/opt/rh/rh-nginx114/root/usr/sbin/nginx -g "daemon off;"' >> /etc/services.d/nginx/run -#Add Service PHP-FPM to be Monitored by S6 +#Add service php-fpm to s6-supervisor RUN mkdir -p /etc/services.d/php-fpm/ \ && touch /etc/services.d/php-fpm/run \ && echo '#!/usr/bin/execlineb -P' > /etc/services.d/php-fpm/run \ && echo '/opt/rh/rh-php72/root/usr/sbin/php-fpm' >> /etc/services.d/php-fpm/run --nodaemonize \ && sed -i 's|pid = /run/php-fpm/php-fpm.pid|pid = /run/php-fpm.pid|g' /etc/opt/rh/rh-php72/php-fpm.conf -#Add Service Postfix to be Monitored by S6 +#Add service postfix to s6-supervisor RUN mkdir -p /etc/services.d/postfix/ \ && touch /etc/services.d/postfix/run \ && echo '#!/usr/bin/execlineb -P' > /etc/services.d/postfix/run \ && echo '/usr/sbin/postfix start' >> /etc/services.d/postfix/run -#Copy the SimpleSAMLphp CLI Install Script into the Container to be executed on startup +#Copy the simplesamlphp install script into the container to be executed on startup COPY install-simplesamlphp.sh /etc/cont-init.d/ RUN chmod u+x /etc/cont-init.d/install-simplesamlphp.sh