From 8d6be0bcf3ffc3b323bbf548dc3ccf0264b9d625 Mon Sep 17 00:00:00 2001 From: parth-gr Date: Thu, 8 Dec 2022 18:25:17 +0530 Subject: [PATCH] docs: import external K8s cluster on existing cluster If there is a external k8s cluster which need to use rook-ceph as a storageclass backend then user can do the following steps import it to the running rook-ceph cluster Closes:https://github.com/rook/rook/issues/11404 Signed-off-by: parth-gr --- Documentation/CRDs/Cluster/external-cluster.md | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/Documentation/CRDs/Cluster/external-cluster.md b/Documentation/CRDs/Cluster/external-cluster.md index 39c44cc0e..1ff9f013c 100644 --- a/Documentation/CRDs/Cluster/external-cluster.md +++ b/Documentation/CRDs/Cluster/external-cluster.md @@ -163,3 +163,18 @@ spec: cephVersion: image: quay.io/ceph/ceph:v17.2.5 # Should match external cluster version ``` + +## Exporting Rook to another cluster + +If you have multiple K8s clusters running, and want to use the local `rook-ceph` cluster as the central storage, +you can export the settings from this cluster with the following steps. + +1) Copy create-external-cluster-resources.py into the directory `/etc/ceph/` of the toolbox. + ```console + toolbox=$(kubectl get pod -l app=rook-ceph-tools -n rook-ceph -o jsonpath='{.items[*].metadata.name}') + kubectl -n rook-ceph cp deploy/examples/create-external-cluster-resources.py $toolbox:/etc/ceph + ``` +2) Exec to the toolbox pod and execute create-external-cluster-resources.py with needed options to create required [users and keys](#supported-features). + +!!! important + For other clusters to connect to storage in this cluster, Rook must be configured with a networking configuration that is accessible from other clusters. Most commonly this is done by enabling host networking in the CephCluster CR so the Ceph daemons will be addressable by their host IPs.