This commit is contained in:
Daniel Berteaud 2023-12-18 14:15:06 +01:00
parent dfdf308c4d
commit 4e36c99901
1 changed files with 12 additions and 12 deletions

View File

@ -13,7 +13,7 @@ job "[[ .pg.instance ]]-manage[[ $c.consul.suffix ]]" {
}
[[- end ]]
[[ template "common/job_start.tpl" $c ]]
[[ template "common/job_start" $c ]]
group "manage" {
network {
@ -26,10 +26,10 @@ job "[[ .pg.instance ]]-manage[[ $c.consul.suffix ]]" {
service {
name = "[[ .pg.instance ]]-manage[[ $c.consul.suffix ]]"
[[ template "common/connect.tpl" $c ]]
[[ template "common/connect" $c ]]
}
[[ template "common/task.wait_for.tpl" $c ]]
[[ template "common/task.wait_for" $c ]]
task "postgres-manage" {
driver = [[ $c.nomad.driver | toJSON ]]
@ -72,7 +72,7 @@ job "[[ .pg.instance ]]-manage[[ $c.consul.suffix ]]" {
[[- end ]]
}
[[ template "common/file_env.tpl" $c.env ]]
[[ template "common/file_env" $c.env ]]
template {
data =<<_EOF
@ -82,10 +82,10 @@ PGUSER=postgres
PGPASSWORD={{ with secret "[[ .vault.prefix ]]kv/service/[[ .pg.instance ]]" }}{{ .Data.data.pg_pwd | sprig_squote }}{{ end }}
_EOF
destination = "secrets/pg-manage.env"
uid = 100000
gid = 100000
perms = 0400
env = true
uid = 100000
gid = 100000
perms = 0400
env = true
}
template {
@ -96,12 +96,12 @@ rules:
[[ (coll.Slice $c.rules $c.default_rules) | flatten | toYAML | strings.Indent 2]]
_EOF
destination = "secrets/ldap2pg.yml"
uid = 100000
gid = 100000
perms = 0400
uid = 100000
gid = 100000
perms = 0400
}
[[ template "common/resources.tpl" $c.resources ]]
[[ template "common/resources" $c.resources ]]
}
}
}