# THIS IS A DEVELOPER CONFIGURATION FILE
# IT IS NOT AN EXAMPLE OF SOMETHING YOU DEPLOY
# I ONLY USE IT FOR DEVELOPING HEADPLANE

networks:
  headplane-dev:
    name: "headplane-dev"
    driver: "bridge"
services:
  caddy:
    image: "caddy:2"
    container_name: "headplane-caddy"
    restart: "unless-stopped"
    depends_on:
      - "headscale"
    networks:
      - "headplane-dev"
    ports:
      - "80:80"
      - "443:443"
    volumes:
      - "./Caddyfile:/etc/caddy/Caddyfile"
      - "./test/caddy/data:/data"
      - "./test/caddy/config:/config"
      - "./test/caddy/certs:/certs"
  headscale:
    image: "headscale/headscale:0.27.0-debug"
    container_name: "headscale"
    labels:
      me.tale.headplane.target: headscale
    restart: "unless-stopped"
    command: "serve"
    networks:
      - "headplane-dev"
    volumes:
      - "./.cache/headscale:/var/lib/headscale"
      - "./test:/etc/headscale"
    ports:
      - "8080:8080"
      - "9090:9090"
    environment:
      TZ: "America/New_York"
