- Documentation
Container Registry
Container Registry (CR)
User guide
User authorization
Authorization management
Adding custom policies
Authorization management
Adding custom policies
Adding custom policies
If CR-related preset policies of the system cannot meet your requirements for managing permissions, you can configure custom policies.
Procedure
- In the left navigation bar, click Policy Management.
- On the Policy Management page, click Create Policy.
- In the Create Policy dialog box, create a policy as shown below.
tip
When editing policy content, you need to adhere to the IAM policy syntax. For more details, please refer to Policy Syntax. - Click Submit to complete the creation.
- On the creation success page, click Add authorization.
- Select the target account. In this example, cr-demo is used.
8. Click Confirm to complete the configuration.
Authorization examples
The following are examples of how to use authentication rules in different CR scenarios.
Scenario 1: Push images
Grant an IAM user the permission to push images to a specific namespace associated with a Standard Edition instance (for example: Standard Edition instance "instance-a" and namespace "library"). After logging in to the CR console as the IAM user, you can push all image instances under the specified namespace. You can also obtain information about the namespace and all image instances under it via OpenAPI.
Scenario 2: Pull images
Grant an IAM user the read permission for a namespace associated with a Standard Edition instance (for example: Standard Edition instance "instance-a" and namespace "library"). After logging in to the CR console as the IAM user, you can pull all image instances under the specified namespace. You can also obtain information about the namespace and all image instances under it via OpenAPI.
Last updated: 2026.09.23 14:37:20