Project

General

Profile

Actions

Feature #19115

open

Add setting to define which PXE loaders are enabled

Added by Dominic Schlegel about 7 years ago. Updated about 7 years ago.

Status:
New
Priority:
Normal
Assignee:
-
Category:
Templates
Target version:
-
Difficulty:
Triaged:
Fixed in Releases:
Found in Releases:

Description

If I deleted the "PXEGrub default local boot" template and now want to cancel a pending build I get the following error message:

Error: Failed to cancel pending build for xxxxxx with the following errors: Unable to render 'PXEGrub default local boot' template: ERF42-4689 [Foreman::Exception]: Template 'PXEGrub default local boot' was not found

Given the fact that I did not assign any PXEGrub template to the OS of this particular host this is kind of unexpected at the first sight.
After some analysis it turned out that obviously foreman needs to create local boot files for all boot loaders as you cant assign a specific one to a host.

now my suggestion is to create a global foreman setting that defines which boot loaders are being used in the environment foreman is in. this would allow at least 2 things:

  1. only show the enabled pxe boot loaders in the drop down under "new host > operating system > pxe loader"
  2. only render the local boot templates for enabled pxe boot loaders
  3. maybe narrow down boot loader related tasks to only enabled once in other places I haven’t seen yet.
Actions #1

Updated by Dominic Cleal about 7 years ago

  • Tracker changed from Bug to Feature
  • Subject changed from cancel a build not possible when defaul template no longer exists to Add setting to define which PXE loaders are enabled
  • Category set to Templates

This error should no longer be possible since #18639, which locks the template and prevents it from being deleted.

I've changed the ticket to track the request to restrict which PXE loaders are managed, but if that's no longer important either, please close it.

Actions #2

Updated by Lukas Zapletal about 7 years ago

How you managed to delete "PXEGrub default local boot" template? It is supposed to be locked, isn't it?

Anyway, what you propose is maybe too complicated. How about just change the code that delivers local boot templates so it skips all missing ones instead of raising an error? That should do it.

Actions #3

Updated by Dominic Cleal about 7 years ago

Lukas Zapletal wrote:

How you managed to delete "PXEGrub default local boot" template? It is supposed to be locked, isn't it?

No templates are meant to be locked in this release, only since the ticket above (in develop only).

Actions #4

Updated by Dominic Schlegel about 7 years ago

How about just change the code that delivers local boot templates so it skips all missing ones instead of raising an error?

This sounds like a good idea. Although I still believe the user should be able to decide which boot loaders should be available/managable.

Actions

Also available in: Atom PDF