services: # https://docker-mailserver.github.io/docker-mailserver/latest/
  mailserver:
    image: ghcr.io/docker-mailserver/docker-mailserver:latest
    container_name: mailserver
    hostname: mail.secretbee.buzz
    env_file: mailserver.env
    ports:
      - "25:25"
      - "143:143"
      - "465:465"
      - "587:587"
      - "993:993"
    volumes:
      - /opt/beeserver/mail/mail-data/:/var/mail/
      - /opt/beeserver/mail/mail-state/:/var/mail-state/
      - /opt/beeserver/mail/mail-logs/:/var/log/mail/
      - /opt/beeserver/mail/config/:/tmp/docker-mailserver/
      - /etc/localtime:/etc/localtime:ro
      - /etc/letsencrypt:/etc/letsencrypt
    restart: always
    stop_grace_period: 1m
    cap_add:
      - NET_ADMIN
