From 88cae8982fb6d280dadd441b1e985f6ab0c20b30 Mon Sep 17 00:00:00 2001 From: CanbiZ <47820557+MickLesk@users.noreply.github.com> Date: Wed, 4 Jun 2025 13:06:17 +0200 Subject: [PATCH] some fixes with venv --- install/bazarr-install.sh | 1 + install/calibre-web-install.sh | 4 ++-- install/changedetection-install.sh | 2 +- install/crafty-controller-install.sh | 6 +++--- install/deluge-install.sh | 1 - install/documenso-install.sh | 1 - install/esphome-install.sh | 1 - misc/tools.func | 2 +- 8 files changed, 8 insertions(+), 10 deletions(-) diff --git a/install/bazarr-install.sh b/install/bazarr-install.sh index cdf17e8c7..f7727d552 100755 --- a/install/bazarr-install.sh +++ b/install/bazarr-install.sh @@ -21,6 +21,7 @@ curl -fsSL "https://github.com/morpheus65535/bazarr/releases/latest/download/baz $STD unzip bazarr -d /opt/bazarr chmod 775 /opt/bazarr /var/lib/bazarr/ cd /opt/bazarr +$STD uv venv /opt/bazarr/.venv $STD /opt/bazarr/.venv/bin/uv pip install -r requirements.txt msg_ok "Installed Bazarr" diff --git a/install/calibre-web-install.sh b/install/calibre-web-install.sh index 905cd6324..ea91a38ee 100644 --- a/install/calibre-web-install.sh +++ b/install/calibre-web-install.sh @@ -31,8 +31,8 @@ msg_info "Installing Calibre-Web" mkdir -p /opt/calibre-web $STD curl -fsSL https://github.com/janeczku/calibre-web/raw/master/library/metadata.db -o /opt/calibre-web/metadata.db cd /opt/calibre-web -$STD uv venv .venv -$STD .venv/bin/uv pip install calibreweb jsonschema +$STD uv venv /opt/calibre-web/.venv +$STD /opt/calibre-web/.venv/bin/uv pip install calibreweb jsonschema msg_ok "Installed Calibre-Web" msg_info "Creating Service" diff --git a/install/changedetection-install.sh b/install/changedetection-install.sh index 245a05c05..3f1bc855d 100644 --- a/install/changedetection-install.sh +++ b/install/changedetection-install.sh @@ -49,7 +49,7 @@ NODE_VERSION="22" install_node_and_modules msg_info "Installing Change Detection" mkdir -p /opt/changedetection cd /opt/changedetection -$STD uv venv .venv +$STD uv venv /opt/changedetection/.venv $STD /opt/changedetection/.venv/bin/uv pip install changedetection.io msg_ok "Installed Change Detection" diff --git a/install/crafty-controller-install.sh b/install/crafty-controller-install.sh index 7273a7af3..a88757492 100644 --- a/install/crafty-controller-install.sh +++ b/install/crafty-controller-install.sh @@ -23,6 +23,8 @@ $STD apt-get install -y \ software-properties-common msg_ok "Installed Dependencies" +PYTHON_VERSION="3.12" setup_uv + msg_info "Setting up TemurinJDK" mkdir -p /etc/apt/keyrings curl -fsSL "https://packages.adoptium.net/artifactory/api/gpg/key/public" | tee /etc/apt/keyrings/adoptium.asc @@ -32,8 +34,6 @@ $STD apt-get install -y temurin-{8,11,17,21}-jre sudo update-alternatives --set java /usr/lib/jvm/temurin-21-jre-amd64/bin/java msg_ok "Installed TemurinJDK" -PYTHON_VERSION="3.12" setup_uv - msg_info "Installing Craty-Controller (Patience)" useradd crafty -m -s /bin/bash cd /opt @@ -46,7 +46,7 @@ cp -a crafty-4-v${RELEASE}/. /opt/crafty-controller/crafty/crafty-4/ rm -rf crafty-4-v${RELEASE} cd /opt/crafty-controller/crafty -$STD uv venv .venv +$STD uv venv /opt/crafty-controller/crafty/.venv chown -R crafty:crafty /opt/crafty-controller/ $STD sudo -u crafty bash -c ' source /opt/crafty-controller/crafty/.venv/bin/activate diff --git a/install/deluge-install.sh b/install/deluge-install.sh index 21cac7b5b..375954ad9 100644 --- a/install/deluge-install.sh +++ b/install/deluge-install.sh @@ -22,7 +22,6 @@ PYTHON_VERSION="3.12" setup_uv msg_info "Installing Deluge" mkdir -p /opt/deluge $STD uv venv /opt/deluge/.venv -source /opt/deluge/.venv/bin/activate $STD /opt/deluge/.venv/bin/uv pip install deluge[all] msg_ok "Installed Deluge" diff --git a/install/documenso-install.sh b/install/documenso-install.sh index 142765c85..ac0c94320 100644 --- a/install/documenso-install.sh +++ b/install/documenso-install.sh @@ -55,7 +55,6 @@ $STD unzip v${RELEASE}.zip mv documenso-${RELEASE} /opt/documenso cd /opt/documenso $STD uv venv /opt/documenso/.venv -source /opt/documenso/.venv/bin/activate $STD /opt/documenso/.venv/bin/uv pip install bcrypt mv .env.example /opt/documenso/.env sed -i \ diff --git a/install/esphome-install.sh b/install/esphome-install.sh index 2ceaaf407..892ed16d5 100644 --- a/install/esphome-install.sh +++ b/install/esphome-install.sh @@ -22,7 +22,6 @@ PYTHON_VERSION="3.12" setup_uv msg_info "Setting up Virtual Environment" mkdir -p /opt/esphome $STD uv venv /opt/esphome/.venv -source /opt/esphome/.venv/bin/activate $STD /opt/esphome/.venv/bin/uv pip install esphome tornado esptool msg_ok "Setup and Installed ESPHome" diff --git a/misc/tools.func b/misc/tools.func index bd80b58ac..03e58a2b3 100644 --- a/misc/tools.func +++ b/misc/tools.func @@ -1103,7 +1103,7 @@ function setup_uv() { msg_error "Failed to install Python $VERSION_MATCH via uv" return 1 fi - msg_ok "Installed Python $VERSION_MATCH via uv" + msg_ok "Installed Python $VERSION_MATCH" fi fi }