homelab/nomad-job/chainetv.nomad

50 lines
1.3 KiB
Plaintext
Raw Normal View History

2022-05-10 08:34:43 +00:00
job "chainetv" {
datacenters = ["homelab"]
type = "service"
meta {
2022-05-19 18:06:12 +00:00
forcedeploy = "2"
2022-05-10 08:34:43 +00:00
}
group "chainetv"{
network {
mode = "host"
port "http" {
to = 5000
}
}
2022-05-12 09:36:51 +00:00
task "chainetv" {
2022-05-10 08:34:43 +00:00
driver = "docker"
service {
name = "chainetv"
port = "http"
tags = [
2022-05-23 19:44:34 +00:00
"homer.enable=true",
"homer.name=ChaineTV",
"homer.service=Application",
"homer.icon=fas fa-tv",
"homer.target=_blank",
"homer.url=https://www.ducamps.win/${NOMAD_JOB_NAME}",
2022-05-10 08:34:43 +00:00
"traefik.enable=true",
2022-05-12 09:36:51 +00:00
"traefik.http.routers.${NOMAD_JOB_NAME}.rule=Host(`www.ducamps.win`)&&PathPrefix(`/chainetv`)",
"traefik.http.routers.${NOMAD_JOB_NAME}.tls.domains[0].sans=www.ducamps.win",
2022-05-10 08:34:43 +00:00
"traefik.http.routers.${NOMAD_JOB_NAME}.tls.certresolver=myresolver",
"traefik.http.routers.${NOMAD_JOB_NAME}.middlewares=chainetv,chainetvStrip",
"traefik.http.middlewares.chainetv.headers.customrequestheaders.X-Script-Name=/chainetv",
"traefik.http.middlewares.chainetvStrip.stripprefix.prefixes=/chainetv",
]
}
config {
2022-05-10 09:24:26 +00:00
image = "ducampsv/chainetv:latest"
2022-05-10 08:34:43 +00:00
ports = ["http"]
}
2022-05-12 09:36:04 +00:00
resources {
memory = 200
}
2022-05-10 08:34:43 +00:00
}
}
}