Illia Polliul | 2a2b6d1 | 2017-05-29 17:05:11 +0200 | [diff] [blame] | 1 | {% from 'virtual-mcp10-contrail/underlay.yaml' import HOSTNAME_CFG01 with context %} |
| 2 | |
| 3 | # Install OpenStack control services |
Illia Polliul | 87f8eb6 | 2017-08-03 11:15:30 +0200 | [diff] [blame] | 4 | - description: Downgrade libc for glance |
| 5 | cmd: salt --hard-crash --state-output=mixed --state-verbose=False |
| 6 | -C 'I@glance:server' cmd.run ' apt install libc6=2.19-0ubuntu6.11 -y --force-yes' |
| 7 | node_name: {{ HOSTNAME_CFG01 }} |
| 8 | retry: {count: 1, delay: 5} |
| 9 | skip_fail: false |
Illia Polliul | 2a2b6d1 | 2017-05-29 17:05:11 +0200 | [diff] [blame] | 10 | |
| 11 | - description: Install glance on all controllers |
Illia Polliul | 323d727 | 2017-05-29 18:24:28 +0200 | [diff] [blame] | 12 | cmd: salt --hard-crash --state-output=mixed --state-verbose=False |
Illia Polliul | 2a2b6d1 | 2017-05-29 17:05:11 +0200 | [diff] [blame] | 13 | -C 'I@glance:server' state.sls glance -b 1 |
| 14 | node_name: {{ HOSTNAME_CFG01 }} |
| 15 | retry: {count: 1, delay: 5} |
| 16 | skip_fail: false |
| 17 | |
| 18 | - description: Install keystone service (note that different fernet keys are created on different nodes) |
Illia Polliul | 323d727 | 2017-05-29 18:24:28 +0200 | [diff] [blame] | 19 | cmd: salt --hard-crash --state-output=mixed --state-verbose=False |
Illia Polliul | 2a2b6d1 | 2017-05-29 17:05:11 +0200 | [diff] [blame] | 20 | -C 'I@keystone:server' state.sls keystone.server -b 1 |
| 21 | node_name: {{ HOSTNAME_CFG01 }} |
| 22 | retry: {count: 2, delay: 15} |
| 23 | skip_fail: false |
| 24 | |
Illia Polliul | 323d727 | 2017-05-29 18:24:28 +0200 | [diff] [blame] | 25 | #- description: Restart apache due to PROD-10477 |
| 26 | # cmd: salt --hard-crash --state-output=mixed --state-verbose=False 'ctl*' cmd.run "systemctl restart apache2" |
| 27 | # node_name: {{ HOSTNAME_CFG01 }} |
| 28 | # retry: {count: 1, delay: 15} |
| 29 | # skip_fail: false |
| 30 | # |
| 31 | #- description: Check apache status to PROD-10477 |
| 32 | # cmd: salt --hard-crash --state-output=mixed --state-verbose=False 'ctl*' cmd.run "systemctl status apache2" |
| 33 | # node_name: {{ HOSTNAME_CFG01 }} |
| 34 | # retry: {count: 1, delay: 15} |
| 35 | # skip_fail: false |
Illia Polliul | 2a2b6d1 | 2017-05-29 17:05:11 +0200 | [diff] [blame] | 36 | |
| 37 | - description: Mount glusterfs.client volumes (resuires created 'keystone' and 'glusterfs' system users) |
Illia Polliul | 323d727 | 2017-05-29 18:24:28 +0200 | [diff] [blame] | 38 | cmd: salt --hard-crash --state-output=mixed --state-verbose=False |
Illia Polliul | 2a2b6d1 | 2017-05-29 17:05:11 +0200 | [diff] [blame] | 39 | -C 'I@glance:server' state.sls glusterfs.client |
| 40 | node_name: {{ HOSTNAME_CFG01 }} |
Illia Polliul | 323d727 | 2017-05-29 18:24:28 +0200 | [diff] [blame] | 41 | retry: {count: 2, delay: 5} |
Illia Polliul | 2a2b6d1 | 2017-05-29 17:05:11 +0200 | [diff] [blame] | 42 | skip_fail: false |
| 43 | |
| 44 | - description: Update fernet keys for keystone server on the mounted glusterfs volume |
Illia Polliul | 323d727 | 2017-05-29 18:24:28 +0200 | [diff] [blame] | 45 | cmd: salt --hard-crash --state-output=mixed --state-verbose=False |
Illia Polliul | 2a2b6d1 | 2017-05-29 17:05:11 +0200 | [diff] [blame] | 46 | -C 'I@keystone:server' state.sls keystone.server -b 1 |
| 47 | node_name: {{ HOSTNAME_CFG01 }} |
| 48 | retry: {count: 1, delay: 5} |
| 49 | skip_fail: false |
| 50 | |
| 51 | - description: Populate keystone services/tenants/admins |
Illia Polliul | 323d727 | 2017-05-29 18:24:28 +0200 | [diff] [blame] | 52 | cmd: salt --hard-crash --state-output=mixed --state-verbose=False |
Illia Polliul | 2a2b6d1 | 2017-05-29 17:05:11 +0200 | [diff] [blame] | 53 | -C 'I@keystone:client' state.sls keystone.client |
| 54 | node_name: {{ HOSTNAME_CFG01 }} |
| 55 | retry: {count: 1, delay: 5} |
| 56 | skip_fail: false |
| 57 | |
| 58 | - description: Check keystone service-list |
Illia Polliul | 323d727 | 2017-05-29 18:24:28 +0200 | [diff] [blame] | 59 | cmd: salt --hard-crash --state-output=mixed --state-verbose=False |
Illia Polliul | 2a2b6d1 | 2017-05-29 17:05:11 +0200 | [diff] [blame] | 60 | -C 'I@keystone:server' cmd.run '. /root/keystonerc; openstack service list' |
| 61 | node_name: {{ HOSTNAME_CFG01 }} |
| 62 | retry: {count: 1, delay: 5} |
| 63 | skip_fail: false |
| 64 | |
| 65 | - description: Check glance image-list |
Illia Polliul | 323d727 | 2017-05-29 18:24:28 +0200 | [diff] [blame] | 66 | cmd: salt --hard-crash --state-output=mixed --state-verbose=False |
Illia Polliul | 2a2b6d1 | 2017-05-29 17:05:11 +0200 | [diff] [blame] | 67 | -C 'I@keystone:server' cmd.run '. /root/keystonerc; glance image-list' |
| 68 | node_name: {{ HOSTNAME_CFG01 }} |
| 69 | retry: {count: 1, delay: 5} |
| 70 | skip_fail: false |
| 71 | |
| 72 | |
| 73 | - description: Install nova on all controllers |
Illia Polliul | 323d727 | 2017-05-29 18:24:28 +0200 | [diff] [blame] | 74 | cmd: salt --hard-crash --state-output=mixed --state-verbose=False |
Illia Polliul | 2a2b6d1 | 2017-05-29 17:05:11 +0200 | [diff] [blame] | 75 | -C 'I@nova:controller' state.sls nova -b 1 |
| 76 | node_name: {{ HOSTNAME_CFG01 }} |
| 77 | retry: {count: 2, delay: 5} |
| 78 | skip_fail: false |
| 79 | |
| 80 | - description: Check nova service-list |
Illia Polliul | 323d727 | 2017-05-29 18:24:28 +0200 | [diff] [blame] | 81 | cmd: salt --hard-crash --state-output=mixed --state-verbose=False |
Illia Polliul | 2a2b6d1 | 2017-05-29 17:05:11 +0200 | [diff] [blame] | 82 | -C 'I@keystone:server' cmd.run '. /root/keystonerc; nova service-list' |
| 83 | node_name: {{ HOSTNAME_CFG01 }} |
Illia Polliul | 323d727 | 2017-05-29 18:24:28 +0200 | [diff] [blame] | 84 | retry: {count: 3, delay: 5} |
Illia Polliul | 2a2b6d1 | 2017-05-29 17:05:11 +0200 | [diff] [blame] | 85 | skip_fail: false |
| 86 | |
| 87 | |
| 88 | - description: Install cinder |
Illia Polliul | 323d727 | 2017-05-29 18:24:28 +0200 | [diff] [blame] | 89 | cmd: salt --hard-crash --state-output=mixed --state-verbose=False |
Illia Polliul | 2a2b6d1 | 2017-05-29 17:05:11 +0200 | [diff] [blame] | 90 | -C 'I@cinder:controller' state.sls cinder -b 1 |
| 91 | node_name: {{ HOSTNAME_CFG01 }} |
| 92 | retry: {count: 1, delay: 5} |
| 93 | skip_fail: false |
| 94 | |
| 95 | - description: Check cinder list |
Illia Polliul | 323d727 | 2017-05-29 18:24:28 +0200 | [diff] [blame] | 96 | cmd: salt --hard-crash --state-output=mixed --state-verbose=False |
Illia Polliul | 2a2b6d1 | 2017-05-29 17:05:11 +0200 | [diff] [blame] | 97 | -C 'I@keystone:server' cmd.run '. /root/keystonerc; cinder list' |
| 98 | node_name: {{ HOSTNAME_CFG01 }} |
| 99 | retry: {count: 1, delay: 5} |
| 100 | skip_fail: false |
| 101 | |
| 102 | |
| 103 | - description: Install neutron service |
Illia Polliul | 323d727 | 2017-05-29 18:24:28 +0200 | [diff] [blame] | 104 | cmd: salt --hard-crash --state-output=mixed --state-verbose=False |
Illia Polliul | 2a2b6d1 | 2017-05-29 17:05:11 +0200 | [diff] [blame] | 105 | -C 'I@neutron:server' state.sls neutron -b 1 |
| 106 | node_name: {{ HOSTNAME_CFG01 }} |
| 107 | retry: {count: 1, delay: 5} |
| 108 | skip_fail: false |
| 109 | |
| 110 | # |
| 111 | #- description: Install neutron on gtw node |
| 112 | # cmd: salt --hard-crash --state-output=mixed --state-verbose=False |
| 113 | # -C 'I@neutron:gateway' state.sls neutron |
| 114 | # node_name: {{ HOSTNAME_CFG01 }} |
| 115 | # retry: {count: 1, delay: 5} |
| 116 | # skip_fail: false |
| 117 | |
| 118 | |
| 119 | #- description: Check neutron agent-list |
| 120 | # cmd: salt --hard-crash --state-output=mixed --state-verbose=False |
| 121 | # -C 'I@keystone:server' cmd.run '. /root/keystonerc; neutron agent-list' |
| 122 | # node_name: {{ HOSTNAME_CFG01 }} |
| 123 | # retry: {count: 1, delay: 5} |
| 124 | # skip_fail: false |
| 125 | |
| 126 | # install contrail |
| 127 | - description: Install contrail db |
Illia Polliul | 323d727 | 2017-05-29 18:24:28 +0200 | [diff] [blame] | 128 | cmd: salt --hard-crash --state-output=mixed --state-verbose=False |
Illia Polliul | 2a2b6d1 | 2017-05-29 17:05:11 +0200 | [diff] [blame] | 129 | -C 'I@opencontrail:database' state.sls opencontrail.database |
| 130 | node_name: {{ HOSTNAME_CFG01 }} |
| 131 | retry: {count: 2, delay: 20} |
| 132 | skip_fail: false |
| 133 | |
| 134 | - description: Install contrail on 1st node and skip client part |
| 135 | cmd: salt --hard-crash --state-output=mixed --state-verbose=False |
| 136 | -C 'I@opencontrail:control and *01*' state.sls opencontrail exclude=opencontrail.client |
| 137 | node_name: {{ HOSTNAME_CFG01 }} |
| 138 | retry: {count: 3, delay: 5} |
| 139 | skip_fail: false |
| 140 | |
| 141 | - description: Install contrail on all nodes still skipping client |
| 142 | cmd: salt --hard-crash --state-output=mixed --state-verbose=Falsa |
| 143 | -C 'I@opencontrail:control' state.sls opencontrail exclude=opencontrail.client |
| 144 | node_name: {{ HOSTNAME_CFG01 }} |
| 145 | retry: {count: 2, delay: 5} |
| 146 | skip_fail: false |
| 147 | |
| 148 | - description: Install contrail and do client part as well |
| 149 | cmd: salt --hard-crash --state-output=mixed --state-verbose=False |
| 150 | -C 'I@opencontrail:control' state.sls opencontrail |
| 151 | node_name: {{ HOSTNAME_CFG01 }} |
| 152 | retry: {count: 1, delay: 5} |
| 153 | skip_fail: false |
| 154 | |
| 155 | - description: Configure contrail |
| 156 | cmd: salt --hard-crash --state-output=mixed --state-verbose=False |
| 157 | -C 'I@opencontrail:database:id:1' state.sls opencontrail.client |
| 158 | node_name: {{ HOSTNAME_CFG01 }} |
| 159 | retry: {count: 1, delay: 5} |
| 160 | skip_fail: false |
| 161 | |
| 162 | - description: Check contrail status |
| 163 | cmd: salt --hard-crash --state-output=mixed --state-verbose=False |
| 164 | -C 'I@opencontrail:control' cmd.run contrail-status |
| 165 | node_name: {{ HOSTNAME_CFG01 }} |
| 166 | retry: {count: 1, delay: 5} |
| 167 | skip_fail: false |
| 168 | |
| 169 | - description: Install heat service |
Illia Polliul | 323d727 | 2017-05-29 18:24:28 +0200 | [diff] [blame] | 170 | cmd: salt --hard-crash --state-output=mixed --state-verbose=False |
Illia Polliul | 2a2b6d1 | 2017-05-29 17:05:11 +0200 | [diff] [blame] | 171 | -C 'I@heat:server' state.sls heat -b 1 |
| 172 | node_name: {{ HOSTNAME_CFG01 }} |
| 173 | retry: {count: 1, delay: 5} |
| 174 | skip_fail: false |
| 175 | |
| 176 | - description: Check heat service |
Illia Polliul | 323d727 | 2017-05-29 18:24:28 +0200 | [diff] [blame] | 177 | cmd: salt --hard-crash --state-output=mixed --state-verbose=False |
Illia Polliul | 2a2b6d1 | 2017-05-29 17:05:11 +0200 | [diff] [blame] | 178 | -C 'I@keystone:server' cmd.run '. /root/keystonerc; heat resource-type-list' |
| 179 | node_name: {{ HOSTNAME_CFG01 }} |
| 180 | retry: {count: 1, delay: 5} |
| 181 | skip_fail: false |
| 182 | |
| 183 | |
| 184 | - description: Deploy horizon dashboard |
Illia Polliul | 323d727 | 2017-05-29 18:24:28 +0200 | [diff] [blame] | 185 | cmd: salt --hard-crash --state-output=mixed --state-verbose=False |
Illia Polliul | 2a2b6d1 | 2017-05-29 17:05:11 +0200 | [diff] [blame] | 186 | -C 'I@horizon:server' state.sls horizon |
| 187 | node_name: {{ HOSTNAME_CFG01 }} |
| 188 | retry: {count: 1, delay: 5} |
| 189 | skip_fail: true |
| 190 | |
| 191 | - description: Deploy nginx proxy |
Illia Polliul | 323d727 | 2017-05-29 18:24:28 +0200 | [diff] [blame] | 192 | cmd: salt --hard-crash --state-output=mixed --state-verbose=False |
Illia Polliul | 2a2b6d1 | 2017-05-29 17:05:11 +0200 | [diff] [blame] | 193 | -C 'I@nginx:server' state.sls nginx |
| 194 | node_name: {{ HOSTNAME_CFG01 }} |
| 195 | retry: {count: 1, delay: 5} |
| 196 | skip_fail: true |
| 197 | |
| 198 | |
| 199 | # Install compute node |
| 200 | |
| 201 | - description: Apply formulas for compute node |
| 202 | cmd: salt --hard-crash --state-output=mixed --state-verbose=False 'cmp*' state.apply |
| 203 | node_name: {{ HOSTNAME_CFG01 }} |
| 204 | retry: {count: 1, delay: 5} |
| 205 | skip_fail: true |
| 206 | |
| 207 | - description: Re-apply(as in doc) formulas for compute node |
| 208 | cmd: salt --hard-crash --state-output=mixed --state-verbose=False 'cmp*' state.apply |
| 209 | node_name: {{ HOSTNAME_CFG01 }} |
| 210 | retry: {count: 1, delay: 5} |
Oleksii Butenko | 9f2601c | 2018-02-08 15:13:21 +0200 | [diff] [blame] | 211 | skip_fail: false |
Illia Polliul | 2a2b6d1 | 2017-05-29 17:05:11 +0200 | [diff] [blame] | 212 | |
| 213 | - description: Check IP on computes |
| 214 | cmd: salt --hard-crash --state-output=mixed --state-verbose=False 'cmp*' cmd.run |
| 215 | 'ip a' |
| 216 | node_name: {{ HOSTNAME_CFG01 }} |
| 217 | retry: {count: 10, delay: 30} |
| 218 | skip_fail: false |
| 219 | |
Illia Polliul | ea26c1e | 2017-06-10 14:13:51 +0200 | [diff] [blame] | 220 | - description: Provision Contrail-vRouter on Computes |
Illia Polliul | 2a2b6d1 | 2017-05-29 17:05:11 +0200 | [diff] [blame] | 221 | cmd: salt --hard-crash --state-output=mixed --state-verbose=False |
Illia Polliul | ea26c1e | 2017-06-10 14:13:51 +0200 | [diff] [blame] | 222 | -C 'I@opencontrail:compute' state.sls 'opencontrail.client' |
Illia Polliul | 2a2b6d1 | 2017-05-29 17:05:11 +0200 | [diff] [blame] | 223 | node_name: {{ HOSTNAME_CFG01 }} |
| 224 | retry: {count: 1, delay: 5} |
| 225 | skip_fail: false |
| 226 | |
Illia Polliul | ea26c1e | 2017-06-10 14:13:51 +0200 | [diff] [blame] | 227 | - description: Install Opencontrail on computes |
| 228 | cmd: salt --hard-crash --state-output=mixed --state-verbose=False |
| 229 | -C 'I@opencontrail:compute' state.sls 'opencontrail' |
Illia Polliul | 2a2b6d1 | 2017-05-29 17:05:11 +0200 | [diff] [blame] | 230 | node_name: {{ HOSTNAME_CFG01 }} |
| 231 | retry: {count: 1, delay: 5} |
| 232 | skip_fail: false |
Illia Polliul | ea26c1e | 2017-06-10 14:13:51 +0200 | [diff] [blame] | 233 | |
| 234 | - description: Reboot Opencontrail compute nodes |
| 235 | cmd: salt --hard-crash --state-output=mixed --state-verbose=False |
| 236 | -C 'I@opencontrail:compute' system.reboot |
| 237 | node_name: {{ HOSTNAME_CFG01 }} |
| 238 | retry: {count: 1, delay: 5} |
| 239 | skip_fail: false |