sshkeys from puppetdb failing after migration to puppet 6

27 views
Skip to first unread message

Andy Hall

unread,
Aug 2, 2019, 3:06:02 PM8/2/19
to Puppet Users
Hey there. We use the combination of jtopjian/sshkeys and dalen/puppetdbquery as it's a great solution to store and retrieve sshkeys from puppetdb. Currently we are migrating from puppet 3.8 to 6.6 and all issues have been ironed out except for the following:

When calling query_facts against puppetdb 6 I can see the connection on port 8081 with tcpdump but get the following error:


Error while evaluating a Function Call, undefined method facts_query for #<PuppetDB::Parser:0x6bab009>


Which seems to relate to the following code in the query_facts function:


parser = PuppetDB::Parser.new

query = parser.facts_query query, facts_for_query if query.is_a? String

parser.facts_hash(puppetdb.query(:facts, query, :extract => [:certname, :name, :value]), facts)


Of course we will check with the module authors but wonder has anyone else seen something similar and could it relate to the version of puppetdb ? As noted we can see the database connection being made but can't view the payload due to SSL. Any help would be greatly appreciated.

Andy Hall

unread,
Aug 3, 2019, 3:26:00 AM8/3/19
to Puppet Users
OK it seems all is well and that error is shown if the sshpubkey_username fact is not yet available in the puppetdb. Once available it all works fine.
Reply all
Reply to author
Forward
0 new messages