The following resources are composed to implement the referenced Composite Resource Definition (XRD).
XNetwork
XEKS
XServices
kind: Composition
apiVersion: apiextensions.crossplane.io/v1
metadata:
name: xclusters.aws.platformref.upbound.io
creationTimestamp: null
spec:
compositeTypeRef:
apiVersion: aws.platformref.upbound.io/v1alpha1
kind: XCluster
resources:
- name: compositeNetworkEKS
base:
apiVersion: aws.platformref.upbound.io/v1alpha1
kind: XNetwork
patches:
- fromFieldPath: spec.id
toFieldPath: spec.id
- type: ToCompositeFieldPath
fromFieldPath: status.subnetIds
toFieldPath: status.subnetIds
policy:
fromFieldPath: Required
- type: ToCompositeFieldPath
fromFieldPath: status.securityGroupIds
toFieldPath: status.securityGroupIds
policy:
fromFieldPath: Required
- name: compositeClusterEKS
base:
apiVersion: aws.platformref.upbound.io/v1alpha1
kind: XEKS
patches:
- fromFieldPath: spec.id
toFieldPath: spec.id
- fromFieldPath: spec.id
toFieldPath: metadata.annotations[crossplane.io/external-name]
- fromFieldPath: metadata.uid
toFieldPath: spec.writeConnectionSecretToRef.name
transforms:
- type: string
string:
fmt: "%s-eks"
- fromFieldPath: spec.writeConnectionSecretToRef.namespace
toFieldPath: spec.writeConnectionSecretToRef.namespace
- fromFieldPath: spec.parameters.nodes.count
toFieldPath: spec.parameters.nodes.count
- fromFieldPath: spec.parameters.nodes.size
toFieldPath: spec.parameters.nodes.size
- fromFieldPath: status.subnetIds
toFieldPath: spec.parameters.subnetIds
policy:
fromFieldPath: Required
- fromFieldPath: status.securityGroupIds
toFieldPath: spec.parameters.securityGroupIds
policy:
fromFieldPath: Required
connectionDetails:
- fromConnectionSecretKey: kubeconfig
- name: compositeClusterServices
base:
apiVersion: aws.platformref.upbound.io/v1alpha1
kind: XServices
patches:
- fromFieldPath: spec.id
toFieldPath: spec.providerConfigRef.name
- fromFieldPath: spec.parameters.services.operators.prometheus.version
toFieldPath: spec.operators.prometheus.version
writeConnectionSecretsToNamespace: upbound-system