aboutsummaryrefslogtreecommitdiff
path: root/docker/compose/local-sync-mount-compose.yml
blob: 0ce1fdeda84a20af72905f900021d20b49364e7e (plain)
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
version: '3.9'
services:
  node1:
    image: chrislusf/seaweedfs:local
    command: "server -master -volume -filer"
    ports:
      - 8888:8888
      - 18888:18888
    healthcheck:
      test: [ "CMD", "curl", "--fail", "-I", "http://localhost:9333/cluster/healthz" ]
      interval: 1s
      start_period: 10s
      timeout: 30s
  mount1:
    image: chrislusf/seaweedfs:local
    privileged: true
    command: "mount -filer=node1:8888 -dir=/mnt -dirAutoCreate"
    healthcheck:
      test: [ "CMD", "curl", "--fail", "-I", "http://node1:8888/" ]
      interval: 1s
      start_period: 10s
      timeout: 30s
    depends_on:
      node1:
        condition: service_healthy
  node2:
    image: chrislusf/seaweedfs:local
    ports:
      - 7888:8888
      - 17888:18888
    command: "server -master -volume -filer"
    healthcheck:
      test: [ "CMD", "curl", "--fail", "-I", "http://localhost:9333/cluster/healthz" ]
      interval: 1s
      start_period: 10s
      timeout: 30s
  mount2:
    image: chrislusf/seaweedfs:local
    privileged: true
    command: "mount -filer=node2:8888 -dir=/mnt -dirAutoCreate"
    healthcheck:
      test: [ "CMD", "curl", "--fail", "-I", "http://node2:8888/" ]
      interval: 1s
      start_period: 10s
      timeout: 30s
    depends_on:
      node2:
        condition: service_healthy
  sync:
    image: chrislusf/seaweedfs:local
    command: "-v=4 filer.sync -a=node1:8888 -b=node2:8888 -a.debug -b.debug"
    depends_on:
      mount1:
        condition: service_healthy
      mount2:
        condition: service_healthy