-
Notifications
You must be signed in to change notification settings - Fork 30
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #418 from Danil-Grigorev/reg-method-default
Make control plane endpoint default registration method
- Loading branch information
Showing
12 changed files
with
217 additions
and
21 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
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
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
173 changes: 173 additions & 0 deletions
173
test/e2e/data/infrastructure/cluster-template-docker-updated.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,173 @@ | ||
apiVersion: v1 | ||
data: | ||
value: |- | ||
# generated by kind | ||
global | ||
log /dev/log local0 | ||
log /dev/log local1 notice | ||
daemon | ||
# limit memory usage to approximately 18 MB | ||
# (see https://github.com/kubernetes-sigs/kind/pull/3115) | ||
maxconn 100000 | ||
resolvers docker | ||
nameserver dns 127.0.0.11:53 | ||
defaults | ||
log global | ||
mode tcp | ||
option dontlognull | ||
# TODO: tune these | ||
timeout connect 5000 | ||
timeout client 50000 | ||
timeout server 50000 | ||
# allow to boot despite dns don't resolve backends | ||
default-server init-addr none | ||
frontend stats | ||
bind *:8404 | ||
stats enable | ||
stats uri / | ||
stats refresh 10s | ||
frontend control-plane | ||
bind *:{{ .FrontendControlPlanePort }} | ||
{{ if .IPv6 -}} | ||
bind :::{{ .FrontendControlPlanePort }}; | ||
{{- end }} | ||
default_backend kube-apiservers | ||
backend kube-apiservers | ||
option httpchk GET /healthz | ||
http-check expect status 401 | ||
# TODO: we should be verifying (!) | ||
{{range $server, $address := .BackendServers}} | ||
server {{ $server }} {{ JoinHostPort $address $.BackendControlPlanePort }} check check-ssl verify none resolvers docker resolve-prefer {{ if $.IPv6 -}} ipv6 {{- else -}} ipv4 {{- end }} | ||
{{- end}} | ||
frontend rke2-join | ||
bind *:9345 | ||
{{ if .IPv6 -}} | ||
bind :::9345; | ||
{{- end }} | ||
default_backend rke2-servers | ||
backend rke2-servers | ||
option httpchk GET /v1-rke2/readyz | ||
http-check expect status 403 | ||
{{range $server, $address := .BackendServers}} | ||
server {{ $server }} {{ $address }}:9345 check check-ssl verify none | ||
{{- end}} | ||
kind: ConfigMap | ||
metadata: | ||
name: ${CLUSTER_NAME}-lb-config | ||
--- | ||
apiVersion: cluster.x-k8s.io/v1beta1 | ||
kind: Cluster | ||
metadata: | ||
name: ${CLUSTER_NAME} | ||
spec: | ||
clusterNetwork: | ||
pods: | ||
cidrBlocks: | ||
- 10.45.0.0/16 | ||
services: | ||
cidrBlocks: | ||
- 10.46.0.0/16 | ||
serviceDomain: cluster.local | ||
controlPlaneRef: | ||
apiVersion: controlplane.cluster.x-k8s.io/v1beta1 | ||
kind: RKE2ControlPlane | ||
name: ${CLUSTER_NAME}-control-plane | ||
infrastructureRef: | ||
apiVersion: infrastructure.cluster.x-k8s.io/v1beta1 | ||
kind: DockerCluster | ||
name: ${CLUSTER_NAME} | ||
--- | ||
apiVersion: infrastructure.cluster.x-k8s.io/v1beta1 | ||
kind: DockerCluster | ||
metadata: | ||
name: ${CLUSTER_NAME} | ||
spec: | ||
loadBalancer: | ||
customHAProxyConfigTemplateRef: | ||
name: ${CLUSTER_NAME}-lb-config | ||
--- | ||
apiVersion: controlplane.cluster.x-k8s.io/v1beta1 | ||
kind: RKE2ControlPlane | ||
metadata: | ||
name: ${CLUSTER_NAME}-control-plane | ||
spec: | ||
replicas: ${CONTROL_PLANE_MACHINE_COUNT} | ||
version: ${KUBERNETES_VERSION}+rke2r1 | ||
rolloutStrategy: | ||
type: "RollingUpdate" | ||
rollingUpdate: | ||
maxSurge: 1 | ||
agentConfig: | ||
nodeAnnotations: | ||
test: "true" | ||
serverConfig: | ||
disableComponents: | ||
kubernetesComponents: | ||
- cloudController | ||
infrastructureRef: | ||
apiVersion: infrastructure.cluster.x-k8s.io/v1beta1 | ||
kind: DockerMachineTemplate | ||
name: "${CLUSTER_NAME}-control-plane" | ||
nodeDrainTimeout: 30s | ||
--- | ||
apiVersion: infrastructure.cluster.x-k8s.io/v1beta1 | ||
kind: DockerMachineTemplate | ||
metadata: | ||
name: "${CLUSTER_NAME}-control-plane" | ||
spec: | ||
template: | ||
spec: | ||
customImage: kindest/node:${KIND_IMAGE_VERSION} | ||
bootstrapTimeout: 15m | ||
--- | ||
apiVersion: cluster.x-k8s.io/v1beta1 | ||
kind: MachineDeployment | ||
metadata: | ||
name: ${CLUSTER_NAME}-md-0 | ||
spec: | ||
clusterName: ${CLUSTER_NAME} | ||
replicas: ${WORKER_MACHINE_COUNT} | ||
selector: | ||
matchLabels: | ||
cluster.x-k8s.io/cluster-name: ${CLUSTER_NAME} | ||
template: | ||
spec: | ||
version: ${KUBERNETES_VERSION}+rke2r1 | ||
clusterName: ${CLUSTER_NAME} | ||
bootstrap: | ||
configRef: | ||
apiVersion: bootstrap.cluster.x-k8s.io/v1beta1 | ||
kind: RKE2ConfigTemplate | ||
name: ${CLUSTER_NAME}-md-0 | ||
infrastructureRef: | ||
apiVersion: infrastructure.cluster.x-k8s.io/v1beta1 | ||
kind: DockerMachineTemplate | ||
name: ${CLUSTER_NAME}-md-0 | ||
--- | ||
apiVersion: infrastructure.cluster.x-k8s.io/v1beta1 | ||
kind: DockerMachineTemplate | ||
metadata: | ||
name: ${CLUSTER_NAME}-md-0 | ||
spec: | ||
template: | ||
spec: | ||
customImage: kindest/node:${KIND_IMAGE_VERSION} | ||
bootstrapTimeout: 15m | ||
--- | ||
apiVersion: bootstrap.cluster.x-k8s.io/v1beta1 | ||
kind: RKE2ConfigTemplate | ||
metadata: | ||
name: ${CLUSTER_NAME}-md-0 | ||
spec: | ||
template: | ||
spec: | ||
agentConfig: | ||
nodeAnnotations: | ||
test: "true" |
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