-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
38 lines (33 loc) · 946 Bytes
/
docker-compose.yml
File metadata and controls
38 lines (33 loc) · 946 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
name: python-boilerplate
networks:
project-network:
name: ${DOCKER_NETWORK_NAME}
driver: bridge
services:
python-boilerplate:
image: ${DOCKER_PROJECT_NAME}:${DOCKER_IMAGE_TAG}
container_name: ${DOCKER_CONTAINER_NAME}
build:
context: .
dockerfile: dev.Dockerfile
develop:
watch:
# Sync the working directory with the `/app` directory in the container
- action: sync
path: .
target: /app
ignore:
- app/.venv/
# Rebuild the image on changes to the `pyproject.toml`
- action: rebuild
path: ./app/pyproject.toml
ports:
- "8080:8000"
restart: on-failure
# Можливо, краще монтувати все в /app (якщо твій код у src, скоригуй)
volumes:
- ./docs/:/app/docs
- ./tests/:/app/tests
- ./src/:/app/src/
networks:
- project-network