Skip to content

Commit 19ecde2

Browse files
committed
* Change pe version check from using that was undefined to , change it to use an if statement to check for upgrade version first
* Set to false as that’s the default in assert_supported_pe_version.pp * Run same verify can connect to all hosts on if it exists
1 parent de8049c commit 19ecde2

File tree

1 file changed

+8
-1
lines changed

1 file changed

+8
-1
lines changed

plans/migrate.pp

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,13 +19,20 @@
1919
# pre-migration checks
2020
out::message('This plan is a work in progress and it is not recommended to be used until it is fully implemented and supported')
2121
peadm::assert_supported_bolt_version()
22-
peadm::assert_supported_pe_version($pe_version, $permit_unsafe_versions)
22+
if $upgrade_version and $upgrade_version != '' and !empty($upgrade_version) {
23+
$permit_unsafe_versions = false
24+
peadm::assert_supported_pe_version($pe_version, $permit_unsafe_versions)
25+
}
2326

2427
$all_hosts = peadm::flatten_compact([
2528
$old_primary_host,
2629
$new_primary_host,
2730
])
2831
run_command('hostname', $all_hosts) # verify can connect to targets
32+
33+
if $replica_host != '' and !empty($replica_host) {
34+
run_command('hostname', $replica_host)
35+
}
2936

3037
# verify the cluster we are migrating from is operational and is a supported architecture
3138
$cluster = run_task('peadm::get_peadm_config', $old_primary_host).first.value

0 commit comments

Comments
 (0)