Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Eliminate some errors on bookworm #6

Merged
merged 4 commits into from
Dec 21, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
23 changes: 16 additions & 7 deletions scripts/install.sh
Original file line number Diff line number Diff line change
Expand Up @@ -8,16 +8,23 @@ function fail {
echo "### RPI-KVM Install ##############"
echo "--- RPI-KVM Dependency Install ---"
echo "Install required basic packages via apt-get"
sudo apt-get install git tmux python python3 python-dev python3-dev python3-pip -y
sudo apt update
sudo apt-get install git tmux python-is-python3 python3 python3-dev python3-pip -y
echo "Install required bluetooth packages via apt-get"
sudo apt-get install bluez bluez-tools bluez-firmware python3-bluez -y
echo "Install required python packages via pip3"
sudo pip3 install evdev dbus-next aiohttp RPi.GPIO
echo "Install required python packages via apt-get"
sudo apt-get install python3-pyudev python3-evdev python3-dbus python3-numpy python3-gi -y
echo "Install dev tools"
curl -sSL https://deb.nodesource.com/setup_16.x | sudo bash -
sudo apt install -y nodejs
sudo apt-get install python3-pyudev python3-evdev python3-dbus python3-dbus-next python3-aiohttp python3-rpi.gpio python3-numpy python3-gi -y
echo "Install nodejs"
sudo apt-get update
sudo apt-get install -y ca-certificates curl gnupg
sudo mkdir -p /etc/apt/keyrings
# --yes allows overwriting if re-running the script (to repair a broken install or get new fixes)
curl -fsSL https://deb.nodesource.com/gpgkey/nodesource-repo.gpg.key | sudo gpg --dearmor --yes -o /etc/apt/keyrings/nodesource.gpg
# This can be changed to a newer supported version once tested
NODE_MAJOR=16
echo "deb [signed-by=/etc/apt/keyrings/nodesource.gpg] https://deb.nodesource.com/node_$NODE_MAJOR.x nodistro main" | sudo tee /etc/apt/sources.list.d/nodesource.list
sudo apt-get update
sudo apt-get install nodejs -y
echo "--- Dependency Install Done ------"

echo "--- RPI-KVM Configuration Step ---"
Expand Down Expand Up @@ -54,6 +61,8 @@ sudo sed -i "s|BLUETOOTH_DAEMON_PATH|${bluetoothd_path}|" /lib/systemd/system/bl

echo "Copy RPI-KVM service config"
sudo cp ./conf/rpi-kvm.service /lib/systemd/system/rpi-kvm.service
echo "Replace legacy pi user with current user if necessary"
sudo sed -i'' -e "s|/pi/|/${SUDO_USER}/|g" /lib/systemd/system/rpi-kvm.service
sudo systemctl daemon-reload
echo "Restart bluetooth service with the new config"
sudo systemctl restart bluetooth
Expand Down