mirror of
https://github.com/community-scripts/ProxmoxVE.git
synced 2026-03-10 21:54:57 +00:00
fix(core): remove duplicate -nameserver/-searchdomain prefix in pct create
The NS and SD variables already contain the -nameserver= and -searchdomain= prefixes (set in advanced_settings). PR #12521 incorrectly added a second prefix when building PCT_OPTIONS_STRING, resulting in '-nameserver -nameserver=8.8.8.8' which pct rejects. Also fixes the misleading comment ('Add storage' -> 'Add searchdomain'). Fixes #12572
This commit is contained in:
@@ -3617,16 +3617,16 @@ build_container() {
|
||||
$PCT_OPTIONS_STRING"
|
||||
fi
|
||||
|
||||
# Add storage if specified
|
||||
# Add searchdomain if specified
|
||||
if [ -n "$SD" ]; then
|
||||
PCT_OPTIONS_STRING="$PCT_OPTIONS_STRING
|
||||
-searchdomain $SD"
|
||||
$SD"
|
||||
fi
|
||||
|
||||
# Add nameserver if specified
|
||||
if [ -n "$NS" ]; then
|
||||
PCT_OPTIONS_STRING="$PCT_OPTIONS_STRING
|
||||
-nameserver $NS"
|
||||
$NS"
|
||||
fi
|
||||
|
||||
# Network configuration
|
||||
|
||||
Reference in New Issue
Block a user