foreman_bootdisk 21.0.0 → 21.0.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/app/controllers/foreman_bootdisk/api/v2/disks_controller.rb +3 -3
- data/app/controllers/foreman_bootdisk/api/v2/subnet_disks_controller.rb +2 -2
- data/config/routes.rb +6 -4
- data/db/migrate/20221102105354_fix_bootdisk_settings_category_to_dsl.rb +7 -0
- data/lib/foreman_bootdisk/engine.rb +7 -7
- data/lib/foreman_bootdisk/version.rb +1 -1
- metadata +3 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 1af794db64199b1cb16cc9ddc7c9effc086930bba2ce77ccb890a3db932f3450
|
4
|
+
data.tar.gz: 71645b371a4f7ada01b3630e977e5ffa109d2111845963569b46e88f8cab5923
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 274f768d29de9360586a51f07ae5f8c142457c0548a71438a7b136dc5dcb165eaa65def7fdb479fac5fead9bca0240deec1ca3f5ae55095198e06204eb6f9b0f
|
7
|
+
data.tar.gz: 29304e2d2a0048e22b6bc7027dd8135f27d9a65b25f26df293da4484cecb7917176771c732656897f192cf6da7cb5d0560f25e5161cfb7383bc410b82fa6fdab
|
@@ -14,10 +14,10 @@ module ForemanBootdisk
|
|
14
14
|
skip_after_action :log_response_body
|
15
15
|
|
16
16
|
# no-op, but required for apipie documentation
|
17
|
-
api :GET, '', N_('Boot disks')
|
17
|
+
api :GET, '/bootdisk', N_('Boot disks')
|
18
18
|
def index; end
|
19
19
|
|
20
|
-
api :GET, '/generic', N_('Download generic image')
|
20
|
+
api :GET, '/bootdisk/generic', N_('Download generic image')
|
21
21
|
def generic
|
22
22
|
# EFI not supported for iPXE generic bootdisk
|
23
23
|
tmpl = ForemanBootdisk::Renderer.new.generic_template_render
|
@@ -26,7 +26,7 @@ module ForemanBootdisk
|
|
26
26
|
end
|
27
27
|
end
|
28
28
|
|
29
|
-
api :GET, '/hosts/:host_id', N_('Download host image')
|
29
|
+
api :GET, '/bootdisk/hosts/:host_id', N_('Download host image')
|
30
30
|
param :full, :bool, required: false, desc: N_('True for full, false for basic reusable image')
|
31
31
|
param :host_id, :identifier_dottable, required: true
|
32
32
|
def host
|
@@ -16,10 +16,10 @@ module ForemanBootdisk
|
|
16
16
|
skip_after_action :log_response_body
|
17
17
|
|
18
18
|
# no-op, but required for apipie documentation
|
19
|
-
api :GET, '', N_('Subnet boot disks')
|
19
|
+
api :GET, '/bootdisk', N_('Subnet boot disks')
|
20
20
|
def index; end
|
21
21
|
|
22
|
-
api :GET, '/subnets/:subnet_id', N_('Download subnet generic image')
|
22
|
+
api :GET, '/bootdisk/subnets/:subnet_id', N_('Download subnet generic image')
|
23
23
|
param :subnet_id, :identifier_dottable, required: true
|
24
24
|
def subnet
|
25
25
|
subnet = @subnet_disk
|
data/config/routes.rb
CHANGED
@@ -14,10 +14,12 @@ ForemanBootdisk::Engine.routes.draw do
|
|
14
14
|
|
15
15
|
namespace :api, defaults: { format: 'json' } do
|
16
16
|
scope '(:apiv)', module: :v2, defaults: { apiv: 'v2' }, apiv: /v1|v2/, constraints: ApiConstraints.new(version: 2, default: true) do
|
17
|
-
|
18
|
-
|
19
|
-
|
20
|
-
|
17
|
+
scope :bootdisk do
|
18
|
+
get 'generic', to: 'disks#generic'
|
19
|
+
constraints(id: %r{[^/]+}) do
|
20
|
+
get 'hosts/:id', to: 'disks#host'
|
21
|
+
get 'subnets/:id', to: 'subnet_disks#subnet'
|
22
|
+
end
|
21
23
|
end
|
22
24
|
end
|
23
25
|
end
|
@@ -10,7 +10,7 @@ module ForemanBootdisk
|
|
10
10
|
isolate_namespace ForemanBootdisk
|
11
11
|
|
12
12
|
config.autoload_paths += Dir["#{config.root}/app/controllers/concerns"]
|
13
|
-
config.autoload_paths += Dir["#{config.root}/app/helpers
|
13
|
+
config.autoload_paths += Dir["#{config.root}/app/helpers"]
|
14
14
|
config.autoload_paths += Dir["#{config.root}/app/models/concerns"]
|
15
15
|
config.autoload_paths += Dir["#{config.root}/app/lib"]
|
16
16
|
|
@@ -28,6 +28,12 @@ module ForemanBootdisk
|
|
28
28
|
Apipie.configuration.checksum_path += ['/bootdisk/api/']
|
29
29
|
end
|
30
30
|
|
31
|
+
# Temporary workaround fix for helpers
|
32
|
+
initializer 'foreman_bootdisk.rails_loading_workaround' do
|
33
|
+
HostsHelper.prepend ForemanBootdisk::HostsHelperExt
|
34
|
+
SubnetsHelper.include ForemanBootdisk::SubnetsHelperExt
|
35
|
+
end
|
36
|
+
|
31
37
|
initializer 'foreman_bootdisk.register_plugin', before: :finisher_hook do |_app|
|
32
38
|
Foreman::Plugin.register :foreman_bootdisk do
|
33
39
|
requires_foreman '>= 3.4'
|
@@ -139,12 +145,6 @@ module ForemanBootdisk
|
|
139
145
|
Foreman::Gettext::Support.add_text_domain locale_domain, locale_dir
|
140
146
|
end
|
141
147
|
|
142
|
-
# Temporary workaround fix for helpers
|
143
|
-
initializer 'foreman_bootdisk.rails_loading_workaround' do
|
144
|
-
HostsHelper.prepend ForemanBootdisk::HostsHelperExt
|
145
|
-
SubnetsHelper.prepend ForemanBootdisk::SubnetsHelperExt
|
146
|
-
end
|
147
|
-
|
148
148
|
config.to_prepare do
|
149
149
|
begin
|
150
150
|
Host::Managed.prepend ForemanBootdisk::HostExt
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: foreman_bootdisk
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 21.0.
|
4
|
+
version: 21.0.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Dominic Cleal
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2022-
|
11
|
+
date: 2022-11-03 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: theforeman-rubocop
|
@@ -84,6 +84,7 @@ files:
|
|
84
84
|
- db/migrate/20131021095100_edit_host_bootdisk_template_dns_secondary.rb
|
85
85
|
- db/migrate/20140522185700_change_templatekind_to_bootdisk.rb
|
86
86
|
- db/migrate/20171009225200_remove_duplicate_bootdisk_templates.rb
|
87
|
+
- db/migrate/20221102105354_fix_bootdisk_settings_category_to_dsl.rb
|
87
88
|
- lib/foreman_bootdisk.rb
|
88
89
|
- lib/foreman_bootdisk/engine.rb
|
89
90
|
- lib/foreman_bootdisk/version.rb
|