Import Strategy
CAAPF follows a simple import strategy for CAPI clusters:
- Each CAPI cluster has a corresponding Fleet
Cluster
object. - Each CAPI Cluster Class has a corresponding Fleet
ClusterGroup
object. - When a CAPI
Cluster
references aClusterClass
in a different namespace, aClusterGroup
is created in theCluster
namespace. ThisClusterGroup
targets all clusters in this namespace that reference the sameClusterClass
. See the configuration section for details. - If at least one CAPI
Cluster
references aClusterClass
in a different namespace, aBundleNamespaceMapping
is created in theClusterClass
namespace. This allows FleetCluster
resources to use application sources such asBundles
,HelmApps
, orGitRepos
from theClusterClass
namespace as if they were deployed in theCluster
namespace. See the configuration section for details.
By default, CAAPF
imports all CAPI
clusters under Fleet management. See the configuration section for details.
Label Synchronization
Fleet relies on Cluster
labels, Cluster
names, and ClusterGroups
for target matching when deploying applications or referenced repository content. To ensure consistency, CAAPF
synchronizes resource labels:
- From the CAPI
ClusterClass
to the imported FleetCluster
resource. - From the CAPI
ClusterClass
to the imported FleetClusterGroup
resource.
When a CAPI Cluster
references a ClusterClass
, CAAPF
applies two specific labels to both the Cluster
and ClusterGroup
resources:
clusterclass-name.fleet.addons.cluster.x-k8s.io: <class-name>
clusterclass-namespace.fleet.addons.cluster.x-k8s.io: <class-ns>