Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions manifests/init.pp
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@
}

# Validate node_ttl
validate_re ($node_ttl_real, ['^(\d)+[s,m,d]$'], "node_ttl is <${node_ttl}> which does not match the regex validation")
validate_re ($node_ttl_real, ['^\d+(d|h|m|s|ms)$'], "node_ttl is <${node_ttl}> which does not match the regex validation")

# Apply necessary suffix if zero is specified.
if $node_purge_ttl == '0' {
Expand All @@ -49,7 +49,7 @@
}

# Validate node_purge_ttl
validate_re ($node_purge_ttl_real, ['^(\d)+[s,m,d]$'], "node_purge_ttl is <${node_purge_ttl}> which does not match the regex validation")
validate_re ($node_purge_ttl_real, ['^\d+(d|h|m|s|ms)$'], "node_purge_ttl is <${node_purge_ttl}> which does not match the regex validation")

# Apply necessary suffix if zero is specified.
if $report_ttl == '0' {
Expand All @@ -59,7 +59,7 @@
}

# Validate report_ttl
validate_re ($report_ttl_real, ['^(\d)+[s,m,d]$'], "report_ttl is <${report_ttl}> which does not match the regex validation")
validate_re ($report_ttl_real, ['^\d+(d|h|m|s|ms)$'], "report_ttl is <${report_ttl}> which does not match the regex validation")

# Validate puppetdb_service_status
if !($puppetdb_service_status in ['true', 'running', 'false', 'stopped']) {
Expand Down
6 changes: 3 additions & 3 deletions manifests/server.pp
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@
}

# Validate node_ttl
validate_re ($node_ttl_real, ['^(\d)+[s,m,d]$'], "node_ttl is <${node_ttl}> which does not match the regex validation")
validate_re ($node_ttl_real, ['^\d+(d|h|m|s|ms)$'], "node_ttl is <${node_ttl}> which does not match the regex validation")

# Apply necessary suffix if zero is specified.
if $node_purge_ttl == '0' {
Expand All @@ -48,7 +48,7 @@
}

# Validate node_purge_ttl
validate_re ($node_purge_ttl_real, ['^(\d)+[s,m,d]$'], "node_purge_ttl is <${node_purge_ttl}> which does not match the regex validation")
validate_re ($node_purge_ttl_real, ['^\d+(d|h|m|s|ms)$'], "node_purge_ttl is <${node_purge_ttl}> which does not match the regex validation")

# Apply necessary suffix if zero is specified.
if $report_ttl == '0' {
Expand All @@ -58,7 +58,7 @@
}

# Validate report_ttl
validate_re ($report_ttl_real, ['^(\d)+[s,m,d]$'], "report_ttl is <${report_ttl}> which does not match the regex validation")
validate_re ($report_ttl_real, ['^\d+(d|h|m|s|ms)$'], "report_ttl is <${report_ttl}> which does not match the regex validation")

# Validate puppetdb_service_status
if !($puppetdb_service_status in ['true', 'running', 'false', 'stopped']) {
Expand Down