Fix var path for adhoc backup jobs
This commit is contained in:
parent
2efc7f8c2f
commit
a57e87d21f
@ -95,7 +95,7 @@ MYSQL_PORT=3306
|
||||
MYSQL_USER=root
|
||||
MYSQL_PASSWORD={{ .mysql_root_password }}
|
||||
{{ end -}}
|
||||
{{ with nomadVar (print "nomad/jobs/" (env "NOMAD_JOB_ID")) -}}
|
||||
{{ with nomadVar (print "nomad/jobs/" (index (env "NOMAD_JOB_ID" | split "/") 0)) -}}
|
||||
BACKUP_PASSPHRASE={{ .backup_passphrase }}
|
||||
RCLONE_FTP_HOST={{ .nas_ftp_host }}
|
||||
RCLONE_FTP_USER={{ .nas_ftp_user }}
|
||||
@ -181,7 +181,7 @@ PSKsecrets = {{ env "NOMAD_SECRETS_DIR" }}/mysql_stunnel_psk.txt
|
||||
# Probably should use variable ACLs to grant each node job to this path
|
||||
template {
|
||||
data = <<EOF
|
||||
{{- with nomadVar (print "nomad/jobs/" (env "NOMAD_JOB_ID")) }}{{ .mysql_stunnel_psk }}{{ end -}}
|
||||
{{- with nomadVar (print "nomad/jobs/" (index (env "NOMAD_JOB_ID" | split "/") 0)) }}{{ .mysql_stunnel_psk }}{{ end -}}
|
||||
EOF
|
||||
destination = "$${NOMAD_SECRETS_DIR}/mysql_stunnel_psk.txt"
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user