Skip to content
Browse files

17594 - Fixes suggested by cprice-puppet

  • Loading branch information...
1 parent 0afc276 commit 0cf963279a1e5624c910fd6a3270b3479ae839c9 Drew Blessing committed
Showing with 11 additions and 15 deletions.
  1. +1 −10 manifests/init.pp
  2. +2 −2 manifests/params.pp
  3. +1 −1 manifests/server.pp
  4. +7 −2 manifests/server/firewall.pp
View
11 manifests/init.pp
@@ -28,14 +28,12 @@
# ['ssl_listen_port'] - The port on which the puppetdb web server should
# accept HTTPS requests (defaults to 8081).
# ['open_ssl_listen_port'] - If true, open the ssl listen port on the firewall.
-# (defaults to false).
+# (defaults to true).
# ['database'] - Which database backend to use; legal values are
# `postgres` (default) or `embedded`. (The `embedded`
# db can be used for very small installations or for
# testing, but is not recommended for use in production
# environments. For more info, see the puppetdb docs.)
-# ['database_host'] - The hostname or IP address of the database server.
-# (defaults to `localhost`; ignored for `embedded` db)
# ['database_port'] - The port that the database server listens on.
# (defaults to `5432`; ignored for `embedded` db)
# ['database_username'] - The name of the database user to connect as.
@@ -50,10 +48,6 @@
# number, 'present', or 'latest'. (defaults to
# 'present')
# ['puppetdb_service'] - The name of the puppetdb service.
-# ['postgres_listen_addresses'] - The addresses for postgres to listen on.
-# (defaults to 'localhost'. '*' = all)
-# ['open_postgres_port'] - If true, open the postgres listen port on the firewall.
-# (defaults to false).
# ['manage_redhat_firewall'] - DEPRECATED: Use open_ssl_listen_port instead.
# boolean indicating whether or not the module
# should open a port in the firewall on redhat-based
@@ -83,7 +77,6 @@
$ssl_listen_port = $puppetdb::params::ssl_listen_port,
$open_ssl_listen_port = $puppetdb::params::open_ssl_listen_port,
$database = $puppetdb::params::database,
- $database_host = $puppetdb::params::database_host,
$database_port = $puppetdb::params::database_port,
$database_username = $puppetdb::params::database_username,
$database_password = $puppetdb::params::database_password,
@@ -91,7 +84,6 @@
$puppetdb_package = $puppetdb::params::puppetdb_package,
$puppetdb_version = $puppetdb::params::puppetdb_version,
$puppetdb_service = $puppetdb::params::puppetdb_service,
- $postgres_listen_addresses = $puppetdb::params::postgres_listen_addresses,
$open_postgres_port = $puppetdb::params::open_postgres_port,
$manage_redhat_firewall = $puppetdb::params::manage_redhat_firewall,
$confdir = $puppetdb::params::confdir
@@ -109,7 +101,6 @@
ssl_listen_port => $ssl_listen_port,
open_ssl_listen_port => $open_ssl_listen_port,
database => $database,
- database_host => $database_host,
database_port => $database_port,
database_username => $database_username,
database_password => $database_password,
View
4 manifests/params.pp
@@ -16,9 +16,9 @@
$open_listen_port = false
$ssl_listen_address = $::clientcert
$ssl_listen_port = '8081'
- $open_ssl_listen_port = false
+ $open_ssl_listen_port = true
$postgres_listen_addresses = 'localhost'
- $open_postgres_port = false
+ $open_postgres_port = true
$database = 'postgres'
View
2 manifests/server.pp
@@ -35,7 +35,7 @@
# ['ssl_listen_port'] - The port on which the puppetdb web server should
# accept HTTPS requests (defaults to 8081).
# ['open_ssl_listen_port'] - If true, open the ssl listen port on the firewall.
-# (defaults to false).
+# (defaults to true).
# ['database'] - Which database backend to use; legal values are
# `postgres` (default) or `embedded`. (The `embedded`
# db can be used for very small installations or for
View
9 manifests/server/firewall.pp
@@ -45,8 +45,13 @@
}
if ($open_ssl_port or $manage_redhat_firewall) {
- firewall { "${ssl_port} accept - puppetdb":
- port => $ssl_port,
+ if ($ssl_port) {
+ $final_ssl_port = $ssl_port
+ } else {
+ $final_ssl_port = $port
+ }
+ firewall { "${final_ssl_port} accept - puppetdb":
+ port => $final_ssl_port,
proto => 'tcp',
action => 'accept',
}

0 comments on commit 0cf9632

Please sign in to comment.
Something went wrong with that request. Please try again.