add postgres service configuration to docker-compose.yml
All checks were successful
Portainer Stack Update / update_stack (push) Successful in 27s
All checks were successful
Portainer Stack Update / update_stack (push) Successful in 27s
This commit is contained in:
parent
344deeb9fa
commit
7c153f61f6
@ -50,6 +50,46 @@ services:
|
|||||||
|
|
||||||
#mariaDb MaxScale -https://hub.docker.com/r/mariadb/maxscale
|
#mariaDb MaxScale -https://hub.docker.com/r/mariadb/maxscale
|
||||||
|
|
||||||
|
postgres:
|
||||||
|
image: ghcr.io/immich-app/postgres:15-vectorchord0.4.2-pgvectors0.3.0
|
||||||
|
networks:
|
||||||
|
- database
|
||||||
|
environment:
|
||||||
|
POSTGRES_PASSWORD_FILE: /run/secrets/postgres_password
|
||||||
|
POSTGRES_INITDB_ARGS: '--data-checksums'
|
||||||
|
TZ: Europe/Berlin
|
||||||
|
secrets:
|
||||||
|
- postgres_password
|
||||||
|
volumes:
|
||||||
|
- postgres:/var/lib/postgresql/data
|
||||||
|
- type: tmpfs
|
||||||
|
target: /dev/shm
|
||||||
|
tmpfs:
|
||||||
|
size: 134217728
|
||||||
|
deploy:
|
||||||
|
mode: replicated
|
||||||
|
replicas: 1
|
||||||
|
restart_policy:
|
||||||
|
condition: any
|
||||||
|
update_config:
|
||||||
|
parallelism: 1
|
||||||
|
delay: 5s
|
||||||
|
order: stop-first
|
||||||
|
failure_action: rollback
|
||||||
|
rollback_config:
|
||||||
|
order: stop-first
|
||||||
|
resources:
|
||||||
|
limits:
|
||||||
|
memory: 2G
|
||||||
|
cpus: '2'
|
||||||
|
reservations:
|
||||||
|
memory: 1G
|
||||||
|
cpus: '1'
|
||||||
|
placement:
|
||||||
|
constraints:
|
||||||
|
- node.labels.postgres == true
|
||||||
|
|
||||||
|
|
||||||
adminer:
|
adminer:
|
||||||
image: adminer:5.2.1-standalone
|
image: adminer:5.2.1-standalone
|
||||||
networks:
|
networks:
|
||||||
@ -88,3 +128,11 @@ volumes:
|
|||||||
mariadb:
|
mariadb:
|
||||||
name: mariadb
|
name: mariadb
|
||||||
driver: local
|
driver: local
|
||||||
|
postgres:
|
||||||
|
name: postgres
|
||||||
|
driver: local
|
||||||
|
|
||||||
|
secrets:
|
||||||
|
postgres_password:
|
||||||
|
name: postgres-password
|
||||||
|
external: true
|
||||||
Loading…
x
Reference in New Issue
Block a user