blob: e9c17ecbd3dd946511574bf7fbcbd29125e18591 [file] [log] [blame]
Artem Panchenkoedf70ef2017-06-13 09:14:34 +03001{% from 'virtual-mcp11-k8s-calico/underlay.yaml' import HOSTNAME_CFG01 with context %}
2
Artem Panchenkoedf70ef2017-06-13 09:14:34 +03003- description: Install etcd
4 cmd: salt --hard-crash --state-output=mixed --state-verbose=False
5 -C 'I@etcd:server' state.sls etcd.server.service
6 node_name: {{ HOSTNAME_CFG01 }}
7 retry: {count: 1, delay: 5}
8 skip_fail: false
9
10- description: Check the etcd health
11 cmd: salt --hard-crash --state-output=mixed --state-verbose=False
12 -C 'I@etcd:server' cmd.run '. /var/lib/etcd/configenv && etcdctl cluster-health'
13 node_name: {{ HOSTNAME_CFG01 }}
14 retry: {count: 1, delay: 5}
15 skip_fail: false
16
17- description: Install Kubernetes and Calico
18 cmd: salt --hard-crash --state-output=mixed --state-verbose=False
19 -C 'I@kubernetes:master' state.sls kubernetes.master.kube-addons;
20 salt --hard-crash --state-output=mixed --state-verbose=False -C 'I@kubernetes:pool' state.sls kubernetes.pool;
21 salt --hard-crash --state-output=mixed --state-verbose=False -C 'I@kubernetes:pool' cmd.run 'calicoctl node status';
22 node_name: {{ HOSTNAME_CFG01 }}
Victor Ryzhenkin3ffa2b42017-10-05 16:38:44 +040023 retry: {count: 3, delay: 5}
Artem Panchenkoedf70ef2017-06-13 09:14:34 +030024 skip_fail: false
25
26- description: Setup NAT for Calico
27 cmd: salt --hard-crash --state-output=mixed --state-verbose=False
28 -C 'I@etcd:server' --subset 1 state.sls etcd.server.setup
29 node_name: {{ HOSTNAME_CFG01 }}
30 retry: {count: 1, delay: 5}
31 skip_fail: false
32
33- description: Run whole master to check consistency
34 cmd: salt --hard-crash --state-output=mixed --state-verbose=False
35 -C 'I@kubernetes:master' state.sls kubernetes exclude=kubernetes.master.setup
36 node_name: {{ HOSTNAME_CFG01 }}
37 retry: {count: 1, delay: 5}
38 skip_fail: true
39
akasatkin6a3c36e2017-08-21 19:25:00 +030040- description: Restart kubelet
41 cmd: salt --hard-crash --state-output=mixed --state-verbose=False
42 -C 'I@kubernetes:pool' service.restart kubelet
43 node_name: {{ HOSTNAME_CFG01 }}
44 retry: {count: 1, delay: 5}
45 skip_fail: false
46
Artem Panchenkoedf70ef2017-06-13 09:14:34 +030047- description: Register addons
48 cmd: salt --hard-crash --state-output=mixed --state-verbose=False
49 -C 'I@kubernetes:master' --subset 1 state.sls kubernetes.master.setup
50 node_name: {{ HOSTNAME_CFG01 }}
51 retry: {count: 1, delay: 5}
52 skip_fail: false