services:
  enclosed:
    image: corentinth/enclosed
    #ports:
    #  - 8787:8787
    volumes:
      - /home/ubuntu/docker/enclosed:/app/.data
    restart: unless-stopped
    networks:
      - proxy
    labels:
      - "traefik.enable=true"
      - "traefik.docker.network=proxy"
      - "traefik.http.routers.enclosed.entrypoints=http"
      - "traefik.http.routers.enclosed.rule=Host(`enclosed.jimsgarage.co.uk`)"
      - "traefik.http.middlewares.enclosed-https-redirect.redirectscheme.scheme=https"
      - "traefik.http.routers.enclosed.middlewares=enclosed-https-redirect"
      - "traefik.http.routers.enclosed-secure.entrypoints=https"
      - "traefik.http.routers.enclosed-secure.rule=Host(`enclosed.jimsgarage.co.uk`)"
      - "traefik.http.routers.enclosed-secure.tls=true"
      - "traefik.http.routers.enclosed-secure.tls.certresolver=cloudflare"
      - "traefik.http.routers.enclosed-secure.service=enclosed"
      - "traefik.http.services.enclosed.loadbalancer.server.port=8787"

networks:
  proxy:
    external: true