Skip to content

Commit

Permalink
Add syslog to docker-compose to fix logging (#147)
Browse files Browse the repository at this point in the history
  • Loading branch information
nathanfranklin authored Oct 12, 2023
1 parent a5b3cf7 commit 8f3280c
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 0 deletions.
16 changes: 16 additions & 0 deletions devops/geoapi-services/docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,10 @@ services:
- FLASK_APP=/app/geoapi/app.py
- ASSETS_BASE_DIR=/assets
- GEOAPI_TAG=ENV_GEOAPI_TAG
logging:
driver: syslog
options:
tag: geoapi_rabbitmq

nginx:
image: nginx
Expand All @@ -24,6 +28,10 @@ services:
volumes:
- /assets:/assets
- ./nginx.conf:/etc/nginx/nginx.conf
logging:
driver: syslog
options:
tag: geoapi_nginx
networks:
- geoapi

Expand All @@ -42,6 +50,10 @@ services:
tty: true
container_name: geoapicelerybeat
hostname: geoapicelerybeat
logging:
driver: syslog
options:
tag: geoapi_celerybeat
command: "celery -A geoapi.celery_app beat -l info"

api:
Expand All @@ -64,6 +76,10 @@ services:
tty: true
container_name: geoapi
hostname: geoapi
logging:
driver: syslog
options:
tag: geoapi_api
command: "gunicorn -w 4 -b 0.0.0.0:8000 geoapi.app:app -k gevent --reload --timeout 300"
extra_hosts:
- "host.docker.internal:host-gateway"
Expand Down
4 changes: 4 additions & 0 deletions devops/geoapi-workers/docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,4 +14,8 @@ services:
tty: true
container_name: geoapiworkers
hostname: geoapiworkers
logging:
driver: syslog
options:
tag: geoapi_workers
command: "celery -A geoapi.celery_app worker -l info"

0 comments on commit 8f3280c

Please sign in to comment.