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

Add a doc for the meanings of 'p' and 'g' in the ArgoCD policy.csv file on RBAC Configuration page #16029

Closed
able8 opened this issue Oct 19, 2023 · 3 comments
Labels
bug Something isn't working type:docs Missing or incomplete documentation

Comments

@able8
Copy link

able8 commented Oct 19, 2023

Some users are confused about what the p and g stand for?
Can we provide an explanation for what the "p" and "g" stand for to help clarify confusion among users?

On the RBAC Configuration page: https://argo-cd.readthedocs.io/en/stable/operator-manual/rbac/

I guess, p means permission or policy, and g means group or grant?

apiVersion: v1
kind: ConfigMap
metadata:
  name: argocd-rbac-cm
  namespace: argocd
data:
  policy.default: role:readonly
  policy.csv: |
    p, role:org-admin, logs, get, *, allow
    p, role:org-admin, exec, create, */*, allow

    g, your-github-org:your-team, role:org-admin
@able8 able8 added the bug Something isn't working label Oct 19, 2023
@yyzxw
Copy link
Contributor

yyzxw commented Oct 19, 2023

argo-server uses casbin to auth

@able8
Copy link
Author

able8 commented Oct 19, 2023

Thanks @yyzxw.

Checking casbin docs, p is used for policy_definition and g is for role_definition.
we can say p means policy, g means group.

https://casbin.org/docs/syntax-for-models#policy-definition

https://casbin.org/docs/rbac

Screenshot 2023-10-19 at 16 28 35 Screenshot 2023-10-19 at 16 29 04

@christianh814 christianh814 added the type:docs Missing or incomplete documentation label Oct 23, 2023
@agaudreault
Copy link
Member

Closed by #18124

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working type:docs Missing or incomplete documentation
Projects
None yet
Development

No branches or pull requests

4 participants