Merge pull request #6 from redbrick/add_nova_timetable
Add job for a nova-timetable user project
This commit is contained in:
commit
4108c27db1
2 changed files with 42 additions and 1 deletions
|
@ -24,7 +24,7 @@ job "traefik" {
|
||||||
task "traefik" {
|
task "traefik" {
|
||||||
driver = "docker"
|
driver = "docker"
|
||||||
config {
|
config {
|
||||||
image = "traefik:2.8"
|
image = "traefik"
|
||||||
network_mode = "host"
|
network_mode = "host"
|
||||||
|
|
||||||
volumes = [
|
volumes = [
|
||||||
|
|
41
jobs/user-projects/general/nova-timetable.hcl
Normal file
41
jobs/user-projects/general/nova-timetable.hcl
Normal file
|
@ -0,0 +1,41 @@
|
||||||
|
job "nova-timetable" {
|
||||||
|
datacenters = ["aperture"]
|
||||||
|
|
||||||
|
type = "service"
|
||||||
|
|
||||||
|
group "nova-timetable" {
|
||||||
|
count = 1
|
||||||
|
|
||||||
|
network {
|
||||||
|
port "http" {
|
||||||
|
to = 80
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
service {
|
||||||
|
port = "http"
|
||||||
|
name = "nova-timetable"
|
||||||
|
check {
|
||||||
|
type = "http"
|
||||||
|
path = "/healthcheck"
|
||||||
|
interval = "10s"
|
||||||
|
timeout = "2s"
|
||||||
|
}
|
||||||
|
|
||||||
|
tags = [
|
||||||
|
"traefik.enable=true",
|
||||||
|
"traefik.http.routers.nova-timetable.rule=Host(`timetable.redbrick.dcu.ie`)",
|
||||||
|
"traefik.http.routers.nova-timetable.entrypoints=web,websecure",
|
||||||
|
"traefik.http.routers.nova-timetable.tls.certresolver=lets-encrypt",
|
||||||
|
]
|
||||||
|
}
|
||||||
|
|
||||||
|
task "python-application" {
|
||||||
|
driver = "docker"
|
||||||
|
config {
|
||||||
|
image = "novanai/timetable-sync"
|
||||||
|
ports = ["http"]
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
Loading…
Reference in a new issue