foreman_hdm 0.1.4 → 1.0.0

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: f7c2f8cc35ed7ff2b93dc0b5dbb3976d300c816c1375d1f30f14a5a72efdca74
4
- data.tar.gz: be8956fb7497b6687442f6baff9675456da71f6964c2576dd524ec232ddc91bc
3
+ metadata.gz: 7c627d0c4d9425e3ccf9b2866feff8366ddcbf1ab3908e8cbb5d952de721b5ec
4
+ data.tar.gz: 96320bc1d09351c736ac810184c60fac735c46579ed9c92691faa0bfe5fb8498
5
5
  SHA512:
6
- metadata.gz: 2fe04c4f63dd2bea87d24e87024bbe289563e0899cbb13406f286d12e21022032d0802a98570c261c1649a47de5a6445e9f169370cbb8bda1b0607b66c829989
7
- data.tar.gz: 7d80a489929d79c35155c8d4733da9bb5768fe7fd62eefd456033c5517630269438fcbba6b4e1a8bbcf9b471f31f2211d5c2ce041d17034c1f782eeed8127005
6
+ metadata.gz: b6e70f150af87ab8833f3c8c7c214477f269df2153591ad005ea681c19d4cda99c9c3ded8de7a0db7a37b31c977aa0d01a6603e65d16b612f3dd477abf60a4b1
7
+ data.tar.gz: 8cc9fb9f1fdfe3051262136b2c7ee21b9ab2260435d28ac6673b0bf04c491715419947a452b24cdc5fa545fc64f455e5c5a85e63655687ea1a22c3a06e381910
data/README.md CHANGED
@@ -6,16 +6,44 @@
6
6
  [![RubyGem Version](https://img.shields.io/gem/v/foreman_hdm.svg)](https://rubygems.org/gems/foreman_hdm)
7
7
  [![RubyGem Downloads](https://img.shields.io/gem/dt/foreman_hdm.svg)](https://rubygems.org/gems/foreman_hdm)
8
8
 
9
- Browse hiera data for a given Host using [HDM](https://github.com/betadots/hdm) and the [HDM smart proxy plugin](https://github.com/betadots/foreman_hdm).
9
+ Browse hiera data for a given Host using [HDM](https://github.com/betadots/hdm) and the [HDM smart proxy plugin](https://github.com/betadots/smart_proxy_hdm).
10
+
11
+ ## Requirement
12
+
13
+ You must have a [HDM](https://github.com/betadots/hdm) installation running.
14
+ If you are running with authentication enabled, you need an API user in HDM.
10
15
 
11
16
  ## Installation
12
17
 
13
18
  See [How_to_Install_a_Plugin](http://projects.theforeman.org/projects/foreman/wiki/How_to_Install_a_Plugin)
14
19
  for how to install Foreman plugins
15
20
 
21
+ The most simple way is installing from packages (available with Foreman 3.6 and later)
22
+
23
+ RedHat: `dnf install rubygem-foreman_hdm rubygem-smart_proxy_hdm`
24
+
25
+ After installation you must initialize the database: `foreman-rake db:migrate`
26
+
27
+ The HDM Smart Proxy must be configured:
28
+
29
+ ```yaml
30
+ # /etc/foreman-proxy/settings.d/hdm.yml
31
+ # HDM Smart Proxy
32
+ :enabled: https
33
+ :hdm_url: 'http://<HDM IP>:<HDM Port>'
34
+ :hdm_user: '<HDM API User Email>'
35
+ :hdm_password: '<HDM API User Password>'
36
+ ```
37
+
38
+ Next you must restart the smart-proxy: `systemctl restart foreman-proxy`
39
+
16
40
  ## Usage
17
41
 
18
- *Usage here*
42
+ Go to Foreman and Refresh the Smart Proxy features.
43
+
44
+ Within the nodes or node groups you can now set the HDM Smart Proxy.
45
+
46
+ When you now select a node, you will see an HDM tab.
19
47
 
20
48
  ## TODO
21
49
 
data/Rakefile CHANGED
@@ -53,7 +53,7 @@ else
53
53
  version = ForemanHdm::VERSION
54
54
  config.future_release = "v#{version}" if /^\d+\.\d+.\d+$/.match?(version)
55
55
  config.header = "# Changelog\n\nAll notable changes to this project will be documented in this file."
56
- config.exclude_labels = %w[duplicate question invalid wontfix wont-fix skip-changelog]
56
+ config.exclude_labels = %w[duplicate question invalid wontfix wont-fix skip-changelog github_actions]
57
57
  config.user = 'betadots'
58
58
  config.project = 'foreman_hdm'
59
59
  end
@@ -0,0 +1,5 @@
1
+ class AddForeignKeyToHdmProxyId < ActiveRecord::Migration[6.1]
2
+ def change
3
+ add_foreign_key :hosts, :smart_proxies, column: :hdm_proxy_id, on_delete: :nullify
4
+ end
5
+ end
@@ -31,7 +31,7 @@ module ForemanHdm
31
31
  # Add a new role called 'Discovery' if it doesn't exist
32
32
  role 'ForemanHdm', [:view_foreman_hdm]
33
33
 
34
- smart_proxy_for Host, :hdm_proxy,
34
+ smart_proxy_for Host::Managed, :hdm_proxy,
35
35
  feature: 'Hdm',
36
36
  label: N_('HDM Proxy'),
37
37
  description: N_('Smart proxy to access HDM'),
@@ -1,3 +1,3 @@
1
1
  module ForemanHdm
2
- VERSION = '0.1.4'.freeze
2
+ VERSION = '1.0.0'.freeze
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: foreman_hdm
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.4
4
+ version: 1.0.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - betadots GmbH
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2023-06-23 00:00:00.000000000 Z
11
+ date: 2024-03-14 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rake
@@ -70,14 +70,14 @@ dependencies:
70
70
  requirements:
71
71
  - - "~>"
72
72
  - !ruby/object:Gem::Version
73
- version: 0.31.0
73
+ version: 0.35.0
74
74
  type: :development
75
75
  prerelease: false
76
76
  version_requirements: !ruby/object:Gem::Requirement
77
77
  requirements:
78
78
  - - "~>"
79
79
  - !ruby/object:Gem::Version
80
- version: 0.31.0
80
+ version: 0.35.0
81
81
  - !ruby/object:Gem::Dependency
82
82
  name: rubocop-performance
83
83
  requirement: !ruby/object:Gem::Requirement
@@ -140,6 +140,7 @@ files:
140
140
  - app/services/proxy_api/hdm.rb
141
141
  - config/routes.rb
142
142
  - db/migrate/20230519125201_add_hdm_proxy_id_to_hosts.rb
143
+ - db/migrate/20240228114101_add_foreign_key_to_hdm_proxy_id.rb
143
144
  - db/seeds.d/75-hdm_seeds.rb
144
145
  - lib/foreman_hdm.rb
145
146
  - lib/foreman_hdm/engine.rb
@@ -165,7 +166,7 @@ files:
165
166
  - webpack/test_setup.js
166
167
  homepage: https://github.com/betadots/foreman_hdm
167
168
  licenses:
168
- - GPL-3.0
169
+ - GPL-3.0-only
169
170
  metadata:
170
171
  is_foreman_plugin: 'true'
171
172
  post_install_message:
@@ -183,7 +184,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
183
184
  - !ruby/object:Gem::Version
184
185
  version: '0'
185
186
  requirements: []
186
- rubygems_version: 3.2.33
187
+ rubygems_version: 3.5.3
187
188
  signing_key:
188
189
  specification_version: 4
189
190
  summary: Display hiera data in Foreman using HDM