FROM python:3.9
ENV PYTHONUNBUFFERED 1
WORKDIR /backend
ADD . /backend
COPY start.sh /backend/start.sh
RUN chmod +x ./start.sh
RUN pip install -r /backend/requirements.txt
# RUN ls -a
CMD ["/backend/start.sh"]
version: "3.9"
volumes:
db-data:
services:
db:
image: postgres
volumes:
- ./data/db:/var/lib/postgresql/data
ports:
- 5432:5432
environment:
- POSTGRES_DB=visionmark
- POSTGRES_USER=nariman
- POSTGRES_PASSWORD=Alimuradov@63
volumes:
- db-data:/var/lib/postgresql/data
backend:
build: ./backend
volumes:
- .:/backend
expose:
- "8000"
depends_on:
- db