forked from canada-ca/tracker
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathDockerfile
More file actions
40 lines (32 loc) · 837 Bytes
/
Dockerfile
File metadata and controls
40 lines (32 loc) · 837 Bytes
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
FROM ubuntu:20.04
LABEL maintainer="mike.williamson@tbs-sct.gc.ca"
ENV PYTHONUNBUFFERED=TRUE
ENV PIPENV_NOSPIN=TRUE
ENV LC_ALL=C.UTF-8
ENV LANG=C.UTF-8
ENV DEBIAN_FRONTEND=noninteractive
RUN set -ex \
\
&& savedAptMark="$(apt-mark showmanual)" \
&& apt-get update && apt-get install -y --no-install-recommends \
openssl \
libffi-dev \
postgresql \
postgresql-contrib \
musl-dev \
python3.8 \
python3-dev \
python3-pip \
build-essential
RUN addgroup -gid 1000 -system trackerapi && \
adduser -u 1000 -system trackerapi -gecos trackerapi
RUN python3 -m pip install --upgrade setuptools
RUN python3 -m pip install wheel
RUN python3 -m pip install pipenv --no-cache-dir
COPY . /app/
ENV PYTHONPATH=/app
WORKDIR /app
USER trackerapi
RUN pipenv sync --bare
EXPOSE 5000
CMD pipenv run server