docker-compose.yml
Raw
version: "3.8"
services:
db:
env_file: "vars.env"
image: postgres
container_name: local_pgdb
restart: always
environment:
POSTGRES_USER: ${DB_USERNAME}
POSTGRES_PASSWORD: ${DB_PASSWORD}
volumes:
- local_pgdata:/var/lib/postgresql/data
networks:
pg-net:
aliases: []
pgadmin:
env_file: "vars.env"
image: dpage/pgadmin4
container_name: pgadmin4_container
restart: always
environment:
PGADMIN_DEFAULT_EMAIL: ${PG_EMAIL}
PGADMIN_DEFAULT_PASSWORD: ${PG_PASSWORD}
volumes:
- pgadmin-data:/var/lib/pgadmin
networks:
pg-net:
aliases: []
pgcloudflare:
image: cloudflare/cloudflared
command: tunnel --no-autoupdate run
environment:
- TUNNEL_TOKEN=${CF_TOKEN}
networks:
pg-net:
aliases: []
volumes:
local_pgdata:
pgadmin-data:
networks:
pg-net:
driver: "bridge"
1 | version: "3.8" |
2 | services: |
3 | db: |
4 | env_file: "vars.env" |
5 | image: postgres |
6 | container_name: local_pgdb |
7 | restart: always |
8 | environment: |
9 | POSTGRES_USER: ${DB_USERNAME} |
10 | POSTGRES_PASSWORD: ${DB_PASSWORD} |
11 | volumes: |
12 | - local_pgdata:/var/lib/postgresql/data |
13 | networks: |
14 | pg-net: |
15 | aliases: [] |
16 | |
17 | pgadmin: |
18 | env_file: "vars.env" |
19 | image: dpage/pgadmin4 |
20 | container_name: pgadmin4_container |
21 | restart: always |
22 | environment: |
23 | PGADMIN_DEFAULT_EMAIL: ${PG_EMAIL} |
24 | PGADMIN_DEFAULT_PASSWORD: ${PG_PASSWORD} |
25 | volumes: |
26 | - pgadmin-data:/var/lib/pgadmin |
27 | networks: |
28 | pg-net: |
29 | aliases: [] |
30 | |
31 | pgcloudflare: |
32 | image: cloudflare/cloudflared |
33 | command: tunnel --no-autoupdate run |
34 | environment: |
35 | - TUNNEL_TOKEN=${CF_TOKEN} |
36 | networks: |
37 | pg-net: |
38 | aliases: [] |
39 | |
40 | volumes: |
41 | local_pgdata: |
42 | pgadmin-data: |
43 | |
44 | networks: |
45 | pg-net: |
46 | driver: "bridge" |