-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathDockerfile
35 lines (28 loc) · 1.28 KB
/
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
27
28
29
30
31
32
33
34
35
# Dockerfile
FROM python:3.11
# Copy source code and test files
COPY requirements.txt /opt/lsst/transfer_embargo/
COPY src/ /opt/lsst/transfer_embargo/src/
COPY tests_docker/ /opt/lsst/transfer_embargo/tests_docker/
# Set the working directory
WORKDIR /opt/lsst/transfer_embargo
# List files for debugging
# RUN ls -la /opt/lsst/transfer_embargo/
# RUN ls -R /opt/lsst/transfer_embargo/src/
# RUN ls -R /opt/lsst/transfer_embargo/tests_docker/
# RUN ls -R /opt/lsst/transfer_embargo/tests/data/test_from/
RUN pip install -r requirements.txt
# Define the environment variables
# These are written over if they are re-defined
# by the cronjob or on the command line deploy
# of the pod
ENV FROMREPO "tests_docker/temp_from"
ENV TOREPO "tests_docker/temp_to"
ENV INSTRUMENT "LATISS"
ENV NOW "2020-03-01 23:59:59.999999"
ENV EMBARGO_HRS "7200"
ENV DATAQUERIES '{ "datasettype": "raw", "collections": "LATISS/raw/all"}'
ENV LOG "True"
ENV PASTEMBARGO "1.0"
#CMD ["/bin/sh", "-c", "python src/move_embargo_args.py \"$FROMREPO\" \"$TOREPO\" \"$INSTRUMENT\" --log \"$LOG\""]
CMD ["/bin/sh", "-c", "python src/move_embargo_args.py \"$FROMREPO\" \"$TOREPO\" \"$INSTRUMENT\" --nowtime \"$NOW\" --embargohours \"$EMBARGO_HRS\" --log \"$LOG\" --pastembargohours \"$PASTEMBARGO\" --dataqueries \"$DATAQUERIES\""]