foreman_salt 7.0.0 → 7.0.1

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: d6086715f9091869bb9b9e4bf8ce55b07737200f
4
- data.tar.gz: d1404318a8da0127688638755d3247a1a0b23964
3
+ metadata.gz: 2ee51989d82f34d76d55912ccd8703f57174338b
4
+ data.tar.gz: 5b031339533e12d2cdb1ebfe55a51866e6b65463
5
5
  SHA512:
6
- metadata.gz: 6f1f0df003e6cb6566e9836ed3161b6c27ef55069b99eb50721c068fa63f6a7e3b45d8617be3ad424454aeeac05485157ae11227c31cf86e18cdf49e6fe21cba
7
- data.tar.gz: fe7dc9289fc0f93d234b24e050b60adba1fb215051b9ffee8e7be6cd8ba15949d185991ebd07ac99fb4be4324505f7b77ec11d9a11878e926e2bb64470c9a78b
6
+ metadata.gz: 118f8385c0bedde86944f5153bad4c0e71f0ce42087589bf58899544616a508f847b1899e6325702da26caa795b272415176dc03c68014172e765a9d2da1fa2c
7
+ data.tar.gz: 916ff3a5404117a014d6bbf859ff5b82c9664a5b3ba534ce9e2737b59e0be0c40e8439beb4fd9115cd4a0daf6c73526a5e3c20f56716be5ee4eee515bfe32fb9
@@ -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
15
14
  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,10 +58,8 @@ module ForemanSalt
58
58
  false
59
59
  end
60
60
 
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
61
+ def inherited_attributes_with_salt
62
+ inherited_attributes_without_salt + %w(salt_proxy_id salt_environment_id)
65
63
  end
66
64
 
67
65
  def smart_proxy_ids_with_salt_proxy
@@ -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.keys
56
+ @facts_to_create ||= facts.keys - db_facts.pluck('fact_names.name')
57
57
  end
58
58
 
59
59
  def fact_names
@@ -0,0 +1,8 @@
1
+ class AddIndexToJoinTables < ActiveRecord::Migration
2
+ def change
3
+ add_index :host_salt_modules, :host_id
4
+ add_index :host_salt_modules, :salt_module_id
5
+ add_index :hostgroup_salt_modules, :hostgroup_id
6
+ add_index :hostgroup_salt_modules, :salt_module_id
7
+ end
8
+ end
@@ -1,3 +1,3 @@
1
1
  module ForemanSalt
2
- VERSION = '7.0.0'
2
+ VERSION = '7.0.1'
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.0
4
+ version: 7.0.1
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-08-18 00:00:00.000000000 Z
11
+ date: 2016-11-19 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: deface
@@ -136,6 +136,7 @@ files:
136
136
  - db/migrate/20150411003302_add_environments_to_modules.rb
137
137
  - db/migrate/20150509094409_rename_join_tables.rb
138
138
  - db/migrate/20150509101505_add_primary_keys.rb
139
+ - db/migrate/20161103104146_add_index_to_join_tables.rb
139
140
  - db/seeds.d/75-salt_seeds.rb
140
141
  - lib/foreman_salt.rb
141
142
  - lib/foreman_salt/engine.rb
@@ -187,22 +188,22 @@ signing_key:
187
188
  specification_version: 4
188
189
  summary: Foreman Plug-in for Salt
189
190
  test_files:
190
- - test/integration/salt_module_test.rb
191
- - test/integration/salt_environment_test.rb
191
+ - test/factories/foreman_salt_factories.rb
192
+ - test/functional/api/v2/salt_autosign_controller_test.rb
193
+ - test/functional/api/v2/salt_environments_controller_test.rb
194
+ - test/functional/api/v2/salt_keys_controller_test.rb
195
+ - test/functional/api/v2/salt_states_controller_test.rb
196
+ - test/functional/minions_controller_test.rb
192
197
  - test/integration/salt_autosign_test.rb
198
+ - test/integration/salt_environment_test.rb
193
199
  - test/integration/salt_keys_test.rb
194
- - test/test_plugin_helper.rb
195
- - test/unit/grains_importer_test.rb
200
+ - test/integration/salt_module_test.rb
196
201
  - test/unit/grains_centos.json
197
- - test/unit/host_extensions_test.rb
198
- - test/unit/report_importer_test.rb
199
- - test/unit/hostgroup_extensions_test.rb
200
- - test/unit/salt_modules_test.rb
201
202
  - test/unit/highstate.json
202
203
  - test/unit/salt_keys_test.rb
203
- - test/functional/minions_controller_test.rb
204
- - test/functional/api/v2/salt_autosign_controller_test.rb
205
- - test/functional/api/v2/salt_states_controller_test.rb
206
- - test/functional/api/v2/salt_keys_controller_test.rb
207
- - test/functional/api/v2/salt_environments_controller_test.rb
208
- - test/factories/foreman_salt_factories.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
+ - test/test_plugin_helper.rb