Add logging to docker compose files
This commit is contained in:
parent
3152fd5b48
commit
25b49de65c
|
@ -16,6 +16,11 @@ services:
|
||||||
- TZ=${TZ}
|
- TZ=${TZ}
|
||||||
env_file:
|
env_file:
|
||||||
- .env
|
- .env
|
||||||
|
logging:
|
||||||
|
driver: "json-file"
|
||||||
|
options:
|
||||||
|
max-size: "100m"
|
||||||
|
max-file: "10"
|
||||||
depends_on:
|
depends_on:
|
||||||
db:
|
db:
|
||||||
condition: service_healthy
|
condition: service_healthy
|
||||||
|
@ -43,6 +48,11 @@ services:
|
||||||
- DATASTORE_READONLY_PASSWORD=${DATASTORE_READONLY_PASSWORD}
|
- DATASTORE_READONLY_PASSWORD=${DATASTORE_READONLY_PASSWORD}
|
||||||
- POSTGRES_PASSWORD=${POSTGRES_PASSWORD}
|
- POSTGRES_PASSWORD=${POSTGRES_PASSWORD}
|
||||||
- PGDATA=/var/lib/postgresql/data/db
|
- PGDATA=/var/lib/postgresql/data/db
|
||||||
|
logging:
|
||||||
|
driver: "json-file"
|
||||||
|
options:
|
||||||
|
max-size: "100m"
|
||||||
|
max-file: "10"
|
||||||
volumes:
|
volumes:
|
||||||
- pg_data:/var/lib/postgresql/data
|
- pg_data:/var/lib/postgresql/data
|
||||||
restart: unless-stopped
|
restart: unless-stopped
|
||||||
|
@ -52,6 +62,11 @@ services:
|
||||||
solr:
|
solr:
|
||||||
container_name: ${SOLR_CONTAINER_NAME}
|
container_name: ${SOLR_CONTAINER_NAME}
|
||||||
image: ckan/ckan-solr:${SOLR_IMAGE_VERSION}
|
image: ckan/ckan-solr:${SOLR_IMAGE_VERSION}
|
||||||
|
logging:
|
||||||
|
driver: "json-file"
|
||||||
|
options:
|
||||||
|
max-size: "100m"
|
||||||
|
max-file: "10"
|
||||||
volumes:
|
volumes:
|
||||||
- solr_data:/var/solr
|
- solr_data:/var/solr
|
||||||
restart: unless-stopped
|
restart: unless-stopped
|
||||||
|
@ -61,6 +76,11 @@ services:
|
||||||
redis:
|
redis:
|
||||||
container_name: ${REDIS_CONTAINER_NAME}
|
container_name: ${REDIS_CONTAINER_NAME}
|
||||||
image: redis:${REDIS_VERSION}
|
image: redis:${REDIS_VERSION}
|
||||||
|
logging:
|
||||||
|
driver: "json-file"
|
||||||
|
options:
|
||||||
|
max-size: "100m"
|
||||||
|
max-file: "10"
|
||||||
restart: unless-stopped
|
restart: unless-stopped
|
||||||
healthcheck:
|
healthcheck:
|
||||||
test: ["CMD", "redis-cli", "-e", "QUIT"]
|
test: ["CMD", "redis-cli", "-e", "QUIT"]
|
|
@ -15,6 +15,11 @@ services:
|
||||||
dockerfile: Dockerfile
|
dockerfile: Dockerfile
|
||||||
env_file:
|
env_file:
|
||||||
- .env
|
- .env
|
||||||
|
logging:
|
||||||
|
driver: "json-file"
|
||||||
|
options:
|
||||||
|
max-size: "100m"
|
||||||
|
max-file: "10"
|
||||||
depends_on:
|
depends_on:
|
||||||
ckan:
|
ckan:
|
||||||
condition: service_healthy
|
condition: service_healthy
|
||||||
|
@ -30,6 +35,11 @@ services:
|
||||||
image: ghcr.io/mjanez/ckan-spatial:master
|
image: ghcr.io/mjanez/ckan-spatial:master
|
||||||
env_file:
|
env_file:
|
||||||
- .env
|
- .env
|
||||||
|
logging:
|
||||||
|
driver: "json-file"
|
||||||
|
options:
|
||||||
|
max-size: "100m"
|
||||||
|
max-file: "10"
|
||||||
depends_on:
|
depends_on:
|
||||||
db:
|
db:
|
||||||
condition: service_healthy
|
condition: service_healthy
|
||||||
|
@ -56,6 +66,11 @@ services:
|
||||||
- DATASTORE_READONLY_PASSWORD=${DATASTORE_READONLY_PASSWORD}
|
- DATASTORE_READONLY_PASSWORD=${DATASTORE_READONLY_PASSWORD}
|
||||||
- POSTGRES_PASSWORD=${POSTGRES_PASSWORD}
|
- POSTGRES_PASSWORD=${POSTGRES_PASSWORD}
|
||||||
- PGDATA=/var/lib/postgresql/data/db
|
- PGDATA=/var/lib/postgresql/data/db
|
||||||
|
logging:
|
||||||
|
driver: "json-file"
|
||||||
|
options:
|
||||||
|
max-size: "100m"
|
||||||
|
max-file: "10"
|
||||||
volumes:
|
volumes:
|
||||||
- pg_data:/var/lib/postgresql/data
|
- pg_data:/var/lib/postgresql/data
|
||||||
restart: unless-stopped
|
restart: unless-stopped
|
||||||
|
@ -70,6 +85,11 @@ services:
|
||||||
image: ckan/ckan-solr:${SOLR_IMAGE_VERSION}
|
image: ckan/ckan-solr:${SOLR_IMAGE_VERSION}
|
||||||
env_file:
|
env_file:
|
||||||
- .env
|
- .env
|
||||||
|
logging:
|
||||||
|
driver: "json-file"
|
||||||
|
options:
|
||||||
|
max-size: "100m"
|
||||||
|
max-file: "10"
|
||||||
volumes:
|
volumes:
|
||||||
- solr_data:/var/solr
|
- solr_data:/var/solr
|
||||||
restart: unless-stopped
|
restart: unless-stopped
|
||||||
|
@ -79,6 +99,11 @@ services:
|
||||||
redis:
|
redis:
|
||||||
container_name: ${REDIS_CONTAINER_NAME}
|
container_name: ${REDIS_CONTAINER_NAME}
|
||||||
image: redis:${REDIS_VERSION}
|
image: redis:${REDIS_VERSION}
|
||||||
|
logging:
|
||||||
|
driver: "json-file"
|
||||||
|
options:
|
||||||
|
max-size: "100m"
|
||||||
|
max-file: "10"
|
||||||
restart: unless-stopped
|
restart: unless-stopped
|
||||||
healthcheck:
|
healthcheck:
|
||||||
test: ["CMD", "redis-cli", "-e", "QUIT"]
|
test: ["CMD", "redis-cli", "-e", "QUIT"]
|
||||||
|
|
|
@ -14,6 +14,11 @@ services:
|
||||||
dockerfile: Dockerfile
|
dockerfile: Dockerfile
|
||||||
env_file:
|
env_file:
|
||||||
- .env
|
- .env
|
||||||
|
logging:
|
||||||
|
driver: "json-file"
|
||||||
|
options:
|
||||||
|
max-size: "100m"
|
||||||
|
max-file: "10"
|
||||||
depends_on:
|
depends_on:
|
||||||
ckan:
|
ckan:
|
||||||
condition: service_healthy
|
condition: service_healthy
|
||||||
|
@ -23,12 +28,17 @@ services:
|
||||||
|
|
||||||
ckan:
|
ckan:
|
||||||
container_name: ${CKAN_CONTAINER_NAME}
|
container_name: ${CKAN_CONTAINER_NAME}
|
||||||
build:
|
# build:
|
||||||
context: ckan/
|
# context: ckan/
|
||||||
dockerfile: Dockerfile
|
# dockerfile: Dockerfile
|
||||||
image: ghcr.io/mjanez/ckan-spatial:master
|
image: ghcr.io/mjanez/ckan-spatial:master
|
||||||
env_file:
|
env_file:
|
||||||
- .env
|
- .env
|
||||||
|
logging:
|
||||||
|
driver: "json-file"
|
||||||
|
options:
|
||||||
|
max-size: "100m"
|
||||||
|
max-file: "10"
|
||||||
depends_on:
|
depends_on:
|
||||||
db:
|
db:
|
||||||
condition: service_healthy
|
condition: service_healthy
|
||||||
|
@ -51,6 +61,11 @@ services:
|
||||||
dockerfile: Dockerfile
|
dockerfile: Dockerfile
|
||||||
env_file:
|
env_file:
|
||||||
- .env
|
- .env
|
||||||
|
logging:
|
||||||
|
driver: "json-file"
|
||||||
|
options:
|
||||||
|
max-size: "100m"
|
||||||
|
max-file: "10"
|
||||||
depends_on:
|
depends_on:
|
||||||
ckan:
|
ckan:
|
||||||
condition: service_healthy
|
condition: service_healthy
|
||||||
|
@ -76,6 +91,11 @@ services:
|
||||||
- PGDATA=/var/lib/postgresql/data/db
|
- PGDATA=/var/lib/postgresql/data/db
|
||||||
volumes:
|
volumes:
|
||||||
- pg_data:/var/lib/postgresql/data
|
- pg_data:/var/lib/postgresql/data
|
||||||
|
logging:
|
||||||
|
driver: "json-file"
|
||||||
|
options:
|
||||||
|
max-size: "100m"
|
||||||
|
max-file: "10"
|
||||||
restart: unless-stopped
|
restart: unless-stopped
|
||||||
healthcheck:
|
healthcheck:
|
||||||
test: ["CMD", "pg_isready", "-U", "ckan"]
|
test: ["CMD", "pg_isready", "-U", "ckan"]
|
||||||
|
@ -88,6 +108,11 @@ services:
|
||||||
image: ckan/ckan-solr:${SOLR_IMAGE_VERSION}
|
image: ckan/ckan-solr:${SOLR_IMAGE_VERSION}
|
||||||
env_file:
|
env_file:
|
||||||
- .env
|
- .env
|
||||||
|
logging:
|
||||||
|
driver: "json-file"
|
||||||
|
options:
|
||||||
|
max-size: "100m"
|
||||||
|
max-file: "10"
|
||||||
volumes:
|
volumes:
|
||||||
- solr_data:/var/solr
|
- solr_data:/var/solr
|
||||||
restart: unless-stopped
|
restart: unless-stopped
|
||||||
|
@ -97,6 +122,11 @@ services:
|
||||||
redis:
|
redis:
|
||||||
container_name: ${REDIS_CONTAINER_NAME}
|
container_name: ${REDIS_CONTAINER_NAME}
|
||||||
image: redis:${REDIS_VERSION}
|
image: redis:${REDIS_VERSION}
|
||||||
|
logging:
|
||||||
|
driver: "json-file"
|
||||||
|
options:
|
||||||
|
max-size: "100m"
|
||||||
|
max-file: "10"
|
||||||
restart: unless-stopped
|
restart: unless-stopped
|
||||||
healthcheck:
|
healthcheck:
|
||||||
test: ["CMD", "redis-cli", "-e", "QUIT"]
|
test: ["CMD", "redis-cli", "-e", "QUIT"]
|
||||||
|
|
Loading…
Reference in New Issue