-
Notifications
You must be signed in to change notification settings - Fork 4
/
Copy pathdocker-compose.yml
125 lines (109 loc) · 3.14 KB
/
docker-compose.yml
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
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
services:
lespass_postgres:
image: postgres:13-bookworm
restart: always
container_name: lespass_postgres
hostname: lespass_postgres
# ports:
# - 5432:5432
volumes:
# - ./database:/var/lib/postgresql/data
- lespass_dev_db:/var/lib/postgresql/data
env_file: .env
networks:
- frontend
lespass_memcached:
image : memcached:1.6
container_name: lespass_memcached
hostname: lespass_memcached
restart: always
networks:
- frontend
lespass_redis:
container_name: lespass_redis
hostname: lespass_redis
image: redis:7.2.3-bookworm
restart: always
networks:
- frontend
lespass_django:
build: .
# image: tibillet/lespass:latest
restart: always
container_name: lespass_django
hostname: lespass_django
volumes:
- ./:/DjangoFiles
- ./backup:/Backup/dumps/
env_file: .env
depends_on:
- lespass_postgres
- lespass_redis
- lespass_memcached
links:
- lespass_postgres:postgres
- lespass_redis:redis
- lespass_memcached:memcached
networks:
- frontend
# extra_hosts:
# - "fedow.tibillet.localhost:172.17.0.1"
# - "cashless.tibillet.localhost:172.17.0.1"
# - "cashless2.tibillet.localhost:172.17.0.1"
lespass_celery:
build: .
# image: tibillet/lespass:latest
container_name: lespass_celery
restart: always
hostname: lespass_celery
env_file: .env
volumes:
- ./:/DjangoFiles
depends_on:
- lespass_postgres
- lespass_redis
- lespass_memcached
links:
- lespass_postgres:postgres
- lespass_redis:redis
- lespass_memcached:memcached
networks:
- frontend
# extra_hosts:
# - "fedow.tibillet.localhost:172.17.0.1"
# - "demo.tibillet.localhost:172.17.0.1"
# - "billetistan.tibillet.localhost:172.17.0.1"
# - "cashless.tibillet.localhost:172.17.0.1"
# command: "sleep infinity"
command: "poetry run celery -A TiBillet worker -l INFO"
lespass_nginx:
image: nginx:latest
container_name: lespass_nginx
restart: always
hostname: lespass_nginx
links:
- lespass_django:lespass_django
volumes:
- ./www:/www
- ./logs:/logs
- ./nginx:/etc/nginx/conf.d
labels:
- traefik.enable=true
- traefik.docker.network=frontend
- traefik.http.routers.lespass_nginx.tls.certresolver=myresolver
- traefik.http.routers.lespass_nginx.rule=Host(`$DOMAIN`) || Host(`www.$DOMAIN`) || Host(`$META.$DOMAIN`) || Host(`$SUB.$DOMAIN`)
- traefik.http.services.lespass_nginx.loadbalancer.server.port=80
networks:
- frontend
networks:
frontend:
external: true
# lespass_backend:
volumes:
lespass_dev_db:
# Pour test stripe :
# stripe listen --forward-to https://fedow.tibillet.localhost/webhook_stripe/ --skip-verify
# poetry shell
# django-admin makemessages -l fr && django-admin makemessages -l en
# django-admin compilemessages
# docker build -t lespass . && docker tag lespass tibillet/lespass:latest && docker tag lespass tibillet/lespass:0.10.5 && docker push tibillet/lespass:latest && docker push tibillet/lespass:0.10.5