job "traefik-local" { datacenters = ["homelab"] type = "service" group "traefik-local" { network { mode = "host" port "http" { static = 80 } port "https" { static = 443 } port "ssh" { static = 2222 } port "admin" { static = 9080 } } vault{ policies=["access-tables"] } task "server" { driver = "docker" service { name = "traefik-local" tags = ["traefik"] port = "https" } service { name = "traefi-local-admin" port = "admin" tags = [ "traefik.enable=true", "traefik.http.routers.${NOMAD_JOB_NAME}_insecure.rule=Host(`${NOMAD_JOB_NAME}.ducamps.win`)", "traefik.http.routers.${NOMAD_JOB_NAME}.tls.domains[0].sans=${NOMAD_JOB_NAME}.ducamps.win", ] } config { image = "traefik" ports = [ "http", "https", "admin", "ssh" ] volumes =[ "local/traefik.toml:/etc/traefik/traefik.toml", "/mnt/diskstation/nomad/traefik/acme-local.json:/acme.json" ] } # vault{ #} env { } template{ data=<