The Puppet Labs Issue Tracker has Moved: https://tickets.puppetlabs.com

Bug #14463

hiera+puppetlabs-firewall: Type issue: dport: can't convert Fixnum into String

Added by Jens Bräuer almost 2 years ago. Updated over 1 year ago.

Status:Merged - Pending ReleaseStart date:05/14/2012
Priority:NormalDue date:
Assignee:-% Done:

0%

Category:firewallSpent time:-
Target version:-
Keywords:hiera, type error, Fixnum, String, firewall Branch:

We've Moved!

Ticket tracking is now hosted in JIRA: https://tickets.puppetlabs.com

This issue is currently not available for export. If you are experiencing the issue described below, please file a new ticket in JIRA. Once a new ticket has been created, please add a link to it that points back to this Redmine ticket.


Description

Puppet-firewall throws an error, when using variables from hiera. There seems to be a type problem. Please have a look at the following example. One has the dport directly set from Puppet. The second one reads from hiera into a variable, which is used as dport.


firewall { ‘100: puppet works’:

proto => 'tcp',
dport => 1194,
action => "accept",
state => ["NEW"]

}

$port = hiera(“firewall.port”) firewall { ‘101: hiera does not’:

proto => 'tcp',
dport => $port,
action => "accept",
state => ["NEW"]

}

The second resource (“hiera does not”) causes Puppet to fail with:

Parameter dport failed: Munging failed for value 1194 in class dport: can’t convert Fixnum into String

I am unsure if this is a puppetlabs-firewall issue or maybe even a more general one, when using hiera.

This happens in – puppetlabs-firewall.git: 31b45bf88129870e4e028847e5a8955130f68e32 – puppetlabs-firewall.git: 4fd37c283a6033bd7caea32066fb1249c17c37a0

History

#1 Updated by William Van Hevelingen almost 2 years ago

  • Category set to firewall

#2 Updated by Sharif Nassar over 1 year ago

This finally got annoying enough to track down and fix:

https://github.com/puppetlabs/puppetlabs-firewall/pull/101

#3 Updated by Dan Carley over 1 year ago

  • Status changed from Unreviewed to Merged - Pending Release

Also available in: Atom PDF