Jiri Broulik | 99887c8 | 2017-10-31 09:27:52 +0100 | [diff] [blame] | 1 | /** |
| 2 | * |
| 3 | * Remove Ceph node from existing cluster |
| 4 | * |
| 5 | * Requred parameters: |
| 6 | * SALT_MASTER_URL URL of Salt master |
| 7 | * SALT_MASTER_CREDENTIALS Credentials to the Salt API |
| 8 | * HOST Host (minion id) to be removed |
| 9 | * HOST_TYPE Type of Ceph node to be removed. Valid values are mon/osd/rgw |
| 10 | * ADMIN_HOST Host (minion id) with admin keyring |
| 11 | * WAIT_FOR_HEALTHY Wait for cluster rebalance before stoping daemons |
| 12 | * GENERATE_CRUSHMAP Set to true if the crush map should be generated |
| 13 | * |
| 14 | */ |
| 15 | |
Ivan Berezovskiy | 19c685a | 2019-11-05 17:42:57 +0400 | [diff] [blame] | 16 | def common = new com.mirantis.mk.Common() |
| 17 | def salt = new com.mirantis.mk.Salt() |
| 18 | def ceph = new com.mirantis.mk.Ceph() |
Jiri Broulik | 99887c8 | 2017-10-31 09:27:52 +0100 | [diff] [blame] | 19 | def python = new com.mirantis.mk.Python() |
Jiri Broulik | 99887c8 | 2017-10-31 09:27:52 +0100 | [diff] [blame] | 20 | def pepperEnv = "pepperEnv" |
| 21 | |
Mateusz Los | 8b64b81 | 2020-05-11 10:33:58 +0200 | [diff] [blame] | 22 | def cleanDisk = CLEANDISK |
| 23 | |
Jakub Josef | a63f986 | 2018-01-11 17:58:38 +0100 | [diff] [blame] | 24 | timeout(time: 12, unit: 'HOURS') { |
| 25 | node("python") { |
Jiri Broulik | 96c867a | 2017-11-07 16:14:10 +0100 | [diff] [blame] | 26 | |
Jakub Josef | a63f986 | 2018-01-11 17:58:38 +0100 | [diff] [blame] | 27 | // create connection to salt master |
| 28 | python.setupPepperVirtualenv(pepperEnv, SALT_MASTER_URL, SALT_MASTER_CREDENTIALS) |
Jiri Broulik | 99887c8 | 2017-10-31 09:27:52 +0100 | [diff] [blame] | 29 | |
Jakub Josef | a63f986 | 2018-01-11 17:58:38 +0100 | [diff] [blame] | 30 | matches = ["osd", "mon", "rgw"] |
| 31 | def found = false |
| 32 | for (s in matches) { |
| 33 | if (HOST_TYPE.toLowerCase() == s) { |
| 34 | found = true |
Jiri Broulik | 99887c8 | 2017-10-31 09:27:52 +0100 | [diff] [blame] | 35 | } |
| 36 | } |
| 37 | |
Jakub Josef | a63f986 | 2018-01-11 17:58:38 +0100 | [diff] [blame] | 38 | if (!found) { |
| 39 | common.errorMsg("No such HOST_TYPE was found. Please insert one of the following types: mon/osd/rgw") |
| 40 | throw new InterruptedException() |
| 41 | } |
| 42 | |
Mateusz Los | 13d0520 | 2020-05-11 09:51:13 +0200 | [diff] [blame] | 43 | def checknode = salt.runSaltProcessStep(pepperEnv, HOST, 'test.ping') |
| 44 | if (checknode['return'][0].values().isEmpty()) { |
| 45 | common.errorMsg("Host not found") |
| 46 | throw new InterruptedException() |
| 47 | } |
| 48 | |
Jakub Josef | a63f986 | 2018-01-11 17:58:38 +0100 | [diff] [blame] | 49 | stage('Refresh_pillar') { |
| 50 | salt.runSaltProcessStep(pepperEnv, '*', 'saltutil.refresh_pillar', [], null, true, 5) |
| 51 | } |
| 52 | |
| 53 | // split minion id on '.' and remove '*' |
| 54 | def target = HOST.split("\\.")[0].replace("*", "") |
| 55 | |
| 56 | salt.runSaltProcessStep(pepperEnv, 'I@salt:master', 'saltutil.sync_grains', [], null, true, 5) |
| 57 | def _pillar = salt.getGrain(pepperEnv, 'I@salt:master', 'domain') |
| 58 | domain = _pillar['return'][0].values()[0].values()[0] |
| 59 | |
| 60 | if (HOST_TYPE.toLowerCase() == 'rgw') { |
| 61 | // Remove Ceph rgw |
| 62 | stage('Remove Ceph RGW') { |
| 63 | salt.enforceState(pepperEnv, 'I@ceph:radosgw', ['keepalived', 'haproxy'], true) |
Jiri Broulik | 99887c8 | 2017-10-31 09:27:52 +0100 | [diff] [blame] | 64 | } |
Mateusz Los | 9f50377 | 2019-05-07 15:10:45 +0200 | [diff] [blame] | 65 | |
| 66 | stage('Purge Ceph RGW pkgs') { |
| 67 | salt.runSaltProcessStep(pepperEnv, HOST, 'pkg.purge', 'ceph-common,libcephfs2,python-cephfs,radosgw,python-rados,python-rbd,python-rgw') |
| 68 | } |
Jiri Broulik | 99887c8 | 2017-10-31 09:27:52 +0100 | [diff] [blame] | 69 | } |
| 70 | |
Jakub Josef | a63f986 | 2018-01-11 17:58:38 +0100 | [diff] [blame] | 71 | if (HOST_TYPE.toLowerCase() != 'osd') { |
| 72 | |
| 73 | // virsh destroy rgw04.deploy-name.local; virsh undefine rgw04.deploy-name.local; |
| 74 | stage('Destroy/Undefine VM') { |
| 75 | _pillar = salt.getGrain(pepperEnv, 'I@salt:control', 'id') |
| 76 | def kvm01 = _pillar['return'][0].values()[0].values()[0] |
| 77 | |
| 78 | _pillar = salt.getPillar(pepperEnv, "${kvm01}", "salt:control:cluster:internal:node:${target}:provider") |
| 79 | def targetProvider = _pillar['return'][0].values()[0] |
| 80 | |
| 81 | salt.cmdRun(pepperEnv, "${targetProvider}", "virsh destroy ${target}.${domain}") |
| 82 | salt.cmdRun(pepperEnv, "${targetProvider}", "virsh undefine ${target}.${domain}") |
| 83 | } |
Mateusz Los | 8b64b81 | 2020-05-11 10:33:58 +0200 | [diff] [blame] | 84 | } |
| 85 | else if (HOST_TYPE.toLowerCase() == 'osd') { |
Jakub Josef | a63f986 | 2018-01-11 17:58:38 +0100 | [diff] [blame] | 86 | def osd_ids = [] |
Mateusz Los | 2ae66db | 2020-04-28 16:36:11 +0200 | [diff] [blame] | 87 | def device_grain_name = "ceph_disk" |
Jakub Josef | a63f986 | 2018-01-11 17:58:38 +0100 | [diff] [blame] | 88 | // get list of osd disks of the host |
| 89 | salt.runSaltProcessStep(pepperEnv, HOST, 'saltutil.sync_grains', [], null, true, 5) |
mjedynski | 12955c7 | 2019-12-09 15:17:58 +0100 | [diff] [blame] | 90 | def ceph_disks = salt.getGrain(pepperEnv, HOST, 'ceph')['return'][0].values()[0].values()[0][device_grain_name] |
Jakub Josef | a63f986 | 2018-01-11 17:58:38 +0100 | [diff] [blame] | 91 | |
| 92 | for (i in ceph_disks) { |
| 93 | def osd_id = i.getKey().toString() |
| 94 | osd_ids.add('osd.' + osd_id) |
| 95 | print("Will delete " + osd_id) |
| 96 | } |
| 97 | |
| 98 | // `ceph osd out <id> <id>` |
| 99 | stage('Set OSDs out') { |
Ivan Berezovskiy | 19c685a | 2019-11-05 17:42:57 +0400 | [diff] [blame] | 100 | salt.cmdRun(pepperEnv, ADMIN_HOST, 'ceph osd out ' + osd_ids.join(' ')) |
Jakub Josef | a63f986 | 2018-01-11 17:58:38 +0100 | [diff] [blame] | 101 | } |
| 102 | |
| 103 | // wait for healthy cluster |
Ivan Berezovskiy | 19c685a | 2019-11-05 17:42:57 +0400 | [diff] [blame] | 104 | if (WAIT_FOR_HEALTHY.toBoolean()) { |
Jakub Josef | a63f986 | 2018-01-11 17:58:38 +0100 | [diff] [blame] | 105 | sleep(5) |
Ivan Berezovskiy | 19c685a | 2019-11-05 17:42:57 +0400 | [diff] [blame] | 106 | ceph.waitForHealthy(pepperEnv, ADMIN_HOST) |
Jakub Josef | a63f986 | 2018-01-11 17:58:38 +0100 | [diff] [blame] | 107 | } |
| 108 | |
| 109 | // stop osd daemons |
| 110 | stage('Stop OSD daemons') { |
| 111 | for (i in osd_ids) { |
Ivan Berezovskiy | 19c685a | 2019-11-05 17:42:57 +0400 | [diff] [blame] | 112 | salt.runSaltProcessStep(pepperEnv, HOST, 'service.stop', ['ceph-osd@' + i.replaceAll('osd.', '')], null, true) |
Jakub Josef | a63f986 | 2018-01-11 17:58:38 +0100 | [diff] [blame] | 113 | } |
| 114 | } |
| 115 | |
| 116 | // `ceph osd crush remove osd.2` |
| 117 | stage('Remove OSDs from CRUSH') { |
| 118 | for (i in osd_ids) { |
Ivan Berezovskiy | 19c685a | 2019-11-05 17:42:57 +0400 | [diff] [blame] | 119 | salt.cmdRun(pepperEnv, ADMIN_HOST, 'ceph osd crush remove ' + i) |
Jakub Josef | a63f986 | 2018-01-11 17:58:38 +0100 | [diff] [blame] | 120 | } |
| 121 | } |
| 122 | |
| 123 | // remove keyring `ceph auth del osd.3` |
| 124 | stage('Remove OSD keyrings from auth') { |
| 125 | for (i in osd_ids) { |
Ivan Berezovskiy | 19c685a | 2019-11-05 17:42:57 +0400 | [diff] [blame] | 126 | salt.cmdRun(pepperEnv, ADMIN_HOST, 'ceph auth del ' + i) |
Jakub Josef | a63f986 | 2018-01-11 17:58:38 +0100 | [diff] [blame] | 127 | } |
| 128 | } |
| 129 | |
| 130 | // remove osd `ceph osd rm osd.3` |
| 131 | stage('Remove OSDs') { |
| 132 | for (i in osd_ids) { |
Ivan Berezovskiy | 19c685a | 2019-11-05 17:42:57 +0400 | [diff] [blame] | 133 | salt.cmdRun(pepperEnv, ADMIN_HOST, 'ceph osd rm ' + i) |
Jakub Josef | a63f986 | 2018-01-11 17:58:38 +0100 | [diff] [blame] | 134 | } |
| 135 | } |
| 136 | |
| 137 | for (osd_id in osd_ids) { |
Jakub Josef | a63f986 | 2018-01-11 17:58:38 +0100 | [diff] [blame] | 138 | id = osd_id.replaceAll('osd.', '') |
Jakub Josef | a63f986 | 2018-01-11 17:58:38 +0100 | [diff] [blame] | 139 | |
Jakub Josef | a63f986 | 2018-01-11 17:58:38 +0100 | [diff] [blame] | 140 | // remove journal, block_db, block_wal partition `parted /dev/sdj rm 3` |
| 141 | stage('Remove journal / block_db / block_wal partition') { |
| 142 | def partition_uuid = "" |
| 143 | def journal_partition_uuid = "" |
| 144 | def block_db_partition_uuid = "" |
| 145 | def block_wal_partition_uuid = "" |
Mateusz Los | 8b64b81 | 2020-05-11 10:33:58 +0200 | [diff] [blame] | 146 | def ceph_version = salt.getPillar(pepperEnv, HOST, 'ceph:common:ceph_version').get('return')[0].values()[0] |
| 147 | |
| 148 | if (ceph_version == "luminous") { |
| 149 | try { |
| 150 | journal_partition_uuid = salt.cmdRun(pepperEnv, HOST, "cat /var/lib/ceph/osd/ceph-${id}/journal_uuid")['return'][0].values()[0].split("\n")[0] |
| 151 | } |
| 152 | catch(Exception e) { |
| 153 | common.infoMsg(e) |
| 154 | } |
| 155 | try { |
| 156 | block_db_partition_uuid = salt.cmdRun(pepperEnv, HOST, "cat /var/lib/ceph/osd/ceph-${id}/block.db_uuid")['return'][0].values()[0].split("\n")[0] |
| 157 | } |
| 158 | catch(Exception e) { |
| 159 | common.infoMsg(e) |
| 160 | } |
| 161 | try { |
| 162 | block_wal_partition_uuid = salt.cmdRun(pepperEnv, HOST, "cat /var/lib/ceph/osd/ceph-${id}/block.wal_uuid")['return'][0].values()[0].split("\n")[0] |
| 163 | } |
| 164 | catch(Exception e) { |
| 165 | common.infoMsg(e) |
| 166 | } |
Jakub Josef | a63f986 | 2018-01-11 17:58:38 +0100 | [diff] [blame] | 167 | } |
Mateusz Los | 8b64b81 | 2020-05-11 10:33:58 +0200 | [diff] [blame] | 168 | else { |
| 169 | def volumes = salt.cmdRun(pepperEnv, HOST, "ceph-volume lvm list --format=json", checkResponse=true, batch=null, output=false) |
| 170 | volumes = new groovy.json.JsonSlurperClassic().parseText(volumes['return'][0].values()[0]) |
| 171 | |
| 172 | block_db_partition_uuid = volumes[id][0]['tags'].get('ceph.db_uuid') |
| 173 | block_wal_partition_uuid = volumes[id][0]['tags'].get('ceph.wal_uuid') |
Jakub Josef | a63f986 | 2018-01-11 17:58:38 +0100 | [diff] [blame] | 174 | } |
| 175 | |
Jakub Josef | a63f986 | 2018-01-11 17:58:38 +0100 | [diff] [blame] | 176 | |
Jakub Josef | a63f986 | 2018-01-11 17:58:38 +0100 | [diff] [blame] | 177 | if (journal_partition_uuid?.trim()) { |
Mateusz Los | 8b64b81 | 2020-05-11 10:33:58 +0200 | [diff] [blame] | 178 | ceph.removePartition(pepperEnv, HOST, journal_partition_uuid) |
Jakub Josef | a63f986 | 2018-01-11 17:58:38 +0100 | [diff] [blame] | 179 | } |
Mateusz Los | 8b64b81 | 2020-05-11 10:33:58 +0200 | [diff] [blame] | 180 | if (block_db_partition_uuid?.trim()) { |
| 181 | ceph.removePartition(pepperEnv, HOST, block_db_partition_uuid) |
Jakub Josef | a63f986 | 2018-01-11 17:58:38 +0100 | [diff] [blame] | 182 | } |
| 183 | if (block_wal_partition_uuid?.trim()) { |
Ivan Berezovskiy | 19c685a | 2019-11-05 17:42:57 +0400 | [diff] [blame] | 184 | ceph.removePartition(pepperEnv, HOST, block_wal_partition_uuid) |
Jakub Josef | a63f986 | 2018-01-11 17:58:38 +0100 | [diff] [blame] | 185 | } |
Mateusz Los | 8b64b81 | 2020-05-11 10:33:58 +0200 | [diff] [blame] | 186 | |
| 187 | try { |
| 188 | salt.cmdRun(pepperEnv, HOST, "partprobe") |
| 189 | } catch (Exception e) { |
| 190 | common.warningMsg(e) |
| 191 | } |
| 192 | } |
| 193 | |
| 194 | if (cleanDisk) { |
| 195 | // remove data / block / lockbox partition `parted /dev/sdj rm 3` |
| 196 | stage('Remove data / block / lockbox partition') { |
| 197 | def data_partition_uuid = "" |
| 198 | def block_partition_uuid = "" |
| 199 | def osd_fsid = "" |
| 200 | def lvm = "" |
| 201 | def lvm_enabled= salt.getPillar(pepperEnv,"I@ceph:osd","ceph:osd:lvm_enabled")['return'].first().containsValue(true) |
| 202 | try { |
| 203 | osd_fsid = salt.cmdRun(pepperEnv, HOST, "cat /var/lib/ceph/osd/ceph-${id}/fsid")['return'][0].values()[0].split("\n")[0] |
| 204 | if (lvm_enabled) { |
| 205 | lvm = salt.runSaltCommand(pepperEnv, 'local', ['expression': HOST, 'type': 'compound'], 'cmd.run', null, "salt-call lvm.lvdisplay --output json -l quiet")['return'][0].values()[0] |
| 206 | lvm = new groovy.json.JsonSlurperClassic().parseText(lvm) |
| 207 | lvm["local"].each { lv, params -> |
| 208 | if (params["Logical Volume Name"].contains(osd_fsid)) { |
| 209 | data_partition_uuid = params["Logical Volume Name"].minus("/dev/") |
| 210 | } |
| 211 | } |
| 212 | } else { |
| 213 | data_partition_uuid = osd_fsid |
| 214 | } |
| 215 | } catch (Exception e) { |
| 216 | common.infoMsg(e) |
| 217 | } |
| 218 | try { |
| 219 | block_partition_uuid = salt.cmdRun(pepperEnv, HOST, "cat /var/lib/ceph/osd/ceph-${id}/block_uuid")['return'][0].values()[0].split("\n")[0] |
| 220 | } |
| 221 | catch (Exception e) { |
| 222 | common.infoMsg(e) |
| 223 | } |
| 224 | |
| 225 | // remove partition_uuid = 2c76f144-f412-481e-b150-4046212ca932 |
| 226 | if (block_partition_uuid?.trim()) { |
| 227 | ceph.removePartition(pepperEnv, HOST, block_partition_uuid) |
| 228 | try { |
| 229 | salt.cmdRun(pepperEnv, HOST, "ceph-volume lvm zap `readlink /var/lib/ceph/osd/ceph-${id}/block` --destroy") |
| 230 | } |
| 231 | catch (Exception e) { |
| 232 | common.infoMsg(e) |
| 233 | } |
| 234 | } |
| 235 | if (data_partition_uuid?.trim()) { |
| 236 | ceph.removePartition(pepperEnv, HOST, data_partition_uuid, 'data', id) |
| 237 | } |
| 238 | } |
Jakub Josef | a63f986 | 2018-01-11 17:58:38 +0100 | [diff] [blame] | 239 | } |
| 240 | } |
| 241 | |
| 242 | // purge Ceph pkgs |
| 243 | stage('Purge Ceph OSD pkgs') { |
Mateusz Los | 9f50377 | 2019-05-07 15:10:45 +0200 | [diff] [blame] | 244 | salt.runSaltProcessStep(pepperEnv, HOST, 'pkg.purge', 'ceph-base,ceph-common,ceph-fuse,ceph-mds,ceph-osd,python-cephfs,librados2,python-rados,python-rbd,python-rgw') |
Jakub Josef | a63f986 | 2018-01-11 17:58:38 +0100 | [diff] [blame] | 245 | } |
| 246 | |
| 247 | stage('Remove OSD host from crushmap') { |
Ivan Berezovskiy | 19c685a | 2019-11-05 17:42:57 +0400 | [diff] [blame] | 248 | def hostname = salt.cmdRun(pepperEnv, HOST, "hostname -s")['return'][0].values()[0].split('\n')[0] |
Jakub Josef | a63f986 | 2018-01-11 17:58:38 +0100 | [diff] [blame] | 249 | try { |
Ivan Berezovskiy | 19c685a | 2019-11-05 17:42:57 +0400 | [diff] [blame] | 250 | salt.cmdRun(pepperEnv, ADMIN_HOST, "ceph osd crush remove ${hostname}") |
Jakub Josef | a63f986 | 2018-01-11 17:58:38 +0100 | [diff] [blame] | 251 | } catch (Exception e) { |
| 252 | common.warningMsg(e) |
| 253 | } |
| 254 | } |
| 255 | |
| 256 | // stop salt-minion service and move its configuration |
| 257 | stage('Stop salt-minion') { |
| 258 | salt.cmdRun(pepperEnv, HOST, "mv /etc/salt/minion.d/minion.conf minion.conf") |
| 259 | salt.runSaltProcessStep(pepperEnv, HOST, 'service.stop', ['salt-minion'], [], null, true, 5) |
Jiri Broulik | 99887c8 | 2017-10-31 09:27:52 +0100 | [diff] [blame] | 260 | } |
Jiri Broulik | 99887c8 | 2017-10-31 09:27:52 +0100 | [diff] [blame] | 261 | |
Mateusz Los | 8b64b81 | 2020-05-11 10:33:58 +0200 | [diff] [blame] | 262 | stage('Remove salt-key') { |
| 263 | try { |
| 264 | salt.cmdRun(pepperEnv, 'I@salt:master', "salt-key -d ${target}.${domain} -y") |
| 265 | } catch (Exception e) { |
| 266 | common.warningMsg(e) |
Jakub Josef | a63f986 | 2018-01-11 17:58:38 +0100 | [diff] [blame] | 267 | } |
Mateusz Los | 8b64b81 | 2020-05-11 10:33:58 +0200 | [diff] [blame] | 268 | try { |
| 269 | salt.cmdRun(pepperEnv, 'I@salt:master', "rm /srv/salt/reclass/nodes/_generated/${target}.${domain}.yml") |
| 270 | } catch (Exception e) { |
| 271 | common.warningMsg(e) |
| 272 | } |
Jiri Broulik | 3485b2c | 2017-11-28 15:06:12 +0100 | [diff] [blame] | 273 | } |
Jiri Broulik | 99887c8 | 2017-10-31 09:27:52 +0100 | [diff] [blame] | 274 | } |
Jiri Broulik | 99887c8 | 2017-10-31 09:27:52 +0100 | [diff] [blame] | 275 | |
Jakub Josef | a63f986 | 2018-01-11 17:58:38 +0100 | [diff] [blame] | 276 | if (HOST_TYPE.toLowerCase() == 'mon') { |
| 277 | // Update Monmap |
| 278 | stage('Update monmap') { |
Ivan Berezovskiy | 19c685a | 2019-11-05 17:42:57 +0400 | [diff] [blame] | 279 | salt.cmdRun(pepperEnv, 'I@ceph:mon', "ceph mon getmap -o monmap.backup") |
Jakub Josef | a63f986 | 2018-01-11 17:58:38 +0100 | [diff] [blame] | 280 | try { |
Ivan Berezovskiy | 19c685a | 2019-11-05 17:42:57 +0400 | [diff] [blame] | 281 | salt.cmdRun(pepperEnv, 'I@ceph:mon', "ceph mon remove ${target}") |
Jakub Josef | a63f986 | 2018-01-11 17:58:38 +0100 | [diff] [blame] | 282 | } catch (Exception e) { |
| 283 | common.warningMsg(e) |
| 284 | } |
Ivan Berezovskiy | 19c685a | 2019-11-05 17:42:57 +0400 | [diff] [blame] | 285 | salt.cmdRun(pepperEnv, 'I@ceph:mon', "monmaptool /tmp/monmap --rm ${target}") |
Jakub Josef | a63f986 | 2018-01-11 17:58:38 +0100 | [diff] [blame] | 286 | } |
| 287 | |
| 288 | def target_hosts = salt.getMinions(pepperEnv, 'I@ceph:common') |
Jakub Josef | a63f986 | 2018-01-11 17:58:38 +0100 | [diff] [blame] | 289 | |
| 290 | // Update configs |
| 291 | stage('Update Ceph configs') { |
| 292 | for (tgt in target_hosts) { |
| 293 | salt.enforceState(pepperEnv, tgt, 'ceph.common', true) |
| 294 | } |
| 295 | } |
Mateusz Los | 9f50377 | 2019-05-07 15:10:45 +0200 | [diff] [blame] | 296 | |
| 297 | stage('Purge Ceph MON pkgs') { |
| 298 | salt.runSaltProcessStep(pepperEnv, HOST, 'pkg.purge', 'ceph-base,ceph-common,ceph-mgr,ceph-mon,libcephfs2,python-cephfs,python-rbd,python-rgw') |
| 299 | } |
Jakub Josef | a63f986 | 2018-01-11 17:58:38 +0100 | [diff] [blame] | 300 | } |
| 301 | |
Mateusz Los | bb35289 | 2019-10-09 11:36:10 +0200 | [diff] [blame] | 302 | def crushmap_target = salt.getMinions(pepperEnv, "I@ceph:setup:crush") |
Ivan Berezovskiy | 19c685a | 2019-11-05 17:42:57 +0400 | [diff] [blame] | 303 | if (HOST_TYPE.toLowerCase() == 'osd' && GENERATE_CRUSHMAP.toBoolean() == true && crushmap_target) { |
Jakub Josef | a63f986 | 2018-01-11 17:58:38 +0100 | [diff] [blame] | 304 | stage('Generate CRUSHMAP') { |
| 305 | salt.enforceState(pepperEnv, 'I@ceph:setup:crush', 'ceph.setup.crush', true) |
| 306 | } |
Jiri Broulik | 99887c8 | 2017-10-31 09:27:52 +0100 | [diff] [blame] | 307 | } |
| 308 | } |
| 309 | } |