Configuring RGW multi-site with HTTPS using cephadm
Configure HTTPS trust between Ceph Object Gateway (RGW) deployments in a multi-site environment by using cephadm-managed certificates.
In a multi-site deployment, each site uses cephadm-generated certificates. To enable secure communication between sites, you must copy each site's root Certificate Authority (CA) certificate to the other sites and trust these certificates.
Prerequisites
- A running and healthy IBM Storage Ceph.
- RGW services are deployed on both primary and secondary sites by using
cephadmwith HTTPS enabled. - Access to both primary and secondary cluster nodes.
Procedure
- Retrieve the
cephadmroot CA certificate and store it on the primary site.ceph orch certmgr cert get cephadm_root_ca_cert > cephadm-root-ca.crtExample output:
-----BEGIN CERTIFICATE----- MIIC... -----END CERTIFICATE----- - From the primary site, copy the root CA certificate to the trusted CA directory on the secondary site.
scp cephadm-root-ca.crt root@node-sec:/etc/pki/ca-trust/source/anchors/On the secondary site, verify that the certificate is present:
ls -l /etc/pki/ca-trust/source/anchors/cephadm-root-ca.crt - Update the trusted certificate store.
update-ca-trust - Verify connectivity from the secondary site to the primary RGW endpoint.
Run an RGW admin command:
radosgw-admin realm pull --rgw-realm RGW_REALM --url https://PRIMARY_RGW_ENDPOINT:PORT --access-key ACCESS_KEY --secret SECRET_KEY --defaultExample output:
{ "name": "RGW_REALM", "epoch": 2 }From the secondary site, verify HTTPS access to the primary RGW endpoint:
curl https://PRIMARY_RGW_ENDPOINTExample response:
<ListAllMyBucketsResult>...</ListAllMyBucketsResult>
-
Repeat these steps on the primary site by copying the secondary site's
cephadm_root_ca_certto/etc/pki/ca-trust/source/anchors/and runningupdate-ca-trustextract to complete the reverse CA exchange.After completing these steps, both sites trust each other's cephadm root CA certificates, enabling secure multi-site replication and operations over HTTPS.
After completing these steps, RGW services in both sites trust each other's certificates, enabling secure multi-site replication and operations over HTTPS.