mount: allow [ro|rw|rq|sw|xx] as available mount options

This commit is contained in:
tschettervictor
2025-01-11 12:06:30 -07:00
committed by GitHub
parent fbb9c8cce3
commit 753c537e52

View File

@@ -89,8 +89,8 @@ elif [ ! -e "${_hostpath}" ] || [ "${_type}" != "nullfs" ]; then
usage
fi
# Mount permissions,options need to start with "ro" or "rw"
if ! echo "${_perms}" | grep -Eq 'r[w|o],.*$'; then
# Mount permissions,options need to include at least on of "ro, rw, rq, sw, xx"
if ! echo "${_perms}" | grep -Eq '[ro|rw|rq|sw|xx]'; then
error_notify "Detected invalid mount permissions in FSTAB."
warn "Format: /host/path /jail/path nullfs ro 0 0"
warn "Read: ${_fstab}"