docker-compose.yml 1.79 KB
Newer Older
1
version: "3.7"
2
3
4

volumes:
  lufidb-data:
5
    name: lufidb-data
6
  lufi-files:
7
    name: lufi-files
8
9
  lufi-data:
    name: lufi-data
10

11
networks:
12
  proxy:
13
14
    external: true
  lufi:
Paco's avatar
Paco committed
15
    name: lufi
16

Romain de Laage's avatar
Romain de Laage committed
17
18
services:
  lufi:
19
    image: registry.picasoft.net/lufi:fix-mail-0.05.15
20
    build: .
Romain de Laage's avatar
Romain de Laage committed
21
22
23
24
    container_name: lufi
    depends_on:
      - lufidb
    volumes:
25
26
      - lufi-data:/lufi/data
      - lufi-files:/lufi/files
27
28
      - ./lufi.conf:/lufi/lufi.conf
    networks:
29
      - proxy
30
      - lufi
31
    labels:
32
33
34
      traefik.http.routers.lufi.entrypoints: websecure
      traefik.http.routers.lufi.rule: Host(`drop.picasoft.net`)
      traefik.http.services.lufi.loadbalancer.server.port: 8081
35
      traefik.enable: true
36
37
38
    env_file:
      - ./secrets/lufi.secrets
      - ./secrets/lufidb.secrets
39
    restart: unless-stopped
40

Quentin Duchemin's avatar
Quentin Duchemin committed
41
42
43
  lufidb:
    image: postgres:12
    container_name: lufidb
44
    env_file: ./secrets/lufidb.secrets
Quentin Duchemin's avatar
Quentin Duchemin committed
45
46
    volumes:
      - lufidb-data:/var/lib/postgresql/data
47
48
49
    networks:
      - lufi
    restart: unless-stopped
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69

  lufi-exporter:
    image: registry.picasoft.net/pica-lufi-exporter:0.1.0
    build: ./prometheus-exporter
    container_name: lufi-exporter
    volumes:
      - /etc/localtime:/etc/localtime:ro
    env_file: ./secrets/lufi-exporter.secrets
    networks:
      - lufi
      - proxy
    labels:
      traefik.http.routers.lufi-metrics.entrypoints: websecure
      traefik.http.routers.lufi-metrics.rule: "Host(`drop.picasoft.net`) && PathPrefix(`/metrics`)"
      traefik.http.routers.lufi-metrics.service: lufi-metrics
      traefik.http.routers.lufi-metrics.middlewares: "lufi-metrics-auth@docker"
      traefik.http.middlewares.lufi-metrics-auth.basicauth.users: "${METRICS_AUTH}"
      traefik.http.services.lufi-metrics.loadbalancer.server.port: 8000
      traefik.enable: true
    restart: unless-stopped