Split postgres, default sqlite
This commit is contained in:
@ -33,3 +33,6 @@ COMPOSE_FILE="compose.yml"
|
||||
#GRIST_OIDC_IDP_SKIP_END_SESSION_ENDPOINT
|
||||
#GRIST_OIDC_SP_PROFILE_NAME_ATTR
|
||||
#GRIST_OIDC_SP_PROFILE_EMAIL_ATTR
|
||||
|
||||
# Postgres DB instead of SQLite (beware performance issues)
|
||||
#COMPOSE_FILE="$COMPOSE_FILE:compose.oidc.yml"
|
||||
|
33
compose.postgres.yml
Normal file
33
compose.postgres.yml
Normal file
@ -0,0 +1,33 @@
|
||||
services:
|
||||
app:
|
||||
environment:
|
||||
- TYPEORM_DATABASE=grist
|
||||
- TYPEORM_TYPE=postgres
|
||||
- TYPEORM_USERNAME=grist
|
||||
- TYPEORM_PASSWORD_FILE=/run/secrets/db_password
|
||||
- TYPEORM_HOST=db
|
||||
depends_on:
|
||||
- db
|
||||
secrets:
|
||||
- db_password
|
||||
|
||||
db:
|
||||
image: postgres:13
|
||||
networks:
|
||||
- internal
|
||||
secrets:
|
||||
- db_password
|
||||
volumes:
|
||||
- 'postgresql_data:/var/lib/postgresql/data'
|
||||
environment:
|
||||
- POSTGRES_USER=grist
|
||||
- POSTGRES_DB=grist
|
||||
- POSTGRES_PASSWORD_FILE=/run/secrets/db_password
|
||||
|
||||
secrets:
|
||||
db_password:
|
||||
external: true
|
||||
name: ${STACK_NAME}_db_password_${SECRET_DB_PASSWORD_VERSION}
|
||||
|
||||
volumes:
|
||||
postgresql_data:
|
22
compose.yml
22
compose.yml
@ -5,11 +5,6 @@ services:
|
||||
- proxy
|
||||
- internal
|
||||
environment:
|
||||
- TYPEORM_DATABASE=grist
|
||||
- TYPEORM_TYPE=postgres
|
||||
- TYPEORM_USERNAME=grist
|
||||
- TYPEORM_PASSWORD_FILE=/run/secrets/db_password
|
||||
- TYPEORM_HOST=db
|
||||
- REDIS_URL=redis://${STACK_NAME}_redis:6379
|
||||
- GRIST_SUPPORT_ANON
|
||||
- GRIST_SESSION_SECRET_FILE=/run/secrets/session_secret
|
||||
@ -24,7 +19,6 @@ services:
|
||||
- GRIST_DEFAULT_EMAIL
|
||||
secrets:
|
||||
- session_secret
|
||||
- db_password
|
||||
configs:
|
||||
- source: entrypoint_conf
|
||||
target: /docker-entrypoint.sh
|
||||
@ -33,7 +27,6 @@ services:
|
||||
volumes:
|
||||
- grist_data:/persist
|
||||
depends_on:
|
||||
- db
|
||||
- redis
|
||||
deploy:
|
||||
labels:
|
||||
@ -47,19 +40,6 @@ services:
|
||||
- "caddy.tls.on_demand="
|
||||
- "coop-cloud.${STACK_NAME}.version=1.0.2+1.1.14"
|
||||
|
||||
db:
|
||||
image: postgres:13
|
||||
networks:
|
||||
- internal
|
||||
secrets:
|
||||
- db_password
|
||||
volumes:
|
||||
- 'postgresql_data:/var/lib/postgresql/data'
|
||||
environment:
|
||||
- POSTGRES_USER=grist
|
||||
- POSTGRES_DB=grist
|
||||
- POSTGRES_PASSWORD_FILE=/run/secrets/db_password
|
||||
|
||||
redis:
|
||||
image: redis:7.2-alpine
|
||||
networks:
|
||||
@ -76,11 +56,9 @@ secrets:
|
||||
name: ${STACK_NAME}_session_secret_${SECRET_GRIST_SESSION_SECRET_VERSION}
|
||||
|
||||
volumes:
|
||||
postgresql_data:
|
||||
redis_data:
|
||||
grist_data:
|
||||
|
||||
|
||||
networks:
|
||||
proxy:
|
||||
external: true
|
||||
|
Reference in New Issue
Block a user