Puppet Provider and Type

15 views
Skip to first unread message

ggun

unread,
May 24, 2017, 1:41:01 PM5/24/17
to Puppet Developers, Gaurav Gundal
Writing puppet provider and type :
1. I am trying to write my module with provider and type and every time I run the module. I get the error 'Error: Could not find a suitable provider ssm'

Please find attached module. Every time I run 'puppet apply -e 'include storagemanagement' I get above error. I have written simple print commands in provider but still getting that error.






storagemanagement.zip

Nick Lewis

unread,
May 24, 2017, 1:52:44 PM5/24/17
to puppe...@googlegroups.com, Gaurav Gundal
It looks like your provider probably has incorrect `confine` statements. You have `confine :ssm => '/usr/bin/ssm'`, which will only match if there is a fact called 'ssm' with the value '/usr/bin/ssm'. I think what you're looking for is `commands :ssm => '/usr/bin/ssm'` (commands vs. confine), which will restrict the provider to only nodes where that command exists. It will also create a helper method called 'ssm' that will run that command.
 




--
You received this message because you are subscribed to the Google Groups "Puppet Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email to puppet-dev+...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/puppet-dev/9698eb69-d7d6-462e-840c-da2dfc375c87%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

ggun

unread,
May 24, 2017, 3:11:47 PM5/24/17
to Puppet Developers, gaurav...@glic.com
Thank you for quick reply. 
Reply all
Reply to author
Forward
0 new messages