Update hw-acceleration.sh
This commit is contained in:
parent
46d1e2e309
commit
3d63800e65
@ -52,21 +52,25 @@ function msg() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
function select_hw_features() {
|
function select_hw_features() {
|
||||||
local opts=(
|
local opts
|
||||||
"usb" "USB Passthrough" OFF
|
opts=$(
|
||||||
"intel" "Intel VAAPI GPU" OFF
|
whiptail --title "🔧 Hardware Integration" --checklist \
|
||||||
"nvidia" "NVIDIA GPU" OFF
|
"\nSelect hardware features to passthrough:\n" 20 60 8 \
|
||||||
"amd" "AMD GPU (ROCm)" OFF
|
"usb" "🖧 USB Passthrough " OFF \
|
||||||
)
|
"intel" "🟦 Intel VAAPI GPU " OFF \
|
||||||
SELECTED_FEATURES=$(whiptail --title "Hardware Options" --checklist \
|
"nvidia" "🟨 NVIDIA GPU " OFF \
|
||||||
"Select hardware features to passthrough:" 20 50 10 \
|
"amd" "🟥 AMD GPU (ROCm) " OFF \
|
||||||
"${opts[@]}" 3>&1 1>&2 2>&3 | tr -d '"')
|
3>&1 1>&2 2>&3
|
||||||
|
) || exit 1
|
||||||
|
|
||||||
|
SELECTED_FEATURES=$(echo "$opts" | tr -d '"')
|
||||||
if [[ -z "$SELECTED_FEATURES" ]]; then
|
if [[ -z "$SELECTED_FEATURES" ]]; then
|
||||||
msg warn "No hardware passthrough options selected"
|
msg warn "No passthrough options selected"
|
||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
function select_lxc_targets() {
|
function select_lxc_targets() {
|
||||||
local list; local opts=()
|
local list; local opts=()
|
||||||
if ! list=$(pct list | awk 'NR>1 {print $1 "|" $2}' | xargs -n1); then
|
if ! list=$(pct list | awk 'NR>1 {print $1 "|" $2}' | xargs -n1); then
|
||||||
|
Loading…
x
Reference in New Issue
Block a user