summaryrefslogtreecommitdiff
path: root/sandcastle/docker-compose.yml
blob: c04962ed5d713b63ad9fdf96227495a32a68203b (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
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
version: '3' # it's a constant

volumes:
  talerdata:
  talerlogs:

services:
  talerdb:
    build: ./images/postgres
    image: sandcastle_talerdb
    ports:
      - ${TALER_DB_PORT}:5432
    volumes:
      - talerlogs:/logs
      - talerdata:/var/lib/postgresql/data/
      - ${TALER_SANDCASTLE_CONFIG:-./config}:/config:ro
    environment:
      # root is the only role existing in the DBMS.  That
      # matches the role used by other containers when
      # they connect to the database.
      POSTGRES_USER: root
      # this changes to the password used by other
      # containers to connect here.  This definition
      # only makes the init logic happy.
      POSTGRES_PASSWORD: nonce
      POSTGRES_HOST_AUTH_METHOD: scram-sha-256
      # the final "/postgresql" is used to create
      # a "postgresql" subfolder in the data volume.
      PGDATA: /var/lib/postgresql/data/postgresql
    restart: always

  exchange:
    build: ./images/exchange
    image: sandcastle_exchange
    depends_on:
      - talerdb
    ports:
      - ${TALER_EXCHANGE_PORT}:80
    volumes:
      - talerlogs:/logs
      - talerdata:/data
      - ${TALER_SANDCASTLE_CONFIG:-./config}:/config:ro
    restart: always

  merchant:
    build: ./images/merchant
    image: sandcastle_merchant
    depends_on:
      - talerdb
    ports:
      - ${TALER_MERCHANT_PORT}:80 # backend
      - ${TALER_BLOG_PORT}:8080 # blog
      - ${TALER_DONATIONS_PORT}:8081 # donations
      - ${TALER_SURVEY_PORT}:8082 # survey
      - ${TALER_LANDING_PORT}:8083 # landing
      - ${TALER_SYNC_PORT}:8084 # sync
    volumes:
      - talerlogs:/logs
      - ${TALER_SANDCASTLE_CONFIG:-./config}:/config:ro
    # uwsgi allocates memory based on available file descriptors, so be
    # conservative here
    ulimits:
      nproc: 5000
      nofile:
        soft: 2000
        hard: 4000
    restart: always

  bank:
    build: ./images/libeufin
    ports:
      - ${LIBEUFIN_SANDBOX_PORT}:15000 # Sandbox
      - ${LIBEUFIN_NEXUS_PORT}:15001 # Nexus
      - ${LIBEUFIN_FRONTEND_PORT}:80 # Nginx serving the SPA
    volumes:
      - talerlogs:/logs
      - talerdata:/data
      - ${TALER_SANDCASTLE_CONFIG:-./config}:/config:ro
    restart: always