dis | c529838 | 2016-11-23 16:03:33 +0200 | [diff] [blame] | 1 | # Install support services |
dis | f0924fb | 2016-12-03 04:01:12 +0200 | [diff] [blame] | 2 | |
| 3 | - description: Install keepalived |
| 4 | cmd: salt --hard-crash --state-output=mixed --state-verbose=False |
| 5 | -C 'I@keepalived:cluster' state.sls keepalived -b 1 |
dis | c529838 | 2016-11-23 16:03:33 +0200 | [diff] [blame] | 6 | node_name: cfg01.mk22-qa-lab01.local |
| 7 | retry: {count: 10, delay: 10} |
| 8 | skip_fail: true |
dis | f0924fb | 2016-12-03 04:01:12 +0200 | [diff] [blame] | 9 | |
dis | c529838 | 2016-11-23 16:03:33 +0200 | [diff] [blame] | 10 | - description: Check the VIP |
dis | f0924fb | 2016-12-03 04:01:12 +0200 | [diff] [blame] | 11 | cmd: salt --hard-crash --state-output=mixed --state-verbose=False |
| 12 | -C 'I@keepalived:cluster' cmd.run 'ip a | grep 172.16.10.2' | grep -B1 172.16.10.2 |
dis | c529838 | 2016-11-23 16:03:33 +0200 | [diff] [blame] | 13 | node_name: cfg01.mk22-qa-lab01.local |
| 14 | retry: {count: 3, delay: 5} |
| 15 | skip_fail: false |
| 16 | |
| 17 | |
dis | f0924fb | 2016-12-03 04:01:12 +0200 | [diff] [blame] | 18 | - description: Install glusterfs |
| 19 | cmd: salt --hard-crash --state-output=mixed --state-verbose=False |
| 20 | -C 'I@glusterfs:server' state.sls glusterfs.server.service |
dis | c529838 | 2016-11-23 16:03:33 +0200 | [diff] [blame] | 21 | node_name: cfg01.mk22-qa-lab01.local |
| 22 | retry: {count: 3, delay: 5} |
| 23 | skip_fail: false |
dis | f0924fb | 2016-12-03 04:01:12 +0200 | [diff] [blame] | 24 | |
dis | c529838 | 2016-11-23 16:03:33 +0200 | [diff] [blame] | 25 | - description: Setup glusterfs on primary controller |
dis | f0924fb | 2016-12-03 04:01:12 +0200 | [diff] [blame] | 26 | cmd: salt --hard-crash --state-output=mixed --state-verbose=False |
| 27 | -C 'I@glusterfs:server' state.sls glusterfs.server.setup -b 1 |
dis | c529838 | 2016-11-23 16:03:33 +0200 | [diff] [blame] | 28 | node_name: cfg01.mk22-qa-lab01.local |
| 29 | retry: {count: 3, delay: 5} |
| 30 | skip_fail: false |
dis | f0924fb | 2016-12-03 04:01:12 +0200 | [diff] [blame] | 31 | |
dis | c529838 | 2016-11-23 16:03:33 +0200 | [diff] [blame] | 32 | - description: Check the gluster status |
dis | f0924fb | 2016-12-03 04:01:12 +0200 | [diff] [blame] | 33 | cmd: salt --hard-crash --state-output=mixed --state-verbose=False |
| 34 | -C 'I@glusterfs:server' cmd.run 'gluster peer status; gluster volume status' -b 1 |
dis | c529838 | 2016-11-23 16:03:33 +0200 | [diff] [blame] | 35 | node_name: cfg01.mk22-qa-lab01.local |
| 36 | retry: {count: 3, delay: 5} |
| 37 | skip_fail: false |
dis | f0924fb | 2016-12-03 04:01:12 +0200 | [diff] [blame] | 38 | |
| 39 | |
| 40 | - description: Install RabbitMQ |
| 41 | cmd: salt --hard-crash --state-output=mixed --state-verbose=False |
| 42 | -C 'I@rabbitmq:server' state.sls rabbitmq |
dis | c529838 | 2016-11-23 16:03:33 +0200 | [diff] [blame] | 43 | node_name: cfg01.mk22-qa-lab01.local |
| 44 | retry: {count: 3, delay: 5} |
| 45 | skip_fail: false |
dis | f0924fb | 2016-12-03 04:01:12 +0200 | [diff] [blame] | 46 | |
dis | c529838 | 2016-11-23 16:03:33 +0200 | [diff] [blame] | 47 | - description: Check the rabbitmq status |
dis | f0924fb | 2016-12-03 04:01:12 +0200 | [diff] [blame] | 48 | cmd: salt --hard-crash --state-output=mixed --state-verbose=False |
| 49 | -C 'I@rabbitmq:server' cmd.run 'rabbitmqctl cluster_status' |
dis | c529838 | 2016-11-23 16:03:33 +0200 | [diff] [blame] | 50 | node_name: cfg01.mk22-qa-lab01.local |
| 51 | retry: {count: 3, delay: 5} |
| 52 | skip_fail: false |
dis | f0924fb | 2016-12-03 04:01:12 +0200 | [diff] [blame] | 53 | |
| 54 | |
dis | f0924fb | 2016-12-03 04:01:12 +0200 | [diff] [blame] | 55 | - description: Install Galera on first server |
| 56 | cmd: salt --hard-crash --state-output=mixed --state-verbose=False |
| 57 | -C 'I@galera:master' state.sls galera |
dis | c529838 | 2016-11-23 16:03:33 +0200 | [diff] [blame] | 58 | node_name: cfg01.mk22-qa-lab01.local |
| 59 | retry: {count: 3, delay: 5} |
| 60 | skip_fail: false |
dis | f0924fb | 2016-12-03 04:01:12 +0200 | [diff] [blame] | 61 | |
| 62 | - description: Install Galera on other servers |
| 63 | cmd: salt --hard-crash --state-output=mixed --state-verbose=False |
| 64 | -C 'I@galera:slave' state.sls galera |
dis | c529838 | 2016-11-23 16:03:33 +0200 | [diff] [blame] | 65 | node_name: cfg01.mk22-qa-lab01.local |
| 66 | retry: {count: 3, delay: 5} |
| 67 | skip_fail: false |
dis | f0924fb | 2016-12-03 04:01:12 +0200 | [diff] [blame] | 68 | |
dis | c529838 | 2016-11-23 16:03:33 +0200 | [diff] [blame] | 69 | - description: Check mysql status |
dis | f0924fb | 2016-12-03 04:01:12 +0200 | [diff] [blame] | 70 | cmd: salt --hard-crash --state-output=mixed --state-verbose=False |
| 71 | -C 'I@galera:*' mysql.status | grep -A1 -e "wsrep_incoming_addresses\|wsrep_cluster_size" |
dis | c529838 | 2016-11-23 16:03:33 +0200 | [diff] [blame] | 72 | node_name: cfg01.mk22-qa-lab01.local |
| 73 | retry: {count: 3, delay: 5} |
| 74 | skip_fail: true |
dis | f0924fb | 2016-12-03 04:01:12 +0200 | [diff] [blame] | 75 | |
| 76 | |
| 77 | - description: Install haproxy |
| 78 | cmd: salt --hard-crash --state-output=mixed --state-verbose=False |
| 79 | -C 'I@haproxy:proxy' state.sls haproxy |
dis | c529838 | 2016-11-23 16:03:33 +0200 | [diff] [blame] | 80 | node_name: cfg01.mk22-qa-lab01.local |
| 81 | retry: {count: 3, delay: 5} |
| 82 | skip_fail: false |
dis | f0924fb | 2016-12-03 04:01:12 +0200 | [diff] [blame] | 83 | |
| 84 | - description: Check haproxy status |
| 85 | cmd: salt --hard-crash --state-output=mixed --state-verbose=False |
| 86 | -C 'I@haproxy:proxy' service.status haproxy |
dis | c529838 | 2016-11-23 16:03:33 +0200 | [diff] [blame] | 87 | node_name: cfg01.mk22-qa-lab01.local |
| 88 | retry: {count: 3, delay: 5} |
| 89 | skip_fail: false |
dis | f0924fb | 2016-12-03 04:01:12 +0200 | [diff] [blame] | 90 | |
| 91 | - description: Restart rsyslog |
| 92 | cmd: salt --hard-crash --state-output=mixed --state-verbose=False |
| 93 | -C 'I@haproxy:proxy' service.restart rsyslog |
dis | c529838 | 2016-11-23 16:03:33 +0200 | [diff] [blame] | 94 | node_name: cfg01.mk22-qa-lab01.local |
| 95 | retry: {count: 3, delay: 5} |
| 96 | skip_fail: false |
dis | f0924fb | 2016-12-03 04:01:12 +0200 | [diff] [blame] | 97 | |
dis | c529838 | 2016-11-23 16:03:33 +0200 | [diff] [blame] | 98 | - description: Install memcached on all controllers |
dis | f0924fb | 2016-12-03 04:01:12 +0200 | [diff] [blame] | 99 | cmd: salt --hard-crash --state-output=mixed --state-verbose=False |
| 100 | -C 'I@memcached:server' state.sls memcached |
dis | c529838 | 2016-11-23 16:03:33 +0200 | [diff] [blame] | 101 | node_name: cfg01.mk22-qa-lab01.local |
| 102 | retry: {count: 3, delay: 5} |
| 103 | skip_fail: false |