mirror of
https://github.com/cookiecutter/cookiecutter-django.git
synced 2025-08-09 06:24:52 +03:00
- Removed docker provider (no more using Docker socket)
- All configuration now exists in traefik.toml
This commit is contained in:
parent
0ba293a566
commit
6ba02e808a
|
@ -1,4 +1,4 @@
|
||||||
logLevel = "DEBUG"
|
logLevel = "ERROR"
|
||||||
defaultEntryPoints = ["http", "https"]
|
defaultEntryPoints = ["http", "https"]
|
||||||
|
|
||||||
[web]
|
[web]
|
||||||
|
@ -30,9 +30,15 @@ OnHostRule = true
|
||||||
[acme.httpChallenge]
|
[acme.httpChallenge]
|
||||||
entryPoint = "http"
|
entryPoint = "http"
|
||||||
|
|
||||||
# Enable Docker configuration backend
|
[file]
|
||||||
[docker]
|
[backends]
|
||||||
endpoint = "unix:///var/run/docker.sock"
|
[backends.django]
|
||||||
domain = "{{cookiecutter.domain_name}}"
|
[backends.django.servers.server1]
|
||||||
watch = true
|
url = "http://django:5000"
|
||||||
exposedbydefault = false
|
|
||||||
|
[frontends]
|
||||||
|
[frontends.django]
|
||||||
|
backend = "django"
|
||||||
|
passHostHeader = true
|
||||||
|
[frontends.django.routes.dr1]
|
||||||
|
rule = "Host:{{ cookiecutter.domain_name }}"
|
||||||
|
|
|
@ -18,11 +18,6 @@ services:
|
||||||
- ./.envs/.production/.django
|
- ./.envs/.production/.django
|
||||||
- ./.envs/.production/.postgres
|
- ./.envs/.production/.postgres
|
||||||
command: /start
|
command: /start
|
||||||
labels:
|
|
||||||
- "traefik.enable=true"
|
|
||||||
- "traefik.backend=django"
|
|
||||||
- "traefik.frontend.rule=Host:{{ cookiecutter.domain_name }}"
|
|
||||||
- "traefik.port=5000"
|
|
||||||
|
|
||||||
postgres:
|
postgres:
|
||||||
build:
|
build:
|
||||||
|
@ -43,7 +38,6 @@ services:
|
||||||
depends_on:
|
depends_on:
|
||||||
- django
|
- django
|
||||||
volumes:
|
volumes:
|
||||||
- /var/run/docker.sock:/var/run/docker.sock:ro
|
|
||||||
- production_traefik:/etc/traefik/acme
|
- production_traefik:/etc/traefik/acme
|
||||||
ports:
|
ports:
|
||||||
- "0.0.0.0:80:80"
|
- "0.0.0.0:80:80"
|
||||||
|
@ -58,15 +52,11 @@ services:
|
||||||
<<: *django
|
<<: *django
|
||||||
image: {{ cookiecutter.project_slug }}_production_celeryworker
|
image: {{ cookiecutter.project_slug }}_production_celeryworker
|
||||||
command: /start-celeryworker
|
command: /start-celeryworker
|
||||||
labels:
|
|
||||||
- "traefik.enable=false"
|
|
||||||
|
|
||||||
celerybeat:
|
celerybeat:
|
||||||
<<: *django
|
<<: *django
|
||||||
image: {{ cookiecutter.project_slug }}_production_celerybeat
|
image: {{ cookiecutter.project_slug }}_production_celerybeat
|
||||||
command: /start-celerybeat
|
command: /start-celerybeat
|
||||||
labels:
|
|
||||||
- "traefik.enable=false"
|
|
||||||
|
|
||||||
flower:
|
flower:
|
||||||
<<: *django
|
<<: *django
|
||||||
|
@ -74,7 +64,5 @@ services:
|
||||||
ports:
|
ports:
|
||||||
- "5555:5555"
|
- "5555:5555"
|
||||||
command: /start-flower
|
command: /start-flower
|
||||||
labels:
|
|
||||||
- "traefik.enable=false"
|
|
||||||
|
|
||||||
{%- endif %}
|
{%- endif %}
|
||||||
|
|
Loading…
Reference in New Issue
Block a user