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
{ | |
"signing": { | |
"default": { | |
"expiry": "43800h" | |
}, | |
"profiles": { | |
"server": { | |
"expiry": "43800h", | |
"usages": [ | |
"signing", |
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
{ | |
"CN": "etcd", | |
"key": { | |
"algo": "rsa", | |
"size": 2048 | |
} | |
} |
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
{ | |
"CN": "client", | |
"key": { | |
"algo": "ecdsa", | |
"size": 256 | |
} | |
} |
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
[Unit] | |
Description=etcd | |
Documentation=https://github.com/coreos/etcd | |
Conflicts=etcd.service | |
Conflicts=etcd2.service | |
[Service] | |
EnvironmentFile=/etc/etcd.env | |
Type=notify | |
Restart=always |
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
! Configuration File for keepalived | |
global_defs { | |
router_id LVS_DEVEL | |
} | |
vrrp_script check_apiserver { | |
script "/etc/keepalived/check_apiserver.sh" | |
interval 3 | |
weight -2 | |
fall 10 |
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
#!/bin/sh | |
errorExit() { | |
echo "*** $*" 1>&2 | |
exit 1 | |
} | |
curl --silent --max-time 2 --insecure https://localhost:6443/ -o /dev/null || errorExit "Error GET https://localhost:6443/" | |
if ip addr | grep -q <VIRTUAL-IP>; then | |
curl --silent --max-time 2 --insecure https://<VIRTUAL-IP>:6443/ -o /dev/null || errorExit "Error GET https://<VIRTUAL-IP>:6443/" |
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
apiVersion: kubeadm.k8s.io/v1alpha1 | |
kind: MasterConfiguration | |
api: | |
advertiseAddress: <master-private-ip> | |
etcd: | |
endpoints: | |
- http://<master0-ip-address>:2379 | |
- http://<master1-ip-address>:2379 | |
- http://<master2-ip-address>:2379 | |
caFile: /etc/kubernetes/pki/etcd/ca.pem |
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
[root@master-0 centos]# kubectl get nodes | |
NAME STATUS ROLES AGE VERSION | |
master-0 Ready master 4h v1.10.4 | |
master-1 Ready master 4h v1.10.4 | |
master-2 Ready master 4h v1.10.4 |
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
root@master-0 centos]# kubectl get pods -n kube-system | |
NAME READY STATUS RESTARTS AGE | |
kube-apiserver-master-0 1/1 Running 1 1m | |
kube-apiserver-master-1 1/1 Running 0 4h | |
kube-apiserver-master-2 1/1 Running 0 4h | |
kube-controller-manager-master-0 1/1 Running 1 1m | |
kube-controller-manager-master-1 1/1 Running 0 4h | |
kube-controller-manager-master-2 1/1 Running 0 4h | |
kube-dns-86f4d74b45-wh795 3/3 Running 0 4h | |
kube-proxy-9ts6r 1/1 Running 0 4h |
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
[root@master-0 centos]# kubectl get nodes | |
NAME STATUS ROLES AGE VERSION | |
master-0 NotReady master 4h v1.10.4 | |
master-1 Ready master 4h v1.10.4 | |
master-2 Ready master 4h v1.10.4 |
OlderNewer