Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Added proxy support for provider, and added spec test #23

Merged
merged 1 commit into from
Feb 24, 2014

Conversation

superseb
Copy link

For people who use the module behind a proxy.

exec { 'system-rvm-get':
path => '/usr/local/rvm/bin:/usr/bin:/usr/sbin:/bin',
command => "rvm get ${version}",
environment => [ "http_proxy=${proxy_url}" , "https_proxy=${proxy_url}" ],
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

in order to avoid the duplication (here and in other code blocks) you could do

environment => $proxy_url ? { undef => undef, default => [ "http_proxy=${proxy_url}" , "https_proxy=${proxy_url}" ]},

@carlossg
Copy link
Member

thanks, added a comment there to avoid duplication

It'd be good to add the proxy_url to rvm::params, and reuse with rvm::params::proxy_url that way with hiera you can set the proxy in one place only and would apply to all rvm operations

@superseb
Copy link
Author

Nice, I'll push a new commit tonight with the change you suggested.

Rewrote parts to avoid duplication, moved proxy_url to params

Avoid duplication
@superseb
Copy link
Author

Should be good to go.

@carlossg carlossg merged commit 3b6c1fa into voxpupuli:maestrodev Feb 24, 2014
@carlossg
Copy link
Member

I had to fix this in 944370, http_proxy was added all the time

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants