---
version: '3.1'
services:
  Bitwarden:
    image: vaultwarden/server:latest
    container_name: {{ name_docker }}
    hostname: {{ name_docker }}
    restart: always
    environment:
      - SIGNUPS_ALLOWED=true
      - ADMIN_TOKEN=fhBMPCHo0TUNDB
      - SHOW_PASSWORD_HINT=true
      - DOMAIN=https://password.{{ domaine_ext }}
      - SMTP_HOST=ssl0.ovh.net
      - SMTP_FROM=contact@{{ domaine_ext }}
      - SMTP_FROM_NAME=RedFrontier Password Manager (Bitwarden)
      - SMTP_SECURITY=force_tls
            # ("starttls", "force_tls", "off") Enable a secure connection. Default is "starttls" (Explicit - ports 587 or 25), "force_tls" (Implicit - port 465) or "off", no encryption (port 25)
      - SMTP_PORT=465
            # Ports 587 (submission) and 25 (smtp) are standard without encryption and with encryption via STARTTLS (Explicit TLS). Port 465 (submissions) is used for encrypted submission (Implicit TLS).
      - SMTP_USERNAME=contact@{{ domaine_ext }}
      - SMTP_PASSWORD=
      - SMTP_TIMEOUT=15
    ports:
      - 9091:80
      - 9092:3012
    volumes:
      - ./:/data