version: "3.3"

services:
  mautrix-signal:
    container_name: mautrix-signal
    image: dock.mau.dev/tulir/mautrix-signal
    restart: unless-stopped
    volumes:
    - /home/icke/mautrix-signal/bridge:/data
    - /home/icke/mautrix-signal/signald:/signald
    depends_on:
    - signald
    networks:
      matrix:
        ipv4_address: 172.25.0.2
  
  signald:
    container_name: signald
    image: docker.io/finn/signald
    restart: unless-stopped
    volumes: 
    - /home/icke/mautrix-signal/signald:/signald
    networks:
      matrix:
        ipv4_address: 172.25.0.3
  db:
    container_name: postgre_signal
    image: postgres:13-alpine
    restart: unless-stopped
    environment:
      POSTGRES_USER: mautrixsignal
      POSTGRES_DATABASE: mautrixsignal
      POSTGRES_PASSWORD: eccmts42*
    volumes:
    - /home/icke/mautrix-signal/db:/var/lib/postgresql/data
    networks:
      matrix:
        ipv4_address: 172.25.0.4

networks:
  matrix:
    driver: bridge
    ipam:
     config:
       - subnet: 172.25.0.0/28

