r10k 3.15.4 → 3.16.2

Sign up to get free protection for your applications and to get access to all the features.
Files changed (70) hide show
  1. checksums.yaml +4 -4
  2. data/.github/dependabot.yml +17 -0
  3. data/.github/workflows/docker.yml +4 -4
  4. data/.github/workflows/release.yml +3 -2
  5. data/.github/workflows/rspec_tests.yml +7 -7
  6. data/.github/workflows/stale.yml +1 -1
  7. data/CHANGELOG.mkd +23 -0
  8. data/Gemfile +2 -2
  9. data/integration/Rakefile +1 -1
  10. data/integration/files/pre-suite/git_config.pp.erb +1 -1
  11. data/integration/pre-suite/10_git_config.rb +0 -3
  12. data/integration/tests/Puppetfile/HTTP_PROXY_affects_git_source.rb +5 -4
  13. data/integration/tests/basic_functionality/proxy_specified_in_configuration.rb +1 -1
  14. data/integration/tests/basic_functionality/proxy_with_puppetfile.rb +1 -1
  15. data/integration/tests/basic_functionality/rugged_git_provider_with_ssh.rb +2 -2
  16. data/integration/tests/basic_functionality/rugged_git_provider_without_ssh.rb +2 -2
  17. data/integration/tests/command_line/deploy_env_without_mod_update.rb +0 -3
  18. data/integration/tests/command_line/negative/neg_deploy_env_with_module_update.rb +0 -3
  19. data/integration/tests/git_source/HTTP_proxy_and_git_source.rb +5 -10
  20. data/integration/tests/git_source/git_source_git.rb +1 -4
  21. data/integration/tests/git_source/git_source_repeated_remote.rb +0 -3
  22. data/integration/tests/git_source/negative/neg_git_unauthorized_ssh.rb +1 -1
  23. data/integration/tests/purging/content_not_purged_at_root.rb +0 -3
  24. data/integration/tests/purging/default_purging.rb +0 -3
  25. data/integration/tests/purging/does_not_purge_files_on_white_list.rb +0 -3
  26. data/integration/tests/user_scenario/basic_workflow/multi_env_custom_forge_git_module.rb +0 -3
  27. data/integration/tests/user_scenario/basic_workflow/multi_env_custom_forge_git_module_static.rb +0 -3
  28. data/integration/tests/user_scenario/basic_workflow/multi_source_custom_forge_git_module.rb +0 -3
  29. data/integration/tests/user_scenario/basic_workflow/negative/neg_bad_forge_module.rb +0 -3
  30. data/integration/tests/user_scenario/basic_workflow/negative/neg_disk_full.rb +1 -1
  31. data/integration/tests/user_scenario/basic_workflow/negative/neg_duplicate_module_names.rb +0 -3
  32. data/integration/tests/user_scenario/basic_workflow/negative/neg_inaccessible_forge.rb +3 -2
  33. data/integration/tests/user_scenario/basic_workflow/negative/neg_specify_deleted_forge_module.rb +1 -5
  34. data/integration/tests/user_scenario/basic_workflow/single_env_10000_files.rb +1 -1
  35. data/integration/tests/user_scenario/basic_workflow/single_env_custom_forge_git_module.rb +0 -3
  36. data/integration/tests/user_scenario/basic_workflow/single_env_custom_forge_module.rb +0 -3
  37. data/integration/tests/user_scenario/basic_workflow/single_env_large_files.rb +1 -1
  38. data/integration/tests/user_scenario/basic_workflow/single_env_module_already_installed.rb +0 -3
  39. data/integration/tests/user_scenario/basic_workflow/single_env_purge_unmanaged_modules.rb +0 -3
  40. data/integration/tests/user_scenario/basic_workflow/single_env_switch_forge_git_module.rb +0 -3
  41. data/integration/tests/user_scenario/basic_workflow/single_env_upgrade_forge_mod_revert_change.rb +0 -3
  42. data/integration/tests/user_scenario/complex_workflow/multi_env_add_change_remove.rb +0 -3
  43. data/lib/r10k/content_synchronizer.rb +7 -2
  44. data/lib/r10k/git/rugged/bare_repository.rb +4 -3
  45. data/lib/r10k/git/rugged/working_repository.rb +6 -4
  46. data/lib/r10k/module/git.rb +5 -0
  47. data/lib/r10k/module_loader/puppetfile.rb +4 -1
  48. data/lib/r10k/puppetfile.rb +1 -1
  49. data/lib/r10k/version.rb +1 -1
  50. data/locales/r10k.pot +10 -6
  51. data/r10k.gemspec +1 -1
  52. metadata +12 -23
  53. data/docker/.gitignore +0 -1
  54. data/docker/.rspec +0 -4
  55. data/docker/Gemfile +0 -11
  56. data/docker/Makefile +0 -99
  57. data/docker/README.md +0 -28
  58. data/docker/docker-compose.yml +0 -18
  59. data/docker/r10k/Dockerfile +0 -68
  60. data/docker/r10k/adduser.sh +0 -13
  61. data/docker/r10k/docker-entrypoint.d/10-analytics.sh +0 -30
  62. data/docker/r10k/docker-entrypoint.sh +0 -10
  63. data/docker/r10k/release.Dockerfile +0 -55
  64. data/docker/spec/dockerfile_spec.rb +0 -37
  65. data/docker/spec/fixtures/Puppetfile +0 -2
  66. data/integration/tests/basic_functionality/install_pe_only_module_with_puppetfile.rb +0 -83
  67. data/integration/tests/basic_functionality/proxy_with_pe_only_module.rb +0 -128
  68. data/integration/tests/purging/invalid_whitelist_types.rb +0 -63
  69. data/integration/tests/user_scenario/basic_workflow/negative/neg_module_specified_at_deleted_release.rb +0 -49
  70. data/integration/tests/user_scenario/basic_workflow/single_env_module_last_release_deleted.rb +0 -68
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 2300d770bc6d49649bacd705ec99dfb416ac7ab7ca2a0b59246ba12623622253
4
- data.tar.gz: bf8e2b45aa052d46b8abe55cc8e1364e48aa4d9f70621280ec7d114c94f1a95e
3
+ metadata.gz: 4e049f760aad80be6b528604923d13227e763698f1a99aeea0b216e747aac75d
4
+ data.tar.gz: 1e8eae627184409c3c9cc3a5ee903f480067bd780b2b7c935cce82e03cad8938
5
5
  SHA512:
6
- metadata.gz: 7544a56bf9f5e135b899c95dca1f7dc12ecd0aefa006ccc847a5407dd10d53945d5a58b16220d6fe228a596c853323b7c49da05e530ddf49388759bc7b88309e
7
- data.tar.gz: 394171c0c00105467c9a23af8444f36935f2042c1f67c1359fa36c3e856dbcdea50f1440a4a8593339314d6783c673994728a1150547e4c4f4faeb2253107300
6
+ metadata.gz: bfc734f0e05e6dda9d82bf28e0c203e65821a98258f75fc7caed5b5173aff78ac8a90234768ce43dfca6d41652a25a2f555bddd5da5d6d28074f4978a06b0599
7
+ data.tar.gz: 9b17e3cc731a65e4a8cf0c612cfd037eb02d09b57ffeaa359076ce8081c3214b4509181c215e4e13613561b73c8e02e36e8507a5d34194abbcbd5bceec825e49
@@ -0,0 +1,17 @@
1
+ version: 2
2
+ updates:
3
+ # raise PRs for gem updates
4
+ - package-ecosystem: bundler
5
+ directory: "/"
6
+ schedule:
7
+ interval: daily
8
+ time: "13:00"
9
+ open-pull-requests-limit: 10
10
+
11
+ # Maintain dependencies for GitHub Actions
12
+ - package-ecosystem: github-actions
13
+ directory: "/"
14
+ schedule:
15
+ interval: daily
16
+ time: "13:00"
17
+ open-pull-requests-limit: 10
@@ -17,7 +17,7 @@ jobs:
17
17
  runs-on: ubuntu-latest
18
18
 
19
19
  steps:
20
- - uses: actions/checkout@master
20
+ - uses: actions/checkout@v3
21
21
  - uses: azure/docker-login@v1
22
22
  with: # This doesn't seem to work unless we point directly to the secrets
23
23
  username: ${{ secrets.DOCKERHUB_USERNAME }}
@@ -27,11 +27,11 @@ jobs:
27
27
  with:
28
28
  ruby-version: 2.6.x
29
29
  - run: gem install bundler
30
- - uses: actions/checkout@v2
30
+ - uses: actions/checkout@v3
31
31
  - name: Set up QEMU
32
- uses: docker/setup-qemu-action@v1
32
+ uses: docker/setup-qemu-action@v2
33
33
  - name: Set up Docker Buildx
34
- uses: docker/setup-buildx-action@v1
34
+ uses: docker/setup-buildx-action@v2
35
35
  - name: Build container
36
36
  working-directory: docker
37
37
  run: |
@@ -4,6 +4,7 @@ on:
4
4
  push:
5
5
  branches:
6
6
  - main
7
+ - 3.x
7
8
  paths:
8
9
  - 'lib/r10k/version.rb'
9
10
 
@@ -11,11 +12,11 @@ jobs:
11
12
  release:
12
13
  runs-on: ubuntu-latest
13
14
  steps:
14
- - uses: actions/checkout@v2
15
+ - uses: actions/checkout@v3
15
16
  with:
16
17
  fetch-depth: '0'
17
18
  - name: Bump version and push tag
18
- uses: anothrNick/github-tag-action@1.35.0
19
+ uses: anothrNick/github-tag-action@1.67.0
19
20
  env:
20
21
  GITHUB_TOKEN: ${{ secrets.PUPPET_RELEASE_GH_TOKEN }}
21
22
  DEFAULT_BUMP: patch
@@ -11,12 +11,12 @@ jobs:
11
11
  strategy:
12
12
  matrix:
13
13
  cfg:
14
- - {os: ubuntu-18.04, ruby: 2.4}
15
- - {os: ubuntu-18.04, ruby: 2.5}
16
- - {os: ubuntu-18.04, ruby: 2.6}
17
- - {os: ubuntu-18.04, ruby: 2.7}
18
- - {os: ubuntu-18.04, ruby: 3.1}
19
- - {os: ubuntu-18.04, ruby: jruby-9.2.10.0}
14
+ - {os: ubuntu-latest, ruby: 2.4}
15
+ - {os: ubuntu-latest, ruby: 2.5}
16
+ - {os: ubuntu-latest, ruby: 2.6}
17
+ - {os: ubuntu-latest, ruby: 2.7}
18
+ - {os: ubuntu-latest, ruby: 3.2}
19
+ - {os: ubuntu-latest, ruby: jruby-9.2.10.0}
20
20
  - {os: windows-2019, ruby: 2.5}
21
21
  - {os: windows-2019, ruby: 2.6}
22
22
  - {os: windows-2019, ruby: 2.7}
@@ -24,7 +24,7 @@ jobs:
24
24
  runs-on: ${{ matrix.cfg.os }}
25
25
  steps:
26
26
  - name: Checkout current PR
27
- uses: actions/checkout@v2
27
+ uses: actions/checkout@v3
28
28
 
29
29
  - name: Install ruby version ${{ matrix.cfg.ruby }}
30
30
  uses: ruby/setup-ruby@v1
@@ -8,7 +8,7 @@ jobs:
8
8
  stale:
9
9
  runs-on: ubuntu-latest
10
10
  steps:
11
- - uses: actions/stale@v3
11
+ - uses: actions/stale@v8
12
12
  with:
13
13
  repo-token: ${{ secrets.GITHUB_TOKEN }}
14
14
  days-before-stale: 60
data/CHANGELOG.mkd CHANGED
@@ -4,21 +4,44 @@ CHANGELOG
4
4
  Unreleased
5
5
  ----------
6
6
 
7
+ 3.16.2
8
+ ------
9
+
10
+ - r10k::module::git: expose remote as getter [#1379](https://github.com/puppetlabs/r10k/pull/1379)
11
+
12
+ 3.16.1
13
+ ------
14
+
15
+ - Make metadata loading during incremental deploys more robust [PE-34917](https://perforce.atlassian.net/browse/PE-34917)
16
+ - Use the production forge for integration testing
17
+
18
+ 3.16.0
19
+ ------
20
+
21
+ - Emit more debug output when modules fail to sync [#1347](https://github.com/puppetlabs/r10k/pull/1347)
22
+ - Update GitHub Actions & introduce dependabot [#1337](https://github.com/puppetlabs/r10k/pull/1337)
23
+ - Update R10K proxy usage to follow newer rugged best practices [PE-35980](https://tickets.puppet.com/browse/PE-35980)
24
+ - Update Acceptance tests to be compatible with Puppet 8 [#1349](https://github.com/puppetlabs/r10k/pull/1349)
25
+
7
26
  3.15.4
8
27
  ------
28
+
9
29
  - Pin dependencies to maintain support for old Ruby versions [#1329](https://github.com/puppetlabs/r10k/pull/1329)
10
30
 
11
31
  3.15.3
12
32
  ------
33
+
13
34
  - Fix dirty working copy debug logging [#1321](https://github.com/puppetlabs/r10k/pull/1321)
14
35
  - Allow gettext-setup < 2 for compatibility with Ruby 3.2 and Puppet 8 [#1325](https://github.com/puppetlabs/r10k/pull/1325)
15
36
 
16
37
  3.15.2
17
38
  ------
39
+
18
40
  - Implement exclude regex for puppetfile install [#1248](https://github.com/puppetlabs/r10k/issues/1248)
19
41
 
20
42
  3.15.1
21
43
  ------
44
+
22
45
  - Add TOC to configuration docs [#1298](https://github.com/puppetlabs/r10k/issues/1298)
23
46
  - Remove the spec folder from gemspec [#1316](https://github.com/puppetlabs/r10k/issues/1316)
24
47
 
data/Gemfile CHANGED
@@ -6,10 +6,10 @@ group :extra do
6
6
  end
7
7
 
8
8
  group :development do
9
- gem 'simplecov', '~> 0.9.1'
9
+ gem 'simplecov', '~> 0.17.1'
10
10
  gem 'ruby-prof', :platforms => :ruby
11
11
  end
12
12
 
13
- if File.exists? "#{__FILE__}.local"
13
+ if File.exist? "#{__FILE__}.local"
14
14
  eval(File.read("#{__FILE__}.local"), binding)
15
15
  end
data/integration/Rakefile CHANGED
@@ -69,7 +69,7 @@ rototiller_task :beaker_hostgenerator do |t|
69
69
  # This is a hack :(
70
70
  t.add_flag(:name => '', :default => 'centos7-64mdca-64.fa', :override_env => 'TEST_TARGET')
71
71
 
72
- t.add_flag(:name => '--global-config', :default => '{forge_host=forge-aio01-petest.puppetlabs.com}', :override_env => 'BHG_GLOBAL_CONFIG')
72
+ t.add_flag(:name => '--global-config', :default => '{forge_host=forgeapi.puppet.com}', :override_env => 'BHG_GLOBAL_CONFIG')
73
73
  end
74
74
  end
75
75
 
@@ -1,4 +1,4 @@
1
- $git_package = $osfamily ? {
1
+ $git_package = $facts['os']['family'] ? {
2
2
  'Debian' => 'git-core',
3
3
  default => 'git'
4
4
  }
@@ -23,9 +23,6 @@ pe_version = get_puppet_version(master)
23
23
  fail_test('This pre-suite requires PE 3.7 or above!') if pe_version < 3.7
24
24
 
25
25
  #Setup
26
- step 'Stub Forge on Master'
27
- stub_forge_on(master)
28
-
29
26
  step 'Read module path'
30
27
  on(master, puppet('config print basemodulepath')) do |result|
31
28
  (result.stdout.include? ':') ? separator = ':' : separator = ';'
@@ -19,7 +19,7 @@ r10k_config_bak_path = "#{r10k_config_path}.bak"
19
19
 
20
20
  puppetfile =<<-EOS
21
21
  mod 'motd',
22
- :git => 'https://github.com/puppetlabs/puppetlabs-motd'
22
+ :git => 'https://github.com/puppetlabs/puppetlabs-motd', :branch => 'main'
23
23
  EOS
24
24
 
25
25
  proxy_env_value = 'http://ferritsarebest.net:3219'
@@ -36,7 +36,7 @@ sources:
36
36
  CONF
37
37
 
38
38
  teardown do
39
- master.clear_env_var('HTTP_PROXY')
39
+ master.clear_env_var('HTTPS_PROXY')
40
40
 
41
41
  step 'Restore Original "r10k" Config'
42
42
  on(master, "mv #{r10k_config_bak_path} #{r10k_config_path}")
@@ -45,7 +45,7 @@ teardown do
45
45
  clean_up_r10k(master, last_commit, git_environments_path)
46
46
  end
47
47
 
48
- master.add_env_var('HTTP_PROXY', proxy_env_value)
48
+ master.add_env_var('HTTPS_PROXY', proxy_env_value)
49
49
 
50
50
  step 'Backup Current "r10k" Config'
51
51
  on(master, "mv #{r10k_config_path} #{r10k_config_bak_path}")
@@ -64,7 +64,8 @@ git_add_commit_push(master, 'production', 'add Puppetfile', git_environments_pat
64
64
 
65
65
  #test
66
66
  on(master, "#{r10k_fqp} deploy environment -p", :accept_all_exit_codes => true) do |r|
67
- regex = /(Couldn't|Could not) resolve proxy.*ferritsarebest\.net/i
67
+ # Rugged as of 0.28 has a different error message than shellgit
68
+ regex = /((failed to resolve address for)|(Could not resolve proxy:)) ferritsarebest\.net/
68
69
  assert(r.exit_code == 1, 'expected error code was not observed')
69
70
  assert_match(regex, r.stderr, 'The expected error message was not observed' )
70
71
  end
@@ -50,7 +50,7 @@ forge:
50
50
  CONF
51
51
 
52
52
  #Verification
53
- squid_log_regex = /CONNECT forgeapi.puppetlabs.com:443/
53
+ squid_log_regex = /CONNECT forgeapi.puppet(labs)?.com:443/
54
54
 
55
55
  #Teardown
56
56
  teardown do
@@ -21,7 +21,7 @@ remove_squid = "#{pkg_manager} remove -y squid"
21
21
  squid_log = "/var/log/squid/access.log"
22
22
 
23
23
  #Verification
24
- squid_log_regex = /CONNECT forgeapi.puppetlabs.com:443/
24
+ squid_log_regex = /CONNECT forgeapi.puppet(labs)?.com:443/
25
25
 
26
26
  #Teardown
27
27
  teardown do
@@ -10,7 +10,7 @@ confine(:to, :platform => ['el', 'ubuntu', 'sles'])
10
10
 
11
11
  if ENV['GIT_PROVIDER'] == 'shellgit'
12
12
  skip_test('Skipping test because removing Git from the system affects other "shellgit" tests.')
13
- elsif fact_on(master, 'osfamily') == 'RedHat' and fact_on(master, "operatingsystemmajrelease").to_i < 6
13
+ elsif fact_on(master, 'osfamily') == 'RedHat' and fact_on(master, "os.release.major").to_i < 6
14
14
  skip_test('This version of EL is not supported by this test case!')
15
15
  end
16
16
 
@@ -87,7 +87,7 @@ step 'Remove "git" Package from System'
87
87
  if master_platform == 'RedHat'
88
88
  on(master, 'yum remove -y git')
89
89
  elsif master_platform == 'Debian'
90
- if fact_on(master, "operatingsystemmajrelease") == '10.04'
90
+ if fact_on(master, "os.release.major") == '10.04'
91
91
  on(master, 'apt-get remove -y git-core')
92
92
  else
93
93
  on(master, 'apt-get remove -y git')
@@ -8,7 +8,7 @@ confine(:to, :platform => ['el', 'ubuntu', 'sles'])
8
8
 
9
9
  if ENV['GIT_PROVIDER'] == 'shellgit'
10
10
  skip_test('Skipping test because removing Git from the system affects other "shellgit" tests.')
11
- elsif fact_on(master, 'osfamily') == 'RedHat' and fact_on(master, "operatingsystemmajrelease").to_i < 6
11
+ elsif fact_on(master, 'osfamily') == 'RedHat' and fact_on(master, "os.release.major").to_i < 6
12
12
  skip_test('This version of EL is not supported by this test case!')
13
13
  end
14
14
 
@@ -86,7 +86,7 @@ step 'Remove "git" Package from System'
86
86
  if master_platform == 'RedHat'
87
87
  on(master, 'yum remove -y git')
88
88
  elsif master_platform == 'Debian'
89
- if fact_on(master, "operatingsystemmajrelease") == '10.04'
89
+ if fact_on(master, "os.release.major") == '10.04'
90
90
  on(master, 'apt-get remove -y git-core')
91
91
  else
92
92
  on(master, 'apt-get remove -y git')
@@ -46,9 +46,6 @@ teardown do
46
46
  end
47
47
 
48
48
  #Setup
49
- step 'Stub Forge on Master'
50
- stub_forge_on(master)
51
-
52
49
  step 'Inject New "site.pp" to the "production" Environment'
53
50
  inject_site_pp(master, site_pp_path, site_pp)
54
51
 
@@ -47,9 +47,6 @@ teardown do
47
47
  end
48
48
 
49
49
  #Setup
50
- step 'Stub Forge on Master'
51
- stub_forge_on(master)
52
-
53
50
  step 'Inject New "site.pp" to the "production" Environment'
54
51
  inject_site_pp(master, site_pp_path, site_pp)
55
52
 
@@ -16,28 +16,24 @@ r10k_config_bak_path = "#{r10k_config_path}.bak"
16
16
 
17
17
  puppetfile =<<-EOS
18
18
  mod 'motd',
19
- :git => 'https://github.com/puppetlabs/puppetlabs-motd'
19
+ :git => 'https://github.com/puppetlabs/puppetlabs-motd', :branch => 'main'
20
20
  EOS
21
21
 
22
- proxy_env_value = 'http://cattastic.net:3219'
23
-
24
22
  #In-line files
25
23
  r10k_conf = <<-CONF
26
24
  cachedir: '/var/cache/r10k'
27
25
  git:
28
26
  provider: '#{git_provider}'
29
27
  repositories:
30
- - remote: 'http://example.com/fake_git_source.git'
28
+ - remote: 'https://something.else/repo'
31
29
  proxy: 'http://foooooooo.unresolvable:3128'
32
30
  sources:
33
31
  control:
34
32
  basedir: "#{env_path}"
35
- remote: "http://example.com/fake_git_source.git"
33
+ remote: 'https://something.else/repo'
36
34
  CONF
37
35
 
38
36
  teardown do
39
- master.clear_env_var('HTTP_PROXY')
40
-
41
37
  step 'Restore Original "r10k" Config'
42
38
  on(master, "mv #{r10k_config_bak_path} #{r10k_config_path}")
43
39
 
@@ -45,8 +41,6 @@ teardown do
45
41
  clean_up_r10k(master, last_commit, git_environments_path)
46
42
  end
47
43
 
48
- master.add_env_var('HTTP_PROXY', proxy_env_value)
49
-
50
44
  step 'Backup Current "r10k" Config'
51
45
  on(master, "mv #{r10k_config_path} #{r10k_config_bak_path}")
52
46
 
@@ -64,7 +58,8 @@ git_add_commit_push(master, 'production', 'add Puppetfile', git_environments_pat
64
58
 
65
59
  #test
66
60
  on(master, "#{r10k_fqp} deploy environment -p", :accept_all_exit_codes => true) do |r|
67
- regex = /proxy.*foooooooo\.unresolvable/
61
+ # Rugged as of 0.28 has a different error message than shellgit
62
+ regex = /((failed to resolve address for)|(Could not resolve proxy:)) foooooooo\.unresolvable/
68
63
  assert(r.exit_code == 1, 'expected error code was not observed')
69
64
  assert_match(regex, r.stderr, 'The expected error message was not observed' )
70
65
  end
@@ -5,7 +5,7 @@ test_name 'CODEMGMT-92 - C59235 - Single Git Source Using "GIT" Transport Protoc
5
5
 
6
6
  confine(:to, :platform => 'el')
7
7
 
8
- if fact_on(master, "operatingsystemmajrelease").to_i < 6
8
+ if fact_on(master, "os.release.major").to_i < 6 || fact_on(master, "os.release.major").to_i > 8
9
9
  skip_test('This version of EL is not supported by this test case!')
10
10
  end
11
11
 
@@ -84,9 +84,6 @@ teardown do
84
84
  end
85
85
 
86
86
  #Setup
87
- step 'Stub Forge on Master'
88
- stub_forge_on(master)
89
-
90
87
  step 'Backup Current "r10k" Config'
91
88
  on(master, "mv #{r10k_config_path} #{r10k_config_bak_path}")
92
89
 
@@ -44,9 +44,6 @@ teardown do
44
44
  clean_up_r10k(master, last_commit, git_environments_path)
45
45
  end
46
46
 
47
- step 'Stub the forge'
48
- stub_forge_on(master)
49
-
50
47
  step 'Backup Current "r10k" Config'
51
48
  on(master, "mv #{r10k_config_path} #{r10k_config_bak_path}")
52
49
 
@@ -68,6 +68,6 @@ on(master, "chmod 600 #{ssh_private_key_path}")
68
68
 
69
69
  #Tests
70
70
  step 'Attempt to Deploy via r10k'
71
- on(master, "#{r10k_fqp} deploy environment -v", :acceptable_exit_codes => 1) do |result|
71
+ on(master, "SSH_AUTH_SOCK= SSH_CONNECTION= SSH_CLIENT= #{r10k_fqp} deploy environment -v", :acceptable_exit_codes => 1) do |result|
72
72
  assert_match(error_message_regex, result.stderr, 'Expected message not found!')
73
73
  end
@@ -50,9 +50,6 @@ teardown do
50
50
  clean_up_r10k(master, last_commit, git_environments_path)
51
51
  end
52
52
 
53
- step 'Stub the forge'
54
- stub_forge_on(master)
55
-
56
53
  step 'Backup Current "r10k" Config'
57
54
  on(master, "mv #{r10k_config_path} #{r10k_config_bak_path}")
58
55
 
@@ -51,9 +51,6 @@ fake_file_b_to_be_left_alone = "#{fake_environment_path_b}/fakefile2.txt"
51
51
  fake_file_c_to_be_purged = "#{fake_environment_path_c}/fakefile3.txt"
52
52
 
53
53
  # initalize file content
54
- step 'Stub the forge'
55
- stub_forge_on(master)
56
-
57
54
  step 'Backup Current "r10k" Config'
58
55
  on(master, "mv #{r10k_config_path} #{r10k_config_bak_path}")
59
56
 
@@ -26,9 +26,6 @@ teardown do
26
26
  end
27
27
 
28
28
  # initalize file content
29
- step 'Stub the forge'
30
- stub_forge_on(master)
31
-
32
29
  step 'Backup Current "r10k" Config'
33
30
  on(master, "mv #{r10k_config_path} #{r10k_config_bak_path}")
34
31
 
@@ -62,9 +62,6 @@ teardown do
62
62
  end
63
63
 
64
64
  #Setup
65
- step 'Stub Forge on Master'
66
- stub_forge_on(master)
67
-
68
65
  env_names.each do |env|
69
66
  if env == 'production'
70
67
  step "Checkout \"#{env}\" Branch"
@@ -66,9 +66,6 @@ teardown do
66
66
  end
67
67
 
68
68
  #Setup
69
- step 'Stub Forge on Master'
70
- stub_forge_on(master)
71
-
72
69
  env_names.each do |env|
73
70
  if env == 'production'
74
71
  step "Checkout \"#{env}\" Branch"
@@ -102,9 +102,6 @@ teardown do
102
102
  end
103
103
 
104
104
  #Setup
105
- step 'Stub Forge on Master'
106
- stub_forge_on(master)
107
-
108
105
  step 'Backup Current "r10k" Config'
109
106
  on(master, "mv #{r10k_config_path} #{r10k_config_bak_path}")
110
107
 
@@ -29,9 +29,6 @@ teardown do
29
29
  end
30
30
 
31
31
  #Setup
32
- step 'Stub Forge on Master'
33
- stub_forge_on(master)
34
-
35
32
  step 'Checkout "production" Branch'
36
33
  git_on(master, 'checkout production', git_environments_path)
37
34
 
@@ -2,7 +2,7 @@ require 'git_utils'
2
2
  require 'r10k_utils'
3
3
  test_name 'CODEMGMT-86 - C59265 - Attempt to Deploy Environment to Disk with Insufficient Free Space'
4
4
 
5
- if fact_on(master, 'osfamily') == 'RedHat' and fact_on(master, "operatingsystemmajrelease").to_i < 6
5
+ if fact_on(master, 'osfamily') == 'RedHat' and fact_on(master, "os.release.major").to_i < 6
6
6
  skip_test('This version of EL is not supported by this test case!')
7
7
  end
8
8
 
@@ -25,9 +25,6 @@ teardown do
25
25
  end
26
26
 
27
27
  #Setup
28
- step 'Stub Forge on Master'
29
- stub_forge_on(master)
30
-
31
28
  step 'Checkout "production" Branch'
32
29
  git_on(master, 'checkout production', git_environments_path)
33
30
 
@@ -19,7 +19,7 @@ PUPPETFILE
19
19
  puppet_file_path = File.join(git_environments_path, 'Puppetfile')
20
20
 
21
21
  #Verification
22
- error_message_regex = /Error: Could not connect via HTTPS to https:\/\/forgeapi.puppetlabs.com/
22
+ error_message_regex = /Error: Could not connect via HTTPS to https:\/\/forgeapi.puppet(labs)?.com/
23
23
 
24
24
  #Teardown
25
25
  teardown do
@@ -34,7 +34,8 @@ step 'Backup "/etc/hosts" File on Master'
34
34
  on(master, "mv #{hosts_file_path} #{hosts_file_path}.bak")
35
35
 
36
36
  step 'Point Forge Hostname to Localhost'
37
- on(master, "echo '127.0.0.1 forgeapi.puppetlabs.com' > #{hosts_file_path}")
37
+ on(master, "echo '127.0.0.1 forgeapi.puppet.com' > #{hosts_file_path}")
38
+ on(master, "echo '127.0.0.1 forgeapi.puppetlabs.com' >> #{hosts_file_path}")
38
39
 
39
40
  step 'Checkout "production" Branch'
40
41
  git_on(master, 'checkout production', git_environments_path)
@@ -10,7 +10,7 @@ last_commit = git_last_commit(master, git_environments_path)
10
10
  r10k_fqp = get_r10k_fqp(master)
11
11
 
12
12
  #Verification
13
- error_notification_regex = /The module puppetlabs-regret does not appear to have any published releases/
13
+ error_notification_regex = /(The module puppetlabs-regret does not appear to have any published releases)|(module puppetlabs-regret does not exist on)/
14
14
 
15
15
  #File
16
16
  puppet_file = <<-PUPPETFILE
@@ -24,10 +24,6 @@ teardown do
24
24
  clean_up_r10k(master, last_commit, git_environments_path)
25
25
  end
26
26
 
27
- #Setup
28
- step 'Stub Forge on Master'
29
- stub_forge_on(master)
30
-
31
27
  #Tests
32
28
  step 'Checkout "production" Branch'
33
29
  git_on(master, 'checkout production', git_environments_path)
@@ -3,7 +3,7 @@ require 'r10k_utils'
3
3
  require 'master_manipulator'
4
4
  test_name 'CODEMGMT-62 - C59239 - Single Environment with 10,000 Files'
5
5
 
6
- if fact_on(master, 'osfamily') == 'RedHat' and fact_on(master, "operatingsystemmajrelease").to_i < 6
6
+ if fact_on(master, 'osfamily') == 'RedHat' and fact_on(master, "os.release.major").to_i < 6
7
7
  skip_test('This version of EL is not supported by this test case!')
8
8
  end
9
9
 
@@ -64,9 +64,6 @@ teardown do
64
64
  end
65
65
 
66
66
  #Setup
67
- step 'Stub Forge on Master'
68
- stub_forge_on(master)
69
-
70
67
  step 'Checkout "production" Branch'
71
68
  git_on(master, 'checkout production', git_environments_path)
72
69
 
@@ -45,9 +45,6 @@ teardown do
45
45
  end
46
46
 
47
47
  #Setup
48
- step 'Stub Forge on Master'
49
- stub_forge_on(master)
50
-
51
48
  step 'Checkout "production" Branch'
52
49
  git_on(master, 'checkout production', git_environments_path)
53
50
 
@@ -3,7 +3,7 @@ require 'r10k_utils'
3
3
  require 'master_manipulator'
4
4
  test_name 'CODEMGMT-62 - C59242 - Single Environment with Large Binary Files'
5
5
 
6
- if fact_on(master, 'osfamily') == 'RedHat' and fact_on(master, "operatingsystemmajrelease").to_i < 6
6
+ if fact_on(master, 'osfamily') == 'RedHat' and fact_on(master, "os.release.major").to_i < 6
7
7
  skip_test('This version of EL is not supported by this test case!')
8
8
  end
9
9
 
@@ -44,9 +44,6 @@ teardown do
44
44
  end
45
45
 
46
46
  #Setup
47
- step 'Stub Forge on Master'
48
- stub_forge_on(master)
49
-
50
47
  step 'Add motd module from the forge using the PMT'
51
48
  on(master, puppet('module', 'install', 'puppetlabs-motd', '--modulepath', forge_module_path))
52
49
 
@@ -43,9 +43,6 @@ teardown do
43
43
  end
44
44
 
45
45
  #Setup
46
- step 'Stub Forge on Master'
47
- stub_forge_on(master)
48
-
49
46
  step 'Checkout "production" Branch'
50
47
  git_on(master, 'checkout production', git_remote_environments_path)
51
48
 
@@ -57,9 +57,6 @@ teardown do
57
57
  end
58
58
 
59
59
  #Setup
60
- step 'Stub Forge on Master'
61
- stub_forge_on(master)
62
-
63
60
  step 'Checkout "production" Branch'
64
61
  git_on(master, 'checkout production', git_environments_path)
65
62
 
@@ -60,9 +60,6 @@ teardown do
60
60
  end
61
61
 
62
62
  #Setup
63
- step 'Stub Forge on Master'
64
- stub_forge_on(master)
65
-
66
63
  step 'Checkout "production" Branch'
67
64
  git_on(master, 'checkout production', git_environments_path)
68
65
 
@@ -65,9 +65,6 @@ teardown do
65
65
  end
66
66
 
67
67
  #Setup
68
- step 'Stub Forge on Master'
69
- stub_forge_on(master)
70
-
71
68
  initial_env_names.each do |env|
72
69
  if env == 'production'
73
70
  step "Checkout \"#{env}\" Branch"