Sha256: 2bda46e175cdbf7eeee3904591b558722bd791fe2014fcaf56ce7e7818a68716

Contents?: true

Size: 759 Bytes

Versions: 12

Compression:

Stored size: 759 Bytes

Contents

Puppet::Type.type(:package).provide :puppet_gem, :parent => :gem do
  desc "Puppet Ruby Gem support. This provider is useful for managing
        gems needed by the ruby provided in the puppet-agent package."

  has_feature :versionable, :install_options, :uninstall_options

  if Puppet::Util::Platform.windows?
    # On windows, we put our ruby ahead of anything that already
    # existed on the system PATH. This means that we do not need to
    # sort out the absolute path.
    commands :gemcmd => "gem"
  else
    commands :gemcmd => "/opt/puppetlabs/puppet/bin/gem"
  end

  def uninstall
    super
    Puppet.debug("Invalidating rubygems cache after uninstalling gem '#{resource[:name]}'")
    Puppet::Util::Autoload.gem_source.clear_paths
  end
end

Version data entries

12 entries across 12 versions & 1 rubygems

Version Path
puppet-6.17.0 lib/puppet/provider/package/puppet_gem.rb
puppet-6.17.0-x86-mingw32 lib/puppet/provider/package/puppet_gem.rb
puppet-6.17.0-x64-mingw32 lib/puppet/provider/package/puppet_gem.rb
puppet-6.17.0-universal-darwin lib/puppet/provider/package/puppet_gem.rb
puppet-6.16.0 lib/puppet/provider/package/puppet_gem.rb
puppet-6.16.0-x86-mingw32 lib/puppet/provider/package/puppet_gem.rb
puppet-6.16.0-x64-mingw32 lib/puppet/provider/package/puppet_gem.rb
puppet-6.16.0-universal-darwin lib/puppet/provider/package/puppet_gem.rb
puppet-6.15.0 lib/puppet/provider/package/puppet_gem.rb
puppet-6.15.0-x86-mingw32 lib/puppet/provider/package/puppet_gem.rb
puppet-6.15.0-x64-mingw32 lib/puppet/provider/package/puppet_gem.rb
puppet-6.15.0-universal-darwin lib/puppet/provider/package/puppet_gem.rb