Skip to content

Commit

Permalink
rm commented code
Browse files Browse the repository at this point in the history
  • Loading branch information
v-rocheleau committed Aug 28, 2024
1 parent 2dcd039 commit c492445
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions py_bentoctl/auth_helper.py
Original file line number Diff line number Diff line change
Expand Up @@ -391,17 +391,16 @@ def create_grafana_client_roles_if_needed(token: str, client_id: str) -> Optiona
return role_representations

def create_grafana_client_groups_if_needed(token: str, role_mappings: dict, client_id: str) -> None:
# create parent grafana group (no role mapping)
parent_group = {"name": "grafana"}
parent_group = create_group_or_exit(token, parent_group)

# create subgroups with client-role mappings
sub_groups = [
{"name": "admin"},
{"name": "editor"},
{"name": "viewer"}
]

# Add client-level role mappings to groups
# grafana_client_kc_id: Optional[str] = fetch_existing_client_id(token, GRAFANA_CLIENT_ID, verbose=False)
for subgroup in sub_groups:
group_rep = create_group_or_exit(token, subgroup, parent_group_rep=parent_group)
role_rep = role_mappings[subgroup["name"]]
Expand Down

0 comments on commit c492445

Please sign in to comment.