networks:
  vpn:
    external: true

services:
    nginx-mailcow:
      container_name: mailcow
      networks:
        vpn:
          ipv4_address: IPADDRESSHERE
      #labels:
        #traefik.enable: true
        #traefik.http.routers.moo.rule: Host(`${MAILCOW_HOSTNAME}`)
        #traefik.http.routers.moo.tls: true
        #traefik.http.routers.moo.tls.certresolver: production
        #traefik.http.services.moo.loadbalancer.server.port: PORT1
        #traefik.http.routers.moo.entrypoints: websecure
        #traefik.docker.network: DOCKERNETWORKHERE
        #traefik.http.routers.moo.middlewares:
    healthcheck:
      disable: false #HEALTHCHECKHERE

    certdumper:
      image: humenius/traefik-certs-dumper
      command: --restart-containers ${COMPOSE_PROJECT_NAME}-postfix-mailcow-1,${COMPOSE_PROJECT_NAME}-nginx-mailcow-1,${COMPOSE_PROJECT_NAME}-dovecot-mailcow-1
        #network_mode: none
      volumes:
          - /var/run/docker.sock:/var/run/docker.sock:ro #SOCKETHERE
          - /docker/containers/traefik/etc/certs:/traefik:ro
          - ./data/assets/ssl/:/output:rw
      restart: always
      environment:
          # only change this, if you're using another domain for mailcow's web frontend compared to the standard config
          - DOMAIN=${MAILCOW_HOSTNAME}
