Update gitea secret paths

Signed-off-by: magic_rb <magic_rb@redalder.org>
This commit is contained in:
magic_rb 2024-01-18 21:23:18 +01:00
parent 843047ea40
commit d7c2cfa959
No known key found for this signature in database
GPG key ID: 08D5287CC5DDCA0E
2 changed files with 5 additions and 5 deletions

View file

@ -24,7 +24,7 @@ in
resource."vault_policy"."gitea-policy" = {
name = "gitea-policy";
policy = ''
path "kv/data/gitea" {
path "kv/data/cluster/gitea/gitea" {
capabilities = ["read"]
}
'';

View file

@ -109,28 +109,28 @@ job "gitea" {
template {
data = <<EOF
{{ with secret "kv/data/gitea" }}{{ .Data.data.secret_key }}{{ end }}
{{ with secret "kv/data/cluster/gitea/gitea" }}{{ .Data.data.secret_key }}{{ end }}
EOF
destination = "secrets/secret_key"
}
template {
data = <<EOF
{{ with secret "kv/data/gitea" }}{{ .Data.data.internal_token }}{{ end }}
{{ with secret "kv/data/cluster/gitea/gitea" }}{{ .Data.data.internal_token }}{{ end }}
EOF
destination = "secrets/internal_token"
}
template {
data = <<EOF
{{ with secret "kv/data/gitea" }}{{ .Data.data.jwt_secret }}{{ end }}
{{ with secret "kv/data/cluster/gitea/gitea" }}{{ .Data.data.jwt_secret }}{{ end }}
EOF
destination = "secrets/jwt_secret"
}
template {
data = <<EOF
{{ with secret "kv/data/gitea" }}{{ .Data.data.lfs_jwt_secret }}{{ end }}
{{ with secret "kv/data/cluster/gitea/gitea" }}{{ .Data.data.lfs_jwt_secret }}{{ end }}
EOF
destination = "secrets/lfs_jwt_secret"
}