File size: 1,422 Bytes
3206347
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
version: '3.9'

services:
  app:
    build:
      context: ..
      dockerfile: .devcontainer/Dockerfile
    volumes:
      - ..:/workspace:cached
    command: sleep infinity
  postgres:
    image: 'postgres:14.5-alpine'
    environment:
      - POSTGRES_DB=automatisch
      - POSTGRES_USER=automatisch_user
      - POSTGRES_PASSWORD=automatisch_password
    volumes:
      - postgres_data:/var/lib/postgresql/data
    healthcheck:
      test: ['CMD-SHELL', 'pg_isready -U $${POSTGRES_USER} -d $${POSTGRES_DB}']
      interval: 10s
      timeout: 5s
      retries: 5
    ports:
      - '5432:5432'
    expose:
      - 5432
  redis:
    image: 'redis:7.0.4-alpine'
    volumes:
      - redis_data:/data
    ports:
      - '6379:6379'
    expose:
      - 6379
  keycloak:
    image: quay.io/keycloak/keycloak:21.1
    restart: always
    environment:
      - KEYCLOAK_ADMIN=admin
      - KEYCLOAK_ADMIN_PASSWORD=admin
      - KC_DB=postgres
      - KC_DB_URL_HOST=postgres
      - KC_DB_URL_DATABASE=keycloak
      - KC_DB_USERNAME=automatisch_user
      - KC_DB_PASSWORD=automatisch_password
      - KC_HEALTH_ENABLED=true
    ports:
      - "8080:8080"
    command: start-dev
    depends_on:
      - postgres
    healthcheck:
      test: "curl -f http://localhost:8080/health/ready || exit 1"
    volumes:
      - keycloak:/opt/keycloak/data/
    expose:
      - 8080

volumes:
  postgres_data:
  redis_data:
  keycloak: