-
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
0672d20
commit 2440cef
Showing
5 changed files
with
26 additions
and
16 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,8 @@ | ||
source ENV['GEM_SOURCE'] || 'https://rubygems.org' | ||
|
||
gem 'puppet_metadata' | ||
gem 'puppet_metadata' # generates the beaker matrix | ||
gem 'json' | ||
gem 'beaker' | ||
gem 'beaker-docker' | ||
gem 'beaker-rspec' # used for parsing BEAKER_SETFILE env var | ||
gem 'rake' | ||
gem 'beaker-rspec' # used for providing `hosts` in install_puppet.rb | ||
gem 'beaker_puppet_helpers' # used to install puppet |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
# frozen_string_literal: true | ||
|
||
# this is inspired by https://github.com/voxpupuli/voxpupuli-acceptance/blob/397055f9d9ff1d7da17a7955430ddcf35619d641/lib/voxpupuli/acceptance/spec_helper_acceptance.rb | ||
|
||
require 'beaker_puppet_helpers' | ||
require 'beaker-rspec' | ||
|
||
collection = ENV['BEAKER_PUPPET_COLLECTION'] || 'puppet' | ||
|
||
block_on hosts, run_in_parallel: true do |host| | ||
unless %w[none preinstalled].include?(collection) | ||
BeakerPuppetHelpers::InstallUtils.install_puppet_release_repo_on(host, collection) | ||
end | ||
package_name = ENV.fetch('BEAKER_PUPPET_PACKAGE_NAME', BeakerPuppetHelpers::InstallUtils.puppet_package_name(host, prefer_aio: collection != 'none')) | ||
host.install_package(package_name) | ||
|
||
# by default, puppet-agent creates /etc/profile.d/puppet-agent.sh which adds /opt/puppetlabs/bin to PATH | ||
# in our non-interactive ssh sessions we manipulate PATH in ~/.ssh/environment, we need to do this step here as well | ||
host.add_env_var('PATH', '/opt/puppetlabs/bin') | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters