forked from cds-snc/tracker
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Dockerfile.run
29 lines (22 loc) · 1002 Bytes
/
Dockerfile.run
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
27
28
29
FROM python:3.6
MAINTAINER David Buckley <david.buckley@cds-snc.ca>
LABEL Description="Track Digital Security Compliance" Vendor="Canadian Digital Service"
RUN pip install awscli
ENV DOMAIN_HOME /opt/scan/domain-scan
ENV TRACKER_HOME /opt/scan/tracker
ENV DOMAIN_SCAN_PATH $DOMAIN_HOME/scan
ENV DOMAIN_GATHER_PATH $DOMAIN_HOME/gather
# Pull down the domain-scan repo to /opt/scan/domain-scan
RUN mkdir -p $DOMAIN_HOME && wget -q -O - https://api.github.com/repos/cds-snc/domain-scan/tarball | tar xz --strip-components=1 -C $DOMAIN_HOME
COPY deploy/scan.sh $TRACKER_HOME/deploy/scan.sh
RUN chmod +x $TRACKER_HOME/deploy/scan.sh
# Copy required source and package files
COPY MANIFEST.in $TRACKER_HOME/MANIFEST.in
COPY setup.py $TRACKER_HOME/setup.py
COPY data $TRACKER_HOME/data
# Setup environment
RUN pip install $TRACKER_HOME/.
RUN pip install -r $DOMAIN_HOME/requirements.txt
RUN pip install -r $DOMAIN_HOME/requirements-scanners.txt
# Set entrypoint
ENTRYPOINT $TRACKER_HOME/deploy/scan.sh