summaryrefslogtreecommitdiffstats
path: root/modules-available/serversetup-bwlp-ipxe/inc/ipxe.inc.php
diff options
context:
space:
mode:
authorSimon Rettberg2020-06-10 17:12:02 +0200
committerSimon Rettberg2020-06-10 17:12:02 +0200
commit3fb99a5e8c229885602198bea4dce26bcf0fcc4f (patch)
tree775501f868c5afe913ef6485dabb89feefea7fb0 /modules-available/serversetup-bwlp-ipxe/inc/ipxe.inc.php
parent[statistics] Fix querying location 0 (no location) (diff)
downloadslx-admin-3fb99a5e8c229885602198bea4dce26bcf0fcc4f.tar.gz
slx-admin-3fb99a5e8c229885602198bea4dce26bcf0fcc4f.tar.xz
slx-admin-3fb99a5e8c229885602198bea4dce26bcf0fcc4f.zip
[serversetup-bwlp-ipxe] Start refactoring ipxe script generator
This is WIP. Mostly restored all the old functionality. Boot entries are fetched when selected, not embedded in the main script, so password protection is a bit stronger. Hopefully allows for other script generators in the future.
Diffstat (limited to 'modules-available/serversetup-bwlp-ipxe/inc/ipxe.inc.php')
-rw-r--r--modules-available/serversetup-bwlp-ipxe/inc/ipxe.inc.php10
1 files changed, 4 insertions, 6 deletions
diff --git a/modules-available/serversetup-bwlp-ipxe/inc/ipxe.inc.php b/modules-available/serversetup-bwlp-ipxe/inc/ipxe.inc.php
index 3ee33cae..29885588 100644
--- a/modules-available/serversetup-bwlp-ipxe/inc/ipxe.inc.php
+++ b/modules-available/serversetup-bwlp-ipxe/inc/ipxe.inc.php
@@ -377,10 +377,8 @@ class IPxe
'entryid' => 'localboot',
'hotkey' => 'L',
'title' => 'Lokales System starten',
- 'module' => '.script',
- 'data' => json_encode([
- 'script' => 'goto slx_localboot || goto %fail% ||',
- ]),
+ 'module' => '.special',
+ 'data' => json_encode(['type' => 'localboot']),
]);
Database::exec($query,
[
@@ -389,7 +387,7 @@ class IPxe
'title' => 'Power off',
'module' => '.script',
'data' => json_encode([
- 'script' => 'poweroff || goto %fail% ||',
+ 'script' => 'poweroff || goto fail ||',
]),
]);
Database::exec($query,
@@ -399,7 +397,7 @@ class IPxe
'title' => 'Reboot',
'module' => '.script',
'data' => json_encode([
- 'script' => 'reboot || goto %fail% ||',
+ 'script' => 'reboot || goto fail ||',
]),
]);
}