Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Incorrect policy given in README #284

Open
jakubgs opened this issue Feb 10, 2022 · 1 comment
Open

Incorrect policy given in README #284

jakubgs opened this issue Feb 10, 2022 · 1 comment

Comments

@jakubgs
Copy link

jakubgs commented Feb 10, 2022

I used the policy that's recommended in the Configuration seciont of README:

key "consul-alerts" {
  policy = "write"
}

service "" {
  policy = "read"
}

event "" {
  policy = "read"
}

session "" {
  policy = "write"
}

But that resulted in errors like these from consul-alerts:

[ERROR] watch.watch: Watch errored: type=checks error="Unexpected response code: 403 (rpc error making call: ACL not found)" retry=3m0s

And these on the Consul agent side:

[ERROR] agent.http: Request error: method=PUT url=/v1/session/create?dc=he-eu-hel1&token=<hidden> from=127.0.0.1:60866 error="rpc error making call: Permission denied"

Changing the policy from session to session_prefix did fix that though:

service_prefix "" { 
  policy = "write" 
}

Not sure what that's about, but maybe this helps someone.

@jakubgs
Copy link
Author

jakubgs commented Feb 11, 2022

Actually, after a bunch of fiddling this is what works:

key_prefix "consul-alerts/" {
  policy = "write"
}

service_prefix "" {
  policy = "read"
}

node_prefix "" {
  policy = "read"
}

event_prefix "" {
  policy = "read"
}

session_prefix "" {
  policy = "write"
}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant