
Following the cert-manager migration to FluxCD, it was upversioned to v1.7.1 from v0.41.2, which means we need to update our helm-chart docs to use v1 instead of v1alpha2. Closes-Bug: #1978858 Signed-off-by: Pedro Almeida <pedro.monteiroazevedodemouraalmeida@windriver.com> Change-Id: I79955ed7412c0961b315f3b8a8cabd9dfce88fbf
3.1 KiB
Configure Docker Registry Certificate
The local Docker registry provides secure HTTPS access using the registry API.
By default, a self-signed server certificate is generated at installation time for the registry API. For more secure access, an intermediate or Root CA-signed server certificate is strongly recommended.
To configure or update the HTTPS certificate for the local Docker
registry, create a certificate named
system-registry-local-certificate
in the
deployment
namespace. The secretName
attribute
of this certificate's spec must also be named
system-registry-local-certificate
.
See the example procedure below for creating the certificate for the
local Docker registry. This example assumes you have configured a
system-local-ca
ClusterIssuer as described in starlingx-rest-api-applications-and-the-web-admin-server-cert-9196c5794834
.
Update the following fields:
- The
duration
andrenewBefore
dates for the expiry and renewal times you desire. The system will automatically renew and re-install the certificate. - The
subject
fields to identify your particular system. - The
ipAddresses
with the Floating IP Address and the MGMT Floating IP address for this system. Use thesystem addrpool-list
command to get the floating IP Address and management floating IP Address for your system. - The
dnsNames
withregistry.local
,registry.central
and any names configured for this system's Floating IP Address in an external DNS server.
Create the Docker certificate yaml configuration file.
~(keystone_admin)]$ cat <<EOF > docker-certificate.yaml --- apiVersion: cert-manager.io/v1 kind: Certificate metadata: name: system-registry-local-certificate namespace: deployment spec: secretName: system-registry-local-certificate issuerRef: name: system-local-ca kind: ClusterIssuer duration: 2160h # 90d renewBefore: 360h # 15d subject: organizations: - ABC-Company organizationalUnits: - StarlingX-system-registry-local ipAddresses: - <OAM_FLOATING_IP> - <MGMT_FLOATING_IP> dnsNames: - registry.local - registry.central - <external-FQDN-for-OAM-Floating-IP-Address, if applicable>
Apply the configuration.
~(keystone_admin)]$ kubectl apply -f docker-certificate.yaml
Verify the configuration.
~(keystone_admin)]$ kubectl get certificate system-registry-local-certificate –n deployment
If configuration was successful, the certificate’s Ready status will be
True
.
The Docker registry certificate installation is now complete, and Cert-Manager will handle the lifecycle management of the certificate.