foreman_salt 7.0.1 → 7.0.2

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,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 2ee51989d82f34d76d55912ccd8703f57174338b
4
- data.tar.gz: 5b031339533e12d2cdb1ebfe55a51866e6b65463
3
+ metadata.gz: d2936d97abe52cb693b707b70efe7202cc88e5d7
4
+ data.tar.gz: d89d2744669bf971479183f366704e7d358f0fe4
5
5
  SHA512:
6
- metadata.gz: 118f8385c0bedde86944f5153bad4c0e71f0ce42087589bf58899544616a508f847b1899e6325702da26caa795b272415176dc03c68014172e765a9d2da1fa2c
7
- data.tar.gz: 916ff3a5404117a014d6bbf859ff5b82c9664a5b3ba534ce9e2737b59e0be0c40e8439beb4fd9115cd4a0daf6c73526a5e3c20f56716be5ee4eee515bfe32fb9
6
+ metadata.gz: b7bce3bc44a5aade9c39f8fab76eb9d284f0aa14c518f2dde18e72c1b79939d52dfea1b1f98a5e7051c43ef4bd9732ee704a07b0caeb35dd28fd7cfd4ba05908
7
+ data.tar.gz: 2d89a9a3d209cd6bf6e0536a21e69ccbbf6ee1104f4e65d64aaa9e0c9f9c04a49ffc357759738c143391b656be4bda13b78398464f4c2113231677261b152799
@@ -11,8 +11,8 @@ module ForemanSalt
11
11
  belongs_to :salt_environment, :class_name => 'ForemanSalt::SaltEnvironment'
12
12
 
13
13
  alias_method_chain :params, :salt_proxy
14
+ alias_method_chain :set_hostgroup_defaults, :salt_proxy
14
15
  alias_method_chain :smart_proxy_ids, :salt_proxy
15
- alias_method_chain :inherited_attributes, :salt
16
16
  alias_method_chain :configuration?, :salt
17
17
 
18
18
  scoped_search :in => :salt_modules, :on => :name, :complete_value => true, :rename => :salt_state
@@ -58,8 +58,10 @@ module ForemanSalt
58
58
  false
59
59
  end
60
60
 
61
- def inherited_attributes_with_salt
62
- inherited_attributes_without_salt + %w(salt_proxy_id salt_environment_id)
61
+ def set_hostgroup_defaults_with_salt_proxy
62
+ return unless hostgroup
63
+ assign_hostgroup_attributes(%w(salt_proxy_id salt_environment_id))
64
+ set_hostgroup_defaults_without_salt_proxy
63
65
  end
64
66
 
65
67
  def smart_proxy_ids_with_salt_proxy
@@ -103,3 +105,7 @@ module ForemanSalt
103
105
  end
104
106
  end
105
107
  end
108
+
109
+ class ::Host::Managed::Jail < Safemode::Jail
110
+ allow :salt_environment
111
+ end
@@ -53,7 +53,7 @@ module ForemanSalt
53
53
  end
54
54
 
55
55
  def facts_to_create
56
- @facts_to_create ||= facts.keys - db_facts.pluck('fact_names.name')
56
+ @facts_to_create ||= facts.keys - db_facts.keys
57
57
  end
58
58
 
59
59
  def fact_names
@@ -1,3 +1,3 @@
1
1
  module ForemanSalt
2
- VERSION = '7.0.1'
2
+ VERSION = '7.0.2'
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: foreman_salt
3
3
  version: !ruby/object:Gem::Version
4
- version: 7.0.1
4
+ version: 7.0.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Stephen Benjamin
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2016-11-19 00:00:00.000000000 Z
11
+ date: 2016-11-23 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: deface
@@ -189,21 +189,21 @@ specification_version: 4
189
189
  summary: Foreman Plug-in for Salt
190
190
  test_files:
191
191
  - test/factories/foreman_salt_factories.rb
192
- - test/functional/api/v2/salt_autosign_controller_test.rb
192
+ - test/unit/host_extensions_test.rb
193
+ - test/unit/salt_keys_test.rb
194
+ - test/unit/grains_importer_test.rb
195
+ - test/unit/hostgroup_extensions_test.rb
196
+ - test/unit/report_importer_test.rb
197
+ - test/unit/salt_modules_test.rb
198
+ - test/unit/highstate.json
199
+ - test/unit/grains_centos.json
200
+ - test/functional/minions_controller_test.rb
193
201
  - test/functional/api/v2/salt_environments_controller_test.rb
202
+ - test/functional/api/v2/salt_autosign_controller_test.rb
194
203
  - test/functional/api/v2/salt_keys_controller_test.rb
195
204
  - test/functional/api/v2/salt_states_controller_test.rb
196
- - test/functional/minions_controller_test.rb
197
205
  - test/integration/salt_autosign_test.rb
198
- - test/integration/salt_environment_test.rb
199
206
  - test/integration/salt_keys_test.rb
207
+ - test/integration/salt_environment_test.rb
200
208
  - test/integration/salt_module_test.rb
201
- - test/unit/grains_centos.json
202
- - test/unit/highstate.json
203
- - test/unit/salt_keys_test.rb
204
- - test/unit/salt_modules_test.rb
205
- - test/unit/hostgroup_extensions_test.rb
206
- - test/unit/report_importer_test.rb
207
- - test/unit/grains_importer_test.rb
208
- - test/unit/host_extensions_test.rb
209
209
  - test/test_plugin_helper.rb