Created
January 22, 2020 04:25
-
-
Save egeneralov/f11feeb612e315b221c1205a18392a21 to your computer and use it in GitHub Desktop.
This file contains hidden or 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
| kind delete cluster --name kind | |
| cat <<EOF | kind create cluster --config=- | |
| kind: Cluster | |
| apiVersion: kind.x-k8s.io/v1alpha4 | |
| networking: | |
| apiServerAddress: "0.0.0.0" | |
| apiServerPort: 6443 | |
| nodes: | |
| - role: control-plane | |
| kubeadmConfigPatches: | |
| - | | |
| kind: InitConfiguration | |
| nodeRegistration: | |
| kubeletExtraArgs: | |
| node-labels: "ingress-ready=true" | |
| authorization-mode: "AlwaysAllow" | |
| extraPortMappings: | |
| - containerPort: 6443 | |
| hostPort: 5446 | |
| protocol: TCP | |
| - containerPort: 80 | |
| hostPort: 5480 | |
| protocol: TCP | |
| - containerPort: 443 | |
| hostPort: 5443 | |
| protocol: TCP | |
| - role: worker | |
| - role: worker | |
| - role: worker | |
| EOF | |
| kubectl apply -f https://raw.githubusercontent.com/kubernetes/ingress-nginx/nginx-0.27.0/deploy/static/mandatory.yaml | |
| kubectl apply -f https://raw.githubusercontent.com/kubernetes/ingress-nginx/nginx-0.27.0/deploy/static/provider/baremetal/service-nodeport.yaml | |
| kubectl patch deployments -n ingress-nginx nginx-ingress-controller -p '{"spec":{"template":{"spec":{"containers":[{"name":"nginx-ingress-controller","ports":[{"containerPort":80,"hostPort":80},{"containerPort":443,"hostPort":443}]}],"nodeSelector":{"ingress-ready":"true"},"tolerations":[{"key":"node-role.kubernetes.io/master","operator":"Equal","effect":"NoSchedule"}]}}}}' | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment