beaker-pe 1.12.1 → 1.13.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,15 +1,15 @@
1
1
  ---
2
2
  !binary "U0hBMQ==":
3
3
  metadata.gz: !binary |-
4
- ZmM1MjMxNjZkYjU3ZWM2ZGI4NDhjMmI0ZWYwM2FjOGZkZmQ0NmNmMA==
4
+ YTA2MWQxYmE4MDE4M2E3MzdjNzkzZWQwODc2ODRlMzJmOTFhOTE5OQ==
5
5
  data.tar.gz: !binary |-
6
- YmI3YmJlOWE2NjYwYzUwNTBhYTMyYWQyYTY5OGVmMTFmN2YwMmNmNA==
6
+ MDU5OTkyNTgzODI1MTFjM2Q1OGYyMGMyZWQ2ZTE2NjQxNGM0MTdlZg==
7
7
  SHA512:
8
8
  metadata.gz: !binary |-
9
- NTVjYTNmOTJkOWY0YzVmNjUyOGM0MjAyMzVlZmVhZDI5ZTk3NjhlMjJjOTNm
10
- NmI0YzZlYTMwYWIxYTM1M2FkZTJlYzIwYzlhZTY2M2Q4YTYwNDM1MTRmNTdl
11
- NjQwY2YxZGY0Y2FkMzZmZTk0OWU1MDUzZDJiZTQ3YWM4NTU4ODA=
9
+ OTZmNzgyMmMzY2ExZmRhZTE4NzAyMGZmNDU1NWMwMzhmY2RiYjNkNzcxNWI0
10
+ OTc2YjY2ZTU1NmI1NGJjYjJiOTRjMzQ4NTY1MjQyZDQ3YzFmOWE4ZDIzNDI3
11
+ MWIzOWI2NDkyM2ZhOGQwNmUzNDA0ZjFkZjViYjg5NzM5OWUwY2Q=
12
12
  data.tar.gz: !binary |-
13
- NzBhYTVjOTRmMjc5ODRhZWExNjliY2VkMmI5ODk3YzExODQ3YmIxMWMwMGYw
14
- NDBjOTQwZjY5ZTQ1ZGE2MTk5MDJjNWQ0MDNhNWY2ODI5YTgzZGM3ZGY3MGU4
15
- ODQxNGFjNzYzODlhMjMxYWVjMDU3NjAyZTMyMGM3ODAzYjg5ODA=
13
+ MjkyZjI3MWFjOTczOTZlNjA3OTI4MTNhMmFkODQyMmJhOTZlNDM0ZDE5YTEw
14
+ MWU3ZDAzYjg2ZGEyYTk2ZWI1ZWMxMmY1YjRkZTE4YzA0MjFiMDc1MDkxYjlk
15
+ M2EwNzM4YTNjMjNiNzk5MDk3ZDAzZDAxZTFjZGQyYjAxN2IwZWE=
data/HISTORY.md CHANGED
@@ -1,6 +1,7 @@
1
1
  # worker - History
2
2
  ## Tags
3
- * [LATEST - 29 Mar, 2017 (95b0e94f)](#LATEST)
3
+ * [LATEST - 6 Apr, 2017 (197a55dd)](#LATEST)
4
+ * [1.12.1 - 29 Mar, 2017 (fe8bbc82)](#1.12.1)
4
5
  * [1.12.0 - 23 Mar, 2017 (0784adc6)](#1.12.0)
5
6
  * [1.11.0 - 23 Mar, 2017 (6c3b0067)](#1.11.0)
6
7
  * [1.10.0 - 20 Mar, 2017 (22e22ca8)](#1.10.0)
@@ -35,7 +36,31 @@
35
36
  * [0.1.0 - 29 Feb, 2016 (4fc88d8c)](#0.1.0)
36
37
 
37
38
  ## Details
38
- ### <a name = "LATEST">LATEST - 29 Mar, 2017 (95b0e94f)
39
+ ### <a name = "LATEST">LATEST - 6 Apr, 2017 (197a55dd)
40
+
41
+ * (GEM) update beaker-pe version to 1.13.0 (197a55dd)
42
+
43
+ * (BKR-806) Add tests for frictionless repo setup (5e723bb2)
44
+
45
+ * (BKR-806) Only add pe_repo classes once (a718fbb9)
46
+
47
+
48
+ ```
49
+ (BKR-806) Only add pe_repo classes once
50
+
51
+ Previously, if installing multiple agents with the same platform, the
52
+ work to add the appropriate pe_repo class to the master would be
53
+ performed once for each agent. Because that requires running `puppet
54
+ agent -t` on the master, it can add a significant amount of unnecessary
55
+ overhead to the install process when installing several agents.
56
+
57
+ We now check whether the class has already been included in the Beaker
58
+ Frictionless Agent group and skip running puppet on the master if it
59
+ has.
60
+ ```
61
+ ### <a name = "1.12.1">1.12.1 - 29 Mar, 2017 (fe8bbc82)
62
+
63
+ * (HISTORY) update beaker-pe history for gem release 1.12.1 (fe8bbc82)
39
64
 
40
65
  * (GEM) update beaker-pe version to 1.12.1 (95b0e94f)
41
66
 
@@ -340,11 +340,13 @@ module Beaker
340
340
  node_group['classes'] ||= {}
341
341
  end
342
342
 
343
- # add the pe_repo platform class
344
- node_group['classes'][klass] = {}
343
+ # add the pe_repo platform class if it's not already present
344
+ if ! node_group['classes'].include?(klass)
345
+ node_group['classes'][klass] = {}
345
346
 
346
- _console_dispatcher.create_new_node_group_model(node_group)
347
- on master, puppet("agent -t"), :acceptable_exit_codes => [0,2]
347
+ _console_dispatcher.create_new_node_group_model(node_group)
348
+ on master, puppet("agent -t"), :acceptable_exit_codes => [0,2]
349
+ end
348
350
  end
349
351
  end
350
352
 
@@ -3,7 +3,7 @@ module Beaker
3
3
  module PE
4
4
 
5
5
  module Version
6
- STRING = '1.12.1'
6
+ STRING = '1.13.0'
7
7
  end
8
8
 
9
9
  end
@@ -1,4 +1,5 @@
1
1
  require 'spec_helper'
2
+ require 'scooter'
2
3
 
3
4
  class ClassMixedWithDSLInstallUtils
4
5
  include Beaker::DSL::InstallUtils
@@ -928,6 +929,39 @@ describe ClassMixedWithDSLInstallUtils do
928
929
  end
929
930
  end
930
931
 
932
+ describe '#deploy_frictionless_to_master' do
933
+ let(:master) { make_host('master', :pe_ver => '2017.2', :platform => 'ubuntu-16.04-x86_64', :roles => ['master', 'database', 'dashboard']) }
934
+ let(:agent) { make_host('agent', :pe_ver => '2017.2', :platform => 'el-7-x86_64', :roles => ['frictionless']) }
935
+ let(:dispatcher) { double('dispatcher') }
936
+ let(:node_group) { {} }
937
+
938
+ before :each do
939
+ allow(subject).to receive(:on)
940
+
941
+ allow(subject).to receive(:hosts).and_return([master, agent])
942
+ allow(Scooter::HttpDispatchers::ConsoleDispatcher).to receive(:new).and_return(dispatcher)
943
+
944
+ allow(dispatcher).to receive(:get_node_group_by_name).and_return(node_group)
945
+ allow(dispatcher).to receive(:create_new_node_group_model) {|model| node_group.update(model)}
946
+ end
947
+
948
+ it 'adds the right pe_repo class to the Beaker Frictionless Agent group' do
949
+ subject.deploy_frictionless_to_master(agent)
950
+
951
+ expect(node_group['rule']).to eq(['and', ['=', 'name', 'master']])
952
+ expect(node_group['classes']).to include('pe_repo::platform::el_7_x86_64')
953
+ end
954
+
955
+ it 'only adds classes once' do
956
+ expect(dispatcher).to receive(:create_new_node_group_model).once
957
+
958
+ subject.deploy_frictionless_to_master(agent)
959
+ subject.deploy_frictionless_to_master(agent)
960
+
961
+ expect(node_group['classes']).to include('pe_repo::platform::el_7_x86_64')
962
+ end
963
+ end
964
+
931
965
  describe 'do_install' do
932
966
  it 'chooses to do a simple monolithic install when appropriate' do
933
967
  expect(subject).to receive(:simple_monolithic_install)
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: beaker-pe
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.12.1
4
+ version: 1.13.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Puppetlabs
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2017-03-29 00:00:00.000000000 Z
11
+ date: 2017-04-06 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rspec