|
6 | 6 | Optional[String] $new_replica_postgresql_host = undef, |
7 | 7 | Optional[String] $upgrade_version = undef, |
8 | 8 | ) { |
| 9 | + out::message("primary_host:${primary_host}.") |
| 10 | + out::message("new_primary_host:${new_primary_host}.") |
| 11 | + out::message("new_replica_host:${new_replica_host}.") |
| 12 | + out::message("new_primary_postgresql_host:${new_primary_postgresql_host}.") |
| 13 | + out::message("new_replica_postgresql_host:${new_replica_postgresql_host}.") |
| 14 | + out::message("upgrade_version:${upgrade_version}.") |
| 15 | + |
9 | 16 | # Convert String values to targets if they are not blank |
10 | 17 | $primary_target = $primary_host ? { '' => undef, default => peadm::get_targets($primary_host, 1) } |
11 | 18 | $new_primary_target = $new_primary_host ? { '' => undef, default => peadm::get_targets($new_primary_host, 1) } |
12 | 19 | $new_replica_target = $new_replica_host ? { '' => undef, default => peadm::get_targets($new_replica_host, 1) } |
13 | 20 | $new_primary_postgresql_target = $new_primary_postgresql_host ? { '' => undef, default => peadm::get_targets($new_primary_postgresql_host, 1) } |
14 | 21 | $new_replica_postgresql_target = $new_replica_postgresql_host ? { '' => undef, default => peadm::get_targets($new_replica_postgresql_host, 1) } |
| 22 | + out::message("primary_target:${primary_target}.") |
| 23 | + out::message("new_primary_target:${new_primary_target}.") |
| 24 | + out::message("new_replica_target:${new_replica_target}.") |
| 25 | + out::message("new_primary_postgresql_target:${new_primary_postgresql_target}.") |
| 26 | + out::message("new_replica_postgresql_target:${new_replica_postgresql_target}.") |
15 | 27 |
|
16 | 28 | # run infra status on the primary |
17 | 29 | out::message("Running peadm::status on primary host ${primary_target}") |
|
79 | 91 | # if a new PE version was specified then check it has been upgraded |
80 | 92 | out::message("upgrade_version:${upgrade_version}.") |
81 | 93 | if $upgrade_version and $upgrade_version != '' and !empty($upgrade_version) { |
82 | | - if $peadm_config['value']['pe_version'] == $upgrade_version { |
| 94 | + if $peadm_config['pe_version'] == $upgrade_version { |
83 | 95 | out::message("Upgraded to new PE version ${upgrade_version} correctly") |
84 | 96 | } else { |
85 | 97 | fail_plan("Failed to upgrade to new PE version ${upgrade_version} correctly") |
|
0 commit comments