Add sftp jail.
This commit is contained in:
@@ -31,10 +31,26 @@ function by_bin {
|
||||
for component in base ports; do fetch $SOURCEURL/$component.txz -o - | tar -xf - -C "$DESTDIR" ; done
|
||||
}
|
||||
|
||||
function by_pkg {
|
||||
local config
|
||||
config=$(cat <<EOF
|
||||
base: {
|
||||
url: "https://pkg.freebsd.org/FreeBSD:14:amd64/base_latest",
|
||||
mirror_type: "none",
|
||||
enabled: yes,
|
||||
priority: 100
|
||||
}
|
||||
EOF
|
||||
)
|
||||
IGNORE_OSVERSION=yes pkg --rootdir "$DESTDIR" --config <(cat <<<"$config") install --repository base --yes --glob 'FreeBSD-*'
|
||||
}
|
||||
|
||||
if [ "$1" = "src" ]; then
|
||||
by_src
|
||||
elif [ "$1" = "bin" ]; then
|
||||
by_bin
|
||||
elif [ "$1" = "pkg" ]; then
|
||||
by_pkg
|
||||
else
|
||||
die "First argument must be either 'src' or 'bin', got $1"
|
||||
fi
|
||||
|
||||
Reference in New Issue
Block a user