2 Deployment #
The following procedures describe how to deploy SUSE Private Registry (Private Registry) on a Kubernetes cluster.
2.1 Prerequisites #
A Kubernetes cluster version 1.20 or higher
Helm version 3.2.0 or higher
Persistent Volume (PV) provisioner support in your infrastructure
An active subscription for SUSE Private Registry
2.2 Obtaining Kubernetes secrets from the SUSE Customer Center #
To download and install the Private Registry images from SUSE Registry, you need a Kubernetes secret with SUSE Customer Center (SCC) mirroring credentials. To obtain the credentials from SCC, follow these steps:
Visit SUSE Customer Center at https://scc.suse.com and log in.
Select the organization with an active Private Registry subscription from the left sidebar.
Select
Proxies
in the top menu. The credentials are displayed in the top right corner.To see the password, click the 'eye' icon.
Create a
password.txt
file containing the obtained password.Store the mirroring credentials retrieved from SCC as Kubernetes secrets by running the following command:
$ kubectl create secret docker-registry suse-registry \ --docker-server=registry.suse.com --docker-username=<SUSE_REGISTRY_USERNAME> \ --docker-password=$(head -1 ./password.txt)
2.3 Installing and running Private Registry using Helm #
The following procedure describes how to install Private Registry using Helm.
Replace <RELEASE_NAME>
with your custom release name for the Helm chart deployment.
Log in to SUSE Registry using the obtained SCC mirroring credentials.
$ head -1 ./password.txt | helm registry login registry.suse.com \ --username <SUSE_REGISTRY_USERNAME> --password-stdin
Install the latest version of the Private Registry Helm chart. To change the default installation values, refer to Appendix A, Overriding the SUSE Private Registry Helm chart.
$ helm install <RELEASE_NAME> \ oci://registry.suse.com/private-registry/private-registry-helm
The above
helm install …
command starts deploying several related containers. The deployment may take several minutes to complete. It also prints a message with the URL to the Private Registry Web portal and commands to obtain the administrator credentials.
2.4 Upgrading Private Registry #
To upgrade the release of the Helm chart to a specific newer version, run the following command:
$ helm upgrade <RELEASE_NAME> \ oci://registry.suse.com/private-registry/private-registry-helm --version 1.0.0