devops-toolkit/dot-kubernetes@v0.12.160
cluster-civo

cluster-civo

cluster-civo
devops-toolkit/dot-kubernetes@v0.12.160cluster-civo
Type

Composition

Referenced XRD

CompositeCluster

Source Codegithub.com/vfarcic/crossplane-kubernetes
Resources (1)

The following resources are composed to implement the referenced Composite Resource Definition (XRD).

Kind
Group
Version

No resources found.

YAML
kind: Composition
apiVersion: apiextensions.crossplane.io/v1
metadata:
  name: cluster-civo
  creationTimestamp: null
  labels:
    cluster: ck
    provider: civo
spec:
  compositeTypeRef:
    apiVersion: devopstoolkitseries.com/v1alpha1
    kind: CompositeCluster
  patchSets:
    - name: metadata
      patches:
        - fromFieldPath: metadata.labels
  resources:
    - name: civocluster
      base:
        apiVersion: cluster.civo.crossplane.io/v1alpha1
        kind: CivoKubernetes
        spec:
          applications:
            - civo-cluster-autoscaler
          connectionDetails:
            connectionSecretNamePrefix: cluster-civo
            connectionSecretNamespace: crossplane-system
          name: civocluster
          pools:
            - count: 1
              id: 8382e422-dcdd-461f-afb4-2ab67f171c3e
              size: g3.k3s.small
          providerConfigRef:
            name: crossplane-provider-civo
      patches:
        - fromFieldPath: spec.id
          toFieldPath: metadata.name
        - fromFieldPath: spec.id
          toFieldPath: spec.name
        - fromFieldPath: spec.id
          toFieldPath: spec.writeConnectionSecretToRef.name
          transforms:
            - type: string
              string:
                fmt: "%s-cluster"
        - fromFieldPath: spec.claimRef.namespace
          toFieldPath: spec.writeConnectionSecretToRef.namespace
        - fromFieldPath: spec.parameters.minNodeCount
          toFieldPath: spec.pools[0].count
        - fromFieldPath: spec.parameters.nodeSize
          toFieldPath: spec.pools[0].size
          transforms:
            - type: map
              map:
                large: g3.k3s.xlarge
                medium: g3.k3s.medium
                small: g3.k3s.small
        - type: ToCompositeFieldPath
          fromFieldPath: metadata.name
          toFieldPath: status.clusterName
        - type: ToCompositeFieldPath
          fromFieldPath: status.message
          toFieldPath: status.controlPlaneStatus
        - type: ToCompositeFieldPath
          fromFieldPath: status.message
          toFieldPath: status.nodePoolStatus
      connectionDetails:
        - fromConnectionSecretKey: kubeconfig
        - fromConnectionSecretKey: kubeconfig
          value: value
  writeConnectionSecretsToNamespace: crossplane-system
Discover the building blocks for your internal cloud platform.
© 2024 Upbound, Inc.
Solutions