Files
alo-cluster/services/igsync.hcl
2025-04-21 20:28:54 +01:00

57 lines
910 B
HCL

job "igsync" {
datacenters = ["alo"]
type = "batch"
periodic {
crons = [ "*/5 * * * *" ]
prohibit_overlap = true
}
group "cron" {
volume "nix-store" {
type = "host"
read_only = true
source = "nix-store"
}
volume "sw" {
type = "host"
read_only = true
source = "sw"
}
volume "appdata" {
type = "host"
read_only = false
source = "appdata"
}
task "sync" {
driver = "exec"
config {
command = "/appdata/igsync/run.sh"
}
user = "ppetru"
volume_mount {
volume = "appdata"
destination = "/appdata"
}
volume_mount {
volume = "nix-store"
destination = "/nix/store"
}
volume_mount {
volume = "sw"
destination = "/sw"
}
resources {
memory = 1024
cpu = 2000
}
}
}
}