diff --git a/Dockerfile b/Dockerfile index f7423ce..98ed4a7 100644 --- a/Dockerfile +++ b/Dockerfile @@ -14,6 +14,9 @@ LABEL Version=$version LABEL Build docker build --rm --tag $maintainer/$imagename . +# Add starters and installers +ADD ./container_files /opt + RUN curl -o /etc/yum.repos.d/security:shibboleth.repo \ http://download.opensuse.org/repositories/security://shibboleth/CentOS_7/security:shibboleth.repo \ && yum -y update \ @@ -25,10 +28,9 @@ RUN curl -o /etc/yum.repos.d/security:shibboleth.repo \ && rm /etc/httpd/conf.d/autoindex.conf \ && rm /etc/httpd/conf.d/ssl.conf \ && rm /etc/httpd/conf.d/userdir.conf \ - && rm /etc/httpd/conf.d/welcome.conf - -# Add starters and installers -ADD ./container_files /opt + && rm /etc/httpd/conf.d/welcome.conf \ + && chmod +x /opt/bin/httpd-shib-foreground \ + && chmod +x /opt/bin/shibboleth_keygen.sh #Script to start service, Added ssl default conf, Added shib module apache RUN ln -s /opt/bin/httpd-shib-foreground /usr/local/bin && ln -s /opt/etc/httpd/conf.d/ssl.conf /etc/httpd/conf.d/ssl.conf && ln -s /opt/etc/httpd/conf.modules.d/00-shib.conf /etc/httpd/conf.modules.d/00-shib.conf && ln -s /usr/lib64/shibboleth/mod_shib_24.so /etc/httpd/modules/mod_shib_24.so diff --git a/tests/image.bats b/tests/image.bats index 11b300e..769c4c9 100644 --- a/tests/image.bats +++ b/tests/image.bats @@ -20,4 +20,8 @@ load ../common @test "Includes Shibboleth keygenerator" { docker run -i $maintainer/$imagename find /opt/bin/shibboleth_keygen.sh +} + +@test "Includes httpd + shibd startup script" { + docker run -i $maintainer/$imagename find /opt/bin/httpd-shib-foreground } \ No newline at end of file