using puppetdb module I get str2bool error with puppet4

asked 2016-05-06 18:06:03 -0600

billjamzz2 gravatar image

Error: Could not retrieve catalog from remote server: Error 400 on SERVER: Evaluation Error: Error while evaluating a Function Call, str2bool(): Requires either string to work with at /etc/puppetlabs/code/environments/production/modules/puppetdb/manifests/server/database.pp:24:6 on node puppetdb.test.j2noc.com

If I change the class call to include 'database_validate => "true",' it gets past that error and stops on next str2bool call.

puppetdb::database::postgresql installed fine, puppetdb::server doesn't. I'm using version 5.1.2 of module and puppetserver-2.3.2-1.el7.noarch, puppet-agent-1.4.2-1.el7.x86_64

Did I miss some setting that tells str2bool to allow boolean as input?

edit retag flag offensive close merge delete

Comments

I must be only one with this issue? I got around it by modifying the puppetdb module: if (is_string($ssl_set_cert_paths)) { str2bool($ssl_set_cert_paths)} if $ssl_set_cert_paths == true { for each "str2bool" used, then the module ran fine. Seems to me str2bool should be able to recognize if in

billjamzz2 gravatar imagebilljamzz2 ( 2016-06-03 15:43:59 -0600 )edit

if input is already boolean and just return the boolean.

billjamzz2 gravatar imagebilljamzz2 ( 2016-06-03 15:44:43 -0600 )edit