I tried starting irb from various places along that tree and as my user and 
root.

The /etc/puppet/modules/example/lib/puppet/provider/custom_package/apt.rb 
file contains:
Puppet::Type.type(:custom_package).provide(:apt) do
  def exists?
  end
  def create
  end
  def destroy
  end
  end
end

On Friday, July 11, 2014 9:29:47 AM UTC-7, Rob Reynolds wrote:
>
>
>
>
> On Thu, Jul 10, 2014 at 7:43 PM, Michael Legleux <leg...@gmail.com 
> <javascript:>> wrote:
>
>> Using puppet 3.62
>>
>> Trying to follow along with the book
>> At one point (beginning of ch. 3), it says using irb:
>>
>> >> require 'puppet'
>> >> Puppet::Type.type(:package)
>> => Puppet::Type::Package
>> My output is identical
>> However the next bit diverges...
>>
>> >> require 'puppet'
>> >> Puppet.parse_config
>> >> Puppet::Type.type(:custom_package).provide(:apt)
>> => Puppet::Type::Custom_package::ProviderApt
>>
>
> Are you in the root of your custom module folder when you type irb? 
>  
>
>>
>> Puppet.parse_config returns "notice"
>> and
>> Puppet::Type.type(:custom_package).provide(:apt)  does not return 
>> Puppet::Type::Custom_package::ProviderApt as 
>> Puppet::Type.type(:custom_package) is returning nil.
>>
>> my tree is identical to the books (save for the rpm and yum providers)
>> .
>> └── lib
>>     └── puppet
>>         ├── provider
>>         │   └── custom_package
>>         │       └── apt.rb
>>
>
> Ensure your namespace is correct for the apt.rb file. 
>
>  
>
>>         └── type
>>             └── custom_package.rb
>>
>> Is this book still 100% relevant or are parts achieving obsolescence?
>>
>> -- 
>> You received this message because you are subscribed to the Google Groups 
>> "Puppet Users" group.
>> To unsubscribe from this group and stop receiving emails from it, send an 
>> email to puppet-users...@googlegroups.com <javascript:>.
>> To view this discussion on the web visit 
>> https://groups.google.com/d/msgid/puppet-users/00ab0833-4bd1-4939-a710-6223eb7e122b%40googlegroups.com
>>  
>> <https://groups.google.com/d/msgid/puppet-users/00ab0833-4bd1-4939-a710-6223eb7e122b%40googlegroups.com?utm_medium=email&utm_source=footer>
>> .
>> For more options, visit https://groups.google.com/d/optout.
>>
>
>
>
> -- 
> Rob Reynolds
> Developer, Puppet Labs
>
> *Join us at PuppetConf 2014 <http://www.puppetconf.com/>, September 
> 20-24 in San Francisco*
> *Register by July 31st to take advantage of the Early Bird discount 
> <https://puppetconf2014.eventbrite.com/?discount=EarlyBird> **—**save 
> $249!*
>  

-- 
You received this message because you are subscribed to the Google Groups 
"Puppet Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to puppet-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/puppet-users/9649b787-630c-4b56-a7e6-b40ea6c21615%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to