puppetdb_foreman 6.0.0 → 6.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
  SHA256:
3
- metadata.gz: 2917867afdc2d20921a278f2c2fb35aa90ee71ad3ceca28cbfb6fbff4d087bd9
4
- data.tar.gz: 3f6bd9d01c00bd9007220a95b1c0752c938cbbad24c01c670f03ae79e80fd6a5
3
+ metadata.gz: 2210ab6f4ef16d2fec53bd410bb59ce67e1f1c644f05727df71bcc4882ed2d73
4
+ data.tar.gz: 4c9238693d329f35d307a42cdef7e1a4c3ebb53e0ee13ffc899b528694e64628
5
5
  SHA512:
6
- metadata.gz: 424fd00c14417f01cc1ae6eac59d468bb6b32048f5fbd2f0e646319182500a8b46349f31d2797d87efb578d86704eed14cb42710bf25097334993118a335c904
7
- data.tar.gz: 0e0ad581dbecf0ce351bb50e8fd88c348e080b64a812c82cb933da13c60a9006f681ba1bcdc6229987e36b96d5d37719895eb7be81c685a15ddb5ec1c8630121
6
+ metadata.gz: 073a58bb177e3af928a0f65a62976736ffe2326012fe5cefe22b672866315e2e28d2e0d9cbdc7f1cbc28c2483d07039cb9f183a019db12f594e8e6dcda1976f3
7
+ data.tar.gz: f1a7f4fee3f27b8e652495c0d017356ddfa83c2f4b719096b6e9c4fd98a6be57e16554941d3c5d8776fdcf4f088f0b7770d365ba5e78b5241c5c95e7be8a564b
data/README.md CHANGED
@@ -11,7 +11,7 @@ It does the following:
11
11
  * Compares nodes in PuppetDB to Hosts in Foreman.
12
12
  * Creates Hosts in Foreman from PuppetDB facts.
13
13
 
14
- Feel free to raise issues, ask for features, anything, in the github repository or #theforeman IRC channel in Freenode.
14
+ Feel free to raise issues, ask for features, anything, in the github repository or visit [the Foreman support pages](https://theforeman.org/support.html).
15
15
 
16
16
  ## Compatibility
17
17
 
@@ -20,11 +20,12 @@ module Orchestration
20
20
  end
21
21
 
22
22
  def del_puppetdb
23
- Rails.logger.info "Deactivating node in PuppetDB: #{name}"
24
- ::Puppetdb.client.deactivate_node(name)
23
+ Rails.logger.info "Deactivating node in PuppetDB: #{certname} (#{name})"
24
+ ::Puppetdb.client.deactivate_node(certname)
25
25
  rescue StandardError => e
26
26
  failure format(
27
- _("Failed to deactivate node %<name>s in PuppetDB: %<message>s\n "), name: name, message: e.message
27
+ _("Failed to deactivate node %<certname> (%<name>) in PuppetDB: %<message>\n "),
28
+ name: name, message: e.message, certname: certname
28
29
  ), e
29
30
  end
30
31
 
@@ -0,0 +1,9 @@
1
+ # frozen_string_literal: true
2
+
3
+ class FixPuppetdbSettingsCategoryToDsl < ActiveRecord::Migration[6.0]
4
+ def up
5
+ # rubocop:disable Rails/SkipsModelValidations
6
+ Setting.where(category: 'Setting::Puppetdb').update_all(category: 'Setting')
7
+ # rubocop:enable Rails/SkipsModelValidations
8
+ end
9
+ end
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module PuppetdbForeman
4
- VERSION = '6.0.0'
4
+ VERSION = '6.0.1'
5
5
  end
@@ -26,7 +26,7 @@ class HostTest < ActiveSupport::TestCase
26
26
  end
27
27
 
28
28
  test '#del_puppetdb' do
29
- ::PuppetdbClient::V4.any_instance.expects(:deactivate_node).with(host.name).returns(true)
29
+ ::PuppetdbClient::V4.any_instance.expects(:deactivate_node).with(host.certname).returns(true)
30
30
  host.send(:del_puppetdb)
31
31
  end
32
32
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: puppetdb_foreman
3
3
  version: !ruby/object:Gem::Version
4
- version: 6.0.0
4
+ version: 6.0.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Daniel Lobato Garcia
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2022-10-14 00:00:00.000000000 Z
11
+ date: 2022-11-03 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rake
@@ -66,10 +66,10 @@ dependencies:
66
66
  - - ">="
67
67
  - !ruby/object:Gem::Version
68
68
  version: '0'
69
- description: 'Disable hosts on PuppetDB after they are deleted or built in Foreman.
69
+ description: Disable hosts on PuppetDB after they are deleted or built in Foreman.
70
70
  Follow https://github.com/theforeman/puppetdb_foreman and raise an issue/submit
71
- a pull request if you need extra functionality. You can also find some help in #theforeman
72
- IRC channel on Freenode.'
71
+ a pull request if you need extra functionality. You can also find some help via
72
+ the Foreman support pages (https://theforeman.org/support.html).
73
73
  email: elobatocs@gmail.com
74
74
  executables: []
75
75
  extensions: []
@@ -95,6 +95,7 @@ files:
95
95
  - config/routes.rb
96
96
  - db/migrate/20170717140010_migrate_puppetdb_api_version_setting.rb
97
97
  - db/migrate/20181001113836_remove_puppetdb_dashboard_address_setting.puppetdb_foreman.rb
98
+ - db/migrate/20221026123754_fix_puppetdb_settings_category_to_dsl.rb
98
99
  - lib/puppetdb_foreman.rb
99
100
  - lib/puppetdb_foreman/engine.rb
100
101
  - lib/puppetdb_foreman/version.rb