Skip to content

Instantly share code, notes, and snippets.

@mdbooth
Last active October 9, 2023 18:26
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save mdbooth/bc70234789a601c5afcec55eeb9a2669 to your computer and use it in GitHub Desktop.
Save mdbooth/bc70234789a601c5afcec55eeb9a2669 to your computer and use it in GitHub Desktop.
CAPO POC yamls
apiVersion: cloudcredential.openshift.io/v1
kind: CredentialsRequest
metadata:
name: openshift-cluster-api-openstack
namespace: openshift-cloud-credential-operator
spec:
providerSpec:
apiVersion: cloudcredential.openshift.io/v1
kind: OpenStackProviderSpec
secretRef:
name: openstack-cloud-credentials
namespace: openshift-cluster-api
---
apiVersion: cluster.x-k8s.io/v1beta1
kind: MachineDeployment
metadata:
name: mbooth-psi-p2d6r-workers
namespace: openshift-cluster-api
spec:
clusterName: mbooth-psi-p2d6r
replicas: 2
template:
spec:
bootstrap:
dataSecretName: worker-user-data
clusterName: mbooth-psi-p2d6r
infrastructureRef:
apiVersion: infrastructure.cluster.x-k8s.io/v1alpha7
kind: OpenStackMachineTemplate
name: mbooth-psi-p2d6r-workers
---
apiVersion: infrastructure.cluster.x-k8s.io/v1alpha7
kind: OpenStackMachineTemplate
metadata:
name: mbooth-psi-p2d6r-workers
namespace: openshift-cluster-api
spec:
template:
spec:
cloudName: openstack
flavor: ci.m1.large
identityRef:
kind: Secret
name: openstack-cloud-credentials
image: rhcos-4.14
sshKeyName: mbooth-yubikey
serverMetadata:
Name: mbooth-psi-p2d6r-capi-worker
openshiftClusterID: mbooth-psi-p2d6r
serverGroupID: 59b5325d-1535-4fe3-9079-0264402ef420
trunk: true
securityGroups:
- name: mbooth-psi-p2d6r-worker
ports:
- fixedIPs:
- subnet:
name: mbooth-psi-p2d6r-nodes
tags: openshiftClusterID=mbooth-psi-p2d6r
---
apiVersion: cluster.x-k8s.io/v1beta1
kind: Cluster
metadata:
name: mbooth-psi-662sf
namespace: openshift-cluster-api
spec:
infrastructureRef:
apiVersion: infrastructure.cluster.x-k8s.io/v1alpha7
kind: OpenStackCluster
name: mbooth-psi-662sf
---
apiVersion: infrastructure.cluster.x-k8s.io/v1alpha7
kind: OpenStackCluster
metadata:
name: mbooth-psi-662sf
namespace: openshift-cluster-api
labels:
cluster.x-k8s.io/cluster-name: mbooth-psi-662sf
spec:
controlPlaneEndpoint:
host: 10.0.79.219
port: 6443
cloudName: openstack # Hardcoded
identityRef:
name: openstack-cloud-credentials # Hardcoded for PoC
kind: Secret
managedSecurityGroups: false
externalNetworkId: 14c15d33-175c-424e-88ba-361a875e0c5c
disableAPIServerFloatingIP: true
router:
name: mbooth-psi-662sf-external-router
network:
name: mbooth-psi-662sf-openshift
subnet:
name: mbooth-psi-662sf-nodes
tags:
- openshiftClusterID=mbooth-psi-662sf
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment