foreman_bootdisk 21.2.3 → 22.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: e94520f92ebdffedf1502f23cee42c9816c3a53c9917b39095045030f8ade269
4
- data.tar.gz: f712273e71d7aa2b1a37192941f9da02b634b2caf6b6b007b7f8ead01227a78e
3
+ metadata.gz: cc417dfa460d170e1206a2ea396a2e8b21210941af022849657226ba5ffe736c
4
+ data.tar.gz: 761e86252ac59a8cdb5c2d3b12e9a079567baadd481a4f2ac59eb2a5bd17e0c4
5
5
  SHA512:
6
- metadata.gz: d30245ff81eb9d520f25e70a9efb53d81ce658e624f4bbcf76863f8d30bf108073c798492f036d57d1dc200ffd11bf0f7487b3686a7f5217b98ad7919e63d1d1
7
- data.tar.gz: 67b53d9fafb29735a002ca77fc419b44a2a5eaff51cf119843e60744404417315cc3ea433eff0b737c2e4dc89f887f2096f0f96fea1b9aa076977700f6a914e6
6
+ metadata.gz: d31862bba3c03902e8dc8ecb62d51f9a82283496b67f7426dc7ffda38c080208417a81a06f3a0847a2fcd3939337c784a3dcf091f2b069c174176d57c5cc8151
7
+ data.tar.gz: 9d457586edb53ad9da3578093e468fc8ecf986170cc3923bd3493ba957a26d9b7af526548a61d710bc53e9dce60e6c2f8f56ec8fd786ccdd602061a74d3c198b
@@ -10,7 +10,7 @@ require 'uri'
10
10
  # requires syslinux, ipxe/ipxe-bootimgs, genisoimage, isohybrid
11
11
  module ForemanBootdisk
12
12
  class ISOGenerator
13
- extend Foreman::HTTPProxy
13
+ extend Foreman::HttpProxy
14
14
 
15
15
  def self.generate_full_host(host, opts = {}, &block)
16
16
  raise Foreman::Exception.new(N_('Host is not in build mode, so the template cannot be rendered')) unless host.build?
@@ -0,0 +1,5 @@
1
+ Rails.autoloaders.each do |autoloader|
2
+ autoloader.inflector.inflect(
3
+ 'iso_generator' => 'ISOGenerator'
4
+ )
5
+ end
@@ -1,6 +1,6 @@
1
1
  # frozen_string_literal: true
2
2
 
3
- class EditHostBootdiskTemplateDnsSecondary < ActiveRecord::Migration[4.2]
3
+ class EditHostBootdiskTemplateDNSSecondary < ActiveRecord::Migration[4.2]
4
4
  def self.up; end
5
5
 
6
6
  def self.down; end
@@ -9,11 +9,6 @@ module ForemanBootdisk
9
9
  engine_name 'foreman_bootdisk'
10
10
  isolate_namespace ForemanBootdisk
11
11
 
12
- config.autoload_paths += Dir["#{config.root}/app/controllers/concerns"]
13
- config.autoload_paths += Dir["#{config.root}/app/helpers"]
14
- config.autoload_paths += Dir["#{config.root}/app/models/concerns"]
15
- config.autoload_paths += Dir["#{config.root}/app/lib"]
16
-
17
12
  initializer 'foreman_bootdisk.mount_engine' do |app|
18
13
  app.routes_reloader.paths << "#{ForemanBootdisk::Engine.root}/config/routes/mount_engine.rb"
19
14
  end
@@ -28,113 +23,109 @@ module ForemanBootdisk
28
23
  Apipie.configuration.checksum_path += ['/bootdisk/api/']
29
24
  end
30
25
 
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
-
37
- initializer 'foreman_bootdisk.register_plugin', before: :finisher_hook do |_app|
38
- Foreman::Plugin.register :foreman_bootdisk do
39
- requires_foreman '>= 3.7'
40
- # Add Global files for extending foreman-core components and routes
41
- register_global_js_file 'global'
42
- register_gettext
43
-
44
- security_block :bootdisk do |_map|
45
- permission :download_bootdisk, 'foreman_bootdisk/disks': %i[generic host full_host help bootdisk_options],
46
- 'foreman_bootdisk/subnet_disks': [:subnet],
47
- 'foreman_bootdisk/api/v2/disks': %i[generic host],
48
- 'foreman_bootdisk/api/v2/subnet_disks': [:subnet]
49
- end
26
+ initializer 'foreman_bootdisk.register_plugin', before: :finisher_hook do |app|
27
+ app.reloader.to_prepare do
28
+ Foreman::Plugin.register :foreman_bootdisk do
29
+ requires_foreman '>= 3.13'
30
+ # Add Global files for extending foreman-core components and routes
31
+ register_global_js_file 'global'
32
+ register_gettext
33
+
34
+ security_block :bootdisk do |_map|
35
+ permission :download_bootdisk, 'foreman_bootdisk/disks': %i[generic host full_host help bootdisk_options],
36
+ 'foreman_bootdisk/subnet_disks': [:subnet],
37
+ 'foreman_bootdisk/api/v2/disks': %i[generic host],
38
+ 'foreman_bootdisk/api/v2/subnet_disks': [:subnet]
39
+ end
50
40
 
51
- role 'Boot disk access', [:download_bootdisk], 'Role granting permissions to download bootdisks'
52
- add_all_permissions_to_default_roles
41
+ role 'Boot disk access', [:download_bootdisk], 'Role granting permissions to download bootdisks'
42
+ add_all_permissions_to_default_roles
53
43
 
54
- apipie_documented_controllers ["#{ForemanBootdisk::Engine.root}/app/controllers/foreman_bootdisk/api/v2/*.rb"]
55
- ApipieDSL.configuration.dsl_classes_matchers += [
56
- "#{ForemanBootdisk::Engine.root}/app/lib/foreman_bootdisk/scope/*.rb"
57
- ]
58
- provision_method 'bootdisk', N_('Boot disk based')
59
- allowed_template_helpers :bootdisk_chain_url, :bootdisk_raise
44
+ apipie_documented_controllers ["#{ForemanBootdisk::Engine.root}/app/controllers/foreman_bootdisk/api/v2/*.rb"]
45
+ ApipieDSL.configuration.dsl_classes_matchers += [
46
+ "#{ForemanBootdisk::Engine.root}/app/lib/foreman_bootdisk/scope/*.rb"
47
+ ]
48
+ provision_method 'bootdisk', N_('Boot disk based')
49
+ allowed_template_helpers :bootdisk_chain_url, :bootdisk_raise
60
50
 
61
- extend_page "subnets/index" do |cx|
62
- cx.add_pagelet :subnet_index_action_buttons, name: 'Bootdisk', partial: 'subnets/bootdisk_action_buttons'
63
- cx.add_pagelet :subnet_index_title_buttons, name: 'Bootdisk', partial: 'subnets/bootdisk_title_buttons'
64
- end
51
+ extend_page "subnets/index" do |cx|
52
+ cx.add_pagelet :subnet_index_action_buttons, name: 'Bootdisk', partial: 'subnets/bootdisk_action_buttons'
53
+ cx.add_pagelet :subnet_index_title_buttons, name: 'Bootdisk', partial: 'subnets/bootdisk_title_buttons'
54
+ end
65
55
 
66
- settings do
67
- category :bootdisk, N_("Boot disk") do
68
- ipxe = ['/usr/lib/ipxe'].find { |p| File.exist?(p) } || '/usr/share/ipxe'
69
- isolinux = ['/usr/lib/ISOLINUX'].find { |p| File.exist?(p) } || '/usr/share/syslinux'
70
- syslinux = ['/usr/lib/syslinux/modules/bios', '/usr/lib/syslinux'].find { |p| File.exist?(p) } || '/usr/share/syslinux'
71
- grub2 = ['/var/lib/tftpboot/grub2'].find { |p| File.exist?(p) } || '/var/lib/foreman/bootdisk'
72
- templates = -> {
73
- Hash[ProvisioningTemplate.where(template_kind: TemplateKind.where(name: 'Bootdisk')).map { |temp| [temp[:name], temp[:name]] }]
74
- }
75
-
76
- setting "bootdisk_ipxe_dir",
77
- type: :string,
78
- default: ipxe,
79
- full_name: N_("iPXE directory"),
80
- description: N_("Path to directory containing iPXE images")
81
-
82
- setting "bootdisk_isolinux_dir",
83
- type: :string,
84
- default: isolinux,
85
- full_name: N_("ISOLINUX directory"),
86
- description: N_("Path to directory containing isolinux images")
87
-
88
- setting "bootdisk_syslinux_dir",
89
- type: :string,
90
- default: syslinux,
91
- full_name: N_("SYSLINUX directory"),
92
- description: N_("Path to directory containing syslinux images")
93
-
94
- setting "bootdisk_grub2_dir",
95
- type: :string,
96
- default: grub2,
97
- full_name: N_("Grub2 directory"),
98
- description: N_("Path to directory containing grubx64.efi and shimx64.efi")
99
-
100
- setting "bootdisk_host_template",
101
- type: :string,
102
- collection: templates,
103
- default: "Boot disk iPXE - host",
104
- full_name: N_("Host image template"),
105
- description: N_("iPXE template to use for host-specific boot disks")
106
-
107
- setting "bootdisk_generic_host_template",
108
- type: :string,
109
- collection: templates,
110
- default: "Boot disk iPXE - generic host",
111
- full_name: N_("Generic image template"),
112
- description: N_("iPXE template to use for generic host boot disks")
113
-
114
- setting "bootdisk_generic_efi_host_template",
115
- type: :string,
116
- collection: templates,
117
- default: "Boot disk Grub2 EFI - generic host",
118
- full_name: N_("Generic Grub2 EFI image template"),
119
- description: N_("iPXE template to use for generic EFI host boot disks")
120
-
121
- setting "bootdisk_mkiso_command",
122
- type: :string,
123
- default: "genisoimage",
124
- full_name: N_("ISO generation command"),
125
- description: N_("Command to generate ISO image, use genisoimage or mkisofs")
126
-
127
- setting "bootdisk_cache_media",
128
- type: :boolean,
129
- default: true,
130
- full_name: N_("Installation media caching"),
131
- description: N_("Installation media files will be cached for full host images")
132
-
133
- setting "bootdisk_allowed_types",
134
- type: :array,
135
- default: Setting::Bootdisk.bootdisk_types,
136
- full_name: N_("Allowed bootdisk types"),
137
- description: N_("List of allowed bootdisk types, remove type to disable it")
56
+ settings do
57
+ category :bootdisk, N_("Boot disk") do
58
+ ipxe = ['/usr/lib/ipxe'].find { |p| File.exist?(p) } || '/usr/share/ipxe'
59
+ isolinux = ['/usr/lib/ISOLINUX'].find { |p| File.exist?(p) } || '/usr/share/syslinux'
60
+ syslinux = ['/usr/lib/syslinux/modules/bios', '/usr/lib/syslinux'].find { |p| File.exist?(p) } || '/usr/share/syslinux'
61
+ grub2 = ['/var/lib/tftpboot/grub2'].find { |p| File.exist?(p) } || '/var/lib/foreman/bootdisk'
62
+ templates = -> {
63
+ Hash[ProvisioningTemplate.where(template_kind: TemplateKind.where(name: 'Bootdisk')).map { |temp| [temp[:name], temp[:name]] }]
64
+ }
65
+
66
+ setting "bootdisk_ipxe_dir",
67
+ type: :string,
68
+ default: ipxe,
69
+ full_name: N_("iPXE directory"),
70
+ description: N_("Path to directory containing iPXE images")
71
+
72
+ setting "bootdisk_isolinux_dir",
73
+ type: :string,
74
+ default: isolinux,
75
+ full_name: N_("ISOLINUX directory"),
76
+ description: N_("Path to directory containing isolinux images")
77
+
78
+ setting "bootdisk_syslinux_dir",
79
+ type: :string,
80
+ default: syslinux,
81
+ full_name: N_("SYSLINUX directory"),
82
+ description: N_("Path to directory containing syslinux images")
83
+
84
+ setting "bootdisk_grub2_dir",
85
+ type: :string,
86
+ default: grub2,
87
+ full_name: N_("Grub2 directory"),
88
+ description: N_("Path to directory containing grubx64.efi and shimx64.efi")
89
+
90
+ setting "bootdisk_host_template",
91
+ type: :string,
92
+ collection: templates,
93
+ default: "Boot disk iPXE - host",
94
+ full_name: N_("Host image template"),
95
+ description: N_("iPXE template to use for host-specific boot disks")
96
+
97
+ setting "bootdisk_generic_host_template",
98
+ type: :string,
99
+ collection: templates,
100
+ default: "Boot disk iPXE - generic host",
101
+ full_name: N_("Generic image template"),
102
+ description: N_("iPXE template to use for generic host boot disks")
103
+
104
+ setting "bootdisk_generic_efi_host_template",
105
+ type: :string,
106
+ collection: templates,
107
+ default: "Boot disk Grub2 EFI - generic host",
108
+ full_name: N_("Generic Grub2 EFI image template"),
109
+ description: N_("iPXE template to use for generic EFI host boot disks")
110
+
111
+ setting "bootdisk_mkiso_command",
112
+ type: :string,
113
+ default: "genisoimage",
114
+ full_name: N_("ISO generation command"),
115
+ description: N_("Command to generate ISO image, use genisoimage or mkisofs")
116
+
117
+ setting "bootdisk_cache_media",
118
+ type: :boolean,
119
+ default: true,
120
+ full_name: N_("Installation media caching"),
121
+ description: N_("Installation media files will be cached for full host images")
122
+
123
+ setting "bootdisk_allowed_types",
124
+ type: :array,
125
+ default: Setting::Bootdisk.bootdisk_types,
126
+ full_name: N_("Allowed bootdisk types"),
127
+ description: N_("List of allowed bootdisk types, remove type to disable it")
128
+ end
138
129
  end
139
130
  end
140
131
  end
@@ -142,6 +133,8 @@ module ForemanBootdisk
142
133
 
143
134
  config.to_prepare do
144
135
  begin
136
+ ::HostsHelper.prepend ForemanBootdisk::HostsHelperExt
137
+ ::SubnetsHelper.include ForemanBootdisk::SubnetsHelperExt
145
138
  Host::Managed.prepend ForemanBootdisk::HostExt
146
139
  Host::Managed.include ForemanBootdisk::Orchestration::Compute
147
140
  Foreman::Model::Vmware.prepend ForemanBootdisk::ComputeResources::Vmware if Foreman::Model::Vmware.available?
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module ForemanBootdisk
4
- VERSION = '21.2.3'
4
+ VERSION = '22.0.0'
5
5
  end
@@ -7,7 +7,7 @@
7
7
  # Robert Antoni Buj i Gelonch <rbuj@fedoraproject.org>, 2015-2016
8
8
  msgid ""
9
9
  msgstr ""
10
- "Project-Id-Version: foreman_bootdisk 21.1.0\n"
10
+ "Project-Id-Version: foreman_bootdisk 21.0.4\n"
11
11
  "Report-Msgid-Bugs-To: \n"
12
12
  "PO-Revision-Date: 2014-02-13 12:12+0000\n"
13
13
  "Last-Translator: Robert Antoni Buj i Gelonch <rbuj@fedoraproject.org>, 2017\n"
@@ -1,23 +1,21 @@
1
- # SOME DESCRIPTIVE TITLE.
2
- # Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
1
+ # Czech translations for foreman_bootdisk package.
2
+ # Copyright (C) 2023 THE PACKAGE'S COPYRIGHT HOLDER
3
3
  # This file is distributed under the same license as the foreman_bootdisk package.
4
+ # FIRST AUTHOR <EMAIL@ADDRESS>, 2023.
4
5
  #
5
- # Translators:
6
- # Pavel Borecki <pavel.borecki@gmail.com>, 2018-2020
7
6
  msgid ""
8
7
  msgstr ""
9
- "Project-Id-Version: foreman_bootdisk 21.1.0\n"
8
+ "Project-Id-Version: foreman_bootdisk 1.0.0\n"
10
9
  "Report-Msgid-Bugs-To: \n"
11
- "PO-Revision-Date: 2014-02-13 12:12+0000\n"
12
- "Last-Translator: Pavel Borecki <pavel.borecki@gmail.com>, 2018-2020\n"
13
- "Language-Team: Czech (Czech Republic) (http://app.transifex.com/foreman/forema"
14
- "n/language/cs_CZ/)\n"
10
+ "PO-Revision-Date: 2023-05-15 15:36+0200\n"
11
+ "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
12
+ "Language-Team: Czech\n"
13
+ "Language: cs_CZ\n"
15
14
  "MIME-Version: 1.0\n"
16
15
  "Content-Type: text/plain; charset=UTF-8\n"
17
16
  "Content-Transfer-Encoding: 8bit\n"
18
- "Language: cs_CZ\n"
19
- "Plural-Forms: nplurals=4; plural=(n == 1 && n % 1 == 0) ? 0 : (n >= 2 && n <= "
20
- "4 && n % 1 == 0) ? 1: (n % 1 != 0 ) ? 2 : 3;\n"
17
+ "Plural-Forms: nplurals=; plural=;\n"
18
+ "\n"
21
19
 
22
20
  #: ../app/controllers/concerns/allowed_actions.rb:7
23
21
  msgid "This type of bootdisk is not allowed. Please contact administrator."
@@ -65,7 +63,7 @@ msgstr ""
65
63
 
66
64
  #: ../app/controllers/foreman_bootdisk/disks_controller.rb:120 ../app/helpers/concerns/foreman_bootdisk/hosts_helper_ext.rb:66
67
65
  msgid "Host '%s' image"
68
- msgstr "Obraz stroje „%s“"
66
+ msgstr ""
69
67
 
70
68
  #: ../app/controllers/foreman_bootdisk/disks_controller.rb:120 ../app/helpers/concerns/foreman_bootdisk/hosts_helper_ext.rb:76 ../app/helpers/concerns/foreman_bootdisk/hosts_helper_ext.rb:86
71
69
  msgid "Full host '%s' image"
@@ -81,7 +79,7 @@ msgstr ""
81
79
 
82
80
  #: ../app/helpers/bootdisk_links_helper.rb:40 ../app/helpers/concerns/foreman_bootdisk/hosts_helper_ext.rb:20 ../app/models/setting/bootdisk.rb:6 ../lib/foreman_bootdisk/engine.rb:67 ../webpack/src/extensions/host/HostBootdiskButtons.js:86
83
81
  msgid "Boot disk"
84
- msgstr "Disk pro zavádění systému"
82
+ msgstr ""
85
83
 
86
84
  #: ../app/helpers/concerns/foreman_bootdisk/hosts_helper_ext.rb:21 ../webpack/src/extensions/host/HostBootdiskButtons.js:74
87
85
  msgid "Boot disk download not available for %s architecture"
@@ -97,11 +95,11 @@ msgstr ""
97
95
 
98
96
  #: ../app/helpers/concerns/foreman_bootdisk/subnets_helper_ext.rb:27 ../app/views/foreman_bootdisk/disks/help.html.erb:35
99
97
  msgid "Generic image"
100
- msgstr "Obecný obraz"
98
+ msgstr ""
101
99
 
102
100
  #: ../app/models/concerns/foreman_bootdisk/host_ext.rb:12 ../app/services/foreman_bootdisk/renderer.rb:53 ../app/services/foreman_bootdisk/renderer.rb:60
103
101
  msgid "Unable to find template specified by %s setting"
104
- msgstr "Nedaří se nalézt šablonu určenou nastavením %s"
102
+ msgstr ""
105
103
 
106
104
  #: ../app/models/concerns/foreman_bootdisk/orchestration/compute.rb:30
107
105
  msgid "Generating ISO image for %s"
@@ -177,7 +175,7 @@ msgstr ""
177
175
 
178
176
  #: ../app/services/foreman_bootdisk/iso_generator.rb:160
179
177
  msgid "ISO build failed"
180
- msgstr "Sestavení ISO se nezdařilo"
178
+ msgstr ""
181
179
 
182
180
  #: ../app/services/foreman_bootdisk/iso_generator.rb:163
183
181
  msgid "ISO hybrid conversion failed: %s"
@@ -185,7 +183,7 @@ msgstr ""
185
183
 
186
184
  #: ../app/views/foreman_bootdisk/disks/help.html.erb:2
187
185
  msgid "Back"
188
- msgstr "Zpět"
186
+ msgstr ""
189
187
 
190
188
  #: ../app/views/foreman_bootdisk/disks/help.html.erb:6
191
189
  msgid "Various types of boot disks can be created to provision hosts without the need for PXE services. Boot disks can be attached to the host (physical or virtual) which boots from the disk, contacts Foreman and begins the OS installation."
@@ -205,7 +203,7 @@ msgstr ""
205
203
 
206
204
  #: ../app/views/foreman_bootdisk/disks/help.html.erb:17
207
205
  msgid "Host image"
208
- msgstr "Obraz stroje"
206
+ msgstr ""
209
207
 
210
208
  #: ../app/views/foreman_bootdisk/disks/help.html.erb:19
211
209
  msgid "Per-host images contain data about a particular host registered in Foreman and set up fully static networking, avoiding the requirement for DHCP. After networking is configured, they chainload from Foreman, picking up the current OS configuration and build state from the server."
@@ -257,19 +255,19 @@ msgstr ""
257
255
 
258
256
  #: ../lib/foreman_bootdisk/engine.rb:58
259
257
  msgid "Boot disk based"
260
- msgstr "Založeno na zaváděcím disku"
258
+ msgstr ""
261
259
 
262
260
  #: ../lib/foreman_bootdisk/engine.rb:79
263
261
  msgid "iPXE directory"
264
- msgstr "iPXE složka"
262
+ msgstr ""
265
263
 
266
264
  #: ../lib/foreman_bootdisk/engine.rb:80
267
265
  msgid "Path to directory containing iPXE images"
268
- msgstr "Popis umístění složky obsahující iPXE obrazy"
266
+ msgstr ""
269
267
 
270
268
  #: ../lib/foreman_bootdisk/engine.rb:85
271
269
  msgid "ISOLINUX directory"
272
- msgstr "ISOLINUX složka"
270
+ msgstr ""
273
271
 
274
272
  #: ../lib/foreman_bootdisk/engine.rb:86
275
273
  msgid "Path to directory containing isolinux images"
@@ -277,11 +275,11 @@ msgstr ""
277
275
 
278
276
  #: ../lib/foreman_bootdisk/engine.rb:91
279
277
  msgid "SYSLINUX directory"
280
- msgstr "složka se SYSLINUX"
278
+ msgstr ""
281
279
 
282
280
  #: ../lib/foreman_bootdisk/engine.rb:92
283
281
  msgid "Path to directory containing syslinux images"
284
- msgstr "Popis umístění obsahující syslinux obrazy"
282
+ msgstr ""
285
283
 
286
284
  #: ../lib/foreman_bootdisk/engine.rb:97
287
285
  msgid "Grub2 directory"
@@ -293,7 +291,7 @@ msgstr ""
293
291
 
294
292
  #: ../lib/foreman_bootdisk/engine.rb:104
295
293
  msgid "Host image template"
296
- msgstr "Šablona obrazu stroje"
294
+ msgstr ""
297
295
 
298
296
  #: ../lib/foreman_bootdisk/engine.rb:105
299
297
  msgid "iPXE template to use for host-specific boot disks"
@@ -301,7 +299,7 @@ msgstr ""
301
299
 
302
300
  #: ../lib/foreman_bootdisk/engine.rb:111
303
301
  msgid "Generic image template"
304
- msgstr "Šablona obecného obrazu"
302
+ msgstr ""
305
303
 
306
304
  #: ../lib/foreman_bootdisk/engine.rb:112
307
305
  msgid "iPXE template to use for generic host boot disks"
@@ -317,15 +315,15 @@ msgstr ""
317
315
 
318
316
  #: ../lib/foreman_bootdisk/engine.rb:124
319
317
  msgid "ISO generation command"
320
- msgstr "příkaz pro vytváření ISO obrazu"
318
+ msgstr ""
321
319
 
322
320
  #: ../lib/foreman_bootdisk/engine.rb:125
323
321
  msgid "Command to generate ISO image, use genisoimage or mkisofs"
324
- msgstr "Příkaz pro vytvoření ISO obrazu, použijte genisoimage nebo mkisofs"
322
+ msgstr ""
325
323
 
326
324
  #: ../lib/foreman_bootdisk/engine.rb:130
327
325
  msgid "Installation media caching"
328
- msgstr "Mezipaměť pro instalační médium"
326
+ msgstr ""
329
327
 
330
328
  #: ../lib/foreman_bootdisk/engine.rb:131
331
329
  msgid "Installation media files will be cached for full host images"
@@ -345,19 +343,19 @@ msgstr ""
345
343
 
346
344
  #: action_names.rb:2
347
345
  msgid "Remote action:"
348
- msgstr "Akce na protějšku:"
346
+ msgstr ""
349
347
 
350
348
  #: action_names.rb:3
351
349
  msgid "Import Puppet classes"
352
- msgstr "Importovat Puppet třídy"
350
+ msgstr ""
353
351
 
354
352
  #: action_names.rb:4
355
353
  msgid "Import facts"
356
- msgstr "Importovat fakta"
354
+ msgstr ""
357
355
 
358
356
  #: action_names.rb:5
359
357
  msgid "Action with sub plans"
360
- msgstr "Akce s dílčími plány"
358
+ msgstr ""
361
359
 
362
360
  #: gemspec.rb:4
363
361
  msgid "Plugin for Foreman that creates iPXE-based boot disks to provision hosts without the need for PXE infrastructure."
@@ -6,17 +6,17 @@
6
6
  # Christina Gurski <Gurski_christina@yahoo.de>, 2015
7
7
  # Ettore Atalan <atalanttore@googlemail.com>, 2014,2016
8
8
  # Martin Zimmermann <martin.zimmermann@gmx.com>, 2018
9
- # pdolinic, 2021
9
+ # Patrick Dolinic, 2021
10
10
  # Paul Puschmann, 2014
11
11
  # abf90805572190d649c59f7a021d76cb, 2014
12
12
  # simon11 <transifex@stieger.co>, 2014
13
13
  # simon11 <transifex@stieger.co>, 2014
14
14
  msgid ""
15
15
  msgstr ""
16
- "Project-Id-Version: foreman_bootdisk 21.1.0\n"
16
+ "Project-Id-Version: foreman_bootdisk 21.0.4\n"
17
17
  "Report-Msgid-Bugs-To: \n"
18
18
  "PO-Revision-Date: 2014-02-13 12:12+0000\n"
19
- "Last-Translator: pdolinic, 2021\n"
19
+ "Last-Translator: Patrick Dolinic, 2021\n"
20
20
  "Language-Team: German (http://app.transifex.com/foreman/foreman/language/de/)\n"
21
21
  "MIME-Version: 1.0\n"
22
22
  "Content-Type: text/plain; charset=UTF-8\n"
@@ -4,7 +4,7 @@
4
4
  #
5
5
  msgid ""
6
6
  msgstr ""
7
- "Project-Id-Version: foreman_bootdisk 21.1.0\n"
7
+ "Project-Id-Version: foreman_bootdisk 21.0.4\n"
8
8
  "Report-Msgid-Bugs-To: \n"
9
9
  "PO-Revision-Date: 2014-02-13 12:09+0000\n"
10
10
  "Last-Translator: Dominic Cleal <dcleal@redhat.com>\n"
@@ -8,7 +8,7 @@
8
8
  # 0868a4d1af5275b3f70b0a6dac4c99a4, 2016
9
9
  msgid ""
10
10
  msgstr ""
11
- "Project-Id-Version: foreman_bootdisk 21.1.0\n"
11
+ "Project-Id-Version: foreman_bootdisk 21.0.4\n"
12
12
  "Report-Msgid-Bugs-To: \n"
13
13
  "PO-Revision-Date: 2014-02-13 12:12+0000\n"
14
14
  "Last-Translator: Andi Chandler <andi@gowling.com>, 2015-2017,2023\n"
@@ -8,7 +8,7 @@
8
8
  # Sergio Ocón-Cárdenas <sergio.ocon@redhat.com>, 2014
9
9
  msgid ""
10
10
  msgstr ""
11
- "Project-Id-Version: foreman_bootdisk 21.1.0\n"
11
+ "Project-Id-Version: foreman_bootdisk 21.0.4\n"
12
12
  "Report-Msgid-Bugs-To: \n"
13
13
  "PO-Revision-Date: 2014-02-13 12:12+0000\n"
14
14
  "Last-Translator: Sergio Ocón-Cárdenas <sergio.ocon@redhat.com>, 2014\n"
@@ -9,7 +9,7 @@
9
9
  # Pierre-Emmanuel Dutang <dutangp@gmail.com>, 2014,2016-2017
10
10
  msgid ""
11
11
  msgstr ""
12
- "Project-Id-Version: foreman_bootdisk 21.1.0\n"
12
+ "Project-Id-Version: foreman_bootdisk 21.0.4\n"
13
13
  "Report-Msgid-Bugs-To: \n"
14
14
  "PO-Revision-Date: 2014-02-13 12:12+0000\n"
15
15
  "Last-Translator: 0868a4d1af5275b3f70b0a6dac4c99a4, 2015\n"
@@ -143,7 +143,7 @@ msgstr "L'hôte n'est pas en mode build, c'est pourquoi le modèle ne peut être
143
143
 
144
144
  #: ../app/services/foreman_bootdisk/iso_generator.rb:42
145
145
  msgid "Unable to generate disk template, %{kind} template not found."
146
- msgstr "Impossible de générer le modèle de disque, le modèle %{kind} est introuvable."
146
+ msgstr "Impossible de générer le modèle de disque, le modèle %%{kind} est introuvable."
147
147
 
148
148
  #: ../app/services/foreman_bootdisk/iso_generator.rb:52
149
149
  msgid "Unable to generate disk %{kind} template: %{error}"
@@ -315,7 +315,7 @@ msgstr "Modèle d'image générique Grub2 EFI"
315
315
 
316
316
  #: ../lib/foreman_bootdisk/engine.rb:119
317
317
  msgid "iPXE template to use for generic EFI host boot disks"
318
- msgstr "Modèle iPXE à utiliser pour les disques d'amorçage génériques de l'hôte EFI"
318
+ msgstr ""
319
319
 
320
320
  #: ../lib/foreman_bootdisk/engine.rb:124
321
321
  msgid "ISO generation command"
@@ -5,7 +5,7 @@
5
5
  # Translators:
6
6
  msgid ""
7
7
  msgstr ""
8
- "Project-Id-Version: foreman_bootdisk 21.1.0\n"
8
+ "Project-Id-Version: foreman_bootdisk 21.0.4\n"
9
9
  "Report-Msgid-Bugs-To: \n"
10
10
  "PO-Revision-Date: 2014-02-13 12:12+0000\n"
11
11
  "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
@@ -5,10 +5,9 @@
5
5
  # Translators:
6
6
  # 山田 修司 🍣 Shuji Yamada <uzy.exe@gmail.com>, 2015
7
7
  # 山田 修司 🍣 Shuji Yamada <uzy.exe@gmail.com>, 2015
8
- # 山田 修司 🍣 Shuji Yamada <uzy.exe@gmail.com>, 2015
9
8
  msgid ""
10
9
  msgstr ""
11
- "Project-Id-Version: foreman_bootdisk 21.1.0\n"
10
+ "Project-Id-Version: foreman_bootdisk 21.0.4\n"
12
11
  "Report-Msgid-Bugs-To: \n"
13
12
  "PO-Revision-Date: 2014-02-13 12:12+0000\n"
14
13
  "Last-Translator: 山田 修司 🍣 Shuji Yamada <uzy.exe@gmail.com>, 2015\n"
@@ -122,19 +121,19 @@ msgstr "%s の CDROM ドライブから ISO イメージをデタッチ"
122
121
 
123
122
  #: ../app/models/concerns/foreman_bootdisk/orchestration/compute.rb:73
124
123
  msgid "Failed to generate ISO image for instance %{name}: %{message}"
125
- msgstr "インスタンス %%{name} の ISO イメージの生成に失敗しました: %%{message}"
124
+ msgstr "インスタンス %{name} の ISO イメージの生成に失敗しました: %{message}"
126
125
 
127
126
  #: ../app/models/concerns/foreman_bootdisk/orchestration/compute.rb:82
128
127
  msgid "Failed to upload ISO image for instance %{name}: %{message}"
129
- msgstr "インスタンス %%{name} の ISO イメージのアップロードに失敗しました: %%{message}"
128
+ msgstr "インスタンス %{name} の ISO イメージのアップロードに失敗しました: %{message}"
130
129
 
131
130
  #: ../app/models/concerns/foreman_bootdisk/orchestration/compute.rb:91
132
131
  msgid "Failed to attach ISO image to CDROM drive of instance %{name}: %{message}"
133
- msgstr "インスタンス %%{name} の CDROM ドライブへの ISO イメージの割り当てに失敗しました: %%{message}"
132
+ msgstr "インスタンス %{name} の CDROM ドライブへの ISO イメージの割り当てに失敗しました: %{message}"
134
133
 
135
134
  #: ../app/models/concerns/foreman_bootdisk/orchestration/compute.rb:100
136
135
  msgid "Failed to detach ISO image from CDROM drive of instance %{name}: %{message}"
137
- msgstr "インスタンス %%{name} の CDROM ドライブから ISO イメージのデタッチに失敗しました: %%{message}"
136
+ msgstr "インスタンス %{name} の CDROM ドライブから ISO イメージのデタッチに失敗しました: %{message}"
138
137
 
139
138
  #: ../app/services/foreman_bootdisk/iso_generator.rb:16
140
139
  msgid "Host is not in build mode, so the template cannot be rendered"
@@ -142,11 +141,11 @@ msgstr "ホストはビルドモードではないため、テンプレートは
142
141
 
143
142
  #: ../app/services/foreman_bootdisk/iso_generator.rb:42
144
143
  msgid "Unable to generate disk template, %{kind} template not found."
145
- msgstr "ディスクテンプレートを生成できません。%%{kind} テンプレートが見つかりません。"
144
+ msgstr "ディスクテンプレートを生成できません。%{kind} テンプレートが見つかりません。"
146
145
 
147
146
  #: ../app/services/foreman_bootdisk/iso_generator.rb:52
148
147
  msgid "Unable to generate disk %{kind} template: %{error}"
149
- msgstr "ディスクの %%{kind} テンプレートを生成できません: %%{error}"
148
+ msgstr "ディスクの %{kind} テンプレートを生成できません: %{error}"
150
149
 
151
150
  #: ../app/services/foreman_bootdisk/iso_generator.rb:94
152
151
  msgid "Please ensure the isolinux/syslinux package(s) are installed."
@@ -158,7 +157,7 @@ msgstr "ipxe-bootimgs パッケージがインストールされていること
158
157
 
159
158
  #: ../app/services/foreman_bootdisk/iso_generator.rb:128
160
159
  msgid "Creating new image failed, install truncate utility"
161
- msgstr "新しいイメージの作成に失敗しました。truncate ユーティリティーをインストールしてください"
160
+ msgstr "新しいイメージの作成に失敗しました。truncate ユーティリティをインストールしてください"
162
161
 
163
162
  #: ../app/services/foreman_bootdisk/iso_generator.rb:129
164
163
  msgid "Failed to format the ESP image via mkfs.msdos"
@@ -170,11 +169,11 @@ msgstr "ESP のイメージ内にディレクトリーを作成できません
170
169
 
171
170
  #: ../app/services/foreman_bootdisk/iso_generator.rb:137
172
171
  msgid "Ensure %{file} is readable (or update \"Grub2 directory\" setting)"
173
- msgstr "%%{file} が読み取り可能であることを確認します (または「Grub2 ディレクトリー」設定を更新します)"
172
+ msgstr "%{file} が読み取り可能であることを確認します (または「Grub2 ディレクトリー」設定を更新します)"
174
173
 
175
174
  #: ../app/services/foreman_bootdisk/iso_generator.rb:138
176
175
  msgid "Unable to mcopy %{file}"
177
- msgstr "%%{file} を mcopy できません"
176
+ msgstr "%{file} を mcopy できません"
178
177
 
179
178
  #: ../app/services/foreman_bootdisk/iso_generator.rb:160
180
179
  msgid "ISO build failed"
@@ -222,7 +221,7 @@ msgstr "完全ホストイメージ"
222
221
 
223
222
  #: ../app/views/foreman_bootdisk/disks/help.html.erb:27
224
223
  msgid "A variant of the per-host image which contains the OS bootloader embedded inside the disk. This may be useful if chainloading fails on certain hardware, but has the downside that the image must be regenerated for any change in the OS, bootloader or PXELinux templates."
225
- msgstr "OS ブートローダーがディスク内に組み込まれているホスト別イメージのバリアントです。これは、特定のハードウェアでチェーンロードが失敗した場合に役立ちますが、不利な点として、OS、ブートローダーまたは PXELinux テンプレートに変更がある場合はイメージを再生成する必要があります。"
224
+ msgstr "OS ブートローダーがディスク内に組み込まれているホスト別イメージのバリアントです。これは、特定のハードウェアでチェーンロードが失敗した場合に役立ちますが、不利な点として、イメージを OS、ブートローダーまたは PXELinux テンプレートに変更がある場合にイメージを再生成する必要があります。"
226
225
 
227
226
  #: ../app/views/foreman_bootdisk/disks/help.html.erb:30
228
227
  msgid "Generic images"
@@ -266,7 +265,7 @@ msgstr "iPXE ディレクトリー"
266
265
 
267
266
  #: ../lib/foreman_bootdisk/engine.rb:80
268
267
  msgid "Path to directory containing iPXE images"
269
- msgstr "iPXE イメージを含むディレクトリーへのパス"
268
+ msgstr "iPXE イメージを含むディレクトリーのパス"
270
269
 
271
270
  #: ../lib/foreman_bootdisk/engine.rb:85
272
271
  msgid "ISOLINUX directory"
@@ -282,7 +281,7 @@ msgstr "SYSLINUX ディレクトリー"
282
281
 
283
282
  #: ../lib/foreman_bootdisk/engine.rb:92
284
283
  msgid "Path to directory containing syslinux images"
285
- msgstr "syslinux イメージを含むディレクトリーへのパス"
284
+ msgstr "syslinux イメージを含むディレクトリーのパス"
286
285
 
287
286
  #: ../lib/foreman_bootdisk/engine.rb:97
288
287
  msgid "Grub2 directory"
@@ -314,7 +313,7 @@ msgstr "Grub2 EFI の汎用イメージテンプレート"
314
313
 
315
314
  #: ../lib/foreman_bootdisk/engine.rb:119
316
315
  msgid "iPXE template to use for generic EFI host boot disks"
317
- msgstr "汎用の EFI ホストブートディスクに使用する iPXE テンプレート"
316
+ msgstr ""
318
317
 
319
318
  #: ../lib/foreman_bootdisk/engine.rb:124
320
319
  msgid "ISO generation command"
@@ -5,7 +5,7 @@
5
5
  # Translators:
6
6
  msgid ""
7
7
  msgstr ""
8
- "Project-Id-Version: foreman_bootdisk 21.1.0\n"
8
+ "Project-Id-Version: foreman_bootdisk 21.0.4\n"
9
9
  "Report-Msgid-Bugs-To: \n"
10
10
  "PO-Revision-Date: 2014-02-13 12:12+0000\n"
11
11
  "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
@@ -5,7 +5,7 @@
5
5
  # Translators:
6
6
  msgid ""
7
7
  msgstr ""
8
- "Project-Id-Version: foreman_bootdisk 21.1.0\n"
8
+ "Project-Id-Version: foreman_bootdisk 21.0.4\n"
9
9
  "Report-Msgid-Bugs-To: \n"
10
10
  "PO-Revision-Date: 2014-02-13 12:12+0000\n"
11
11
  "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
@@ -8,7 +8,7 @@
8
8
  # Luiz Henrique Vasconcelos <luizvasconceloss@yahoo.com.br>, 2015
9
9
  msgid ""
10
10
  msgstr ""
11
- "Project-Id-Version: foreman_bootdisk 21.1.0\n"
11
+ "Project-Id-Version: foreman_bootdisk 21.0.4\n"
12
12
  "Report-Msgid-Bugs-To: \n"
13
13
  "PO-Revision-Date: 2014-02-13 12:12+0000\n"
14
14
  "Last-Translator: Luiz Henrique Vasconcelos <luizvasconceloss@yahoo.com.br>, 20"
@@ -7,7 +7,7 @@
7
7
  # Yulia <yulia.poyarkova@redhat.com>, 2016
8
8
  msgid ""
9
9
  msgstr ""
10
- "Project-Id-Version: foreman_bootdisk 21.1.0\n"
10
+ "Project-Id-Version: foreman_bootdisk 21.0.4\n"
11
11
  "Report-Msgid-Bugs-To: \n"
12
12
  "PO-Revision-Date: 2014-02-13 12:12+0000\n"
13
13
  "Last-Translator: Vladimir Pavlov <v.pavlov@i-teco.ru>, 2015\n"
@@ -6,7 +6,7 @@
6
6
  # johnny.westerlund <johnny.westerlund@gmail.com>, 2014
7
7
  msgid ""
8
8
  msgstr ""
9
- "Project-Id-Version: foreman_bootdisk 21.1.0\n"
9
+ "Project-Id-Version: foreman_bootdisk 21.0.4\n"
10
10
  "Report-Msgid-Bugs-To: \n"
11
11
  "PO-Revision-Date: 2014-02-13 12:12+0000\n"
12
12
  "Last-Translator: johnny.westerlund <johnny.westerlund@gmail.com>, 2014\n"
@@ -5,7 +5,7 @@
5
5
  # Translators:
6
6
  msgid ""
7
7
  msgstr ""
8
- "Project-Id-Version: foreman_bootdisk 21.1.0\n"
8
+ "Project-Id-Version: foreman_bootdisk 21.0.4\n"
9
9
  "Report-Msgid-Bugs-To: \n"
10
10
  "PO-Revision-Date: 2014-02-13 12:12+0000\n"
11
11
  "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
@@ -311,7 +311,7 @@ msgstr "通用 Grub2 EFI 镜像模板"
311
311
 
312
312
  #: ../lib/foreman_bootdisk/engine.rb:119
313
313
  msgid "iPXE template to use for generic EFI host boot disks"
314
- msgstr "通用 EFI 主机启动磁盘使用的 iPXE 模板"
314
+ msgstr ""
315
315
 
316
316
  #: ../lib/foreman_bootdisk/engine.rb:124
317
317
  msgid "ISO generation command"
@@ -5,7 +5,7 @@
5
5
  # Translators:
6
6
  msgid ""
7
7
  msgstr ""
8
- "Project-Id-Version: foreman_bootdisk 21.1.0\n"
8
+ "Project-Id-Version: foreman_bootdisk 21.0.4\n"
9
9
  "Report-Msgid-Bugs-To: \n"
10
10
  "PO-Revision-Date: 2014-02-13 12:12+0000\n"
11
11
  "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
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.2.3
4
+ version: 22.0.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Dominic Cleal
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2024-03-25 00:00:00.000000000 Z
11
+ date: 2024-09-12 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: theforeman-rubocop
@@ -77,6 +77,7 @@ files:
77
77
  - app/views/hosts/provision_method/bootdisk/_form.html.erb
78
78
  - app/views/subnets/_bootdisk_action_buttons.erb
79
79
  - app/views/subnets/_bootdisk_title_buttons.erb
80
+ - config/initializers/inflections.rb
80
81
  - config/routes.rb
81
82
  - config/routes/mount_engine.rb
82
83
  - db/migrate/20130914211030_create_host_bootdisk_template.rb
@@ -89,7 +90,6 @@ files:
89
90
  - db/migrate/20221102105354_fix_bootdisk_settings_category_to_dsl.rb
90
91
  - lib/foreman_bootdisk.rb
91
92
  - lib/foreman_bootdisk/engine.rb
92
- - lib/foreman_bootdisk/engine.rb.orig
93
93
  - lib/foreman_bootdisk/version.rb
94
94
  - lib/tasks/bootdisk.rake
95
95
  - locale/Makefile
@@ -199,7 +199,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
199
199
  - !ruby/object:Gem::Version
200
200
  version: '0'
201
201
  requirements: []
202
- rubygems_version: 3.1.6
202
+ rubygems_version: 3.2.33
203
203
  signing_key:
204
204
  specification_version: 4
205
205
  summary: Create boot disks to provision hosts with Foreman
@@ -1,162 +0,0 @@
1
- # frozen_string_literal: true
2
-
3
- require 'foreman_bootdisk'
4
- require 'fast_gettext'
5
- require 'gettext_i18n_rails'
6
-
7
- module ForemanBootdisk
8
- class Engine < ::Rails::Engine
9
- engine_name 'foreman_bootdisk'
10
- isolate_namespace ForemanBootdisk
11
-
12
- config.autoload_paths += Dir["#{config.root}/app/controllers/concerns"]
13
- config.autoload_paths += Dir["#{config.root}/app/helpers"]
14
- config.autoload_paths += Dir["#{config.root}/app/models/concerns"]
15
- config.autoload_paths += Dir["#{config.root}/app/lib"]
16
-
17
- initializer 'foreman_bootdisk.mount_engine' do |app|
18
- app.routes_reloader.paths << "#{ForemanBootdisk::Engine.root}/config/routes/mount_engine.rb"
19
- end
20
-
21
- initializer 'foreman_bootdisk.load_app_instance_data' do |app|
22
- ForemanBootdisk::Engine.paths['db/migrate'].existent.each do |path|
23
- app.config.paths['db/migrate'] << path
24
- end
25
- end
26
-
27
- initializer 'foreman_bootdisk.apipie' do
28
- Apipie.configuration.checksum_path += ['/bootdisk/api/']
29
- end
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
-
37
- initializer 'foreman_bootdisk.register_plugin', before: :finisher_hook do |_app|
38
- Foreman::Plugin.register :foreman_bootdisk do
39
- requires_foreman '>= 3.7'
40
- <<<<<<< HEAD
41
- =======
42
- register_gettext
43
-
44
- >>>>>>> 4665a6a (Translation improvements)
45
- # Add Global files for extending foreman-core components and routes
46
- register_global_js_file 'global'
47
- register_gettext
48
-
49
- security_block :bootdisk do |_map|
50
- permission :download_bootdisk, 'foreman_bootdisk/disks': %i[generic host full_host help bootdisk_options],
51
- 'foreman_bootdisk/subnet_disks': [:subnet],
52
- 'foreman_bootdisk/api/v2/disks': %i[generic host],
53
- 'foreman_bootdisk/api/v2/subnet_disks': [:subnet]
54
- end
55
-
56
- role 'Boot disk access', [:download_bootdisk], 'Role granting permissions to download bootdisks'
57
- add_all_permissions_to_default_roles
58
-
59
- apipie_documented_controllers ["#{ForemanBootdisk::Engine.root}/app/controllers/foreman_bootdisk/api/v2/*.rb"]
60
- ApipieDSL.configuration.dsl_classes_matchers += [
61
- "#{ForemanBootdisk::Engine.root}/app/lib/foreman_bootdisk/scope/*.rb"
62
- ]
63
- provision_method 'bootdisk', N_('Boot disk based')
64
- allowed_template_helpers :bootdisk_chain_url, :bootdisk_raise
65
-
66
- extend_page "subnets/index" do |cx|
67
- cx.add_pagelet :subnet_index_action_buttons, name: 'Bootdisk', partial: 'subnets/bootdisk_action_buttons'
68
- cx.add_pagelet :subnet_index_title_buttons, name: 'Bootdisk', partial: 'subnets/bootdisk_title_buttons'
69
- end
70
-
71
- settings do
72
- category :bootdisk, N_("Boot disk") do
73
- ipxe = ['/usr/lib/ipxe'].find { |p| File.exist?(p) } || '/usr/share/ipxe'
74
- isolinux = ['/usr/lib/ISOLINUX'].find { |p| File.exist?(p) } || '/usr/share/syslinux'
75
- syslinux = ['/usr/lib/syslinux/modules/bios', '/usr/lib/syslinux'].find { |p| File.exist?(p) } || '/usr/share/syslinux'
76
- grub2 = ['/var/lib/tftpboot/grub2'].find { |p| File.exist?(p) } || '/var/lib/foreman/bootdisk'
77
- templates = -> {
78
- Hash[ProvisioningTemplate.where(template_kind: TemplateKind.where(name: 'Bootdisk')).map { |temp| [temp[:name], temp[:name]] }]
79
- }
80
-
81
- setting "bootdisk_ipxe_dir",
82
- type: :string,
83
- default: ipxe,
84
- full_name: N_("iPXE directory"),
85
- description: N_("Path to directory containing iPXE images")
86
-
87
- setting "bootdisk_isolinux_dir",
88
- type: :string,
89
- default: isolinux,
90
- full_name: N_("ISOLINUX directory"),
91
- description: N_("Path to directory containing isolinux images")
92
-
93
- setting "bootdisk_syslinux_dir",
94
- type: :string,
95
- default: syslinux,
96
- full_name: N_("SYSLINUX directory"),
97
- description: N_("Path to directory containing syslinux images")
98
-
99
- setting "bootdisk_grub2_dir",
100
- type: :string,
101
- default: grub2,
102
- full_name: N_("Grub2 directory"),
103
- description: N_("Path to directory containing grubx64.efi and shimx64.efi")
104
-
105
- setting "bootdisk_host_template",
106
- type: :string,
107
- collection: templates,
108
- default: "Boot disk iPXE - host",
109
- full_name: N_("Host image template"),
110
- description: N_("iPXE template to use for host-specific boot disks")
111
-
112
- setting "bootdisk_generic_host_template",
113
- type: :string,
114
- collection: templates,
115
- default: "Boot disk iPXE - generic host",
116
- full_name: N_("Generic image template"),
117
- description: N_("iPXE template to use for generic host boot disks")
118
-
119
- setting "bootdisk_generic_efi_host_template",
120
- type: :string,
121
- collection: templates,
122
- default: "Boot disk Grub2 EFI - generic host",
123
- full_name: N_("Generic Grub2 EFI image template"),
124
- description: N_("iPXE template to use for generic EFI host boot disks")
125
-
126
- setting "bootdisk_mkiso_command",
127
- type: :string,
128
- default: "genisoimage",
129
- full_name: N_("ISO generation command"),
130
- description: N_("Command to generate ISO image, use genisoimage or mkisofs")
131
-
132
- setting "bootdisk_cache_media",
133
- type: :boolean,
134
- default: true,
135
- full_name: N_("Installation media caching"),
136
- description: N_("Installation media files will be cached for full host images")
137
-
138
- setting "bootdisk_allowed_types",
139
- type: :array,
140
- default: Setting::Bootdisk.bootdisk_types,
141
- full_name: N_("Allowed bootdisk types"),
142
- description: N_("List of allowed bootdisk types, remove type to disable it")
143
- end
144
- end
145
- end
146
- end
147
-
148
- config.to_prepare do
149
- begin
150
- Host::Managed.prepend ForemanBootdisk::HostExt
151
- Host::Managed.include ForemanBootdisk::Orchestration::Compute
152
- Foreman::Model::Vmware.prepend ForemanBootdisk::ComputeResources::Vmware if Foreman::Model::Vmware.available?
153
- rescue StandardError => e
154
- Rails.logger.warn "#{ForemanBootdisk::ENGINE_NAME}: skipping engine hook (#{e})"
155
- end
156
- end
157
- end
158
-
159
- def self.logger
160
- Foreman::Logging.logger('foreman_bootdisk')
161
- end
162
- end