Postgres db macro
Some checks failed
continuous-integration/drone/push Build is failing

This commit is contained in:
2024-02-05 18:44:13 +01:00
parent f353f67150
commit e8bbb4b167
9 changed files with 86 additions and 191 deletions

View File

@ -1,3 +1,4 @@
{% import 'macro/postgres.j2' as pg with context %}
---
version: '3'
services:
@ -29,25 +30,14 @@ services:
- backend
- default
db:
image: postgres:15-alpine
restart: unless-stopped
environment:
- POSTGRES_USER={{ wallabag.db.user }}
- POSTGRES_PASSWORD={{ wallabag.db.password }}
volumes:
- database:/var/lib/postgresql/data
healthcheck:
test: ["CMD", "pg_isready", "-U", "{{ wallabag.db.user }}"]
interval: 10s
start_period: 30s
networks:
- backend
{{ pg.postgres("db", wallabag.db.user, wallabag.db.password, wallabag.db.user, ["backend"], version="15-alpine") }}
volumes:
database:
db_data:
networks:
backend:
internal: true
postgres:
internal: true
...