Allow optional status_uri to be set for status backups

This updates the status_backups resource definition to allow for
specific uris to be set. This allows you to do per tenant backups
without tenant white labeling in the web server.

Change-Id: Ia94a16ef8b2a1069b9265bae2773cd323ac9a188
This commit is contained in:
Clark Boylan 2019-03-12 14:34:37 -07:00
parent a6d9a5e4d4
commit e3fb3c27f2
1 changed files with 8 additions and 1 deletions

View File

@ -15,13 +15,20 @@
define zuul::status_backups (
$tenant_name,
$ssl,
$status_uri = undef,
) {
if $tenant_name and $tenant_name != '' {
if $status_uri == undef {
if $ssl {
$status = "https://${name}/api/status"
} else {
$status = "http://${name}/api/status"
}
}
else {
$status = $status_uri
}
if $tenant_name and $tenant_name != '' {
# Minutes, hours, days, etc are not specified here because we are
# interested in running this *every minute*.
# This is a mean of backing up status.json periodically in order to provide