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

This issue tracker is now in read-only archive mode and automatic ticket export has been disabled. Redmine users will need to create a new JIRA account to file tickets using https://tickets.puppetlabs.com. See the following page for information on filing tickets with JIRA:

Bug #14463

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

Added by Jens Bräuer about 3 years ago. Updated over 2 years 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


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 about 3 years ago

  • Category set to firewall

#2 Updated by Sharif Nassar over 2 years 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 2 years ago

  • Status changed from Unreviewed to Merged - Pending Release

Also available in: Atom PDF