Skip to content

Commit

Permalink
Update nomad policies to match https://developer.hashicorp.com/nomad/…
Browse files Browse the repository at this point in the history
  • Loading branch information
tristanmorgan committed Oct 23, 2024
1 parent 2618fc1 commit c1bd646
Show file tree
Hide file tree
Showing 6 changed files with 12 additions and 8 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ agent_prefix "" {
policy = "read"
}
node_prefix "" {
policy = "read"
policy = "write"
}
service_prefix "" {
policy = "write"
Expand Down
6 changes: 4 additions & 2 deletions agent/structs/acltemplatedpolicy/policies/ce/nomad-server.hcl
Original file line number Diff line number Diff line change
@@ -1,10 +1,12 @@

acl = "write"
acl = "write"
mesh = "write"

agent_prefix "" {
policy = "read"
}
node_prefix "" {
policy = "read"
policy = "write"
}
service_prefix "" {
policy = "write"
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"TemplateName": "builtin/nomad-client",
"Schema": "",
"Template": "agent_prefix \"\" {\n policy = \"read\"\n}\nnode_prefix \"\" {\n policy = \"read\"\n}\nservice_prefix \"\" {\n policy = \"write\"\n}\nkey_prefix \"\" {\n policy = \"read\"\n}",
"Template": "agent_prefix \"\" {\n policy = \"read\"\n}\nnode_prefix \"\" {\n policy = \"write\"\n}\nservice_prefix \"\" {\n policy = \"write\"\n}\nkey_prefix \"\" {\n policy = \"read\"\n}",
"Description": "Gives the token or role permissions required for integration with a nomad client."
}
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ agent_prefix "" {
policy = "read"
}
node_prefix "" {
policy = "read"
policy = "write"
}
service_prefix "" {
policy = "write"
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"TemplateName": "builtin/nomad-server",
"Schema": "",
"Template": "\nacl = \"write\"\nagent_prefix \"\" {\n policy = \"read\"\n}\nnode_prefix \"\" {\n policy = \"read\"\n}\nservice_prefix \"\" {\n policy = \"write\"\n}",
"Template": "\nacl = \"write\"\nmesh = \"write\"\n\nagent_prefix \"\" {\n policy = \"read\"\n}\nnode_prefix \"\" {\n policy = \"write\"\n}\nservice_prefix \"\" {\n policy = \"write\"\n}",
"Description": "Gives the token or role permissions required for integration with a nomad server."
}
Original file line number Diff line number Diff line change
Expand Up @@ -5,12 +5,14 @@ Example usage:
consul acl token create -templated-policy builtin/nomad-server
Raw Template:

acl = "write"
acl = "write"
mesh = "write"

agent_prefix "" {
policy = "read"
}
node_prefix "" {
policy = "read"
policy = "write"
}
service_prefix "" {
policy = "write"
Expand Down

0 comments on commit c1bd646

Please sign in to comment.