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

Bkr 1115 Allow options-file to be configured via ENV #90

Merged
merged 3 commits into from
Oct 2, 2017

Conversation

barrymw
Copy link
Contributor

@barrymw barrymw commented May 4, 2017

In order to run beaker acceptance tests unmodified behind a proxy, the host_env configuration needs to be externally settable (i.e. outside of the tests). As this is passed in to beaker via the --options-file, it makes (made?) sense to use expose this runtime parameter.

When used in conjunction with BKR-1114 pull request, it is possible to do the following:

git clone https://github.com/puppetlabs/puppetlabs-inifile.git
cd puppetlabs-inifile
export BEAKER_options_file=~/beaker-proxy.cfg
export DOCKER_BUILDARGS="HTTP_PROXY=http://10.0.2.2:3128/ HTTPS_PROXY=http://10.0.2.2:3128/     http_proxy=http://10.0.2.2:3128/       https_proxy=http://10.0.2.2:3128/"
PUPPET_INSTALL_TYPE=agent BEAKER_debug=true BEAKER_set=docker/centos-7   bundle exec rake -v beaker

Where ~/beaker-config.cfg contains:

{
  :package_proxy => 'http://10.0.2.2:3128/', 
  :host_env => {
    "http_proxy" => "http://10.0.2.2:3128/",
    "https_proxy" => "http://10.0.2.2:3128/",
    "HTTP_PROXY" => "http://10.0.2.2:3128/",
    "HTTPS_PROXY" => "http://10.0.2.2:3128/"
  }
}

barrymw added 3 commits May 4, 2017 15:44
Added a space between `#` and the first word in the titles to correct the formatting..
Adding the ability to pass in the location of the options-file so that attributes such as host_env can be configured easily outside of the host definitions.
@puppetlabs-jenkins
Copy link
Contributor

Can one of the admins verify this patch?

@kevpl
Copy link
Contributor

kevpl commented Sep 26, 2017

@barrymw apologies for the huge delay looking at this. Looks good to me, I'll put it through testing, & hopefully we'll get this out soon for you.

@puppetlabs-jenkins test this please

@puppetlabs-jenkins
Copy link
Contributor

Refer to this link for build results (access rights to CI server needed):
http://jenkins-beaker.delivery.puppetlabs.net//job/qe_beaker-rspec_btc-intn-sys/44/

@kevpl
Copy link
Contributor

kevpl commented Sep 26, 2017

@puppetlabs-jenkins retest this please

@puppetlabs-jenkins
Copy link
Contributor

Refer to this link for build results (access rights to CI server needed):
http://jenkins-beaker.delivery.puppetlabs.net//job/qe_beaker-rspec_btc-intn-sys/46/

@barrymw
Copy link
Contributor Author

barrymw commented Sep 28, 2017

Not a problem @kevpl, I have been running with my mods up until now. Thanks for getting around to merging though!

@kevpl
Copy link
Contributor

kevpl commented Oct 2, 2017

@barrymw np! I'm pretty confident that your changes are fine & that we're having issues that we should resolve with our automation & shouldn't block merging on them. Since that's the case, I'll merge this now. Thanks for the addition!

@kevpl kevpl merged commit cef4503 into voxpupuli:master Oct 2, 2017
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.

3 participants