diff options
| author | Simon Rettberg | 2026-03-04 16:24:43 +0100 |
|---|---|---|
| committer | Simon Rettberg | 2026-03-04 16:24:43 +0100 |
| commit | c6ab72966b57cc261ff9779b347801748c7793fd (patch) | |
| tree | 48cfb23c4294fd36b0d83694ef6c621e5ea25c23 /core/modules | |
| parent | [run-virt] Update comments, minor fixes (diff) | |
| download | mltk-c6ab72966b57cc261ff9779b347801748c7793fd.tar.gz mltk-c6ab72966b57cc261ff9779b347801748c7793fd.tar.xz mltk-c6ab72966b57cc261ff9779b347801748c7793fd.zip | |
[vmchooser2] Fix: PVS join default on when PXE or DHCP IP empty
If we have rooms declared in pvs2.ini that don't have a tutor machine
configured, and either the PXE or DHCP client IP isn't set in our SLX
config, we match those empty lines and erroneously default pvs joining
to on. Make sure an empty IP address doesn't match by replacing it with
the string "invalid".
Diffstat (limited to 'core/modules')
| -rwxr-xr-x | core/modules/vmchooser2/data/opt/openslx/bin/vmchooser | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/core/modules/vmchooser2/data/opt/openslx/bin/vmchooser b/core/modules/vmchooser2/data/opt/openslx/bin/vmchooser index e433b095..5feefaed 100755 --- a/core/modules/vmchooser2/data/opt/openslx/bin/vmchooser +++ b/core/modules/vmchooser2/data/opt/openslx/bin/vmchooser @@ -68,7 +68,7 @@ if [ -z "$SLX_NO_PVS" ]; then if [ "$SLX_PVS_DEFAULT" = "ON" ] || [ "$SLX_PVS_HYBRID" = "yes" ]; then # Config option says checked by default, or this is hybrid manager EXTRA+=( "--pvs-checked" ) - elif grep -q -F -x -e "tutorIP=$SLX_PXE_CLIENT_IP" -e "tutorIP=$SLX_DHCP_CLIENT_IP" "/opt/openslx/pvs2/pvs2.ini"; then + elif grep -q -F -x -e "tutorIP=${SLX_PXE_CLIENT_IP:-invalid}" -e "tutorIP=${SLX_DHCP_CLIENT_IP:-invalid}" "/opt/openslx/pvs2/pvs2.ini"; then # This IP is a tutor, also autoconnect EXTRA+=( "--pvs-checked" ) fi |
