File: docker-compose.yml

package info (click to toggle)
pg-auto-failover 2.2-3
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 5,368 kB
  • sloc: ansic: 58,369; python: 5,515; sql: 3,177; makefile: 629; sh: 35
file content (68 lines) | stat: -rw-r--r-- 1,880 bytes parent folder | download | duplicates (2)
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
65
66
67
68
services:
  monitor:
    build: .
    environment:
      PGDATA: /tmp/pgdata
      PG_AUTOCTL_DEBUG: 1
    command: pg_autoctl create monitor --ssl-self-signed --auth trust --run
    expose:
      - 5432
    container_name: monitor
  node1:
    build: .
    environment:
      PGDATA: /var/lib/postgres/data
      PGPORT: 5433
      PG_AUTOCTL_MONITOR: "postgresql://autoctl_node@monitor:5432/pg_auto_failover"
      HOSTNAME: "node1.tablespaces_default"
    command: pg_autoctl create postgres --ssl-self-signed --auth trust --pg-hba-lan --run
    expose:
      - 5433
    links:
      - monitor
    container_name: node1
    volumes:
      - node1-volume:/var/lib/postgres:rw
      - node1-a-volume:/extra_volumes/extended_a:rw
      - node1-b-volume:/extra_volumes/extended_b:rw
      - node1-c-volume:/extra_volumes/extended_c:rw
  node2:
    build: .
    environment:
      PGDATA: /var/lib/postgres/data
      PGPORT: 5434
      PG_AUTOCTL_MONITOR: "postgresql://autoctl_node@monitor:5432/pg_auto_failover"
      HOSTNAME: "node2.tablespaces_default"
    command: pg_autoctl create postgres --ssl-self-signed --auth trust --pg-hba-lan --run
    expose:
      - 5433
    links:
      - monitor
    container_name: node2
    volumes:
      - node2-volume:/var/lib/postgres:rw
      - node2-a-volume:/extra_volumes/extended_a:rw
      - node2-b-volume:/extra_volumes/extended_b:rw
      - node2-c-volume:/extra_volumes/extended_c:rw
  test:
    build:
      context: .
      target: test
    environment:
      TEST_NUM:
    command: [
    "make", "-C", "/usr/src/pg_auto_failover", "test", "TEST=tablespaces/test_tablespaces_$${TEST_NUM}"
    ]
    container_name: pg_auto_failover_tablespaces_test
    links:
      - monitor

volumes:
  node1-volume:
  node1-a-volume:
  node1-b-volume:
  node1-c-volume:
  node2-volume:
  node2-a-volume:
  node2-b-volume:
  node2-c-volume: