- Notifications
You must be signed in to change notification settings - Fork928
Closed
Labels
Milestone
Description
Implement api interface for group sync settings crud. Group sync settings are now configured in the database and mutable at runtime.
Requires api endpoint to set and read the group sync runtime settings.
The code to interact with the settings from an api handler:
settings:=api.IDPSync.GroupSyncSettings()rlv:=api.Options.RuntimeConfig.OrganizationResolver(db,org.ID)err:=settings.SetRuntimeValue(ctx,rlv,&idpsync.GroupSyncSettings{// Values})
The problem we currently have is the RBAC story is not fully fleshed out. The current authz call isResourceSystem
:
coder/coderd/database/dbauthz/dbauthz.go
Lines 3939 to 3944 in1995c13
func (q*querier)UpsertRuntimeConfig(ctx context.Context,arg database.UpsertRuntimeConfigParams)error { | |
iferr:=q.authorizeContext(ctx,policy.ActionCreate,rbac.ResourceSystem);err!=nil { | |
returnerr | |
} | |
returnq.db.UpsertRuntimeConfig(ctx,arg) | |
} |