-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathDockerfile
38 lines (29 loc) · 864 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
27
28
29
30
31
32
33
34
35
36
37
38
FROM node:18-alpine
# set work directory
WORKDIR /usr/src/app
# set environment variables
ENV PYTHONDONTWRITEBYTECODE 1
ENV PYTHONUNBUFFERED 1
RUN apk update \
&& apk add \
postgresql-dev \
gcc \
python3-dev \
musl-dev \
yarn
# Python 3.11 stuff
RUN rm /usr/lib/python3.11/EXTERNALLY-MANAGED
# setup python and pip since we're using node image as base
RUN python3 -m ensurepip && \
rm -r /usr/lib/python*/ensurepip && \
pip3 install --upgrade pip setuptools==45 && \
if [ ! -e /usr/bin/pip ]; then ln -s pip3 /usr/bin/pip ; fi && \
rm -r /root/.cache
# install dependencies
RUN pip install --upgrade pip
# copy project
COPY . .
RUN pip install -r requirements-dev.txt
RUN yarn install --frozen-lockfile --non-interactive --no-progress --ignore-optional
# run entrypoint.sh
ENTRYPOINT ["/usr/src/app/entrypoint.sh"]