This repository has been archived on 2023-03-15. You can view files and clone it, but cannot push or open issues or pull requests.
infrastructure/app/deployment/plume.hcl

70 lines
1.4 KiB
HCL
Raw Normal View History

2020-09-21 14:29:49 +00:00
job "plume" {
datacenters = ["dc1"]
type = "service"
constraint {
attribute = "${attr.cpu.arch}"
value = "amd64"
}
group "plume" {
count = 1
2020-12-25 10:48:52 +00:00
network {
port "web_port" { }
}
2020-09-21 14:29:49 +00:00
task "plume" {
driver = "docker"
config {
2020-10-19 18:27:54 +00:00
image = "superboum/plume:v1"
network_mode = "host"
2020-12-25 10:48:52 +00:00
ports = [ "web_port" ]
2020-09-21 14:29:49 +00:00
#command = "cat"
#args = [ "/dev/stdout" ]
volumes = [
"/mnt/glusterfs/plume/media:/app/static/media",
"/mnt/glusterfs/plume/search:/app/search_index"
]
}
template {
2020-12-25 10:48:52 +00:00
data = file("../config/configuration/plume/app.env")
2020-09-21 14:29:49 +00:00
destination = "secrets/app.env"
env = true
}
resources {
memory = 100
cpu = 100
}
service {
name = "plume"
tags = [
"plume",
"traefik.enable=true",
"traefik.frontend.entryPoints=https,http",
"traefik.frontend.rule=Host:plume.deuxfleurs.fr",
]
2020-12-25 10:48:52 +00:00
port = "web_port"
address_mode = "host"
2020-09-21 14:29:49 +00:00
check {
2020-12-28 09:49:09 +00:00
type = "http"
protocol = "http"
2020-12-25 10:48:52 +00:00
port = "web_port"
2020-12-28 09:49:09 +00:00
path = "/"
2020-09-21 14:29:49 +00:00
interval = "60s"
timeout = "5s"
check_restart {
limit = 3
grace = "600s"
ignore_warnings = false
}
}
}
}
}
}