Uploaded image for project: 'Puppet'
  1. Puppet
  2. PUP-3688

Allow path environment to be specified on a per-resource basis

    Details

    • Type: New Feature
    • Status: Closed
    • Priority: Normal
    • Resolution: Duplicate
    • Affects Version/s: None
    • Fix Version/s: None
    • Component/s: None
    • Labels:
    • Template:

      Description

      Currently, only the exec resource type permits the path to be specified for commands it executes. However, it would be generally useful for other resource types. For example, to specify the path to use when executing package commands (that are relative).

      The only workaround is to modify the provider source or to use the <http://docs.puppetlabs.com/references/latest/configuration.html#path> setting, though that is global, and won't work in cases where a module installs a package in a location that isn't already in the path, e.g. Java applications on windows.

      Original description:

      Hi,

      I just installed ruby1.9.3.exe package on a windows build server and also i was thinking on installing some gems. It seems that is installing the gems as part as as the 1.8.7 ruby version shipped with the Puppet Client windows installer.

      class ruby{
       
      file {'ruby':
      	name => 'C:\Temp\rubyinstaller-1.9.3-p194.exe',
      	ensure => present,
      	source => 'V:\shardata\Puppet\rubyinstaller-1.9.3-p194.exe'
      }
       
       
      exec { 'ruby':
      		command => 'C:\Temp\rubyinstaller-1.9.3-p194.exe /verysilent /dir="C:\ruby" /tasks="assocfiles,modpath"',
      		require => File["ruby"]
      	}
      	
      	
      # package { 'nokogiri':
      	# ensure => '1.5.5',
      	# provider => 'gem',
      	# require => Exec['ruby']
      # } 
      

      Should I still use the gem provider or should i use the exec and map the new ruby package gem.bat path?

        Attachments

          Issue Links

            Activity

              jsd-sla-details-panel

                People

                • Assignee:
                  Unassigned
                  Reporter:
                  redmine.exporter redmine.exporter
                • Votes:
                  0 Vote for this issue
                  Watchers:
                  3 Start watching this issue

                  Dates

                  • Created:
                    Updated:
                    Resolved: