generated from cloud-gov/.github
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathDockerfile
26 lines (20 loc) · 1022 Bytes
/
Dockerfile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
# Use our hardened cloud-service-broker base image.
ARG base_image
# Builder: Build brokerpaks for use with cloud service broker.
FROM ${base_image} AS build
ADD . /app
WORKDIR /app
ARG BUILD_ENV=development
# For non-production builds only, add the ZScaler CA certificate to the trust store so Docker
# can make HTTPS connections. `csb pak build` needs to do this to download binaries.
# You must copy the ZScaler cert to ./zscaler.crt; the most reliable way is:
# `cp $(brew --prefix)/etc/ca-certificates/cert.pem ./zscaler.crt`.
# See: https://help.zscaler.com/zia/adding-custom-certificate-application-specific-trust-store
RUN set -e; if [ "$BUILD_ENV" = "production" ] ; then echo "production env"; else echo \
"non-production env: $BUILD_ENV"; CERT_DIR=$(openssl version -d | cut -f2 -d \")/certs ; \
cp /app/zscaler.crt $CERT_DIR ; update-ca-certificates ; \
fi
RUN /app/csb pak build brokerpaks/aws-ses
FROM ${base_image}
# Copy brokerpaks to final image
COPY --from=build /app/aws-ses-0.1.0.brokerpak /app/