Skip to content

Commit 89cb952

Browse files
committed
moving to start of plan
1 parent 63f7f1a commit 89cb952

File tree

3 files changed

+32
-20
lines changed

3 files changed

+32
-20
lines changed

plans/install.pp

Lines changed: 11 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -75,6 +75,17 @@
7575
Boolean $permit_unsafe_versions = false,
7676
String $token_lifetime = '1y',
7777
) {
78+
# Log parameters for debugging
79+
peadm::log_plan_parameters({
80+
'primary_host' => $primary_host,
81+
'replica_host' => $replica_host,
82+
'compiler_hosts' => $compiler_hosts,
83+
'legacy_compilers' => $legacy_compilers,
84+
'primary_postgresql_host' => $primary_postgresql_host,
85+
'replica_postgresql_host' => $replica_postgresql_host,
86+
'version' => $version,
87+
})
88+
7889
peadm::assert_supported_bolt_version()
7990

8091
peadm::assert_supported_pe_version($version, $permit_unsafe_versions)
@@ -142,16 +153,6 @@
142153
stagingdir => $stagingdir,
143154
final_agent_state => $final_agent_state,
144155
)
145-
# Log parameters for debugging
146-
peadm::log_plan_parameters({
147-
'primary_host' => $primary_host,
148-
'replica_host' => $replica_host,
149-
'compiler_hosts' => $compiler_hosts,
150-
'legacy_compilers' => $legacy_compilers,
151-
'primary_postgresql_host' => $primary_postgresql_host,
152-
'replica_postgresql_host' => $replica_postgresql_host,
153-
'version' => $version,
154-
})
155156

156157
# Return a string banner reporting on what was done
157158
return([$install_result, $configure_result])

plans/migrate.pp

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,17 @@
1515
Optional[String] $upgrade_version = undef,
1616
Optional[Peadm::SingleTargetSpec] $replica_host = undef,
1717
) {
18+
# Log parameters for debugging
19+
peadm::log_plan_parameters({
20+
'primary_host' => $primary_host,
21+
'replica_host' => $replica_host,
22+
'compiler_hosts' => $compiler_hosts,
23+
'legacy_compilers' => $legacy_compilers,
24+
'primary_postgresql_host' => $primary_postgresql_host,
25+
'replica_postgresql_host' => $replica_postgresql_host,
26+
'version' => $version,
27+
})
28+
1829
# pre-migration checks
1930
out::message('This plan is a work in progress and it is not recommended to be used until it is fully implemented and supported')
2031
peadm::assert_supported_bolt_version()

plans/upgrade.pp

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -62,6 +62,16 @@
6262

6363
Optional[Peadm::UpgradeSteps] $begin_at_step = undef,
6464
) {
65+
# Log parameters for debugging
66+
peadm::log_plan_parameters({
67+
'primary_host' => $primary_host,
68+
'replica_host' => $replica_host,
69+
'compiler_hosts' => $compiler_hosts,
70+
'primary_postgresql_host' => $primary_postgresql_host,
71+
'replica_postgresql_host' => $replica_postgresql_host,
72+
'version' => $version,
73+
})
74+
6575
out::message('# Validating inputs')
6676

6777
# Ensure input valid for a supported architecture
@@ -445,15 +455,5 @@
445455
446456
peadm::check_version_and_known_hosts($current_pe_version, $_version, $r10k_known_hosts)
447457
448-
# Log parameters for debugging
449-
peadm::log_plan_parameters({
450-
'primary_host' => $primary_host,
451-
'replica_host' => $replica_host,
452-
'compiler_hosts' => $compiler_hosts,
453-
'primary_postgresql_host' => $primary_postgresql_host,
454-
'replica_postgresql_host' => $replica_postgresql_host,
455-
'version' => $version,
456-
})
457-
458458
return("Upgrade of Puppet Enterprise ${arch['architecture']} completed.")
459459
}

0 commit comments

Comments
 (0)