1- FROM php:8.2-apache
2- LABEL maintainer "Tadayuki Onishi <tt.tanishi100@gmail.com>"
1+ FROM --platform=$BUILDPLATFORM php:8.2-apache
32
43RUN apt-get update && \
54 apt-get -y install apt-transport-https git curl vim --no-install-recommends && \
6- rm -r /var/lib/apt/lists/*
7-
8- RUN curl -sSL -o /tmp/mo https://git.io/get-mo && \
5+ rm -r /var/lib/apt/lists/* && \
6+ curl -sSL -o /tmp/mo https://git.io/get-mo && \
97 chmod +x /tmp/mo
108
119# Docker build
@@ -14,34 +12,39 @@ ARG GIT_ORIGIN=unkown
1412ARG IMAGE_NAME=unkown
1513LABEL git-revision=$GIT_REVISION \
1614 git-origin=$GIT_ORIGIN \
17- image-name=$IMAGE_NAME
15+ image-name=$IMAGE_NAME \
16+ maintainer="Tadayuki Onishi <tt.tanishi100@gmail.com>"
1817
1918# SimpleSAMLphp
2019ARG SIMPLESAMLPHP_VERSION
2120RUN curl -sSL -o /tmp/simplesamlphp.tar.gz https://github.com/simplesamlphp/simplesamlphp/releases/download/v$SIMPLESAMLPHP_VERSION/simplesamlphp-$SIMPLESAMLPHP_VERSION.tar.gz && \
2221 tar xzf /tmp/simplesamlphp.tar.gz -C /tmp && \
2322 mv /tmp/simplesamlphp-* /var/www/simplesamlphp && \
2423 touch /var/www/simplesamlphp/modules/exampleauth/enable
25- RUN echo "<?php" > /var/www/simplesamlphp/metadata/shib13-sp-remote.php
24+
2625COPY config/simplesamlphp/config.php /var/www/simplesamlphp/config
2726COPY config/simplesamlphp/authsources.php /var/www/simplesamlphp/config
2827COPY config/simplesamlphp/saml20-sp-remote.php /var/www/simplesamlphp/metadata
2928COPY config/simplesamlphp/server.crt /var/www/simplesamlphp/cert/
3029COPY config/simplesamlphp/server.pem /var/www/simplesamlphp/cert/
3130
31+ RUN echo "<?php" > /var/www/simplesamlphp/metadata/shib13-sp-remote.php
32+
3233# Apache
3334ENV HTTP_PORT 8080
3435
3536COPY config/apache/ports.conf.mo /tmp
36- RUN /tmp/mo /tmp/ports.conf.mo > /etc/apache2/ports.conf
3737COPY config/apache/simplesamlphp.conf.mo /tmp
38- RUN /tmp/mo /tmp/simplesamlphp.conf.mo > /etc/apache2/sites-available/simplesamlphp.conf
38+ RUN /tmp/mo /tmp/ports.conf.mo > /etc/apache2/ports.conf && \
39+ /tmp/mo /tmp/simplesamlphp.conf.mo > /etc/apache2/sites-available/simplesamlphp.conf
3940
41+ # hadolint ignore=DL3059
4042RUN a2dissite 000-default.conf default-ssl.conf && \
4143 a2enmod rewrite && \
4244 a2ensite simplesamlphp.conf
4345
4446# Clean up
47+ # hadolint ignore=DL3059
4548RUN rm -rf /tmp/*
4649
4750# Set work dir
0 commit comments