forked from kubernetes-sigs/cluster-api
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Signed-off-by: Stefan Büringer buringerst@vmware.com
- Loading branch information
1 parent
0d4ceea
commit 0a7ae63
Showing
13 changed files
with
1,067 additions
and
9 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
89 changes: 89 additions & 0 deletions
89
test/e2e/data/infrastructure-docker/v1.7/bases/cluster-with-kcp.yaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,89 @@ | ||
--- | ||
# DockerCluster object referenced by the Cluster object | ||
apiVersion: infrastructure.cluster.x-k8s.io/v1beta1 | ||
kind: DockerCluster | ||
metadata: | ||
name: '${CLUSTER_NAME}' | ||
spec: | ||
failureDomains: | ||
fd1: | ||
controlPlane: true | ||
fd2: | ||
controlPlane: true | ||
fd3: | ||
controlPlane: true | ||
fd4: | ||
controlPlane: false | ||
fd5: | ||
controlPlane: false | ||
fd6: | ||
controlPlane: false | ||
fd7: | ||
controlPlane: false | ||
fd8: | ||
controlPlane: false | ||
--- | ||
# Cluster object with | ||
# - Reference to the KubeadmControlPlane object | ||
# - the label cni=${CLUSTER_NAME}-crs-0, so the cluster can be selected by the ClusterResourceSet. | ||
apiVersion: cluster.x-k8s.io/v1beta1 | ||
kind: Cluster | ||
metadata: | ||
name: '${CLUSTER_NAME}' | ||
labels: | ||
cni: "${CLUSTER_NAME}-crs-0" | ||
spec: | ||
clusterNetwork: | ||
services: | ||
cidrBlocks: ['${DOCKER_SERVICE_CIDRS}'] | ||
pods: | ||
cidrBlocks: ['${DOCKER_POD_CIDRS}'] | ||
serviceDomain: '${DOCKER_SERVICE_DOMAIN}' | ||
infrastructureRef: | ||
apiVersion: infrastructure.cluster.x-k8s.io/v1beta1 | ||
kind: DockerCluster | ||
name: '${CLUSTER_NAME}' | ||
controlPlaneRef: | ||
kind: KubeadmControlPlane | ||
apiVersion: controlplane.cluster.x-k8s.io/v1beta1 | ||
name: "${CLUSTER_NAME}-control-plane" | ||
--- | ||
# DockerMachineTemplate object referenced by the KubeadmControlPlane object | ||
apiVersion: infrastructure.cluster.x-k8s.io/v1beta1 | ||
kind: DockerMachineTemplate | ||
metadata: | ||
name: "${CLUSTER_NAME}-control-plane" | ||
spec: | ||
template: | ||
spec: | ||
extraMounts: | ||
- containerPath: "/var/run/docker.sock" | ||
hostPath: "/var/run/docker.sock" | ||
# The DOCKER_PRELOAD_IMAGES variable gets set in self-hosted E2E tests to the list of images of the E2E configuration. | ||
preLoadImages: ${DOCKER_PRELOAD_IMAGES:-[]} | ||
--- | ||
# KubeadmControlPlane referenced by the Cluster object with | ||
# - the label kcp-adoption.step2, because it should be created in the second step of the kcp-adoption test. | ||
kind: KubeadmControlPlane | ||
apiVersion: controlplane.cluster.x-k8s.io/v1beta1 | ||
metadata: | ||
name: "${CLUSTER_NAME}-control-plane" | ||
labels: | ||
kcp-adoption.step2: "" | ||
spec: | ||
replicas: ${CONTROL_PLANE_MACHINE_COUNT} | ||
machineTemplate: | ||
infrastructureRef: | ||
kind: DockerMachineTemplate | ||
apiVersion: infrastructure.cluster.x-k8s.io/v1beta1 | ||
name: "${CLUSTER_NAME}-control-plane" | ||
kubeadmConfigSpec: | ||
clusterConfiguration: | ||
apiServer: | ||
# host.docker.internal is required by kubetest when running on MacOS because of the way ports are proxied. | ||
certSANs: [localhost, 127.0.0.1, 0.0.0.0, host.docker.internal] | ||
initConfiguration: | ||
nodeRegistration: {} # node registration parameters are automatically injected by CAPD according to the kindest/node image in use. | ||
joinConfiguration: | ||
nodeRegistration: {} # node registration parameters are automatically injected by CAPD according to the kindest/node image in use. | ||
version: "${KUBERNETES_VERSION}" |
75 changes: 75 additions & 0 deletions
75
test/e2e/data/infrastructure-docker/v1.7/bases/cluster-with-topology.yaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,75 @@ | ||
apiVersion: cluster.x-k8s.io/v1beta1 | ||
kind: Cluster | ||
metadata: | ||
name: '${CLUSTER_NAME}' | ||
namespace: default | ||
labels: | ||
cni: "${CLUSTER_NAME}-crs-0" | ||
spec: | ||
clusterNetwork: | ||
services: | ||
cidrBlocks: ['${DOCKER_SERVICE_CIDRS}'] | ||
pods: | ||
cidrBlocks: ['${DOCKER_POD_CIDRS}'] | ||
serviceDomain: '${DOCKER_SERVICE_DOMAIN}' | ||
topology: | ||
class: "quick-start" | ||
version: "${KUBERNETES_VERSION}" | ||
controlPlane: | ||
metadata: | ||
labels: | ||
Cluster.topology.controlPlane.label: "Cluster.topology.controlPlane.labelValue" | ||
# Note: this label is propagated to Nodes. | ||
Cluster.topology.controlPlane.label.node.cluster.x-k8s.io: "Cluster.topology.controlPlane.nodeLabelValue" | ||
annotations: | ||
Cluster.topology.controlPlane.annotation: "Cluster.topology.controlPlane.annotationValue" | ||
nodeDeletionTimeout: "30s" | ||
nodeVolumeDetachTimeout: "5m" | ||
replicas: ${CONTROL_PLANE_MACHINE_COUNT} | ||
workers: | ||
machineDeployments: | ||
- class: "default-worker" | ||
name: "md-0" | ||
metadata: | ||
labels: | ||
Cluster.topology.machineDeployment.label: "Cluster.topology.machineDeployment.labelValue" | ||
# Note: this label is propagated to Nodes. | ||
Cluster.topology.machineDeployment.label.node.cluster.x-k8s.io: "Cluster.topology.machineDeployment.nodeLabelValue" | ||
annotations: | ||
Cluster.topology.machineDeployment.annotation: "Cluster.topology.machineDeployment.annotationValue" | ||
nodeDeletionTimeout: "30s" | ||
nodeVolumeDetachTimeout: "5m" | ||
minReadySeconds: 5 | ||
replicas: ${WORKER_MACHINE_COUNT} | ||
failureDomain: fd4 | ||
strategy: | ||
type: RollingUpdate | ||
rollingUpdate: | ||
maxSurge: "20%" | ||
maxUnavailable: 0 | ||
machinePools: | ||
- class: "default-worker" | ||
name: "mp-0" | ||
metadata: | ||
labels: | ||
Cluster.topology.machinePool.label: "Cluster.topology.machinePool.labelValue" | ||
# Note: this label is propagated to Nodes. | ||
Cluster.topology.machinePool.label.node.cluster.x-k8s.io: "Cluster.topology.machinePool.nodeLabelValue" | ||
annotations: | ||
Cluster.topology.machinePool.annotation: "Cluster.topology.machinePool.annotationValue" | ||
nodeDeletionTimeout: "30s" | ||
nodeVolumeDetachTimeout: "5m" | ||
minReadySeconds: 5 | ||
replicas: ${WORKER_MACHINE_COUNT} | ||
failureDomains: | ||
- fd4 | ||
variables: | ||
# We set an empty value to use the default tag kubeadm init is using. | ||
- name: etcdImageTag | ||
value: "" | ||
# We set an empty value to use the default tag kubeadm init is using. | ||
- name: coreDNSImageTag | ||
value: "" | ||
- name: preLoadImages | ||
# The DOCKER_PRELOAD_IMAGES variable gets set in self-hosted E2E tests to the list of images of the E2E configuration. | ||
value: ${DOCKER_PRELOAD_IMAGES:-[]} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
--- | ||
# ConfigMap object referenced by the ClusterResourceSet object and with | ||
# the CNI resource defined in the test config file | ||
apiVersion: v1 | ||
kind: ConfigMap | ||
metadata: | ||
name: "cni-${CLUSTER_NAME}-crs-0" | ||
data: ${CNI_RESOURCES} | ||
binaryData: | ||
--- | ||
# ClusterResourceSet object with | ||
# a selector that targets all the Cluster with label cni=${CLUSTER_NAME}-crs-0 | ||
apiVersion: addons.cluster.x-k8s.io/v1beta1 | ||
kind: ClusterResourceSet | ||
metadata: | ||
name: "${CLUSTER_NAME}-crs-0" | ||
spec: | ||
strategy: ApplyOnce | ||
clusterSelector: | ||
matchLabels: | ||
cni: "${CLUSTER_NAME}-crs-0" | ||
resources: | ||
- name: "cni-${CLUSTER_NAME}-crs-0" | ||
kind: ConfigMap |
Oops, something went wrong.