Skip to content

Commit

Permalink
Add quota permissions to robot account (#19799)
Browse files Browse the repository at this point in the history
Fix #19792

Signed-off-by: Yang Jiao <[email protected]>
Co-authored-by: Yang Jiao <[email protected]>
  • Loading branch information
YangJiao0817 and Yang Jiao authored Jan 8, 2024
1 parent de7ea28 commit 64a2296
Show file tree
Hide file tree
Showing 9 changed files with 14 additions and 0 deletions.
6 changes: 6 additions & 0 deletions src/common/rbac/const.go
Original file line number Diff line number Diff line change
Expand Up @@ -149,6 +149,10 @@ var (
{Resource: ResourceSecurityHub, Action: ActionList},

{Resource: ResourceCatalog, Action: ActionRead},

{Resource: ResourceQuota, Action: ActionRead},
{Resource: ResourceQuota, Action: ActionList},
{Resource: ResourceQuota, Action: ActionUpdate},
},
"Project": {
{Resource: ResourceLog, Action: ActionList},
Expand Down Expand Up @@ -221,6 +225,8 @@ var (
{Resource: ResourceLabel, Action: ActionDelete},
{Resource: ResourceLabel, Action: ActionList},
{Resource: ResourceLabel, Action: ActionUpdate},

{Resource: ResourceQuota, Action: ActionRead},
},
}
)
Original file line number Diff line number Diff line change
Expand Up @@ -77,6 +77,7 @@ export const ACTION_RESOURCE_I18N_MAP = {
'immutable-tag': 'ROBOT_ACCOUNT.IMMUTABLE_TAG',
log: 'ROBOT_ACCOUNT.LOG',
'notification-policy': 'ROBOT_ACCOUNT.NOTIFICATION_POLICY',
quota: 'ROBOT_ACCOUNT.QUOTA',
};

export function convertKey(key: string) {
Expand Down
1 change: 1 addition & 0 deletions src/portal/src/i18n/lang/de-de-lang.json
Original file line number Diff line number Diff line change
Expand Up @@ -411,6 +411,7 @@
"IMMUTABLE_TAG": "Immutable Tag",
"LOG": "Log",
"NOTIFICATION_POLICY": "Notification Policy",
"QUOTA": "Quota",
"BACK": "Back",
"NEXT": "Next",
"FINISH": "Finish",
Expand Down
1 change: 1 addition & 0 deletions src/portal/src/i18n/lang/en-us-lang.json
Original file line number Diff line number Diff line change
Expand Up @@ -411,6 +411,7 @@
"IMMUTABLE_TAG": "Immutable Tag",
"LOG": "Log",
"NOTIFICATION_POLICY": "Notification Policy",
"QUOTA": "Quota",
"BACK": "Back",
"NEXT": "Next",
"FINISH": "Finish",
Expand Down
1 change: 1 addition & 0 deletions src/portal/src/i18n/lang/es-es-lang.json
Original file line number Diff line number Diff line change
Expand Up @@ -412,6 +412,7 @@
"IMMUTABLE_TAG": "Immutable Tag",
"LOG": "Log",
"NOTIFICATION_POLICY": "Notification Policy",
"QUOTA": "Quota",
"BACK": "Back",
"NEXT": "Next",
"FINISH": "Finish",
Expand Down
1 change: 1 addition & 0 deletions src/portal/src/i18n/lang/fr-fr-lang.json
Original file line number Diff line number Diff line change
Expand Up @@ -403,6 +403,7 @@
"IMMUTABLE_TAG": "Immutable Tag",
"LOG": "Log",
"NOTIFICATION_POLICY": "Notification Policy",
"QUOTA": "Quota",
"BACK": "Back",
"NEXT": "Next",
"FINISH": "Finish",
Expand Down
1 change: 1 addition & 0 deletions src/portal/src/i18n/lang/pt-br-lang.json
Original file line number Diff line number Diff line change
Expand Up @@ -409,6 +409,7 @@
"IMMUTABLE_TAG": "Immutable Tag",
"LOG": "Log",
"NOTIFICATION_POLICY": "Notification Policy",
"QUOTA": "Quota",
"BACK": "Back",
"NEXT": "Next",
"FINISH": "Finish",
Expand Down
1 change: 1 addition & 0 deletions src/portal/src/i18n/lang/tr-tr-lang.json
Original file line number Diff line number Diff line change
Expand Up @@ -411,6 +411,7 @@
"IMMUTABLE_TAG": "Immutable Tag",
"LOG": "Log",
"NOTIFICATION_POLICY": "Notification Policy",
"QUOTA": "Quota",
"BACK": "Back",
"NEXT": "Next",
"FINISH": "Finish",
Expand Down
1 change: 1 addition & 0 deletions src/portal/src/i18n/lang/zh-tw-lang.json
Original file line number Diff line number Diff line change
Expand Up @@ -410,6 +410,7 @@
"IMMUTABLE_TAG": "Immutable Tag",
"LOG": "Log",
"NOTIFICATION_POLICY": "Notification Policy",
"QUOTA": "Quota",
"BACK": "Back",
"NEXT": "Next",
"FINISH": "Finish",
Expand Down

0 comments on commit 64a2296

Please sign in to comment.