Puppet Plan: cd4peadm::validate
- Defined in:
-
plans/validate.pp
Summary
Run all validate plans together to verify installation was successful and log results
Overview
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
|
# File 'plans/validate.pp', line 6
plan cd4peadm::validate(
Cd4peadm::Config $config = cd4peadm::config(),
) {
run_plan('cd4peadm::check_bolt_version')
without_default_logging() || {
out::message('images: verifying images are present')
$images_result = run_plan('cd4peadm::validate::images', config => $config)
out::message(cd4peadm::checks::format_results($images_result))
out::message('runtime: verifying installed runtimes match')
$runtime_result = run_plan('cd4peadm::validate::runtime', config => $config)
out::message(cd4peadm::checks::format_results($runtime_result))
out::message('database: verifying database access')
$database_result = run_plan('cd4peadm::validate::database', config => $config)
out::message(cd4peadm::checks::format_results($database_result))
$results = [$images_result, $runtime_result, $database_result]
out::message(cd4peadm::checks::format_summary($results))
$aggregated_results = cd4peadm::checks::aggregate_results($results)
if(length($aggregated_results[failed]) > 0) {
fail_plan('One or more validation checks did not pass', 'cd4pe/error')
}
return $aggregated_results
}
}
|