From 9ed66d711c48f569fca5fcb190037e923e4114ea Mon Sep 17 00:00:00 2001 From: CanbiZ <47820557+MickLesk@users.noreply.github.com> Date: Wed, 4 Jun 2025 17:08:36 +0200 Subject: [PATCH] some fixes --- install/esphome-install.sh | 2 ++ install/pialert-install.sh | 12 +++++------- install/radicale-install.sh | 8 +++++--- install/searxng-install.sh | 6 +++--- install/slskd-install.sh | 2 +- install/spoolman-install.sh | 1 + install/streamlink-webui-install.sh | 2 +- install/tandoor-install.sh | 2 +- install/tasmocompiler-install.sh | 9 ++------- install/tianji-install.sh | 3 ++- install/unmanic-install.sh | 2 +- install/wger-install.sh | 4 ++-- 12 files changed, 26 insertions(+), 27 deletions(-) diff --git a/install/esphome-install.sh b/install/esphome-install.sh index 6ec7f9cee..edd31a10e 100644 --- a/install/esphome-install.sh +++ b/install/esphome-install.sh @@ -21,6 +21,8 @@ PYTHON_VERSION="3.12" setup_uv msg_info "Setting up Virtual Environment" mkdir -p /opt/esphome +mkdir -p /root/config +cd /opt/esphome $STD uv venv /opt/esphome/.venv $STD uv pip install esphome tornado esptool msg_ok "Setup and Installed ESPHome" diff --git a/install/pialert-install.sh b/install/pialert-install.sh index c5c4c057a..46d365779 100644 --- a/install/pialert-install.sh +++ b/install/pialert-install.sh @@ -44,17 +44,15 @@ msg_ok "Installed PHP Dependencies" PYTHON_VERSION="3.12" setup_uv -msg_info "Installing Python Dependencies" -source /opt/pialert/.venv/bin/activate +msg_info "Installing Pi.Alert" +curl -fsSL https://github.com/leiweibau/Pi.Alert/raw/main/tar/pialert_latest.tar | tar xvf - -C /opt >/dev/null 2>&1 +rm -rf /var/lib/ieee-data /var/www/html/index.html +cd /opt/pialert +$STD uv venv /opt/pialert/.venv $STD uv pip install mac-vendor-lookup $STD uv pip install fritzconnection $STD uv pip install cryptography $STD uv pip install pyunifi -msg_ok "Installed Python Dependencies" - -msg_info "Installing Pi.Alert" -curl -fsSL https://github.com/leiweibau/Pi.Alert/raw/main/tar/pialert_latest.tar | tar xvf - -C /opt >/dev/null 2>&1 -rm -rf /var/lib/ieee-data /var/www/html/index.html sed -i -e 's#^sudo cp -n /usr/share/ieee-data/.* /var/lib/ieee-data/#\# &#' -e '/^sudo mkdir -p 2_backup$/s/^/# /' -e '/^sudo cp \*.txt 2_backup$/s/^/# /' -e '/^sudo cp \*.csv 2_backup$/s/^/# /' /opt/pialert/back/update_vendors.sh mv /var/www/html/index.lighttpd.html /var/www/html/index.lighttpd.html.old ln -s /usr/share/ieee-data/ /var/lib/ diff --git a/install/radicale-install.sh b/install/radicale-install.sh index c8e374c11..db4858da9 100644 --- a/install/radicale-install.sh +++ b/install/radicale-install.sh @@ -21,8 +21,10 @@ msg_ok "Installed Dependencies" PYTHON_VERSION="3.12" setup_uv msg_info "Setting up Radicale" -$STD uv venv /opt/radicale -$STD /opt/radicale/bin/uv pip install --upgrade https://github.com/Kozea/Radicale/archive/master.tar.gz +mkdir -p /opt/radicale/{users} +cd /opt/radicale +$STD uv venv /opt/radicale/.venv +$STD uv pip install --upgrade https://github.com/Kozea/Radicale/archive/master.tar.gz RNDPASS=$(openssl rand -base64 18 | tr -dc 'a-zA-Z0-9' | head -c13) $STD htpasswd -c -b -5 /opt/radicale/users admin "$RNDPASS" { @@ -35,7 +37,7 @@ msg_ok "Done setting up Radicale" msg_info "Setup Service" cat </opt/radicale/start.sh #!/usr/bin/env bash -/opt/radicale/bin/uv run -m radicale --storage-filesystem-folder=/var/lib/radicale/collections --hosts 0.0.0.0:5232 --auth-type htpasswd --auth-htpasswd-filename /opt/radicale/users --auth-htpasswd-encryption sha512 +uv run -m radicale --storage-filesystem-folder=/var/lib/radicale/collections --hosts 0.0.0.0:5232 --auth-type htpasswd --auth-htpasswd-filename /opt/radicale/users --auth-htpasswd-encryption sha512 EOF chmod +x /opt/radicale/start.sh diff --git a/install/searxng-install.sh b/install/searxng-install.sh index e3a4fc972..d9875bdef 100644 --- a/install/searxng-install.sh +++ b/install/searxng-install.sh @@ -30,9 +30,9 @@ useradd -d /etc/searxng searxng chown searxng:searxng /usr/local/searxng /etc/searxng $STD git clone https://github.com/searxng/searxng.git /usr/local/searxng/searxng-src cd /usr/local/searxng/ -$STD uv venv /usr/local/searxng/searx-pyenv -$STD /usr/local/searxng/searx-pyenv/bin/uv pip install --upgrade pip setuptools wheel pyyaml -$STD /usr/local/searxng/searx-pyenv/bin/uv pip install --use-pep517 --no-build-isolation -e /usr/local/searxng/searxng-src +$STD uv venv /usr/local/searxng/.venv +$STD uv pip install --upgrade pip setuptools wheel pyyaml +$STD uv pip install --no-build-isolation -e /usr/local/searxng/searxng-src SECRET_KEY=$(openssl rand -hex 32) cat </etc/searxng/settings.yml diff --git a/install/slskd-install.sh b/install/slskd-install.sh index 737a0960c..e758a70d3 100644 --- a/install/slskd-install.sh +++ b/install/slskd-install.sh @@ -43,7 +43,7 @@ $STD unzip main.zip mv soularr-main /opt/soularr cd /opt/soularr $STD uv venv /opt/soularr/.venv -$STD /opt/soularr/.venv/bin/uv pip install -r requirements.txt +$STD uv pip install -r requirements.txt sed -i \ -e "\|[Slskd]|,\|host_url|s|yourslskdapikeygoeshere|$SLSKD_API_KEY|" \ -e "/host_url/s/slskd/localhost/" \ diff --git a/install/spoolman-install.sh b/install/spoolman-install.sh index 5b013924f..c3ebbf861 100644 --- a/install/spoolman-install.sh +++ b/install/spoolman-install.sh @@ -33,6 +33,7 @@ rm -f spoolman.zip cd spoolman $STD uv venv /opt/spoolman/.venv $STD uv pip install -r requirements.txt + curl -fsSL "https://raw.githubusercontent.com/Donkie/Spoolman/master/.env.example" -o ".env" echo "${RELEASE}" >/opt/${APPLICATION}_version.txt msg_ok "Installed Spoolman" diff --git a/install/streamlink-webui-install.sh b/install/streamlink-webui-install.sh index c1ed5c51a..ab83ee58e 100644 --- a/install/streamlink-webui-install.sh +++ b/install/streamlink-webui-install.sh @@ -15,7 +15,7 @@ network_check update_os NODE_VERSION="22" NODE_MODULE="npm@latest,yarn@latest" install_node_and_modules -setup_uv +PYTHON_VERSION="3.12" setup_uv fetch_and_deploy_gh_release "CrazyWolf13/streamlink-webui" msg_info "Setup ${APPLICATION}" diff --git a/install/tandoor-install.sh b/install/tandoor-install.sh index 826513a1a..878c9fb68 100644 --- a/install/tandoor-install.sh +++ b/install/tandoor-install.sh @@ -15,7 +15,7 @@ network_check update_os msg_info "Installing Dependencies (Patience)" -$STD apt-get install -y --no-install-recommends \ +$STD apt-get install -y \ build-essential \ libpq-dev \ libmagic-dev \ diff --git a/install/tasmocompiler-install.sh b/install/tasmocompiler-install.sh index 1e31b51c9..9277b8db3 100644 --- a/install/tasmocompiler-install.sh +++ b/install/tasmocompiler-install.sh @@ -20,13 +20,6 @@ msg_ok "Installed Dependencies" PYTHON_VERSION="3.12" setup_uv NODE_VERSION="22" NODE_MODULE="yarn@latest" install_node_and_modules -msg_info "Setup Platformio" -mkdir -p /opt/tasmocompiler -cd /opt/tasmocompiler -$STD uv venv /opt/tasmocompiler/.venv -$STD uv pip install platformio -msg_ok "Setup Platformio" - msg_info "Setup TasmoCompiler" mkdir /tmp/Tasmota RELEASE=$(curl -fsSL https://api.github.com/repos/benzino77/tasmocompiler/releases/latest | grep "tag_name" | awk '{print substr($2, 3, length($2)-4) }') @@ -35,6 +28,8 @@ cd /tmp tar xzf /tmp/v${RELEASE}.tar.gz mv tasmocompiler-${RELEASE}/ /opt/tasmocompiler/ cd /opt/tasmocompiler +$STD uv venv /opt/tasmocompiler/.venv +$STD uv pip install platformio $STD yarn install export NODE_OPTIONS=--openssl-legacy-provider $STD npm i diff --git a/install/tianji-install.sh b/install/tianji-install.sh index af2c02d4c..45b4200a4 100644 --- a/install/tianji-install.sh +++ b/install/tianji-install.sh @@ -21,7 +21,8 @@ $STD apt-get install -y \ build-essential \ git \ make \ - ca-certificates + ca-certificates \ + jq msg_ok "Installed Dependencies" NODE_VERSION="22" NODE_MODULE="pnpm@$(curl -s https://raw.githubusercontent.com/msgbyte/tianji/master/package.json | jq -r '.packageManager | split("@")[1]')" install_node_and_modules diff --git a/install/unmanic-install.sh b/install/unmanic-install.sh index 7f7c8dd7b..a826a976c 100644 --- a/install/unmanic-install.sh +++ b/install/unmanic-install.sh @@ -14,7 +14,7 @@ network_check update_os msg_info "Installing Dependencies (Patience)" -$STD apt-get install -y ffmpeg +$STD apt-get install -y ffmpeg gcc msg_ok "Installed Dependencies" PYTHON_VERSION="3.12" setup_uv diff --git a/install/wger-install.sh b/install/wger-install.sh index 32e6cefa1..d49d527bf 100644 --- a/install/wger-install.sh +++ b/install/wger-install.sh @@ -38,14 +38,14 @@ curl -fsSL "https://github.com/wger-project/wger/archive/refs/tags/$RELEASE.tar. tar xzf $RELEASE.tar.gz mv wger-$RELEASE /home/wger/src cd /home/wger/src +$STD /home/wger/.venv/bin/wger create-settings --database-path /home/wger/db/database.sqlite $STD uv venv /home/wger/.venv $STD uv pip install -r requirements_prod.txt $STD uv pip install -e . -$STD /home/wger/.venv/bin/wger create-settings --database-path /home/wger/db/database.sqlite sed -i "s#home/wger/src/media#home/wger/media#g" /home/wger/src/settings.py sed -i "/MEDIA_ROOT = '\/home\/wger\/media'/a STATIC_ROOT = '/home/wger/static'" /home/wger/src/settings.py $STD /home/wger/.venv/bin/wger bootstrap -$STD /home/wger/.venv/bin/uv run python manage.py collectstatic +$STD uv run python manage.py collectstatic echo "${RELEASE}" >/opt/wger_version.txt msg_ok "Finished setting up wger"