Related images in Oracle Cloud Infrastructure Registry can be grouped into meaningfully named repositories for convenience.
Repositories can be private or public. Any user with internet access and knowledge of the appropriate URL can pull images from a public repository in Oracle Cloud Infrastructure Registry.
You must belong to the tenancy's Administrators group or have been granted the REPOSITORY_MANAGE permission to:
- create a new public repository
- change an existing repository into a public repository
- change an existing public repository into a private repository
If you make a repository private, you (along with users belonging to the tenancy's Administrators group) will be able to perform any operation on the repository. You can use identity policies to allow other users to perform other operations on repositories (both public and private) that you create.
Typically, the images in a repository are all different versions of the same source image (for example 'acme-web-app'), with each version identified by a tag (for example, 'acme-web-app:4.6.3').
For example, for convenience you might want to group together multiple versions of the acme-web-app image in the acme-dev tenancy in the Ashburn region into a repository called project01. You do this by including the name of the repository in the image name when you push the image, in the format
<tag>. For example,
iad.ocir.io/acme-dev/project01/acme-web-app:4.6.3. Subsequently, when you use the
docker push command, the presence of the repository in the image's name ensures the image is pushed to the intended repository.
If you push an image that includes a repository in the image name and the repository doesn't already exist (for example,
iad.ocir.io/acme-dev/project02/acme-web-app:7.5.2), a new private repository is created in Oracle Cloud Infrastructure Registry.
If you push an image that doesn't explicitly include a repository in the image name (for example,
iad.ocir.io/acme-dev/acme-web-app:7.5.2), the image's name (
acme-web-app) is used as the name of a private repository.
Alternatively, you can use the Console to create an empty repository and give it a name. If you belong to the tenancy's Administrators group or have been granted the REPOSITORY_MANAGE permission, you can also specify whether the repository is to be private or public. Any images you subsequently push to Oracle Cloud Infrastructure Registry that include the repository in the image name are pushed to that repository.