45 lines
821 B
HCL
45 lines
821 B
HCL
job "nginx-karting" {
|
|
datacenters = ["aperture"]
|
|
|
|
type = "service"
|
|
|
|
group "karting-web" {
|
|
count = 1
|
|
|
|
network {
|
|
port "http" {
|
|
to = "80"
|
|
}
|
|
|
|
port "https" {
|
|
to = "443"
|
|
}
|
|
}
|
|
|
|
service {
|
|
port = "http"
|
|
|
|
check {
|
|
type = "http"
|
|
path = "/"
|
|
interval = "10s"
|
|
timeout = "2s"
|
|
}
|
|
tags = [
|
|
"traefik.enable=true",
|
|
"traefik.http.routers.nginx-karting.rule=Host(`dcukartingsociety.ie`)",
|
|
"traefik.http.routers.nginx-karting.entrypoints=web,websecure",
|
|
"traefik.http.routers.nginx-karting.tls.certresolver=lets-encrypt"
|
|
]
|
|
}
|
|
|
|
task "webserver" {
|
|
driver = "docker"
|
|
|
|
config {
|
|
image = "ghcr.io/redbrick/karting"
|
|
ports = ["http", "https"]
|
|
}
|
|
}
|
|
}
|
|
}
|