Samuli Seppänen
2017-Apr-10 07:46 UTC
[syslinux] Prompting the user for input in the PXE boot menu?
Hi, I would like to get some data from the user in the PXE boot menu before launching OS install. Something along these lines: Please enter hostname for the system: <user types the hostname> Please enter harddisk encryption password: <user types the password> The values thus obtained would be fed to the kernel command-line and from there to the OS installer. In our use-case it is not possible to obtain the above information from an external source (e.g. DHCP) or to determine it programmatically. I tried LUA scripting, but the syslinux implementation of LUA seemed to be missing input support. Any pointers? Samuli
Ferenc Wágner
2017-Apr-10 10:05 UTC
[syslinux] Prompting the user for input in the PXE boot menu?
Samuli Sepp?nen via Syslinux <syslinux at zytor.com> writes:> I tried LUA scripting, but the syslinux implementation of LUA seemed to > be missing input support.What version did you try? This works for me: boot: lua Lua 5.2.3 Copyright (C) 1994-2013 Lua.org, PUC-Rio> s = io.read ("*l")foobar> print (s)foobar Input support is indeed limited, but should be sufficient for this. -- Feri
Samuli Seppänen
2017-Apr-10 10:07 UTC
[syslinux] Prompting the user for input in the PXE boot menu?
On 10/04/2017 13:05, Ferenc W?gner wrote:> Samuli Sepp?nen via Syslinux <syslinux at zytor.com> writes: > >> I tried LUA scripting, but the syslinux implementation of LUA seemed to >> be missing input support. > > What version did you try? This works for me: > > boot: lua > Lua 5.2.3 Copyright (C) 1994-2013 Lua.org, PUC-Rio >> s = io.read ("*l") > foobar >> print (s) > foobar > > Input support is indeed limited, but should be sufficient for this. >I used what was bundled in CentOS 7. I will try again with a more up-to-date version and report back. Thanks! Samuli