-
Notifications
You must be signed in to change notification settings - Fork 0
/
Dockerfile_dev
62 lines (36 loc) · 1.44 KB
/
Dockerfile_dev
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
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
FROM hub.opensciencegrid.org/opensciencegrid/software-base:3.6-el8-release
## Build arguments for embedding a version string within the image.
ARG GITHUB_REF
ENV GITHUB_REF="${GITHUB_REF:-}"
ARG GITHUB_SHA
ENV GITHUB_SHA="${GITHUB_SHA:-}"
## Set the Python version.
ARG PY_PKG=python39
ARG PY_EXE=python3.9
## Locale and Python settings required by Flask.
ENV LANG="en_US.utf8"
ENV LC_ALL="en_US.utf8"
ENV PYTHONUNBUFFERED=1
## Install core dependencies and configuration.
RUN yum module enable -y mod_auth_openidc ${PY_PKG} \
&& yum update -y \
&& yum install -y httpd mod_auth_openidc mod_ssl ${PY_PKG}-pip ${PY_PKG}-mod_wsgi \
&& yum clean all \
&& rm -rf /etc/httpd/conf.d/* /var/cache/yum/ \
#
&& ${PY_EXE} -m pip install --no-cache-dir -U pip setuptools wheel
## Install the Flask and WSGI applications.
COPY /registry/requirements.txt /srv/
RUN ${PY_EXE} -m pip install --no-cache-dir -r /srv/requirements.txt
## Copy over httpd.conf
COPY apache/httpd.conf /etc/httpd/conf.d/
COPY apache/supervisor-apache.conf /etc/supervisord.d/40-apache.conf
COPY registry /srv/registry
COPY wsgi.py /srv/
# Set up a instance run space
RUN mkdir -p /srv/instance\
&& rm -rf /srv/instance/* \
&& chown apache:apache /srv/instance/
COPY key /key
ENV OIDC_CLIENT_ID="cilogon:/client_id/385a98bfe7c6c5699ee5da7ccdb37157"
ENV OIDC_CLIENT_SECRET="G79dobp9BVoMBr3a2gmz7s0IiTaBj_vNANXWI2rwP-PT64q6Na-pN3_uUJfWe7svBkJApQxpVxlASHaP6Qyd7w"