-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathheroku.Dockerfile
41 lines (29 loc) · 892 Bytes
/
heroku.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
39
40
41
# A workaround to run both the client and the server on heroku in one container.
FROM python:3.9.10-slim
ENV PYTHONUNBUFFERED 1
WORKDIR /app
# Install make and curl
RUN apt-get update \
&& apt-get install -y make curl --no-install-recommends \
&& apt-get clean \
&& rm -rf /var/lib/apt/lists/*
# Install Dependencies
COPY ./poetry.lock ./pyproject.toml ./Makefile ./
RUN make docker-install
COPY ./app ./app
# Client
ENV REACT_APP_SERVER_URL=http://0.0.0.0:8000/api/v1
ENV REACT_APP_SOCKET_URL=ws://0.0.0.0:8000/api/v1/ws
WORKDIR /client
# Install npm
RUN apt-get update \
&& apt install -y npm --no-install-recommends \
&& apt-get clean \
&& rm -rf /var/lib/apt/lists/*
COPY ./harmony-beauty/package.json ./
COPY ./harmony-beauty/src ./src
COPY ./harmony-beauty/public ./public
RUN npm install --force
# Run both server and client
COPY ./run.sh ./
CMD ["sh", "./run.sh"]