]> Untitled Git - lemmy.git/blob - docker-compose.yml
8607d546c0d47df13227d111e54533f91315ee6d
[lemmy.git] / docker-compose.yml
1 version: '2.4'
2
3 services:
4   db:
5     image: postgres:12-alpine
6     restart: always
7     environment:
8       POSTGRES_USER: rrr
9       POSTGRES_PASSWORD: rrr
10       POSTGRES_DB: rrr
11     volumes:
12       - db:/var/lib/postgresql/data
13     healthcheck:
14       test: ["CMD-SHELL", "pg_isready -U rrr"]
15       interval: 5s
16       timeout: 5s
17       retries: 20
18   lemmy:
19     build: 
20       context: .
21     ports:
22       - "8536:8536"
23     environment:
24       LEMMY_FRONT_END_DIR: /app/dist
25       DATABASE_URL: postgres://rrr:rrr@db:5432/rrr
26       JWT_SECRET: changeme
27       HOSTNAME: rrr
28     restart: always
29     depends_on: 
30       db: 
31         condition: service_healthy 
32 volumes:
33   db: