- Notifications
You must be signed in to change notification settings - Fork928
feat: add auditing for groups#4527
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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.
Already on GitHub?Sign in to your account
Uh oh!
There was an error while loading.Please reload this page.
Changes fromall commits
c59b73c
1d71c29
c3c1726
374521b
ac72abf
3605e55
0144a10
6f4dcf7
3365bea
3158176
bc5e95d
da10838
97867bc
05861d5
94200c2
File filter
Filter by extension
Conversations
Uh oh!
There was an error while loading.Please reload this page.
Jump to
Uh oh!
There was an error while loading.Please reload this page.
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -24,3 +24,22 @@ func (a *Actions) Scan(src interface{}) error { | ||
func (a *Actions) Value() (driver.Value, error) { | ||
return json.Marshal(a) | ||
} | ||
// TemplateACL is a map of ids to permissions. | ||
type TemplateACL map[string][]rbac.Action | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others.Learn more. Could this be a There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others.Learn more. possibly but it involves a lot of code changes, i'll try it out in a separate pr | ||
func (t *TemplateACL) Scan(src interface{}) error { | ||
switch v := src.(type) { | ||
case string: | ||
return json.Unmarshal([]byte(v), &t) | ||
case []byte, json.RawMessage: | ||
//nolint | ||
return json.Unmarshal(v.([]byte), &t) | ||
} | ||
return xerrors.Errorf("unexpected type %T", src) | ||
} | ||
func (t TemplateACL) Value() (driver.Value, error) { | ||
return json.Marshal(t) | ||
} |
Some generated files are not rendered by default. Learn more abouthow customized files appear on GitHub.
Uh oh!
There was an error while loading.Please reload this page.
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
-- You cannot safely remove values from enums https://www.postgresql.org/docs/current/datatype-enum.html | ||
-- You cannot create a new type and do a rename because objects depend on this type now. |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
BEGIN; | ||
ALTER TYPE resource_type ADD VALUE IF NOT EXISTS 'group'; | ||
COMMIT; |
Some generated files are not rendered by default. Learn more abouthow customized files appear on GitHub.
Uh oh!
There was an error while loading.Please reload this page.
Some generated files are not rendered by default. Learn more abouthow customized files appear on GitHub.
Uh oh!
There was an error while loading.Please reload this page.
Uh oh!
There was an error while loading.Please reload this page.