-
Notifications
You must be signed in to change notification settings - Fork 0
/
Dockerfile
31 lines (23 loc) · 841 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
FROM ubuntu:latest
WORKDIR /app
EXPOSE 8000
RUN apt-get update
RUN apt-get install -y python3 python3-pip nodejs npm python3-venv
RUN python3 -m venv /app/venv
COPY ./backend/requirements.txt /app/backend/requirements.txt
COPY ./frontend/package.json /app/frontend/package.json
COPY ./frontend/package-lock.json /app/frontend/package-lock.json
RUN /app/venv/bin/pip install -r /app/backend/requirements.txt
RUN cd /app/frontend && npm install
COPY ./backend /app/backend
COPY ./frontend /app/frontend
COPY ./entrypoint.sh /app/entrypoint.sh
# build args
ARG VITE_SUPABASE_URL
ARG VITE_SUPABASE_ANON_KEY
ARG VITE_PROJECT_REF
ENV VITE_SUPABASE_URL=${VITE_SUPABASE_URL}
ENV VITE_SUPABASE_ANON_KEY=${VITE_SUPABASE_ANON_KEY}
ENV VITE_PROJECT_REF=${VITE_PROJECT_REF}
RUN cd /app/frontend && npm run build
ENTRYPOINT ["/app/entrypoint.sh"]