From de881659e7cc2303814176f71a23e0ccc9343130 Mon Sep 17 00:00:00 2001 From: Jim Van Fleet Date: Mon, 18 Jul 2016 14:44:51 -0400 Subject: [PATCH] Test passing --- Dockerfile | 29 +++++++++++++++++++++++++++-- tests/shibboleth-idp.bats | 4 ++-- 2 files changed, 29 insertions(+), 4 deletions(-) diff --git a/Dockerfile b/Dockerfile index 88cd1aa..7cef8e8 100644 --- a/Dockerfile +++ b/Dockerfile @@ -7,7 +7,6 @@ ARG registry=docker.io ARG maintainer=tier ARG imagename=shibboleth_idp ARG version=3.2.1 - ENV VERSION=$version MAINTAINER $maintainer @@ -17,4 +16,30 @@ LABEL ImageName=$imagename LABEL ImageOS=centos7 LABEL Version=$VERSION -CMD echo $VERSION \ No newline at end of file +RUN yum -y install \ + apr-devel \ + httpd \ + java-1.8.0-openjdk-headless \ + krb5-workstation \ + mod_ssl \ + openssl-devel \ + tomcat \ + tomcat-native.x86_64 \ + wget \ + && yum -y clean all + +ENV SHIB_RELDIR=http://shibboleth.net/downloads/identity-provider/$VERSION +ENV SHIB_PREFIX=shibboleth-identity-provider-$VERSION + +RUN mkdir -p /tmp/shibboleth && cd /tmp/shibboleth && \ + wget https://shibboleth.net/downloads/PGP_KEYS \ + $SHIB_RELDIR/$SHIB_PREFIX.tar.gz \ + $SHIB_RELDIR/$SHIB_PREFIX.tar.gz.asc \ + $SHIB_RELDIR/$SHIB_PREFIX.tar.gz.sha256 && \ + gpg --import PGP_KEYS && \ + gpg $SHIB_PREFIX.tar.gz.asc && \ + sha256sum --check $SHIB_PREFIX.tar.gz.sha256 && \ + tar xf $SHIB_PREFIX.tar.gz && \ + mkdir -p /opt/shibboleth && \ + mv $SHIB_PREFIX /opt/shibboleth/. && \ + ln -s /opt/shibboleth/$SHIB_PREFIX /opt/shibboleth/current \ No newline at end of file diff --git a/tests/shibboleth-idp.bats b/tests/shibboleth-idp.bats index 4413f25..e2ae756 100644 --- a/tests/shibboleth-idp.bats +++ b/tests/shibboleth-idp.bats @@ -2,7 +2,7 @@ load ../common -@test "Creates non-root host directory" { - result="$(docker run -it bigfleet/shibboleth_idp ls /opt)" +@test "Creates non-root Shib IDP home" { + result="$(docker run -it bigfleet/shibboleth_idp ls /opt/shibboleth/current/bin/)" [ "$result" != '' ] } \ No newline at end of file