voxpupuli / puppet-windowsfeature

Library that uses ServerAdministration api that comes with Windows Server 2008 and Windows Server 2012 to add / remove windows features
https://forge.puppet.com/puppet/windowsfeature
MIT License
30 stars 49 forks source link

Invalid resource type windowsfeature #25

Closed listlfa closed 9 years ago

listlfa commented 9 years ago

On Windows 2008 R2 and 2012 R2 I consistently get the error message per the below example

I am a Puppet beginner so I may have made an obvious error. First, I installed Puppet via Chocolatey Then I installed your module; puppet module install opentable-windows_feature Then I ran this example .pp file (code is from your Readme)

Example:

PS C:\Users\Administrator> puppet apply .\01.pp
Error: Puppet::Parser::AST::Resource failed with error ArgumentError: Invalid resource type windowsfeature at C:/Users/A
dministrator/01.pp:1 on node win-cfjnt5scd6c.fritz.box
Wrapped exception:
Invalid resource type windowsfeature
Error: Puppet::Parser::AST::Resource failed with error ArgumentError: Invalid resource type windowsfeature at C:/Users/A
dministrator/01.pp:1 on node win-cfjnt5scd6c.fritz.box
PS C:\Users\Administrator> type .\01.pp
windowsfeature { 'NET-Framework-Core': }
PS C:\Users\Administrator>
stevenruns commented 9 years ago

I don't think you made an error as I am getting the same message when trying to apply a manifest with that resource type. Hopefully we can get a solution soon.

liamjbennett commented 9 years ago

I would assume that the issue here is that it is not able to find the module you installed rather than a problem with the module itself.

Can you try with: puppet apply --moduepath C:\ProgramData\PuppetLabs\puppet\etc\modules .\01.pp

Also can you check the contents of that directory and make sure that the module has installed correctly.

stevenruns commented 9 years ago

My issue was the path of the module. I imported it into my project incorrectly. Everything is good now. Thanks for the help!