Skip to content
This repository has been archived by the owner on Aug 27, 2024. It is now read-only.

Commit

Permalink
Add nerc-common-reader policy
Browse files Browse the repository at this point in the history
This grants access to any secrets stored under nerc/common/. We grant all
clusters access to this path so that we can place common secrets here and
have them accessible to all clusters.
larsks committed Feb 13, 2024
1 parent 10f11f9 commit 8b08553
Showing 3 changed files with 10 additions and 0 deletions.
6 changes: 6 additions & 0 deletions config/global/policies.jsonnet
Original file line number Diff line number Diff line change
@@ -12,6 +12,12 @@
policy: importstr 'policies/default.hcl',
},
},
{
path: '/v1/sys/policy/nerc-common-reader',
payload: {
policy: importstr 'policies/nerc-common-reader.hcl',
},
},
{
path: '/v1/sys/policy/nerc-all-reader',
payload: {
1 change: 1 addition & 0 deletions lib/cluster.libsonnet
Original file line number Diff line number Diff line change
@@ -41,6 +41,7 @@ function(
],
bound_service_account_namespaces: service_account_namespaces,
token_policies: [
"nerc-common-reader",
std.format("%s-reader", cluster_name),
],
},
3 changes: 3 additions & 0 deletions lib/policies/nerc-common-reader.hcl
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
path "nerc/data/common/*" {
capabilities = ["read"]
}

0 comments on commit 8b08553

Please sign in to comment.