Skip to content
This repository was archived by the owner on Oct 6, 2023. It is now read-only.

Commit 2c08870

Browse files
committed
fix: NFS_VERSION=3 results in rpc.nfsd still offering version 4
1 parent c1cf07c commit 2c08870

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

entrypoint.sh

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -396,13 +396,18 @@ boot_helper_mount() {
396396
boot_helper_get_version_flags() {
397397

398398
local versionFlags
399+
local -r requestedVersion="$(get_reqd_nfs_version)"
399400

400-
versionFlags=('--nfs-version' "$(get_reqd_nfs_version)" '--no-nfs-version' 2)
401+
versionFlags=('--nfs-version' "$requestedVersion" '--no-nfs-version' 2)
401402

402403
if [[ -z "$(is_nfs3_enabled)" ]]; then
403404
versionFlags+=('--no-nfs-version' 3)
404405
fi
405406

407+
if [[ "$requestedVersion" == '3' ]]; then
408+
versionFlags+=('--no-nfs-version' 4)
409+
fi
410+
406411
echo "${versionFlags[@]}"
407412
}
408413

0 commit comments

Comments
 (0)