Skip to content

Commit

Permalink
Moving lineage for SP to Debian Jesse
Browse files Browse the repository at this point in the history
  • Loading branch information
Jim Van Fleet committed Jul 26, 2017
1 parent 8f60277 commit a08d49a
Show file tree
Hide file tree
Showing 2 changed files with 26 additions and 24 deletions.
38 changes: 20 additions & 18 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,21 +1,23 @@
FROM tier/shibboleth_sp

# Define args and set a default value
ARG maintainer=tier
ARG imagename=siteadmin-sp
ARG version=1.0

MAINTAINER $maintainer
LABEL Vendor="Internet2"
LABEL ImageType="SP"
LABEL ImageName=$imagename
LABEL ImageOS=centos7
LABEL Version=$version

LABEL Build docker build --rm --tag $maintainer/$imagename .
FROM bigfleet/siteadmin:latest

# Installs Apache Passenger prereqs
RUN apt-get install -y dirmngr gnupg && \
apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv-keys 561F9B9CAC40B2F7 && \
apt-get install -y apt-transport-https ca-certificates && \
sh -c 'echo deb https://oss-binaries.phusionpassenger.com/apt/passenger jessie main > /etc/apt/sources.list.d/passenger.list' && \
apt-get update && \
apt-get install -y \
apache2-threaded-dev \
apache2-mpm-worker \
libapache2-mod-passenger \
odbc-postgresql \
passenger \
shibboleth-sp2-utils

ADD ./container_files /opt

RUN rm /etc/httpd/conf.d/ssl.conf && \
cp /opt/etc/httpd/conf.d/*.conf /etc/httpd/conf.d/. && \
cp /opt/etc/shibboleth/* /etc/shibboleth/.
RUN cp /opt/etc/httpd/conf.d/*.conf /etc/apache2/conf-available/. && \
cp /opt/etc/shibboleth/* /etc/shibboleth/. && \
a2enconf log && a2enconf shib

EXPOSE 80 443
12 changes: 6 additions & 6 deletions tests/image.bats
Original file line number Diff line number Diff line change
Expand Up @@ -4,19 +4,19 @@ load ../common


@test "Shibboleth configuration for httpd secures siteadmin" {
docker run -i $maintainer/$imagename grep siteadmin /etc/httpd/conf.d/shib.conf
docker run -i $maintainer/$imagename grep siteadmin /etc/apache2/conf-enabled/shib.conf
}

@test "Log configuration in place" {
docker run -i $maintainer/$imagename find /etc/httpd/conf.d/log.conf
docker run -i $maintainer/$imagename find /etc/apache2/conf-enabled/log.conf
}

@test "shibboleth2.xml not using a TCP Listener configuration" {
docker run -i $maintainer/$imagename grep -v TCPListener /etc/shibboleth/shibboleth2.xml
@test "Passenger installation validates" {
docker run -i $maintainer/$imagename /usr/bin/passenger-config validate-install --auto
}

@test "Shibboleth configuration is well formed" {
docker run -i $maintainer/$imagename xmlwf /etc/shibboleth/shibboleth2.xml
@test "shibboleth2.xml not using a TCP Listener configuration" {
docker run -i $maintainer/$imagename grep -v TCPListener /etc/shibboleth/shibboleth2.xml
}

@test "Shibboleth configuration is valid" {
Expand Down

0 comments on commit a08d49a

Please sign in to comment.