mirror of
https://github.com/kemko/nomad.git
synced 2026-01-04 17:35:43 +03:00
e2e: fix destination of templates in VaultSecrets test (#9146)
The `$NOMAD_SECRETS_DIR` environment variable is rendered as `/secrets`, which prior to the recent security patch would unintentionally escape the file sandbox and get dropped in a directory named `/secrets` where the Nomad client binary was running. The `VaultSecrets` test was accidentally relying on this behavior and that causes the test to fail.
This commit is contained in:
@@ -33,7 +33,7 @@ job "secrets" {
|
||||
{{ end }}
|
||||
EOT
|
||||
|
||||
destination = "${NOMAD_SECRETS_DIR}/certificate.crt"
|
||||
destination = "secrets/certificate.crt"
|
||||
change_mode = "noop"
|
||||
}
|
||||
|
||||
@@ -42,7 +42,7 @@ EOT
|
||||
SOME_SECRET={{ with secret "secrets-TESTID/data/myapp" }}{{- .Data.data.key -}}{{end}}
|
||||
EOT
|
||||
|
||||
destination = "${NOMAD_SECRETS_DIR}/access.key"
|
||||
destination = "secrets/access.key"
|
||||
}
|
||||
|
||||
resources {
|
||||
|
||||
Reference in New Issue
Block a user