mirror of
https://github.com/community-scripts/ProxmoxVE.git
synced 2026-11-25 20:43:38 +01:00
Compare commits
34
Commits
2026-11-23
...
main
No files matched your search
@@ -587,6 +587,59 @@ Exercise vigilance regarding copycat or coat-tailing sites that seek to exploit
|
||||
|
||||
</details>
|
||||
|
||||
## 2026-11-25
|
||||
|
||||
### 🆕 New Scripts
|
||||
|
||||
- Hister is now Nogon [@MickLesk](https://github.com/MickLesk) ([#19031](https://github.com/community-scripts/ProxmoxVE/pull/19031))
|
||||
- NextDNS [@nberardi](https://github.com/nberardi) ([#18980](https://github.com/community-scripts/ProxmoxVE/pull/18980))
|
||||
- Rauthy [@MickLesk](https://github.com/MickLesk) ([#19021](https://github.com/community-scripts/ProxmoxVE/pull/19021))
|
||||
- Formbricks [@MickLesk](https://github.com/MickLesk) ([#19022](https://github.com/community-scripts/ProxmoxVE/pull/19022))
|
||||
|
||||
### 🚀 Updated Scripts
|
||||
|
||||
- #### 🐞 Bug Fixes
|
||||
|
||||
- Odoo: update PDFKiln on each release, and replace wkhtmltox too [@Jamalofski](https://github.com/Jamalofski) ([#19035](https://github.com/community-scripts/ProxmoxVE/pull/19035))
|
||||
|
||||
- #### 🔧 Refactor
|
||||
|
||||
- ERPNext: install PDFKiln instead of the archived wkhtmltox build [@Jamalofski](https://github.com/Jamalofski) ([#19025](https://github.com/community-scripts/ProxmoxVE/pull/19025))
|
||||
|
||||
### 💾 Core
|
||||
|
||||
- core: back up and restore around a mount below the path [@MickLesk](https://github.com/MickLesk) ([core#295](https://github.com/community-scripts/core/pull/295))
|
||||
|
||||
### 🧰 Tools
|
||||
|
||||
- Immich Power Tools ([#19023](https://github.com/community-scripts/ProxmoxVE/pull/19023))
|
||||
- VueTorrent ([#19024](https://github.com/community-scripts/ProxmoxVE/pull/19024))
|
||||
|
||||
- #### 🐞 Bug Fixes
|
||||
|
||||
- Monitor-All: ping the container's net0 address [@MickLesk](https://github.com/MickLesk) ([#19030](https://github.com/community-scripts/ProxmoxVE/pull/19030))
|
||||
|
||||
## 2026-11-24
|
||||
|
||||
### 🆕 New Scripts
|
||||
|
||||
- 8mblocal [@MickLesk](https://github.com/MickLesk) ([#18975](https://github.com/community-scripts/ProxmoxVE/pull/18975))
|
||||
- Woodpecker-CI [@MickLesk](https://github.com/MickLesk) ([#18973](https://github.com/community-scripts/ProxmoxVE/pull/18973))
|
||||
- HedgeDoc [@MickLesk](https://github.com/MickLesk) ([#18978](https://github.com/community-scripts/ProxmoxVE/pull/18978))
|
||||
- Typecho [@MickLesk](https://github.com/MickLesk) ([#18974](https://github.com/community-scripts/ProxmoxVE/pull/18974))
|
||||
- Kyoo [@MickLesk](https://github.com/MickLesk) ([#18971](https://github.com/community-scripts/ProxmoxVE/pull/18971))
|
||||
- Activepieces [@MickLesk](https://github.com/MickLesk) ([#18970](https://github.com/community-scripts/ProxmoxVE/pull/18970))
|
||||
- Windmill [@MickLesk](https://github.com/MickLesk) ([#18977](https://github.com/community-scripts/ProxmoxVE/pull/18977))
|
||||
- Databasement [@MickLesk](https://github.com/MickLesk) ([#18976](https://github.com/community-scripts/ProxmoxVE/pull/18976))
|
||||
|
||||
### 🚀 Updated Scripts
|
||||
|
||||
- #### 🐞 Bug Fixes
|
||||
|
||||
- Odoo: install PDFKiln instead of the archived wkhtmltox build [@Jamalofski](https://github.com/Jamalofski) ([#19014](https://github.com/community-scripts/ProxmoxVE/pull/19014))
|
||||
- Traefik: actually upgrade and restart traefik on Alpine update [@Tonomis](https://github.com/Tonomis) ([#19005](https://github.com/community-scripts/ProxmoxVE/pull/19005))
|
||||
- Nginx Proxy Manager: bump OpenResty to 1.31.9.1 [@rudydelorenzo](https://github.com/rudydelorenzo) ([#19008](https://github.com/community-scripts/ProxmoxVE/pull/19008))
|
||||
|
||||
## 2026-11-23
|
||||
|
||||
### 🆕 New Scripts
|
||||
|
||||
@@ -0,0 +1,75 @@
|
||||
#!/usr/bin/env bash
|
||||
_cs_boot="${COMMUNITY_SCRIPTS_CORE_DIR:-$(dirname "${BASH_SOURCE[0]}")/../../core}/core/build.func"
|
||||
source "$_cs_boot" 2>/dev/null || source <(curl -fsSL "${COMMUNITY_SCRIPTS_CORE_URL:-https://raw.githubusercontent.com/community-scripts/core/main}/core/build.func")
|
||||
# Copyright (c) 2021-2026 community-scripts ORG
|
||||
# Author: MickLesk (CanbiZ)
|
||||
# License: MIT | https://github.com/community-scripts/ProxmoxVE/raw/main/LICENSE
|
||||
# Source: https://github.com/JMS1717/8mb.local
|
||||
|
||||
APP="8mbLocal"
|
||||
var_tags="${var_tags:-media;video;compression}"
|
||||
var_cpu="${var_cpu:-2}"
|
||||
var_ram="${var_ram:-2048}"
|
||||
var_disk="${var_disk:-10}"
|
||||
var_os="${var_os:-debian}"
|
||||
var_version="${var_version:-13}"
|
||||
var_arm64="${var_arm64:-no}" # psutil 5.9.8 (pinned upstream) has no aarch64 wheel and would need a compiler
|
||||
var_unprivileged="${var_unprivileged:-1}"
|
||||
var_gpu="${var_gpu:-yes}"
|
||||
|
||||
header_info "$APP"
|
||||
variables
|
||||
color
|
||||
catch_errors
|
||||
|
||||
function update_script() {
|
||||
header_info
|
||||
check_container_storage
|
||||
check_container_resources
|
||||
|
||||
if [[ ! -d /opt/8mblocal ]]; then
|
||||
msg_error "No ${APP} Installation Found!"
|
||||
exit
|
||||
fi
|
||||
|
||||
if check_for_gh_release "8mblocal" "JMS1717/8mb.local"; then
|
||||
msg_info "Stopping 8mb.local"
|
||||
systemctl stop 8mblocal 8mblocal-worker
|
||||
msg_ok "Stopped 8mb.local"
|
||||
|
||||
NODE_VERSION="22" setup_nodejs
|
||||
PYTHON_VERSION="3.12" setup_uv
|
||||
CLEAN_INSTALL=1 fetch_and_deploy_gh_release "8mblocal" "JMS1717/8mb.local" "tarball"
|
||||
|
||||
msg_info "Building 8mb.local"
|
||||
mv /opt/8mblocal /opt/8mblocal-build
|
||||
cd /opt/8mblocal-build/frontend
|
||||
$STD npm ci
|
||||
$STD npm run build
|
||||
mkdir -p /opt/8mblocal
|
||||
mv /opt/8mblocal-build/backend-api/app /opt/8mblocal/backend
|
||||
mv /opt/8mblocal-build/worker/app /opt/8mblocal/worker
|
||||
mv /opt/8mblocal-build/shared /opt/8mblocal-build/requirements.txt /opt/8mblocal/
|
||||
mv /opt/8mblocal-build/frontend/build /opt/8mblocal/frontend-build
|
||||
rm -rf /opt/8mblocal-build
|
||||
cd /opt/8mblocal
|
||||
$STD uv venv --python 3.12 .venv
|
||||
$STD uv pip install --python .venv/bin/python -r requirements.txt packaging
|
||||
msg_ok "Built 8mb.local"
|
||||
|
||||
msg_info "Starting 8mb.local"
|
||||
systemctl start 8mblocal-worker 8mblocal
|
||||
msg_ok "Started 8mb.local"
|
||||
msg_ok "Updated successfully!"
|
||||
fi
|
||||
exit
|
||||
}
|
||||
|
||||
start
|
||||
build_container
|
||||
description
|
||||
|
||||
msg_ok "Completed Successfully!\n"
|
||||
echo -e "${CREATING}${GN}${APP} setup has been successfully initialized!${CL}"
|
||||
echo -e "${INFO}${YW}Access it using the following URL:${CL}"
|
||||
echo -e "${GATEWAY}${BGN}http://${IP}:8001${CL}"
|
||||
@@ -0,0 +1,70 @@
|
||||
#!/usr/bin/env bash
|
||||
_cs_boot="${COMMUNITY_SCRIPTS_CORE_DIR:-$(dirname "${BASH_SOURCE[0]}")/../../core}/core/build.func"
|
||||
source "$_cs_boot" 2>/dev/null || source <(curl -fsSL "${COMMUNITY_SCRIPTS_CORE_URL:-https://raw.githubusercontent.com/community-scripts/core/main}/core/build.func")
|
||||
# Copyright (c) 2021-2026 community-scripts ORG
|
||||
# Author: MickLesk (CanbiZ)
|
||||
# License: MIT | https://github.com/community-scripts/ProxmoxVE/raw/main/LICENSE
|
||||
# Source: https://github.com/activepieces/activepieces
|
||||
|
||||
APP="Activepieces"
|
||||
var_tags="${var_tags:-automation;workflow;ai}"
|
||||
var_cpu="${var_cpu:-4}"
|
||||
var_ram="${var_ram:-6144}"
|
||||
var_disk="${var_disk:-12}"
|
||||
var_os="${var_os:-debian}"
|
||||
var_version="${var_version:-13}"
|
||||
var_arm64="${var_arm64:-yes}"
|
||||
var_unprivileged="${var_unprivileged:-1}"
|
||||
|
||||
header_info "$APP"
|
||||
variables
|
||||
color
|
||||
catch_errors
|
||||
|
||||
function update_script() {
|
||||
header_info
|
||||
check_container_storage
|
||||
check_container_resources
|
||||
|
||||
if [[ ! -d /opt/activepieces ]]; then
|
||||
msg_error "No ${APP} Installation Found!"
|
||||
exit
|
||||
fi
|
||||
|
||||
if check_for_gh_release "activepieces" "activepieces/activepieces"; then
|
||||
msg_info "Stopping Activepieces"
|
||||
systemctl stop activepieces activepieces-worker
|
||||
msg_ok "Stopped Activepieces"
|
||||
|
||||
CLEAN_INSTALL=1 fetch_and_deploy_gh_release "activepieces" "activepieces/activepieces" "tarball"
|
||||
NODE_VERSION="24" NODE_MODULE="$(jq -r '.packageManager' /opt/activepieces/package.json)" setup_nodejs
|
||||
fetch_and_deploy_gh_release "deno" "denoland/deno" "prebuild" "v$(jq -r '.devDependencies.deno' /opt/activepieces/packages/server/engine/package.json)" "/usr/local/bin" "deno-$(arch_resolve "x86_64" "aarch64")-unknown-linux-gnu.zip"
|
||||
|
||||
msg_info "Building Activepieces"
|
||||
cd /opt/activepieces
|
||||
REDISMS_DISABLE_POSTINSTALL=1 $STD bun install --frozen-lockfile
|
||||
$STD npx turbo run build --filter=web --filter=@activepieces/engine --filter=api --filter=worker
|
||||
find dist/packages/web -name '*.map' -delete
|
||||
rm -rf node_modules bun.lock packages/pieces/core packages/pieces/custom packages/web packages/cli packages/tests-e2e packages/ee
|
||||
find packages/pieces/community -mindepth 1 -maxdepth 1 -type d ! -name slack ! -name square ! -name facebook-leads ! -name intercom ! -name microsoft-teams-bot -exec rm -rf {} +
|
||||
node -e "const fs=require('fs');const p=JSON.parse(fs.readFileSync('package.json','utf8'));p.workspaces=p.workspaces.filter(w=>fs.existsSync(w.replace('/*','')));fs.writeFileSync('package.json',JSON.stringify(p,null,2))"
|
||||
REDISMS_DISABLE_POSTINSTALL=1 $STD bun install --production
|
||||
rm -rf ~/.bun/install/cache
|
||||
msg_ok "Built Activepieces"
|
||||
|
||||
msg_info "Starting Activepieces"
|
||||
systemctl start activepieces activepieces-worker
|
||||
msg_ok "Started Activepieces"
|
||||
msg_ok "Updated successfully!"
|
||||
fi
|
||||
exit
|
||||
}
|
||||
|
||||
start
|
||||
build_container
|
||||
description
|
||||
|
||||
msg_ok "Completed Successfully!\n"
|
||||
echo -e "${CREATING}${GN}${APP} setup has been successfully initialized!${CL}"
|
||||
echo -e "${INFO}${YW}Access it using the following URL:${CL}"
|
||||
echo -e "${GATEWAY}${BGN}http://${IP}${CL}"
|
||||
@@ -0,0 +1,72 @@
|
||||
#!/usr/bin/env bash
|
||||
_cs_boot="${COMMUNITY_SCRIPTS_CORE_DIR:-$(dirname "${BASH_SOURCE[0]}")/../../core}/core/build.func"
|
||||
source "$_cs_boot" 2>/dev/null || source <(curl -fsSL "${COMMUNITY_SCRIPTS_CORE_URL:-https://raw.githubusercontent.com/community-scripts/core/main}/core/build.func")
|
||||
# Copyright (c) 2021-2026 community-scripts ORG
|
||||
# Author: MickLesk (CanbiZ)
|
||||
# License: MIT | https://github.com/community-scripts/ProxmoxVE/raw/main/LICENSE
|
||||
# Source: https://github.com/David-Crty/databasement
|
||||
|
||||
APP="Databasement"
|
||||
var_tags="${var_tags:-backup;database}"
|
||||
var_cpu="${var_cpu:-2}"
|
||||
var_ram="${var_ram:-2048}"
|
||||
var_disk="${var_disk:-8}"
|
||||
var_os="${var_os:-debian}"
|
||||
var_version="${var_version:-13}"
|
||||
var_arm64="${var_arm64:-yes}"
|
||||
var_unprivileged="${var_unprivileged:-1}"
|
||||
|
||||
header_info "$APP"
|
||||
variables
|
||||
color
|
||||
catch_errors
|
||||
|
||||
function update_script() {
|
||||
header_info
|
||||
check_container_storage
|
||||
check_container_resources
|
||||
|
||||
if [[ ! -d /opt/databasement ]]; then
|
||||
msg_error "No ${APP} Installation Found!"
|
||||
exit
|
||||
fi
|
||||
|
||||
if check_for_gh_release "databasement" "David-Crty/databasement"; then
|
||||
msg_info "Stopping Databasement"
|
||||
systemctl stop databasement-worker databasement-scheduler php8.5-fpm
|
||||
msg_ok "Stopped Databasement"
|
||||
|
||||
setup_composer
|
||||
NODE_VERSION="22" setup_nodejs
|
||||
|
||||
CLEAN_INSTALL=1 fetch_and_deploy_gh_release "databasement" "David-Crty/databasement" "tarball"
|
||||
|
||||
msg_info "Updating Databasement"
|
||||
ln -sf /opt/databasement_data/.env /opt/databasement/.env
|
||||
sed -i "s/^APP_VERSION=.*/APP_VERSION=$(cat ~/.databasement)/" /opt/databasement_data/.env
|
||||
cd /opt/databasement
|
||||
$STD composer install --no-dev --optimize-autoloader --no-interaction
|
||||
$STD php artisan vendor:publish --force --tag=livewire:assets
|
||||
$STD npm ci --ignore-scripts
|
||||
$STD npm run build
|
||||
$STD php artisan migrate --force
|
||||
$STD php artisan optimize
|
||||
chown -R www-data:www-data /opt/databasement /opt/databasement_data
|
||||
msg_ok "Updated Databasement"
|
||||
|
||||
msg_info "Starting Databasement"
|
||||
systemctl start php8.5-fpm databasement-worker databasement-scheduler
|
||||
msg_ok "Started Databasement"
|
||||
msg_ok "Updated successfully!"
|
||||
fi
|
||||
exit
|
||||
}
|
||||
|
||||
start
|
||||
build_container
|
||||
description
|
||||
|
||||
msg_ok "Completed Successfully!\n"
|
||||
echo -e "${CREATING}${GN}${APP} setup has been successfully initialized!${CL}"
|
||||
echo -e "${INFO}${YW}Access it using the following URL:${CL}"
|
||||
echo -e "${GATEWAY}${BGN}http://${IP}${CL}"
|
||||
@@ -41,6 +41,14 @@ function update_script() {
|
||||
$STD supervisorctl stop all
|
||||
msg_ok "Stopped ERPNext service"
|
||||
|
||||
if dpkg -s wkhtmltox &>/dev/null; then
|
||||
$STD apt remove --purge -y wkhtmltox
|
||||
fi
|
||||
|
||||
if check_for_gh_release "pdfkiln" "pdfkiln/pdfkiln"; then
|
||||
fetch_and_deploy_gh_release "pdfkiln" "pdfkiln/pdfkiln" "binary" "latest" "" "pdfkiln_*_$(arch_resolve).deb"
|
||||
fi
|
||||
|
||||
if [[ "${FRAPPE_MAJOR:-0}" -lt 16 ]] && { [[ "${PHS_SILENT:-0}" == "1" ]] || whiptail --backtitle "Proxmox VE Helper Scripts" --title "ERPNext v16 Major Upgrade" \
|
||||
--yesno "A major upgrade from Frappe/ERPNext v15 to v16 is available.\n\nUpgrade to v16 now?" 16 78; }; then
|
||||
|
||||
|
||||
@@ -0,0 +1,91 @@
|
||||
#!/usr/bin/env bash
|
||||
_cs_boot="${COMMUNITY_SCRIPTS_CORE_DIR:-$(dirname "${BASH_SOURCE[0]}")/../../core}/core/build.func"
|
||||
source "$_cs_boot" 2>/dev/null || source <(curl -fsSL "${COMMUNITY_SCRIPTS_CORE_URL:-https://raw.githubusercontent.com/community-scripts/core/main}/core/build.func")
|
||||
# Copyright (c) 2021-2026 community-scripts ORG
|
||||
# Author: MickLesk (CanbiZ)
|
||||
# License: MIT | https://github.com/community-scripts/ProxmoxVE/raw/main/LICENSE
|
||||
# Source: https://github.com/formbricks/formbricks
|
||||
|
||||
APP="Formbricks"
|
||||
var_tags="${var_tags:-survey;feedback;forms}"
|
||||
var_cpu="${var_cpu:-4}"
|
||||
var_ram="${var_ram:-12288}"
|
||||
var_disk="${var_disk:-20}"
|
||||
var_os="${var_os:-debian}"
|
||||
var_version="${var_version:-13}"
|
||||
var_arm64="${var_arm64:-yes}"
|
||||
var_unprivileged="${var_unprivileged:-1}"
|
||||
|
||||
header_info "$APP"
|
||||
variables
|
||||
color
|
||||
catch_errors
|
||||
|
||||
function update_script() {
|
||||
header_info
|
||||
check_container_storage
|
||||
check_container_resources
|
||||
|
||||
if [[ ! -d /opt/formbricks ]]; then
|
||||
msg_error "No ${APP} Installation Found!"
|
||||
exit
|
||||
fi
|
||||
|
||||
if check_for_gh_release "spicedb" "authzed/spicedb"; then
|
||||
msg_info "Stopping SpiceDB"
|
||||
systemctl stop spicedb
|
||||
msg_ok "Stopped SpiceDB"
|
||||
|
||||
fetch_and_deploy_gh_release "spicedb" "authzed/spicedb" "binary"
|
||||
|
||||
msg_info "Migrating SpiceDB Datastore"
|
||||
set -a && source /opt/formbricks_data/spicedb.env && set +a
|
||||
$STD spicedb datastore migrate head
|
||||
msg_ok "Migrated SpiceDB Datastore"
|
||||
|
||||
msg_info "Starting SpiceDB"
|
||||
systemctl start spicedb
|
||||
msg_ok "Started SpiceDB"
|
||||
fi
|
||||
|
||||
if check_for_gh_release "formbricks" "formbricks/formbricks"; then
|
||||
msg_info "Stopping Formbricks"
|
||||
systemctl stop formbricks
|
||||
msg_ok "Stopped Formbricks"
|
||||
|
||||
CLEAN_INSTALL=1 fetch_and_deploy_gh_release "formbricks" "formbricks/formbricks" "tarball"
|
||||
NODE_VERSION="24" NODE_MODULE="pnpm@$(jq -r '.packageManager | split("@")[1]' /opt/formbricks/package.json)" setup_nodejs
|
||||
|
||||
msg_info "Building Formbricks (Patience)"
|
||||
cd /opt/formbricks
|
||||
sed -i "s/\"version\": \"0.0.0\"/\"version\": \"$(cat ~/.formbricks)\"/" apps/web/package.json
|
||||
sed -i 's/^const nextConfig = {$/&\n typescript: { ignoreBuildErrors: true },/' apps/web/next.config.mjs
|
||||
touch apps/web/.env
|
||||
$STD pnpm install --ignore-scripts --frozen-lockfile
|
||||
$STD sh apps/web/scripts/docker/read-secrets.sh pnpm build --filter=@formbricks/web...
|
||||
cp -r apps/web/.next/static apps/web/.next/standalone/apps/web/.next/
|
||||
cp -r apps/web/public apps/web/.next/standalone/apps/web/
|
||||
msg_ok "Built Formbricks"
|
||||
|
||||
msg_info "Migrating Formbricks Database"
|
||||
set -a && source /opt/formbricks_data/.env && set +a
|
||||
$STD node packages/database/dist/scripts/apply-migrations.js
|
||||
$STD node apps/web/dist/authzed-cli/index.mjs upgrade prepare
|
||||
msg_ok "Migrated Formbricks Database"
|
||||
|
||||
msg_info "Starting Formbricks"
|
||||
systemctl start formbricks
|
||||
msg_ok "Started Formbricks"
|
||||
msg_ok "Updated successfully!"
|
||||
fi
|
||||
exit
|
||||
}
|
||||
|
||||
start
|
||||
build_container
|
||||
description
|
||||
|
||||
msg_ok "Completed Successfully!\n"
|
||||
echo -e "${CREATING}${GN}${APP} setup has been successfully initialized!${CL}"
|
||||
echo -e "${INFO}${YW}Access it using the following URL:${CL}"
|
||||
echo -e "${GATEWAY}${BGN}http://${IP}:3000${CL}"
|
||||
@@ -0,0 +1,61 @@
|
||||
#!/usr/bin/env bash
|
||||
_cs_boot="${COMMUNITY_SCRIPTS_CORE_DIR:-$(dirname "${BASH_SOURCE[0]}")/../../core}/core/build.func"
|
||||
source "$_cs_boot" 2>/dev/null || source <(curl -fsSL "${COMMUNITY_SCRIPTS_CORE_URL:-https://raw.githubusercontent.com/community-scripts/core/main}/core/build.func")
|
||||
# Copyright (c) 2021-2026 community-scripts ORG
|
||||
# Author: MickLesk (CanbiZ)
|
||||
# License: MIT | https://github.com/community-scripts/ProxmoxVE/raw/main/LICENSE
|
||||
# Source: https://github.com/hedgedoc/hedgedoc
|
||||
|
||||
APP="HedgeDoc"
|
||||
var_tags="${var_tags:-notes;markdown}"
|
||||
var_cpu="${var_cpu:-2}"
|
||||
var_ram="${var_ram:-2048}"
|
||||
var_disk="${var_disk:-8}"
|
||||
var_os="${var_os:-debian}"
|
||||
var_version="${var_version:-13}"
|
||||
var_arm64="${var_arm64:-yes}"
|
||||
var_unprivileged="${var_unprivileged:-1}"
|
||||
|
||||
header_info "$APP"
|
||||
variables
|
||||
color
|
||||
catch_errors
|
||||
|
||||
function update_script() {
|
||||
header_info
|
||||
check_container_storage
|
||||
check_container_resources
|
||||
|
||||
if [[ ! -d /opt/hedgedoc ]]; then
|
||||
msg_error "No ${APP} Installation Found!"
|
||||
exit
|
||||
fi
|
||||
|
||||
if check_for_gh_release "hedgedoc" "hedgedoc/hedgedoc"; then
|
||||
msg_info "Stopping HedgeDoc"
|
||||
systemctl stop hedgedoc
|
||||
msg_ok "Stopped HedgeDoc"
|
||||
|
||||
CLEAN_INSTALL=1 fetch_and_deploy_gh_release "hedgedoc" "hedgedoc/hedgedoc" "prebuild" "latest" "/opt/hedgedoc" "hedgedoc-*.tar.gz"
|
||||
|
||||
msg_info "Installing HedgeDoc Dependencies"
|
||||
cd /opt/hedgedoc
|
||||
$STD yarn workspaces focus --production
|
||||
msg_ok "Installed HedgeDoc Dependencies"
|
||||
|
||||
msg_info "Starting HedgeDoc"
|
||||
systemctl start hedgedoc
|
||||
msg_ok "Started HedgeDoc"
|
||||
msg_ok "Updated successfully!"
|
||||
fi
|
||||
exit
|
||||
}
|
||||
|
||||
start
|
||||
build_container
|
||||
description
|
||||
|
||||
msg_ok "Completed Successfully!\n"
|
||||
echo -e "${CREATING}${GN}${APP} setup has been successfully initialized!${CL}"
|
||||
echo -e "${INFO}${YW}Access it using the following URL:${CL}"
|
||||
echo -e "${GATEWAY}${BGN}http://${IP}:3000${CL}"
|
||||
+5
-43
@@ -4,53 +4,15 @@ source "$_cs_boot" 2>/dev/null || source <(curl -fsSL "${COMMUNITY_SCRIPTS_CORE_
|
||||
# Copyright (c) 2021-2026 community-scripts ORG
|
||||
# Author: MickLesk (CanbiZ)
|
||||
# License: MIT | https://github.com/community-scripts/ProxmoxVE/raw/main/LICENSE
|
||||
# Source: https://github.com/asciimoo/hister
|
||||
|
||||
APP="Hister"
|
||||
var_tags="${var_tags:-search;browser-history;personal}"
|
||||
var_cpu="${var_cpu:-1}"
|
||||
var_ram="${var_ram:-1024}"
|
||||
var_disk="${var_disk:-20}"
|
||||
var_os="${var_os:-debian}"
|
||||
var_version="${var_version:-13}"
|
||||
var_arm64="${var_arm64:-yes}"
|
||||
var_unprivileged="${var_unprivileged:-1}"
|
||||
|
||||
header_info "$APP"
|
||||
variables
|
||||
color
|
||||
catch_errors
|
||||
|
||||
function update_script() {
|
||||
header_info
|
||||
check_container_storage
|
||||
check_container_resources
|
||||
|
||||
if [[ ! -f /usr/local/bin/hister ]]; then
|
||||
msg_error "No ${APP} Installation Found!"
|
||||
exit
|
||||
fi
|
||||
|
||||
if check_for_gh_release "hister" "asciimoo/hister"; then
|
||||
msg_info "Stopping Service"
|
||||
systemctl stop hister
|
||||
msg_ok "Stopped Service"
|
||||
|
||||
fetch_and_deploy_gh_release "hister" "asciimoo/hister" "singlefile" "latest" "/usr/local/bin" "hister_*_linux_$(arch_resolve)"
|
||||
|
||||
msg_info "Starting Service"
|
||||
systemctl start hister
|
||||
msg_ok "Started Service"
|
||||
msg_ok "Updated successfully!"
|
||||
fi
|
||||
exit
|
||||
}
|
||||
|
||||
start
|
||||
build_container
|
||||
description
|
||||
|
||||
msg_ok "Completed Successfully!\n"
|
||||
echo -e "${CREATING}${GN}${APP} setup has been successfully initialized!${CL}"
|
||||
echo -e "${INFO}${YW}Access it using the following URL:${CL}"
|
||||
echo -e "${GATEWAY}${BGN}http://${IP}:4433${CL}"
|
||||
msg_error "This script is no longer available."
|
||||
msg_warn "Hister has been renamed to Nogon."
|
||||
msg_warn "Run the Nogon script to migrate an existing installation:"
|
||||
echo 'bash -c "$(curl -fsSL https://raw.githubusercontent.com/community-scripts/ProxmoxVE/main/ct/nogon.sh)"'
|
||||
exit 1
|
||||
+89
@@ -0,0 +1,89 @@
|
||||
#!/usr/bin/env bash
|
||||
_cs_boot="${COMMUNITY_SCRIPTS_CORE_DIR:-$(dirname "${BASH_SOURCE[0]}")/../../core}/core/build.func"
|
||||
source "$_cs_boot" 2>/dev/null || source <(curl -fsSL "${COMMUNITY_SCRIPTS_CORE_URL:-https://raw.githubusercontent.com/community-scripts/core/main}/core/build.func")
|
||||
# Copyright (c) 2021-2026 community-scripts ORG
|
||||
# Author: MickLesk (CanbiZ)
|
||||
# License: MIT | https://github.com/community-scripts/ProxmoxVE/raw/main/LICENSE
|
||||
# Source: https://github.com/zoriya/Kyoo
|
||||
|
||||
APP="Kyoo"
|
||||
var_tags="${var_tags:-media;streaming}"
|
||||
var_cpu="${var_cpu:-4}"
|
||||
var_ram="${var_ram:-4096}"
|
||||
var_disk="${var_disk:-16}"
|
||||
var_os="${var_os:-debian}"
|
||||
var_version="${var_version:-13}"
|
||||
var_arm64="${var_arm64:-yes}"
|
||||
var_gpu="${var_gpu:-yes}"
|
||||
var_unprivileged="${var_unprivileged:-1}"
|
||||
|
||||
header_info "$APP"
|
||||
variables
|
||||
color
|
||||
catch_errors
|
||||
|
||||
function update_script() {
|
||||
header_info
|
||||
check_container_storage
|
||||
check_container_resources
|
||||
|
||||
if [[ ! -d /opt/kyoo ]]; then
|
||||
msg_error "No Kyoo Installation Found!"
|
||||
exit
|
||||
fi
|
||||
|
||||
if check_for_gh_release "kyoo" "zoriya/Kyoo"; then
|
||||
msg_info "Stopping Kyoo"
|
||||
systemctl stop kyoo-scanner kyoo-api kyoo-transcoder kyoo-auth
|
||||
msg_ok "Stopped Kyoo"
|
||||
|
||||
setup_go
|
||||
PYTHON_VERSION="3.14" setup_uv
|
||||
NODE_VERSION="24" NODE_MODULE="bun" setup_nodejs
|
||||
CLEAN_INSTALL=1 fetch_and_deploy_gh_release "kyoo" "zoriya/Kyoo" "tarball"
|
||||
|
||||
msg_info "Building Kyoo Auth"
|
||||
cd /opt/kyoo/auth
|
||||
$STD go build -o keibi
|
||||
msg_ok "Built Kyoo Auth"
|
||||
|
||||
msg_info "Building Kyoo Transcoder"
|
||||
cd /opt/kyoo/transcoder
|
||||
$STD go build -o transcoder
|
||||
msg_ok "Built Kyoo Transcoder"
|
||||
|
||||
msg_info "Building Kyoo API"
|
||||
cd /opt/kyoo/api
|
||||
$STD bun install --production
|
||||
$STD bun build --compile --compile-autoload-package-json --minify-whitespace --minify-syntax --target bun --outfile server ./src/index.ts
|
||||
msg_ok "Built Kyoo API"
|
||||
|
||||
msg_info "Setting up Kyoo Scanner"
|
||||
cd /opt/kyoo/scanner
|
||||
$STD uv sync --locked --python 3.14
|
||||
msg_ok "Set up Kyoo Scanner"
|
||||
|
||||
msg_info "Building Kyoo Web App"
|
||||
cd /opt/kyoo/front
|
||||
NODE_ENV=production $STD bun install --production
|
||||
$STD bun run web
|
||||
rm -rf /opt/kyoo/front/node_modules ~/.bun/install/cache
|
||||
msg_ok "Built Kyoo Web App"
|
||||
|
||||
msg_info "Starting Kyoo"
|
||||
systemctl start kyoo-auth kyoo-transcoder kyoo-api kyoo-scanner
|
||||
msg_ok "Started Kyoo"
|
||||
msg_ok "Updated successfully!"
|
||||
fi
|
||||
exit
|
||||
}
|
||||
|
||||
start
|
||||
build_container
|
||||
description
|
||||
|
||||
msg_ok "Completed Successfully!\n"
|
||||
echo -e "${CREATING}${GN}${APP} setup has been successfully initialized!${CL}"
|
||||
echo -e "${INFO}${YW}Access it using the following URL:${CL}"
|
||||
echo -e "${GATEWAY}${BGN}https://${IP}${CL}"
|
||||
echo -e "${INFO}${YW}The library stays empty until videos are in /opt/kyoo_data/media (e.g. pct set <CTID> -mp0 /path/to/media,mp=/opt/kyoo_data/media)${CL}"
|
||||
Executable
+55
@@ -0,0 +1,55 @@
|
||||
#!/usr/bin/env bash
|
||||
# Engine comes from community-scripts/core; this repo only ships the scripts.
|
||||
# A local core checkout wins (COMMUNITY_SCRIPTS_CORE_DIR, else a sibling ../core),
|
||||
# so a fork or branch of core can be tested without editing this file.
|
||||
_cs_boot="${COMMUNITY_SCRIPTS_CORE_DIR:-$(dirname "${BASH_SOURCE[0]}")/../../core}/core/build.func"
|
||||
source "$_cs_boot" 2>/dev/null || source <(curl -fsSL "${COMMUNITY_SCRIPTS_CORE_URL:-https://raw.githubusercontent.com/community-scripts/core/main}/core/build.func")
|
||||
# Copyright (c) 2021-2026 community-scripts ORG
|
||||
# Author: Nick Berardi (nberardi)
|
||||
# License: MIT | https://github.com/community-scripts/ProxmoxVE/raw/main/LICENSE
|
||||
# Source: https://nextdns.io | https://github.com/nextdns/nextdns
|
||||
|
||||
APP="NextDNS"
|
||||
var_tags="${var_tags:-dns;adblock;network}"
|
||||
var_cpu="${var_cpu:-1}"
|
||||
var_ram="${var_ram:-512}"
|
||||
var_disk="${var_disk:-2}"
|
||||
var_os="${var_os:-debian}"
|
||||
var_version="${var_version:-13}"
|
||||
#var_arm64="${var_arm64:-no}" # unset = ask the user; set yes/no only when verified
|
||||
var_unprivileged="${var_unprivileged:-1}"
|
||||
export var_nextdns_profile="${var_nextdns_profile:-}"
|
||||
|
||||
header_info "$APP"
|
||||
variables
|
||||
color
|
||||
catch_errors
|
||||
|
||||
function update_script() {
|
||||
header_info
|
||||
check_container_storage
|
||||
check_container_resources
|
||||
|
||||
if [[ ! -x /usr/bin/nextdns ]]; then
|
||||
msg_error "No ${APP} Installation Found!"
|
||||
exit
|
||||
fi
|
||||
|
||||
msg_info "Updating ${APP}"
|
||||
$STD apt update
|
||||
$STD apt install -y nextdns
|
||||
msg_ok "Updated ${APP}"
|
||||
msg_ok "Updated successfully!"
|
||||
exit
|
||||
}
|
||||
|
||||
start
|
||||
build_container
|
||||
description
|
||||
|
||||
msg_ok "Completed Successfully!\n"
|
||||
echo -e "${CREATING}${GN}${APP} setup has been successfully initialized!${CL}"
|
||||
echo -e "${INFO}${YW}NextDNS is configured and serving DNS on:${CL}"
|
||||
echo -e "${GATEWAY}${BGN}${IP}:53${CL} ${YW}(TCP/UDP)${CL}"
|
||||
echo -e "${INFO}${YW}Profiles are managed at: https://my.nextdns.io${CL}"
|
||||
echo -e "${INFO}${YW}Point DHCP clients or your router upstream DNS at the container IP.${CL}"
|
||||
+1
-10
@@ -61,20 +61,11 @@ function update_script() {
|
||||
fi
|
||||
$STD apt install -y build-essential "$pcre_pkg" libssl-dev zlib1g-dev
|
||||
|
||||
OPENRESTY_VERSION="1.31.8.1"
|
||||
OPENRESTY_VERSION="1.31.9.1"
|
||||
if [[ "$(cat ~/.openresty 2>/dev/null)" != "$OPENRESTY_VERSION" ]]; then
|
||||
CLEAN_INSTALL=1 fetch_and_deploy_from_url "https://openresty.org/download/openresty-${OPENRESTY_VERSION}.tar.gz" "/opt/openresty" ||
|
||||
CLEAN_INSTALL=1 fetch_and_deploy_from_url "https://distfiles.alpinelinux.org/distfiles/edge/openresty-${OPENRESTY_VERSION}.tar.gz" "/opt/openresty"
|
||||
|
||||
msg_info "Patching nginx HTTP/2 (CVE-2026-123007, CVE-2026-123633)"
|
||||
for commit in 61031503dc8087c2c17cd2142c9b4b19062f90c4 2df48a501d0fb8212b7d39dffeeff5876332ba59 e27f5fa84fe6e98505e70bc543b748747dad0a3b; do
|
||||
curl_with_retry "https://api.github.com/repos/nginx/nginx/commits/${commit}" "/tmp/nginx-${commit}.patch" "-HAccept:application/vnd.github.patch" ||
|
||||
curl_with_retry "https://github.com/nginx/nginx/commit/${commit}.patch" "/tmp/nginx-${commit}.patch"
|
||||
patch -d /opt/openresty/bundle/nginx-1.31.8 -p1 --forward -s <"/tmp/nginx-${commit}.patch"
|
||||
rm -f "/tmp/nginx-${commit}.patch"
|
||||
done
|
||||
msg_ok "Patched nginx HTTP/2"
|
||||
|
||||
msg_info "Building OpenResty"
|
||||
cd /opt/openresty
|
||||
$STD ./configure \
|
||||
|
||||
+89
@@ -0,0 +1,89 @@
|
||||
#!/usr/bin/env bash
|
||||
_cs_boot="${COMMUNITY_SCRIPTS_CORE_DIR:-$(dirname "${BASH_SOURCE[0]}")/../../core}/core/build.func"
|
||||
source "$_cs_boot" 2>/dev/null || source <(curl -fsSL "${COMMUNITY_SCRIPTS_CORE_URL:-https://raw.githubusercontent.com/community-scripts/core/main}/core/build.func")
|
||||
# Copyright (c) 2021-2026 community-scripts ORG
|
||||
# Author: MickLesk (CanbiZ)
|
||||
# License: MIT | https://github.com/community-scripts/ProxmoxVE/raw/main/LICENSE
|
||||
# Source: https://github.com/asciimoo/nogon
|
||||
|
||||
APP="Nogon"
|
||||
var_tags="${var_tags:-search;browser-history;personal}"
|
||||
var_cpu="${var_cpu:-1}"
|
||||
var_ram="${var_ram:-1024}"
|
||||
var_disk="${var_disk:-20}"
|
||||
var_os="${var_os:-debian}"
|
||||
var_version="${var_version:-13}"
|
||||
var_arm64="${var_arm64:-yes}"
|
||||
var_unprivileged="${var_unprivileged:-1}"
|
||||
|
||||
header_info "$APP"
|
||||
variables
|
||||
color
|
||||
catch_errors
|
||||
|
||||
function update_script() {
|
||||
header_info
|
||||
check_container_storage
|
||||
check_container_resources
|
||||
|
||||
if [[ ! -f /usr/local/bin/nogon && ! -f /usr/local/bin/hister ]]; then
|
||||
msg_error "No ${APP} Installation Found!"
|
||||
exit
|
||||
fi
|
||||
|
||||
MIGRATING=false
|
||||
[[ -f /usr/local/bin/hister ]] && MIGRATING=true
|
||||
|
||||
if [[ "$MIGRATING" == "true" ]] || check_for_gh_release "nogon" "asciimoo/nogon"; then
|
||||
msg_info "Stopping Service"
|
||||
if [[ "$MIGRATING" == "true" ]]; then
|
||||
systemctl disable -q --now hister
|
||||
else
|
||||
systemctl stop nogon
|
||||
fi
|
||||
msg_ok "Stopped Service"
|
||||
|
||||
fetch_and_deploy_gh_release "nogon" "asciimoo/nogon" "singlefile" "latest" "/usr/local/bin" "nogon_*_linux_$(arch_resolve)"
|
||||
|
||||
if [[ "$MIGRATING" == "true" ]]; then
|
||||
msg_info "Migrating Hister to Nogon"
|
||||
CONFIG_FILE=/etc/nogon/config.yaml
|
||||
[[ -f /etc/hister/config.yaml ]] && CONFIG_FILE=/etc/hister/config.yaml
|
||||
cat <<EOF >/etc/systemd/system/nogon.service
|
||||
[Unit]
|
||||
Description=Nogon Search Engine
|
||||
After=network.target
|
||||
|
||||
[Service]
|
||||
Type=simple
|
||||
User=root
|
||||
ExecStart=/usr/local/bin/nogon listen --config ${CONFIG_FILE}
|
||||
Restart=on-failure
|
||||
RestartSec=5
|
||||
|
||||
[Install]
|
||||
WantedBy=multi-user.target
|
||||
EOF
|
||||
rm -f /etc/systemd/system/hister.service /usr/local/bin/hister ~/.hister
|
||||
systemctl daemon-reload
|
||||
systemctl enable -q nogon
|
||||
sed -i 's/hister/nogon/g' /usr/bin/update
|
||||
msg_ok "Migrated Hister to Nogon"
|
||||
fi
|
||||
|
||||
msg_info "Starting Service"
|
||||
systemctl start nogon
|
||||
msg_ok "Started Service"
|
||||
msg_ok "Updated successfully!"
|
||||
fi
|
||||
exit
|
||||
}
|
||||
|
||||
start
|
||||
build_container
|
||||
description
|
||||
|
||||
msg_ok "Completed Successfully!\n"
|
||||
echo -e "${CREATING}${GN}${APP} setup has been successfully initialized!${CL}"
|
||||
echo -e "${INFO}${YW}Access it using the following URL:${CL}"
|
||||
echo -e "${GATEWAY}${BGN}http://${IP}:4433${CL}"
|
||||
+8
-2
@@ -38,9 +38,15 @@ function update_script() {
|
||||
fi
|
||||
|
||||
if dpkg -s wkhtmltopdf &>/dev/null; then
|
||||
systemctl stop odoo
|
||||
$STD apt remove --purge -y wkhtmltopdf
|
||||
fetch_and_deploy_gh_release "wkhtmltopdf" "wkhtmltopdf/packaging" "binary" "latest" "" "wkhtmltox_*.bookworm_$(arch_resolve).deb"
|
||||
fi
|
||||
if dpkg -s wkhtmltox &>/dev/null; then
|
||||
$STD apt remove --purge -y wkhtmltox
|
||||
fi
|
||||
|
||||
if [[ ! -f ~/.pdfkiln ]] || check_for_gh_release "pdfkiln" "pdfkiln/pdfkiln"; then
|
||||
systemctl stop odoo
|
||||
fetch_and_deploy_gh_release "pdfkiln" "pdfkiln/pdfkiln" "binary" "latest" "" "pdfkiln_*_$(arch_resolve).deb"
|
||||
systemctl start odoo
|
||||
fi
|
||||
|
||||
|
||||
@@ -0,0 +1,74 @@
|
||||
#!/usr/bin/env bash
|
||||
_cs_boot="${COMMUNITY_SCRIPTS_CORE_DIR:-$(dirname "${BASH_SOURCE[0]}")/../../core}/core/build.func"
|
||||
source "$_cs_boot" 2>/dev/null || source <(curl -fsSL "${COMMUNITY_SCRIPTS_CORE_URL:-https://raw.githubusercontent.com/community-scripts/core/main}/core/build.func")
|
||||
# Copyright (c) 2021-2026 community-scripts ORG
|
||||
# Author: MickLesk (CanbiZ)
|
||||
# License: MIT | https://github.com/community-scripts/ProxmoxVE/raw/main/LICENSE
|
||||
# Source: https://github.com/sebadob/rauthy
|
||||
|
||||
APP="Rauthy"
|
||||
var_tags="${var_tags:-auth;sso;oidc}"
|
||||
var_cpu="${var_cpu:-4}"
|
||||
var_ram="${var_ram:-6144}"
|
||||
var_disk="${var_disk:-12}"
|
||||
var_os="${var_os:-debian}"
|
||||
var_version="${var_version:-13}"
|
||||
var_arm64="${var_arm64:-yes}"
|
||||
var_unprivileged="${var_unprivileged:-1}"
|
||||
|
||||
header_info "$APP"
|
||||
variables
|
||||
color
|
||||
catch_errors
|
||||
|
||||
function update_script() {
|
||||
header_info
|
||||
check_container_storage
|
||||
check_container_resources
|
||||
|
||||
if [[ ! -f /opt/rauthy/rauthy ]]; then
|
||||
msg_error "No ${APP} Installation Found!"
|
||||
exit
|
||||
fi
|
||||
|
||||
if check_for_gh_release "rauthy" "sebadob/rauthy"; then
|
||||
setup_rust
|
||||
fetch_and_deploy_gh_release "rauthy" "sebadob/rauthy" "tarball" "latest" "/opt/rauthy-build"
|
||||
|
||||
msg_info "Building Rauthy (Patience)"
|
||||
cd /opt/rauthy-build
|
||||
tar -xf assets/static_html/static_v1.tar.gz
|
||||
tar -xf assets/static_html/templates_html.tar.gz
|
||||
if ! CURL_RETRIES=8 curl_with_retry "https://mds.fidoalliance.org/" "/opt/rauthy-build/mds.jwt"; then
|
||||
rm -rf /opt/rauthy-build
|
||||
msg_error "The FIDO MDS download was rate-limited (HTTP 429); Rauthy was not changed, try the update again later"
|
||||
exit 7
|
||||
fi
|
||||
CARGO_PROFILE_DEV_DEBUG=0 $STD cargo run --bin fido-mds-prep -- --source mds.jwt
|
||||
CARGO_PROFILE_RELEASE_LTO=thin CARGO_PROFILE_RELEASE_CODEGEN_UNITS=16 \
|
||||
$STD cargo build --release --bin rauthy
|
||||
msg_ok "Built Rauthy"
|
||||
|
||||
msg_info "Stopping Rauthy"
|
||||
systemctl stop rauthy
|
||||
mv /opt/rauthy-build/target/release/rauthy /opt/rauthy/rauthy
|
||||
cd /opt
|
||||
rm -rf /opt/rauthy-build ~/.cargo/registry
|
||||
msg_ok "Stopped Rauthy"
|
||||
|
||||
msg_info "Starting Rauthy"
|
||||
systemctl start rauthy
|
||||
msg_ok "Started Rauthy"
|
||||
msg_ok "Updated successfully!"
|
||||
fi
|
||||
exit
|
||||
}
|
||||
|
||||
start
|
||||
build_container
|
||||
description
|
||||
|
||||
msg_ok "Completed Successfully!\n"
|
||||
echo -e "${CREATING}${GN}${APP} setup has been successfully initialized!${CL}"
|
||||
echo -e "${INFO}${YW}Access it using the following URL:${CL}"
|
||||
echo -e "${GATEWAY}${BGN}https://${IP}:8443/auth/v1/${CL}"
|
||||
+5
-1
@@ -58,8 +58,12 @@ update_alpine() {
|
||||
msg_ok "Updated Alpine Packages"
|
||||
|
||||
msg_info "Updating traefik from edge"
|
||||
$STD apk add traefik --repository=https://dl-cdn.alpinelinux.org/alpine/edge/community
|
||||
$STD apk upgrade traefik --repository=https://dl-cdn.alpinelinux.org/alpine/edge/community
|
||||
msg_ok "Updated traefik"
|
||||
|
||||
msg_info "Restarting traefik"
|
||||
$STD rc-service traefik restart
|
||||
msg_ok "Restarted traefik"
|
||||
msg_ok "Updated successfully!"
|
||||
}
|
||||
|
||||
|
||||
@@ -0,0 +1,70 @@
|
||||
#!/usr/bin/env bash
|
||||
_cs_boot="${COMMUNITY_SCRIPTS_CORE_DIR:-$(dirname "${BASH_SOURCE[0]}")/../../core}/core/build.func"
|
||||
source "$_cs_boot" 2>/dev/null || source <(curl -fsSL "${COMMUNITY_SCRIPTS_CORE_URL:-https://raw.githubusercontent.com/community-scripts/core/main}/core/build.func")
|
||||
# Copyright (c) 2021-2026 community-scripts ORG
|
||||
# Author: MickLesk (CanbiZ)
|
||||
# License: MIT | https://github.com/community-scripts/ProxmoxVE/raw/main/LICENSE
|
||||
# Source: https://github.com/typecho/typecho
|
||||
|
||||
APP="Typecho"
|
||||
var_tags="${var_tags:-blog;cms}"
|
||||
var_cpu="${var_cpu:-1}"
|
||||
var_ram="${var_ram:-512}"
|
||||
var_disk="${var_disk:-4}"
|
||||
var_os="${var_os:-debian}"
|
||||
var_version="${var_version:-13}"
|
||||
var_arm64="${var_arm64:-yes}"
|
||||
var_unprivileged="${var_unprivileged:-1}"
|
||||
|
||||
export var_admin_user="${var_admin_user:-admin}"
|
||||
export var_admin_pass="${var_admin_pass:-$(random_password)}"
|
||||
|
||||
header_info "$APP"
|
||||
variables
|
||||
color
|
||||
catch_errors
|
||||
|
||||
function update_script() {
|
||||
header_info
|
||||
check_container_storage
|
||||
check_container_resources
|
||||
|
||||
if [[ ! -d /opt/typecho ]]; then
|
||||
msg_error "No ${APP} Installation Found!"
|
||||
exit
|
||||
fi
|
||||
|
||||
if check_for_gh_release "typecho" "typecho/typecho"; then
|
||||
msg_info "Stopping Typecho"
|
||||
systemctl stop nginx
|
||||
msg_ok "Stopped Typecho"
|
||||
|
||||
CLEAN_INSTALL=1 fetch_and_deploy_gh_release "typecho" "typecho/typecho" "prebuild" "latest" "/opt/typecho" "typecho.zip"
|
||||
fetch_and_deploy_from_url "https://github.com/typecho/languages/releases/download/ci/langs.zip" "/opt/typecho_data/usr/langs"
|
||||
|
||||
msg_info "Linking Typecho Data"
|
||||
rm -rf /opt/typecho/usr /opt/typecho/install.php
|
||||
ln -s /opt/typecho_data/usr /opt/typecho/usr
|
||||
ln -s /opt/typecho_data/config.inc.php /opt/typecho/config.inc.php
|
||||
msg_ok "Linked Typecho Data"
|
||||
|
||||
msg_info "Starting Typecho"
|
||||
systemctl start nginx
|
||||
msg_ok "Started Typecho"
|
||||
msg_ok "Updated successfully!"
|
||||
echo -e "${INFO}${YW}Open http://${LOCAL_IP}/admin/ and confirm the database upgrade if Typecho asks for one${CL}"
|
||||
fi
|
||||
exit
|
||||
}
|
||||
|
||||
start
|
||||
build_container
|
||||
description
|
||||
|
||||
msg_ok "Completed Successfully!\n"
|
||||
echo -e "${CREATING}${GN}${APP} setup has been successfully initialized!${CL}"
|
||||
echo -e "${INFO}${YW}Access it using the following URL:${CL}"
|
||||
echo -e "${GATEWAY}${BGN}http://${IP}${CL}"
|
||||
echo -e "${INFO}${YW}Admin panel: http://${IP}/admin/${CL}"
|
||||
echo -e "${INFO}${YW}Admin Username: ${var_admin_user}${CL}"
|
||||
echo -e "${INFO}${YW}Admin Password: ${var_admin_pass}${CL}"
|
||||
@@ -0,0 +1,59 @@
|
||||
#!/usr/bin/env bash
|
||||
_cs_boot="${COMMUNITY_SCRIPTS_CORE_DIR:-$(dirname "${BASH_SOURCE[0]}")/../../core}/core/build.func"
|
||||
source "$_cs_boot" 2>/dev/null || source <(curl -fsSL "${COMMUNITY_SCRIPTS_CORE_URL:-https://raw.githubusercontent.com/community-scripts/core/main}/core/build.func")
|
||||
# Copyright (c) 2021-2026 community-scripts ORG
|
||||
# Author: MickLesk (CanbiZ)
|
||||
# License: MIT | https://github.com/community-scripts/ProxmoxVE/raw/main/LICENSE
|
||||
# Source: https://github.com/windmill-labs/windmill
|
||||
|
||||
APP="Windmill"
|
||||
var_tags="${var_tags:-automation;workflow;scripts}"
|
||||
var_cpu="${var_cpu:-2}"
|
||||
var_ram="${var_ram:-2048}"
|
||||
var_disk="${var_disk:-10}"
|
||||
var_os="${var_os:-debian}"
|
||||
var_version="${var_version:-13}"
|
||||
var_arm64="${var_arm64:-no}" # upstream ships the CE binary for amd64 only
|
||||
var_unprivileged="${var_unprivileged:-1}"
|
||||
|
||||
header_info "$APP"
|
||||
variables
|
||||
color
|
||||
catch_errors
|
||||
|
||||
function update_script() {
|
||||
header_info
|
||||
check_container_storage
|
||||
check_container_resources
|
||||
|
||||
if [[ ! -f /opt/windmill/windmill ]]; then
|
||||
msg_error "No ${APP} Installation Found!"
|
||||
exit
|
||||
fi
|
||||
|
||||
if check_for_gh_release "windmill" "windmill-labs/windmill"; then
|
||||
msg_info "Stopping Windmill"
|
||||
systemctl stop windmill
|
||||
msg_ok "Stopped Windmill"
|
||||
|
||||
setup_uv
|
||||
NODE_VERSION="24" NODE_MODULE="bun" setup_nodejs
|
||||
fetch_and_deploy_gh_release "windmill" "windmill-labs/windmill" "singlefile" "latest" "/opt/windmill" "windmill-amd64"
|
||||
USE_ORIGINAL_FILENAME="true" fetch_and_deploy_gh_release "windmill-duckdb" "windmill-labs/windmill" "singlefile" "latest" "/opt/windmill" "windmill_duckdb_runner"
|
||||
|
||||
msg_info "Starting Windmill"
|
||||
systemctl start windmill
|
||||
msg_ok "Started Windmill"
|
||||
msg_ok "Updated successfully!"
|
||||
fi
|
||||
exit
|
||||
}
|
||||
|
||||
start
|
||||
build_container
|
||||
description
|
||||
|
||||
msg_ok "Completed Successfully!\n"
|
||||
echo -e "${CREATING}${GN}${APP} setup has been successfully initialized!${CL}"
|
||||
echo -e "${INFO}${YW}Access it using the following URL:${CL}"
|
||||
echo -e "${GATEWAY}${BGN}http://${IP}:8000${CL}"
|
||||
@@ -0,0 +1,79 @@
|
||||
#!/usr/bin/env bash
|
||||
_cs_boot="${COMMUNITY_SCRIPTS_CORE_DIR:-$(dirname "${BASH_SOURCE[0]}")/../../core}/core/build.func"
|
||||
source "$_cs_boot" 2>/dev/null || source <(curl -fsSL "${COMMUNITY_SCRIPTS_CORE_URL:-https://raw.githubusercontent.com/community-scripts/core/main}/core/build.func")
|
||||
# Copyright (c) 2021-2026 community-scripts ORG
|
||||
# Author: MickLesk (CanbiZ)
|
||||
# License: MIT | https://github.com/community-scripts/ProxmoxVE/raw/main/LICENSE
|
||||
# Source: https://github.com/woodpecker-ci/woodpecker
|
||||
|
||||
APP="Woodpecker-CI"
|
||||
var_tags="${var_tags:-ci;devops;git}"
|
||||
var_cpu="${var_cpu:-2}"
|
||||
var_ram="${var_ram:-2048}"
|
||||
var_disk="${var_disk:-10}"
|
||||
var_os="${var_os:-debian}"
|
||||
var_version="${var_version:-13}"
|
||||
var_arm64="${var_arm64:-yes}"
|
||||
var_unprivileged="${var_unprivileged:-1}"
|
||||
|
||||
export var_forge="${var_forge:-}"
|
||||
export var_forge_url="${var_forge_url:-}"
|
||||
export var_forge_client="${var_forge_client:-}"
|
||||
export var_forge_secret="${var_forge_secret:-}"
|
||||
export var_forge_admin="${var_forge_admin:-}"
|
||||
|
||||
if [[ -n "${var_forge}" ]]; then
|
||||
if [[ ! "${var_forge}" =~ ^(forgejo|gitea|github|gitlab|bitbucket)$ ]] ||
|
||||
[[ -z "${var_forge_client}" || -z "${var_forge_secret}" || -z "${var_forge_admin}" ]] ||
|
||||
[[ "${var_forge}" =~ ^(forgejo|gitea)$ && -z "${var_forge_url}" ]]; then
|
||||
msg_error "var_forge must be forgejo, gitea, github, gitlab or bitbucket and needs var_forge_client, var_forge_secret and var_forge_admin (Forgejo and Gitea also var_forge_url)"
|
||||
exit 1
|
||||
fi
|
||||
fi
|
||||
|
||||
header_info "$APP"
|
||||
variables
|
||||
color
|
||||
catch_errors
|
||||
|
||||
function update_script() {
|
||||
header_info
|
||||
check_container_storage
|
||||
check_container_resources
|
||||
|
||||
if [[ ! -d /opt/woodpecker ]]; then
|
||||
msg_error "No ${APP} Installation Found!"
|
||||
exit
|
||||
fi
|
||||
|
||||
if check_for_gh_release "woodpecker-server" "woodpecker-ci/woodpecker"; then
|
||||
msg_info "Stopping Woodpecker CI"
|
||||
systemctl stop woodpecker-agent woodpecker-server
|
||||
msg_ok "Stopped Woodpecker CI"
|
||||
|
||||
fetch_and_deploy_gh_release "woodpecker-server" "woodpecker-ci/woodpecker" "prebuild" "latest" "/opt/woodpecker" "woodpecker-server_linux_$(arch_resolve).tar.gz"
|
||||
fetch_and_deploy_gh_release "woodpecker-agent" "woodpecker-ci/woodpecker" "prebuild" "latest" "/opt/woodpecker" "woodpecker-agent_linux_$(arch_resolve).tar.gz"
|
||||
fetch_and_deploy_gh_release "plugin-git" "woodpecker-ci/plugin-git" "singlefile" "latest" "/usr/local/bin" "linux-$(arch_resolve)_plugin-git"
|
||||
|
||||
msg_info "Starting Woodpecker CI"
|
||||
systemctl start woodpecker-server woodpecker-agent
|
||||
msg_ok "Started Woodpecker CI"
|
||||
msg_ok "Updated successfully!"
|
||||
fi
|
||||
exit
|
||||
}
|
||||
|
||||
start
|
||||
build_container
|
||||
description
|
||||
|
||||
msg_ok "Completed Successfully!\n"
|
||||
echo -e "${CREATING}${GN}${APP} setup has been successfully initialized!${CL}"
|
||||
if [[ -z "${var_forge}" ]]; then
|
||||
echo -e "${INFO}${YW}Woodpecker CI signs in through a forge. Create an OAuth app on Forgejo, Gitea, GitHub, GitLab or Bitbucket with the callback URL:${CL}"
|
||||
echo -e "${TAB}${BGN}http://${IP}:8000/authorize${CL}"
|
||||
echo -e "${INFO}${YW}Fill in the forge block and WOODPECKER_ADMIN in /opt/woodpecker_data/server.env, then start Woodpecker CI:${CL}"
|
||||
echo -e "${TAB}${BGN}systemctl enable --now woodpecker-server woodpecker-agent${CL}"
|
||||
fi
|
||||
echo -e "${INFO}${YW}Access it using the following URL:${CL}"
|
||||
echo -e "${GATEWAY}${BGN}http://${IP}:8000${CL}"
|
||||
@@ -0,0 +1,111 @@
|
||||
#!/usr/bin/env bash
|
||||
|
||||
# Copyright (c) 2021-2026 community-scripts ORG
|
||||
# Author: MickLesk (CanbiZ)
|
||||
# License: MIT | https://github.com/community-scripts/ProxmoxVE/raw/main/LICENSE
|
||||
# Source: https://github.com/JMS1717/8mb.local
|
||||
|
||||
source /dev/stdin <<<"$FUNCTIONS_FILE_PATH"
|
||||
color
|
||||
verb_ip6
|
||||
catch_errors
|
||||
setting_up_container
|
||||
network_check
|
||||
update_os
|
||||
setup_hwaccel
|
||||
|
||||
msg_info "Installing Dependencies"
|
||||
$STD apt install -y redis-server
|
||||
msg_ok "Installed Dependencies"
|
||||
|
||||
setup_ffmpeg
|
||||
NODE_VERSION="22" setup_nodejs
|
||||
PYTHON_VERSION="3.12" setup_uv
|
||||
|
||||
fetch_and_deploy_gh_release "8mblocal" "JMS1717/8mb.local" "tarball"
|
||||
|
||||
msg_info "Building 8mb.local"
|
||||
mv /opt/8mblocal /opt/8mblocal-build
|
||||
cd /opt/8mblocal-build/frontend
|
||||
$STD npm ci
|
||||
$STD npm run build
|
||||
# Same layout as the official image: the worker imports backend.history_manager and Celery includes worker.worker
|
||||
mkdir -p /opt/8mblocal
|
||||
mv /opt/8mblocal-build/backend-api/app /opt/8mblocal/backend
|
||||
mv /opt/8mblocal-build/worker/app /opt/8mblocal/worker
|
||||
mv /opt/8mblocal-build/shared /opt/8mblocal-build/requirements.txt /opt/8mblocal/
|
||||
mv /opt/8mblocal-build/frontend/build /opt/8mblocal/frontend-build
|
||||
rm -rf /opt/8mblocal-build
|
||||
cd /opt/8mblocal
|
||||
$STD uv venv --python 3.12 .venv
|
||||
$STD uv pip install --python .venv/bin/python -r requirements.txt packaging
|
||||
msg_ok "Built 8mb.local"
|
||||
|
||||
msg_info "Configuring 8mb.local"
|
||||
mkdir -p /opt/8mblocal_data/{uploads/.tmp,outputs,state}
|
||||
cat <<EOF >/opt/8mblocal_data/.env
|
||||
AUTH_ENABLED=true
|
||||
AUTH_USER=admin
|
||||
AUTH_PASS=$(random_password)
|
||||
FILE_RETENTION_HOURS=1
|
||||
MEDIA_STORAGE=disk
|
||||
WORKER_CONCURRENCY=auto
|
||||
HISTORY_ENABLED=true
|
||||
REDIS_URL=redis://127.0.0.1:6379/0
|
||||
APP_DATA_DIR=/opt/8mblocal_data
|
||||
ENV_FILE=/opt/8mblocal_data/.env
|
||||
SETTINGS_FILE=/opt/8mblocal_data/state/settings.json
|
||||
HISTORY_FILE=/opt/8mblocal_data/state/history.json
|
||||
TMPDIR=/opt/8mblocal_data/uploads/.tmp
|
||||
FRONTEND_BUILD_DIR=/opt/8mblocal/frontend-build
|
||||
BACKEND_APP_ROOT=/opt/8mblocal
|
||||
EOF
|
||||
chmod 600 /opt/8mblocal_data/.env
|
||||
msg_ok "Configured 8mb.local"
|
||||
|
||||
msg_info "Creating Services"
|
||||
cat <<EOF >/etc/systemd/system/8mblocal-worker.service
|
||||
[Unit]
|
||||
Description=8mb.local Worker
|
||||
After=network.target redis-server.service
|
||||
Requires=redis-server.service
|
||||
|
||||
[Service]
|
||||
Type=simple
|
||||
User=root
|
||||
WorkingDirectory=/opt/8mblocal
|
||||
EnvironmentFile=/opt/8mblocal_data/.env
|
||||
Environment=PYTHONPATH=/opt/8mblocal
|
||||
ExecStart=/opt/8mblocal/.venv/bin/celery -A worker.celery_app worker --loglevel=info
|
||||
Restart=on-failure
|
||||
RestartSec=5
|
||||
|
||||
[Install]
|
||||
WantedBy=multi-user.target
|
||||
EOF
|
||||
cat <<EOF >/etc/systemd/system/8mblocal.service
|
||||
[Unit]
|
||||
Description=8mb.local
|
||||
After=network.target redis-server.service 8mblocal-worker.service
|
||||
Requires=redis-server.service
|
||||
Wants=8mblocal-worker.service
|
||||
|
||||
[Service]
|
||||
Type=simple
|
||||
User=root
|
||||
WorkingDirectory=/opt/8mblocal
|
||||
EnvironmentFile=/opt/8mblocal_data/.env
|
||||
Environment=PYTHONPATH=/opt/8mblocal
|
||||
ExecStart=/opt/8mblocal/.venv/bin/uvicorn backend.main:app --host 0.0.0.0 --port 8001
|
||||
Restart=on-failure
|
||||
RestartSec=5
|
||||
|
||||
[Install]
|
||||
WantedBy=multi-user.target
|
||||
EOF
|
||||
systemctl enable -q --now 8mblocal-worker 8mblocal
|
||||
msg_ok "Created Services"
|
||||
|
||||
motd_ssh
|
||||
customize
|
||||
cleanup_lxc
|
||||
@@ -0,0 +1,114 @@
|
||||
#!/usr/bin/env bash
|
||||
|
||||
# Copyright (c) 2021-2026 community-scripts ORG
|
||||
# Author: MickLesk (CanbiZ)
|
||||
# License: MIT | https://github.com/community-scripts/ProxmoxVE/raw/main/LICENSE
|
||||
# Source: https://github.com/activepieces/activepieces
|
||||
|
||||
source /dev/stdin <<<"$FUNCTIONS_FILE_PATH"
|
||||
color
|
||||
verb_ip6
|
||||
catch_errors
|
||||
setting_up_container
|
||||
network_check
|
||||
update_os
|
||||
|
||||
msg_info "Installing Dependencies"
|
||||
$STD apt install -y \
|
||||
build-essential \
|
||||
python3 \
|
||||
poppler-utils \
|
||||
redis-server
|
||||
msg_ok "Installed Dependencies"
|
||||
|
||||
PG_VERSION="16" PG_MODULES="pgvector" setup_postgresql
|
||||
PG_DB_NAME="activepieces" PG_DB_USER="activepieces" PG_DB_EXTENSIONS="vector" setup_postgresql_db
|
||||
|
||||
fetch_and_deploy_gh_release "activepieces" "activepieces/activepieces" "tarball"
|
||||
NODE_VERSION="24" NODE_MODULE="$(jq -r '.packageManager' /opt/activepieces/package.json)" setup_nodejs
|
||||
fetch_and_deploy_gh_release "deno" "denoland/deno" "prebuild" "v$(jq -r '.devDependencies.deno' /opt/activepieces/packages/server/engine/package.json)" "/usr/local/bin" "deno-$(arch_resolve "x86_64" "aarch64")-unknown-linux-gnu.zip"
|
||||
|
||||
msg_info "Building Activepieces"
|
||||
cd /opt/activepieces
|
||||
REDISMS_DISABLE_POSTINSTALL=1 $STD bun install --frozen-lockfile
|
||||
$STD npx turbo run build --filter=web --filter=@activepieces/engine --filter=api --filter=worker
|
||||
find dist/packages/web -name '*.map' -delete
|
||||
rm -rf node_modules bun.lock packages/pieces/core packages/pieces/custom packages/web packages/cli packages/tests-e2e packages/ee
|
||||
find packages/pieces/community -mindepth 1 -maxdepth 1 -type d ! -name slack ! -name square ! -name facebook-leads ! -name intercom ! -name microsoft-teams-bot -exec rm -rf {} +
|
||||
node -e "const fs=require('fs');const p=JSON.parse(fs.readFileSync('package.json','utf8'));p.workspaces=p.workspaces.filter(w=>fs.existsSync(w.replace('/*','')));fs.writeFileSync('package.json',JSON.stringify(p,null,2))"
|
||||
REDISMS_DISABLE_POSTINSTALL=1 $STD bun install --production
|
||||
rm -rf ~/.bun/install/cache
|
||||
msg_ok "Built Activepieces"
|
||||
|
||||
msg_info "Configuring Activepieces"
|
||||
mkdir -p /opt/activepieces_data/cache
|
||||
JWT_SECRET=$(openssl rand -hex 32)
|
||||
cat <<EOF >/opt/activepieces_data/.env
|
||||
NODE_ENV=production
|
||||
AP_ENVIRONMENT=prod
|
||||
AP_PORT=80
|
||||
AP_FRONTEND_URL=http://${LOCAL_IP}
|
||||
AP_API_KEY=$(openssl rand -hex 64)
|
||||
AP_ENCRYPTION_KEY=$(openssl rand -hex 16)
|
||||
AP_JWT_SECRET=${JWT_SECRET}
|
||||
AP_WORKER_TOKEN=$(node -e "process.stdout.write(require('jsonwebtoken').sign({ id: require('crypto').randomUUID(), type: 'WORKER' }, process.argv[1], { expiresIn: '100y', keyid: '1', algorithm: 'HS256', issuer: 'activepieces' }))" "${JWT_SECRET}")
|
||||
AP_POSTGRES_HOST=localhost
|
||||
AP_POSTGRES_PORT=5432
|
||||
AP_POSTGRES_DATABASE=activepieces
|
||||
AP_POSTGRES_USERNAME=activepieces
|
||||
AP_POSTGRES_PASSWORD=${PG_DB_PASS}
|
||||
AP_REDIS_HOST=localhost
|
||||
AP_REDIS_PORT=6379
|
||||
AP_EXECUTION_MODE=UNSANDBOXED
|
||||
AP_DENO_PATH=/usr/local/bin/deno
|
||||
AP_CACHE_BASE_PATH=/opt/activepieces_data/cache
|
||||
AP_CONFIG_PATH=/opt/activepieces_data
|
||||
AP_TELEMETRY_ENABLED=false
|
||||
EOF
|
||||
chmod 600 /opt/activepieces_data/.env
|
||||
msg_ok "Configured Activepieces"
|
||||
|
||||
msg_info "Creating Services"
|
||||
cat <<EOF >/etc/systemd/system/activepieces.service
|
||||
[Unit]
|
||||
Description=Activepieces
|
||||
After=network.target postgresql.service redis-server.service
|
||||
Wants=activepieces-worker.service
|
||||
|
||||
[Service]
|
||||
Type=simple
|
||||
User=root
|
||||
WorkingDirectory=/opt/activepieces
|
||||
EnvironmentFile=/opt/activepieces_data/.env
|
||||
Environment=AP_CONTAINER_TYPE=APP
|
||||
ExecStart=/usr/bin/node --enable-source-maps packages/server/api/dist/src/bootstrap.js
|
||||
Restart=on-failure
|
||||
RestartSec=5
|
||||
|
||||
[Install]
|
||||
WantedBy=multi-user.target
|
||||
EOF
|
||||
cat <<EOF >/etc/systemd/system/activepieces-worker.service
|
||||
[Unit]
|
||||
Description=Activepieces Worker
|
||||
After=activepieces.service
|
||||
PartOf=activepieces.service
|
||||
|
||||
[Service]
|
||||
Type=simple
|
||||
User=root
|
||||
WorkingDirectory=/opt/activepieces
|
||||
EnvironmentFile=/opt/activepieces_data/.env
|
||||
ExecStart=/usr/bin/node --enable-source-maps packages/server/worker/dist/src/bootstrap.js
|
||||
Restart=on-failure
|
||||
RestartSec=5
|
||||
|
||||
[Install]
|
||||
WantedBy=multi-user.target
|
||||
EOF
|
||||
systemctl enable -q --now activepieces activepieces-worker
|
||||
msg_ok "Created Services"
|
||||
|
||||
motd_ssh
|
||||
customize
|
||||
cleanup_lxc
|
||||
@@ -0,0 +1,159 @@
|
||||
#!/usr/bin/env bash
|
||||
|
||||
# Copyright (c) 2021-2026 community-scripts ORG
|
||||
# Author: MickLesk (CanbiZ)
|
||||
# License: MIT | https://github.com/community-scripts/ProxmoxVE/raw/main/LICENSE
|
||||
# Source: https://github.com/David-Crty/databasement
|
||||
|
||||
source /dev/stdin <<<"$FUNCTIONS_FILE_PATH"
|
||||
color
|
||||
verb_ip6
|
||||
catch_errors
|
||||
setting_up_container
|
||||
network_check
|
||||
update_os
|
||||
|
||||
msg_info "Installing Dependencies"
|
||||
$STD apt install -y \
|
||||
nginx \
|
||||
git \
|
||||
mariadb-client \
|
||||
redis-tools \
|
||||
sqlite3 \
|
||||
sshpass \
|
||||
zstd \
|
||||
7zip
|
||||
msg_ok "Installed Dependencies"
|
||||
|
||||
msg_info "Installing PostgreSQL Clients"
|
||||
setup_deb822_repo \
|
||||
"pgdg" \
|
||||
"https://www.postgresql.org/media/keys/ACCC4CF8.asc" \
|
||||
"https://apt.postgresql.org/pub/repos/apt" \
|
||||
"$(get_os_info codename)-pgdg" \
|
||||
"main"
|
||||
# pg_dump on PATH resolves to the newest client; Databasement switches to the 16 client for servers up to 16
|
||||
$STD apt install -y \
|
||||
postgresql-client-16 \
|
||||
postgresql-client-18
|
||||
msg_ok "Installed PostgreSQL Clients"
|
||||
|
||||
# MongoDB ships no Debian 13 build of its tools and only an amd64 Debian 12 one; the Ubuntu 24.04 build covers both
|
||||
fetch_and_deploy_from_url "https://fastdl.mongodb.org/tools/db/mongodb-database-tools-ubuntu2404-$(arch_resolve "x86_64" "arm64")-$(get_latest_gh_tag "mongodb/mongo-tools" "100.").deb"
|
||||
|
||||
PHP_VERSION="8.5" PHP_FPM="YES" PHP_MODULE="mongodb,smbclient" setup_php
|
||||
setup_composer
|
||||
NODE_VERSION="22" setup_nodejs
|
||||
|
||||
fetch_and_deploy_gh_release "databasement" "David-Crty/databasement" "tarball"
|
||||
|
||||
msg_info "Setting up Databasement"
|
||||
mkdir -p /opt/databasement_data/backups
|
||||
touch /opt/databasement_data/database.sqlite
|
||||
cat <<EOF >/opt/databasement_data/.env
|
||||
APP_NAME=Databasement
|
||||
APP_ENV=production
|
||||
APP_KEY=base64:$(openssl rand -base64 32)
|
||||
APP_DEBUG=false
|
||||
APP_URL=http://${LOCAL_IP}
|
||||
APP_VERSION=$(cat ~/.databasement)
|
||||
APP_DISPLAY_TIMEZONE=UTC
|
||||
|
||||
DB_CONNECTION=sqlite
|
||||
DB_DATABASE=/opt/databasement_data/database.sqlite
|
||||
|
||||
LOG_LEVEL=warning
|
||||
EOF
|
||||
ln -sf /opt/databasement_data/.env /opt/databasement/.env
|
||||
# the demo backup offered at sign-up writes to /data/backups, the volume path of the upstream image
|
||||
ln -s /opt/databasement_data /data
|
||||
cd /opt/databasement
|
||||
$STD composer install --no-dev --optimize-autoloader --no-interaction
|
||||
$STD php artisan vendor:publish --force --tag=livewire:assets
|
||||
$STD npm ci --ignore-scripts
|
||||
$STD npm run build
|
||||
$STD php artisan migrate --force
|
||||
$STD php artisan optimize
|
||||
chown -R www-data:www-data /opt/databasement /opt/databasement_data
|
||||
chmod 600 /opt/databasement_data/.env
|
||||
msg_ok "Set up Databasement"
|
||||
|
||||
msg_info "Configuring Nginx"
|
||||
PHP_SOCK=$(get_php_fpm_socket)
|
||||
cat <<EOF >/etc/nginx/sites-available/databasement
|
||||
server {
|
||||
listen 80;
|
||||
server_name _;
|
||||
root /opt/databasement/public;
|
||||
|
||||
add_header X-Frame-Options "SAMEORIGIN";
|
||||
add_header X-Content-Type-Options "nosniff";
|
||||
|
||||
index index.php;
|
||||
charset utf-8;
|
||||
|
||||
location / {
|
||||
try_files \$uri \$uri/ /index.php?\$query_string;
|
||||
}
|
||||
|
||||
location = /favicon.ico { access_log off; log_not_found off; }
|
||||
location = /robots.txt { access_log off; log_not_found off; }
|
||||
|
||||
error_page 404 /index.php;
|
||||
|
||||
location ~ \.php\$ {
|
||||
fastcgi_pass unix:${PHP_SOCK};
|
||||
fastcgi_param SCRIPT_FILENAME \$realpath_root\$fastcgi_script_name;
|
||||
include fastcgi_params;
|
||||
fastcgi_hide_header X-Powered-By;
|
||||
}
|
||||
|
||||
location ~ /\.(?!well-known).* {
|
||||
deny all;
|
||||
}
|
||||
}
|
||||
EOF
|
||||
nginx_enable_site "databasement"
|
||||
msg_ok "Configured Nginx"
|
||||
|
||||
msg_info "Creating Services"
|
||||
cat <<EOF >/etc/systemd/system/databasement-worker.service
|
||||
[Unit]
|
||||
Description=Databasement Queue Worker
|
||||
After=network.target php8.5-fpm.service
|
||||
|
||||
[Service]
|
||||
Type=simple
|
||||
User=www-data
|
||||
Group=www-data
|
||||
WorkingDirectory=/opt/databasement
|
||||
ExecStart=/usr/bin/php artisan queue:work --queue=backups,default --tries=3 --timeout=3600 --sleep=3 --max-jobs=1000
|
||||
Restart=always
|
||||
RestartSec=5
|
||||
|
||||
[Install]
|
||||
WantedBy=multi-user.target
|
||||
EOF
|
||||
cat <<EOF >/etc/systemd/system/databasement-scheduler.service
|
||||
[Unit]
|
||||
Description=Databasement Scheduler
|
||||
After=network.target php8.5-fpm.service
|
||||
|
||||
[Service]
|
||||
Type=simple
|
||||
User=www-data
|
||||
Group=www-data
|
||||
WorkingDirectory=/opt/databasement
|
||||
ExecStart=/usr/bin/php artisan schedule:work --quiet
|
||||
Restart=always
|
||||
RestartSec=5
|
||||
|
||||
[Install]
|
||||
WantedBy=multi-user.target
|
||||
EOF
|
||||
systemctl enable -q --now databasement-worker databasement-scheduler
|
||||
msg_ok "Created Services"
|
||||
|
||||
motd_ssh
|
||||
customize
|
||||
cleanup_lxc
|
||||
@@ -51,7 +51,7 @@ EOF
|
||||
$STD systemctl restart mariadb
|
||||
msg_ok "Configured MariaDB for ERPNext"
|
||||
|
||||
fetch_and_deploy_gh_release "wkhtmltopdf" "wkhtmltopdf/packaging" "binary" "latest" "" "wkhtmltox_*.bookworm_$(arch_resolve).deb"
|
||||
fetch_and_deploy_gh_release "pdfkiln" "pdfkiln/pdfkiln" "binary" "latest" "" "pdfkiln_*_$(arch_resolve).deb"
|
||||
|
||||
msg_info "Installing Frappe Bench"
|
||||
useradd -m -s /bin/bash frappe
|
||||
|
||||
@@ -0,0 +1,131 @@
|
||||
#!/usr/bin/env bash
|
||||
|
||||
# Copyright (c) 2021-2026 community-scripts ORG
|
||||
# Author: MickLesk (CanbiZ)
|
||||
# License: MIT | https://github.com/community-scripts/ProxmoxVE/raw/main/LICENSE
|
||||
# Source: https://github.com/formbricks/formbricks
|
||||
|
||||
source /dev/stdin <<<"$FUNCTIONS_FILE_PATH"
|
||||
color
|
||||
verb_ip6
|
||||
catch_errors
|
||||
setting_up_container
|
||||
network_check
|
||||
update_os
|
||||
|
||||
msg_info "Installing Dependencies"
|
||||
$STD apt install -y valkey-server
|
||||
sed -i 's/^appendonly no/appendonly yes/' /etc/valkey/valkey.conf
|
||||
systemctl restart valkey-server
|
||||
msg_ok "Installed Dependencies"
|
||||
|
||||
PG_VERSION="18" PG_MODULES="pgvector" setup_postgresql
|
||||
PG_DB_NAME="formbricks" PG_DB_USER="formbricks" PG_DB_EXTENSIONS="vector" setup_postgresql_db
|
||||
# setup_postgresql_db keeps an already set PG_DB_PASS, so the SpiceDB role gets the same password
|
||||
PG_DB_NAME="spicedb" PG_DB_USER="spicedb" setup_postgresql_db
|
||||
|
||||
fetch_and_deploy_gh_release "spicedb" "authzed/spicedb" "binary"
|
||||
fetch_and_deploy_gh_release "formbricks" "formbricks/formbricks" "tarball"
|
||||
NODE_VERSION="24" NODE_MODULE="pnpm@$(jq -r '.packageManager | split("@")[1]' /opt/formbricks/package.json)" setup_nodejs
|
||||
|
||||
msg_info "Building Formbricks (Patience)"
|
||||
cd /opt/formbricks
|
||||
sed -i "s/\"version\": \"0.0.0\"/\"version\": \"$(cat ~/.formbricks)\"/" apps/web/package.json
|
||||
sed -i 's/^const nextConfig = {$/&\n typescript: { ignoreBuildErrors: true },/' apps/web/next.config.mjs
|
||||
touch apps/web/.env
|
||||
$STD pnpm install --ignore-scripts --frozen-lockfile
|
||||
$STD sh apps/web/scripts/docker/read-secrets.sh pnpm build --filter=@formbricks/web...
|
||||
cp -r apps/web/.next/static apps/web/.next/standalone/apps/web/.next/
|
||||
cp -r apps/web/public apps/web/.next/standalone/apps/web/
|
||||
msg_ok "Built Formbricks"
|
||||
|
||||
msg_info "Configuring Formbricks"
|
||||
mkdir -p /opt/formbricks_data
|
||||
AUTHZED_TOKEN=$(openssl rand -hex 32)
|
||||
cat <<EOF >/opt/formbricks_data/.env
|
||||
NODE_ENV=production
|
||||
WEBAPP_URL=http://${LOCAL_IP}:3000
|
||||
NEXTAUTH_URL=http://${LOCAL_IP}:3000
|
||||
NEXTAUTH_SECRET=$(openssl rand -hex 32)
|
||||
ENCRYPTION_KEY=$(openssl rand -hex 32)
|
||||
CRON_SECRET=$(openssl rand -hex 32)
|
||||
DATABASE_URL=postgresql://formbricks:${PG_DB_PASS}@localhost:5432/formbricks?schema=public
|
||||
REDIS_URL=redis://localhost:6379
|
||||
AUTHZED_ENABLED=true
|
||||
AUTHZED_ENDPOINT=127.0.0.1:50051
|
||||
AUTHZED_TOKEN=${AUTHZED_TOKEN}
|
||||
AUTHZED_SYSTEM_KEY=formbricks
|
||||
AUTHZED_INSECURE=true
|
||||
AUTHZED_CONSISTENCY=fully_consistent
|
||||
HUB_API_URL=http://127.0.0.1:8080
|
||||
HUB_API_KEY=$(openssl rand -hex 32)
|
||||
CUBEJS_API_URL=http://127.0.0.1:4000
|
||||
CUBEJS_API_SECRET=$(openssl rand -hex 32)
|
||||
EMAIL_VERIFICATION_DISABLED=1
|
||||
PASSWORD_RESET_DISABLED=1
|
||||
TELEMETRY_DISABLED=1
|
||||
EOF
|
||||
cat <<EOF >/opt/formbricks_data/spicedb.env
|
||||
SPICEDB_DATASTORE_ENGINE=postgres
|
||||
SPICEDB_DATASTORE_CONN_URI=postgres://spicedb:${PG_DB_PASS}@localhost:5432/spicedb?sslmode=disable
|
||||
SPICEDB_GRPC_PRESHARED_KEY=${AUTHZED_TOKEN}
|
||||
SPICEDB_GRPC_ADDR=127.0.0.1:50051
|
||||
SPICEDB_METRICS_ADDR=127.0.0.1:9090
|
||||
SPICEDB_TELEMETRY_ENDPOINT=
|
||||
SPICEDB_LOG_LEVEL=warn
|
||||
EOF
|
||||
chmod 600 /opt/formbricks_data/.env /opt/formbricks_data/spicedb.env
|
||||
msg_ok "Configured Formbricks"
|
||||
|
||||
msg_info "Setting up SpiceDB"
|
||||
set -a && source /opt/formbricks_data/spicedb.env && set +a
|
||||
$STD spicedb datastore migrate head
|
||||
cat <<EOF >/etc/systemd/system/spicedb.service
|
||||
[Unit]
|
||||
Description=SpiceDB
|
||||
After=network.target postgresql.service
|
||||
|
||||
[Service]
|
||||
Type=simple
|
||||
User=root
|
||||
EnvironmentFile=/opt/formbricks_data/spicedb.env
|
||||
ExecStart=/usr/bin/spicedb serve
|
||||
Restart=on-failure
|
||||
RestartSec=5
|
||||
|
||||
[Install]
|
||||
WantedBy=multi-user.target
|
||||
EOF
|
||||
systemctl enable -q --now spicedb
|
||||
msg_ok "Set up SpiceDB"
|
||||
|
||||
msg_info "Migrating Formbricks Database"
|
||||
set -a && source /opt/formbricks_data/.env && set +a
|
||||
$STD node packages/database/dist/scripts/apply-migrations.js
|
||||
$STD node apps/web/dist/authzed-cli/index.mjs upgrade prepare
|
||||
msg_ok "Migrated Formbricks Database"
|
||||
|
||||
msg_info "Creating Service"
|
||||
cat <<EOF >/etc/systemd/system/formbricks.service
|
||||
[Unit]
|
||||
Description=Formbricks
|
||||
After=network.target postgresql.service valkey-server.service spicedb.service
|
||||
|
||||
[Service]
|
||||
Type=simple
|
||||
User=root
|
||||
WorkingDirectory=/opt/formbricks/apps/web/.next/standalone
|
||||
EnvironmentFile=/opt/formbricks_data/.env
|
||||
ExecStart=/usr/bin/node apps/web/server.js
|
||||
Restart=on-failure
|
||||
RestartSec=5
|
||||
|
||||
[Install]
|
||||
WantedBy=multi-user.target
|
||||
EOF
|
||||
systemctl enable -q --now formbricks
|
||||
msg_ok "Created Service"
|
||||
|
||||
motd_ssh
|
||||
customize
|
||||
cleanup_lxc
|
||||
@@ -0,0 +1,84 @@
|
||||
#!/usr/bin/env bash
|
||||
|
||||
# Copyright (c) 2021-2026 community-scripts ORG
|
||||
# Author: MickLesk (CanbiZ)
|
||||
# License: MIT | https://github.com/community-scripts/ProxmoxVE/raw/main/LICENSE
|
||||
# Source: https://github.com/hedgedoc/hedgedoc
|
||||
|
||||
source /dev/stdin <<<"$FUNCTIONS_FILE_PATH"
|
||||
color
|
||||
verb_ip6
|
||||
catch_errors
|
||||
setting_up_container
|
||||
network_check
|
||||
update_os
|
||||
|
||||
msg_info "Installing Dependencies"
|
||||
$STD apt install -y \
|
||||
build-essential \
|
||||
git \
|
||||
python3
|
||||
msg_ok "Installed Dependencies"
|
||||
|
||||
PG_VERSION="18" setup_postgresql
|
||||
PG_DB_NAME="hedgedoc" PG_DB_USER="hedgedoc" setup_postgresql_db
|
||||
NODE_VERSION="24" NODE_MODULE="yarn" setup_nodejs
|
||||
|
||||
fetch_and_deploy_gh_release "hedgedoc" "hedgedoc/hedgedoc" "prebuild" "latest" "/opt/hedgedoc" "hedgedoc-*.tar.gz"
|
||||
|
||||
msg_info "Installing HedgeDoc Dependencies"
|
||||
cd /opt/hedgedoc
|
||||
$STD yarn workspaces focus --production
|
||||
msg_ok "Installed HedgeDoc Dependencies"
|
||||
|
||||
msg_info "Configuring HedgeDoc"
|
||||
mkdir -p /opt/hedgedoc_data/uploads
|
||||
cat <<EOF >/opt/hedgedoc_data/config.json
|
||||
{
|
||||
"production": {
|
||||
"domain": "${LOCAL_IP}",
|
||||
"urlAddPort": true,
|
||||
"sessionSecret": "$(openssl rand -hex 64)",
|
||||
"db": {
|
||||
"dialect": "postgres",
|
||||
"host": "localhost",
|
||||
"port": 5432,
|
||||
"database": "${PG_DB_NAME}",
|
||||
"username": "${PG_DB_USER}",
|
||||
"password": "${PG_DB_PASS}"
|
||||
},
|
||||
"uploadsPath": "/opt/hedgedoc_data/uploads",
|
||||
"allowAnonymous": false,
|
||||
"allowAnonymousEdits": true,
|
||||
"enableStatsApi": false
|
||||
}
|
||||
}
|
||||
EOF
|
||||
chmod 600 /opt/hedgedoc_data/config.json
|
||||
msg_ok "Configured HedgeDoc"
|
||||
|
||||
msg_info "Creating Service"
|
||||
cat <<EOF >/etc/systemd/system/hedgedoc.service
|
||||
[Unit]
|
||||
Description=HedgeDoc
|
||||
After=network.target postgresql.service
|
||||
|
||||
[Service]
|
||||
Type=simple
|
||||
User=root
|
||||
WorkingDirectory=/opt/hedgedoc
|
||||
Environment=NODE_ENV=production
|
||||
Environment=CMD_CONFIG_FILE=/opt/hedgedoc_data/config.json
|
||||
ExecStart=/usr/bin/node app.js
|
||||
Restart=on-failure
|
||||
RestartSec=5
|
||||
|
||||
[Install]
|
||||
WantedBy=multi-user.target
|
||||
EOF
|
||||
systemctl enable -q --now hedgedoc
|
||||
msg_ok "Created Service"
|
||||
|
||||
motd_ssh
|
||||
customize
|
||||
cleanup_lxc
|
||||
@@ -0,0 +1,326 @@
|
||||
#!/usr/bin/env bash
|
||||
|
||||
# Copyright (c) 2021-2026 community-scripts ORG
|
||||
# Author: MickLesk (CanbiZ)
|
||||
# License: MIT | https://github.com/community-scripts/ProxmoxVE/raw/main/LICENSE
|
||||
# Source: https://github.com/zoriya/Kyoo
|
||||
|
||||
source /dev/stdin <<<"$FUNCTIONS_FILE_PATH"
|
||||
color
|
||||
verb_ip6
|
||||
catch_errors
|
||||
setting_up_container
|
||||
network_check
|
||||
update_os
|
||||
|
||||
msg_info "Installing Dependencies"
|
||||
$STD apt install -y \
|
||||
build-essential \
|
||||
pkg-config \
|
||||
git \
|
||||
nginx \
|
||||
libavformat-dev \
|
||||
libavutil-dev \
|
||||
libswscale-dev
|
||||
msg_ok "Installed Dependencies"
|
||||
|
||||
setup_ffmpeg
|
||||
setup_hwaccel
|
||||
PG_VERSION="18" setup_postgresql
|
||||
PG_DB_NAME="kyoo" PG_DB_USER="kyoo" setup_postgresql_db
|
||||
setup_go
|
||||
PYTHON_VERSION="3.14" setup_uv
|
||||
NODE_VERSION="24" NODE_MODULE="bun" setup_nodejs
|
||||
|
||||
fetch_and_deploy_gh_release "kyoo" "zoriya/Kyoo" "tarball"
|
||||
|
||||
msg_info "Building Kyoo Auth"
|
||||
cd /opt/kyoo/auth
|
||||
$STD go build -o keibi
|
||||
msg_ok "Built Kyoo Auth"
|
||||
|
||||
msg_info "Building Kyoo Transcoder"
|
||||
cd /opt/kyoo/transcoder
|
||||
$STD go build -o transcoder
|
||||
msg_ok "Built Kyoo Transcoder"
|
||||
|
||||
msg_info "Building Kyoo API"
|
||||
cd /opt/kyoo/api
|
||||
$STD bun install --production
|
||||
$STD bun build --compile --compile-autoload-package-json --minify-whitespace --minify-syntax --target bun --outfile server ./src/index.ts
|
||||
msg_ok "Built Kyoo API"
|
||||
|
||||
msg_info "Setting up Kyoo Scanner"
|
||||
cd /opt/kyoo/scanner
|
||||
$STD uv sync --locked --python 3.14
|
||||
msg_ok "Set up Kyoo Scanner"
|
||||
|
||||
msg_info "Building Kyoo Web App"
|
||||
cd /opt/kyoo/front
|
||||
NODE_ENV=production $STD bun install --production
|
||||
$STD bun run web
|
||||
rm -rf /opt/kyoo/front/node_modules ~/.bun/install/cache
|
||||
msg_ok "Built Kyoo Web App"
|
||||
|
||||
msg_info "Configuring Kyoo"
|
||||
mkdir -p /opt/kyoo_data/{media,images,profile_pictures,metadata} /var/cache/kyoo
|
||||
$STD openssl genrsa -traditional -out /opt/kyoo_data/keibi.pem 4096
|
||||
SCANNER_APIKEY=$(openssl rand -hex 32)
|
||||
case "${HWACCEL_VENDOR:-none}" in
|
||||
nvidia) KYOO_HWACCEL="nvidia" ;;
|
||||
intel | amd) KYOO_HWACCEL="vaapi" ;;
|
||||
*) KYOO_HWACCEL="disabled" ;;
|
||||
esac
|
||||
cat <<EOF >/opt/kyoo_data/.env
|
||||
PUBLIC_URL=https://${LOCAL_IP}
|
||||
JWT_ISSUER=https://${LOCAL_IP}
|
||||
EXTRA_OIDC_REDIRECT_URLS=kyoo
|
||||
|
||||
PGHOST=127.0.0.1
|
||||
PGPORT=5432
|
||||
PGDATABASE=kyoo
|
||||
PGUSER=kyoo
|
||||
PGPASSWORD=${PG_DB_PASS}
|
||||
PGSSLMODE=disable
|
||||
|
||||
AUTH_SERVER=http://127.0.0.1:4568
|
||||
JWKS_URL=http://127.0.0.1:4568/.well-known/jwks.json
|
||||
TRANSCODER_SERVER=http://127.0.0.1:7666
|
||||
KYOO_URL=http://127.0.0.1:8901/api
|
||||
RSA_PRIVATE_KEY_PATH=/opt/kyoo_data/keibi.pem
|
||||
KEIBI_APIKEY_SCANNER=${SCANNER_APIKEY}
|
||||
KEIBI_APIKEY_SCANNER_CLAIMS='{"permissions": ["core.read", "core.write"]}'
|
||||
KYOO_APIKEY=${SCANNER_APIKEY}
|
||||
|
||||
EXTRA_CLAIMS='{"permissions": ["core.read", "core.play"], "verified": false}'
|
||||
FIRST_USER_CLAIMS='{"permissions": ["users.read", "users.write", "users.delete", "apikeys.read", "apikeys.write", "core.read", "core.write", "core.play", "scanner.trigger", "scanner.guess", "scanner.search", "scanner.add"], "verified": true}'
|
||||
GUEST_CLAIMS='{"permissions": ["core.read"], "verified": true}'
|
||||
PROTECTED_CLAIMS="permissions,verified"
|
||||
|
||||
SCANNER_LIBRARY_ROOT=/opt/kyoo_data/media
|
||||
GOCODER_SAFE_PATH=/opt/kyoo_data/media
|
||||
LIBRARY_IGNORE_PATTERN=".*/[dD]ownloads?/.*"
|
||||
IMAGES_PATH=/opt/kyoo_data/images
|
||||
PROFILE_PICTURE_PATH=/opt/kyoo_data/profile_pictures
|
||||
GOCODER_METADATA_ROOT=/opt/kyoo_data/metadata
|
||||
GOCODER_CACHE_ROOT=/var/cache/kyoo
|
||||
GOCODER_HWACCEL=${KYOO_HWACCEL}
|
||||
GOCODER_PRESET=fast
|
||||
|
||||
THEMOVIEDB_API_ACCESS_TOKEN=
|
||||
TVDB_APIKEY=
|
||||
TVDB_PIN=
|
||||
EOF
|
||||
chmod 600 /opt/kyoo_data/.env /opt/kyoo_data/keibi.pem
|
||||
msg_ok "Configured Kyoo"
|
||||
|
||||
msg_info "Configuring Nginx"
|
||||
create_self_signed_cert "kyoo"
|
||||
# Upstream's Traefik routes; auth_request replaces its forwardAuth that swaps tokens/API keys for a JWT.
|
||||
# HTTPS so browsers honour COOP/COEP (SharedArrayBuffer for subtitles); 127.0.0.1:8901 is plain HTTP for the scanner.
|
||||
cat <<'EOF' >/etc/nginx/sites-available/kyoo
|
||||
map $http_upgrade $kyoo_connection_upgrade {
|
||||
default upgrade;
|
||||
'' close;
|
||||
}
|
||||
|
||||
map $http_x_forwarded_proto $kyoo_forwarded_proto {
|
||||
default $http_x_forwarded_proto;
|
||||
'' $scheme;
|
||||
}
|
||||
|
||||
map $http_x_forwarded_host $kyoo_forwarded_host {
|
||||
default $http_x_forwarded_host;
|
||||
'' $http_host;
|
||||
}
|
||||
|
||||
server {
|
||||
listen 80 default_server;
|
||||
server_name _;
|
||||
return 301 https://$host$request_uri;
|
||||
}
|
||||
|
||||
server {
|
||||
listen 443 ssl default_server;
|
||||
listen 127.0.0.1:8901;
|
||||
server_name _;
|
||||
charset utf-8;
|
||||
client_max_body_size 0;
|
||||
|
||||
ssl_certificate /etc/ssl/kyoo/kyoo.crt;
|
||||
ssl_certificate_key /etc/ssl/kyoo/kyoo.key;
|
||||
|
||||
root /opt/kyoo/front/dist;
|
||||
index index.html;
|
||||
|
||||
location / {
|
||||
add_header Cross-Origin-Opener-Policy same-origin;
|
||||
add_header Cross-Origin-Embedder-Policy credentialless;
|
||||
try_files $uri $uri/ /index.html;
|
||||
}
|
||||
|
||||
location = /_kyoo_jwt {
|
||||
internal;
|
||||
proxy_pass http://127.0.0.1:4568/auth/jwt;
|
||||
proxy_pass_request_body off;
|
||||
proxy_set_header Content-Length "";
|
||||
proxy_set_header X-Forwarded-Method $request_method;
|
||||
proxy_set_header X-Forwarded-Uri $request_uri;
|
||||
proxy_set_header X-Forwarded-Host $kyoo_forwarded_host;
|
||||
proxy_set_header X-Forwarded-Proto $kyoo_forwarded_proto;
|
||||
}
|
||||
|
||||
location /auth/ {
|
||||
proxy_pass http://127.0.0.1:4568;
|
||||
proxy_set_header Host $http_host;
|
||||
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
||||
proxy_set_header X-Forwarded-Host $kyoo_forwarded_host;
|
||||
proxy_set_header X-Forwarded-Proto $kyoo_forwarded_proto;
|
||||
}
|
||||
|
||||
location /.well-known/ {
|
||||
proxy_pass http://127.0.0.1:4568;
|
||||
}
|
||||
|
||||
location /swagger {
|
||||
proxy_pass http://127.0.0.1:3567;
|
||||
}
|
||||
|
||||
location /api/ {
|
||||
if ($request_method = OPTIONS) {
|
||||
add_header Access-Control-Allow-Origin * always;
|
||||
add_header Access-Control-Allow-Methods "GET, OPTIONS" always;
|
||||
add_header Access-Control-Allow-Headers "Authorization, Content-Type, Range, X-Api-Key" always;
|
||||
add_header Vary Origin always;
|
||||
return 204;
|
||||
}
|
||||
add_header Access-Control-Allow-Origin * always;
|
||||
add_header Vary Origin always;
|
||||
auth_request /_kyoo_jwt;
|
||||
auth_request_set $kyoo_jwt $upstream_http_authorization;
|
||||
proxy_pass http://127.0.0.1:3567;
|
||||
proxy_http_version 1.1;
|
||||
proxy_read_timeout 1h;
|
||||
proxy_set_header Authorization $kyoo_jwt;
|
||||
proxy_set_header Host $http_host;
|
||||
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
||||
proxy_set_header X-Forwarded-Host $kyoo_forwarded_host;
|
||||
proxy_set_header X-Forwarded-Proto $kyoo_forwarded_proto;
|
||||
proxy_set_header Upgrade $http_upgrade;
|
||||
proxy_set_header Connection $kyoo_connection_upgrade;
|
||||
}
|
||||
|
||||
location /video {
|
||||
if ($request_method = OPTIONS) {
|
||||
add_header Access-Control-Allow-Origin * always;
|
||||
add_header Access-Control-Allow-Methods "GET, OPTIONS" always;
|
||||
add_header Access-Control-Allow-Headers "Authorization, Content-Type, Range, X-Api-Key" always;
|
||||
add_header Vary Origin always;
|
||||
return 204;
|
||||
}
|
||||
add_header Access-Control-Allow-Origin * always;
|
||||
add_header Vary Origin always;
|
||||
auth_request /_kyoo_jwt;
|
||||
auth_request_set $kyoo_jwt $upstream_http_authorization;
|
||||
proxy_pass http://127.0.0.1:7666;
|
||||
proxy_http_version 1.1;
|
||||
proxy_buffering off;
|
||||
proxy_read_timeout 1h;
|
||||
proxy_set_header Authorization $kyoo_jwt;
|
||||
proxy_set_header Host $http_host;
|
||||
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
||||
proxy_set_header X-Forwarded-Host $kyoo_forwarded_host;
|
||||
proxy_set_header X-Forwarded-Proto $kyoo_forwarded_proto;
|
||||
}
|
||||
|
||||
location /scanner/ {
|
||||
auth_request /_kyoo_jwt;
|
||||
auth_request_set $kyoo_jwt $upstream_http_authorization;
|
||||
proxy_pass http://127.0.0.1:4389;
|
||||
proxy_set_header Authorization $kyoo_jwt;
|
||||
proxy_set_header Host $http_host;
|
||||
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
||||
proxy_set_header X-Forwarded-Host $kyoo_forwarded_host;
|
||||
proxy_set_header X-Forwarded-Proto $kyoo_forwarded_proto;
|
||||
}
|
||||
}
|
||||
EOF
|
||||
nginx_enable_site "kyoo"
|
||||
msg_ok "Configured Nginx"
|
||||
|
||||
msg_info "Creating Services"
|
||||
cat <<EOF >/etc/systemd/system/kyoo-auth.service
|
||||
[Unit]
|
||||
Description=Kyoo Auth
|
||||
After=network.target postgresql.service
|
||||
Requires=postgresql.service
|
||||
|
||||
[Service]
|
||||
Type=simple
|
||||
WorkingDirectory=/opt/kyoo/auth
|
||||
EnvironmentFile=/opt/kyoo_data/.env
|
||||
ExecStart=/opt/kyoo/auth/keibi
|
||||
Restart=always
|
||||
RestartSec=5
|
||||
|
||||
[Install]
|
||||
WantedBy=multi-user.target
|
||||
EOF
|
||||
cat <<EOF >/etc/systemd/system/kyoo-transcoder.service
|
||||
[Unit]
|
||||
Description=Kyoo Transcoder
|
||||
After=network.target postgresql.service kyoo-auth.service
|
||||
Requires=postgresql.service
|
||||
|
||||
[Service]
|
||||
Type=simple
|
||||
WorkingDirectory=/opt/kyoo/transcoder
|
||||
EnvironmentFile=/opt/kyoo_data/.env
|
||||
ExecStart=/opt/kyoo/transcoder/transcoder
|
||||
Restart=always
|
||||
RestartSec=5
|
||||
|
||||
[Install]
|
||||
WantedBy=multi-user.target
|
||||
EOF
|
||||
cat <<EOF >/etc/systemd/system/kyoo-api.service
|
||||
[Unit]
|
||||
Description=Kyoo API
|
||||
After=network.target postgresql.service kyoo-auth.service
|
||||
Requires=postgresql.service
|
||||
|
||||
[Service]
|
||||
Type=simple
|
||||
WorkingDirectory=/opt/kyoo/api
|
||||
EnvironmentFile=/opt/kyoo_data/.env
|
||||
Environment=NODE_ENV=production
|
||||
ExecStart=/opt/kyoo/api/server
|
||||
Restart=always
|
||||
RestartSec=5
|
||||
|
||||
[Install]
|
||||
WantedBy=multi-user.target
|
||||
EOF
|
||||
cat <<EOF >/etc/systemd/system/kyoo-scanner.service
|
||||
[Unit]
|
||||
Description=Kyoo Scanner
|
||||
After=network.target postgresql.service nginx.service kyoo-api.service
|
||||
Requires=postgresql.service
|
||||
|
||||
[Service]
|
||||
Type=simple
|
||||
WorkingDirectory=/opt/kyoo/scanner
|
||||
EnvironmentFile=/opt/kyoo_data/.env
|
||||
ExecStart=/opt/kyoo/scanner/.venv/bin/fastapi run scanner --host 127.0.0.1 --port 4389
|
||||
Restart=always
|
||||
RestartSec=5
|
||||
|
||||
[Install]
|
||||
WantedBy=multi-user.target
|
||||
EOF
|
||||
systemctl enable -q --now kyoo-auth kyoo-transcoder kyoo-api kyoo-scanner
|
||||
msg_ok "Created Services"
|
||||
|
||||
motd_ssh
|
||||
customize
|
||||
cleanup_lxc
|
||||
Executable
+53
@@ -0,0 +1,53 @@
|
||||
#!/usr/bin/env bash
|
||||
|
||||
# Copyright (c) 2021-2026 community-scripts ORG
|
||||
# Author: Nick Berardi (nberardi)
|
||||
# License: MIT | https://github.com/community-scripts/ProxmoxVE/raw/main/LICENSE
|
||||
# Source: https://nextdns.io | https://github.com/nextdns/nextdns
|
||||
|
||||
source /dev/stdin <<<"$FUNCTIONS_FILE_PATH"
|
||||
color
|
||||
verb_ip6
|
||||
catch_errors
|
||||
setting_up_container
|
||||
network_check
|
||||
update_os
|
||||
|
||||
setup_deb822_repo \
|
||||
"nextdns" \
|
||||
"https://repo.nextdns.io/nextdns.gpg" \
|
||||
"https://repo.nextdns.io/deb" \
|
||||
"stable" \
|
||||
"main"
|
||||
|
||||
msg_info "Installing NextDNS"
|
||||
$STD apt install -y nextdns
|
||||
msg_ok "Installed NextDNS"
|
||||
|
||||
if [[ -z "${var_nextdns_profile:-}" ]]; then
|
||||
echo -e "${INFO}${YW}Get your profile ID from: https://my.nextdns.io${CL}"
|
||||
read -r -p "${TAB3}NextDNS Profile ID: " var_nextdns_profile || true
|
||||
fi
|
||||
var_nextdns_profile="${var_nextdns_profile//[[:space:]]/}"
|
||||
if [[ -z "${var_nextdns_profile}" ]]; then
|
||||
msg_error "NextDNS Profile ID is required (set var_nextdns_profile or enter it when prompted)"
|
||||
exit 64
|
||||
fi
|
||||
|
||||
msg_info "Configuring NextDNS"
|
||||
nextdns install \
|
||||
-profile "${var_nextdns_profile}" \
|
||||
-report-client-info \
|
||||
-setup-router
|
||||
mkdir -p /etc/systemd/system/nextdns.service.d
|
||||
cat <<EOF >/etc/systemd/system/nextdns.service.d/network-online.conf
|
||||
[Unit]
|
||||
Wants=network-online.target
|
||||
After=network-online.target
|
||||
EOF
|
||||
systemctl daemon-reload
|
||||
msg_ok "Configured NextDNS (profile ${var_nextdns_profile})"
|
||||
|
||||
motd_ssh
|
||||
customize
|
||||
cleanup_lxc
|
||||
@@ -36,19 +36,10 @@ $STD /opt/certbot/bin/pip install certbot certbot-dns-cloudflare
|
||||
ln -sf /opt/certbot/bin/certbot /usr/local/bin/certbot
|
||||
msg_ok "Set up Certbot"
|
||||
|
||||
OPENRESTY_VERSION="1.31.8.1"
|
||||
OPENRESTY_VERSION="1.31.9.1"
|
||||
fetch_and_deploy_from_url "https://openresty.org/download/openresty-${OPENRESTY_VERSION}.tar.gz" "/opt/openresty" ||
|
||||
fetch_and_deploy_from_url "https://distfiles.alpinelinux.org/distfiles/edge/openresty-${OPENRESTY_VERSION}.tar.gz" "/opt/openresty"
|
||||
|
||||
msg_info "Patching nginx HTTP/2 (CVE-2026-123007, CVE-2026-123633)"
|
||||
for commit in 61031503dc8087c2c17cd2142c9b4b19062f90c4 2df48a501d0fb8212b7d39dffeeff5876332ba59 e27f5fa84fe6e98505e70bc543b748747dad0a3b; do
|
||||
curl_with_retry "https://api.github.com/repos/nginx/nginx/commits/${commit}" "/tmp/nginx-${commit}.patch" "-HAccept:application/vnd.github.patch" ||
|
||||
curl_with_retry "https://github.com/nginx/nginx/commit/${commit}.patch" "/tmp/nginx-${commit}.patch"
|
||||
patch -d /opt/openresty/bundle/nginx-1.31.8 -p1 --forward -s <"/tmp/nginx-${commit}.patch"
|
||||
rm -f "/tmp/nginx-${commit}.patch"
|
||||
done
|
||||
msg_ok "Patched nginx HTTP/2"
|
||||
|
||||
msg_info "Building OpenResty"
|
||||
cd /opt/openresty
|
||||
$STD ./configure \
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
# Copyright (c) 2021-2026 community-scripts ORG
|
||||
# Author: MickLesk (CanbiZ)
|
||||
# License: MIT | https://github.com/community-scripts/ProxmoxVE/raw/main/LICENSE
|
||||
# Source: https://github.com/asciimoo/hister
|
||||
# Source: https://github.com/asciimoo/nogon
|
||||
|
||||
source /dev/stdin <<<"$FUNCTIONS_FILE_PATH"
|
||||
color
|
||||
@@ -13,37 +13,37 @@ setting_up_container
|
||||
network_check
|
||||
update_os
|
||||
|
||||
fetch_and_deploy_gh_release "hister" "asciimoo/hister" "singlefile" "latest" "/usr/local/bin" "hister_*_linux_$(arch_resolve)"
|
||||
fetch_and_deploy_gh_release "nogon" "asciimoo/nogon" "singlefile" "latest" "/usr/local/bin" "nogon_*_linux_$(arch_resolve)"
|
||||
|
||||
msg_info "Configuring Hister"
|
||||
mkdir -p /opt/hister/data /etc/hister
|
||||
msg_info "Configuring Nogon"
|
||||
mkdir -p /opt/nogon/data /etc/nogon
|
||||
LOCAL_IP=$(hostname -I | awk '{print $1}')
|
||||
cat <<EOF >/etc/hister/config.yaml
|
||||
cat <<EOF >/etc/nogon/config.yaml
|
||||
app:
|
||||
directory: '/opt/hister/data'
|
||||
directory: '/opt/nogon/data'
|
||||
server:
|
||||
address: '0.0.0.0:4433'
|
||||
base_url: 'http://${LOCAL_IP}:4433'
|
||||
EOF
|
||||
msg_ok "Configured Hister"
|
||||
msg_ok "Configured Nogon"
|
||||
|
||||
msg_info "Creating Service"
|
||||
cat <<EOF >/etc/systemd/system/hister.service
|
||||
cat <<EOF >/etc/systemd/system/nogon.service
|
||||
[Unit]
|
||||
Description=Hister Search Engine
|
||||
Description=Nogon Search Engine
|
||||
After=network.target
|
||||
|
||||
[Service]
|
||||
Type=simple
|
||||
User=root
|
||||
ExecStart=/usr/local/bin/hister listen --config /etc/hister/config.yaml
|
||||
ExecStart=/usr/local/bin/nogon listen --config /etc/nogon/config.yaml
|
||||
Restart=on-failure
|
||||
RestartSec=5
|
||||
|
||||
[Install]
|
||||
WantedBy=multi-user.target
|
||||
EOF
|
||||
systemctl enable -q --now hister
|
||||
systemctl enable -q --now nogon
|
||||
msg_ok "Created Service"
|
||||
|
||||
motd_ssh
|
||||
@@ -13,7 +13,7 @@ setting_up_container
|
||||
network_check
|
||||
update_os
|
||||
|
||||
fetch_and_deploy_gh_release "wkhtmltopdf" "wkhtmltopdf/packaging" "binary" "latest" "" "wkhtmltox_*.bookworm_$(arch_resolve).deb"
|
||||
fetch_and_deploy_gh_release "pdfkiln" "pdfkiln/pdfkiln" "binary" "latest" "" "pdfkiln_*_$(arch_resolve).deb"
|
||||
|
||||
PG_VERSION="18" setup_postgresql
|
||||
|
||||
@@ -38,6 +38,9 @@ sed -i \
|
||||
-e "s|^;*db_user *=.*|db_user = odoo_usr|" \
|
||||
-e "s|^;*db_password *=.*|db_password = $PG_DB_PASS|" \
|
||||
/etc/odoo/odoo.conf
|
||||
cat <<EOF >>/etc/odoo/odoo.conf
|
||||
http_interface = 0.0.0.0
|
||||
EOF
|
||||
$STD sudo -u odoo odoo -c /etc/odoo/odoo.conf -d odoo -i base --stop-after-init
|
||||
rm -f /opt/odoo.deb
|
||||
echo "${LATEST_VERSION}" >/opt/${APPLICATION}_version.txt
|
||||
|
||||
@@ -0,0 +1,115 @@
|
||||
#!/usr/bin/env bash
|
||||
|
||||
# Copyright (c) 2021-2026 community-scripts ORG
|
||||
# Author: MickLesk (CanbiZ)
|
||||
# License: MIT | https://github.com/community-scripts/ProxmoxVE/raw/main/LICENSE
|
||||
# Source: https://github.com/sebadob/rauthy
|
||||
|
||||
source /dev/stdin <<<"$FUNCTIONS_FILE_PATH"
|
||||
color
|
||||
verb_ip6
|
||||
catch_errors
|
||||
setting_up_container
|
||||
network_check
|
||||
update_os
|
||||
|
||||
msg_info "Installing Dependencies"
|
||||
$STD apt install -y \
|
||||
build-essential \
|
||||
pkg-config
|
||||
msg_ok "Installed Dependencies"
|
||||
|
||||
setup_rust
|
||||
fetch_and_deploy_gh_release "rauthy" "sebadob/rauthy" "tarball" "latest" "/opt/rauthy-build"
|
||||
|
||||
msg_info "Building Rauthy (Patience)"
|
||||
cd /opt/rauthy-build
|
||||
tar -xf assets/static_html/static_v1.tar.gz
|
||||
tar -xf assets/static_html/templates_html.tar.gz
|
||||
if ! CURL_RETRIES=8 curl_with_retry "https://mds.fidoalliance.org/" "/opt/rauthy-build/mds.jwt"; then
|
||||
msg_error "The FIDO MDS download was rate-limited (HTTP 429); run the script again in a few minutes"
|
||||
exit 7
|
||||
fi
|
||||
CARGO_PROFILE_DEV_DEBUG=0 $STD cargo run --bin fido-mds-prep -- --source mds.jwt
|
||||
CARGO_PROFILE_RELEASE_LTO=thin CARGO_PROFILE_RELEASE_CODEGEN_UNITS=16 \
|
||||
$STD cargo build --release --bin rauthy
|
||||
mkdir -p /opt/rauthy
|
||||
mv target/release/rauthy /opt/rauthy/rauthy
|
||||
cd /opt
|
||||
rm -rf /opt/rauthy-build ~/.cargo/registry
|
||||
msg_ok "Built Rauthy"
|
||||
|
||||
create_self_signed_cert "rauthy"
|
||||
|
||||
msg_info "Configuring Rauthy"
|
||||
mkdir -p /opt/rauthy_data
|
||||
ENC_KEY_ID=$(openssl rand -hex 4)
|
||||
cat <<EOF >/opt/rauthy_data/config.toml
|
||||
## Reference: https://sebadob.github.io/rauthy/config/config.html
|
||||
|
||||
[bootstrap]
|
||||
# Password for admin@localhost, only read when the database is created on the first start
|
||||
password_plain = '$(random_password)'
|
||||
|
||||
[cluster]
|
||||
node_id = 1
|
||||
nodes = ['1 localhost:8100 localhost:8200']
|
||||
data_dir = '/opt/rauthy_data/hiqlite'
|
||||
secret_raft = '$(random_password 48)'
|
||||
secret_api = '$(random_password 48)'
|
||||
|
||||
[email]
|
||||
#smtp_url = 'smtp.example.com'
|
||||
#smtp_username = 'rauthy@example.com'
|
||||
#smtp_password = ''
|
||||
#smtp_from = 'Rauthy <rauthy@example.com>'
|
||||
|
||||
[encryption]
|
||||
keys = ['${ENC_KEY_ID}/$(openssl rand -base64 32)']
|
||||
key_active = '${ENC_KEY_ID}'
|
||||
|
||||
[mfa]
|
||||
# Passkeys need a DNS name, so admin MFA cannot be set up while Rauthy is reached by IP
|
||||
admin_force_mfa = false
|
||||
|
||||
[server]
|
||||
scheme = 'https'
|
||||
pub_url = '${LOCAL_IP}:8443'
|
||||
|
||||
[tls]
|
||||
cert_path = '/etc/ssl/rauthy/rauthy.crt'
|
||||
key_path = '/etc/ssl/rauthy/rauthy.key'
|
||||
|
||||
[webauthn]
|
||||
# Must be a domain, an IP is rejected; set both to the public DNS name before registering passkeys
|
||||
rp_id = 'localhost'
|
||||
rp_origin = 'https://localhost:8443'
|
||||
EOF
|
||||
chmod 600 /opt/rauthy_data/config.toml
|
||||
msg_ok "Configured Rauthy"
|
||||
|
||||
msg_info "Creating Service"
|
||||
cat <<EOF >/etc/systemd/system/rauthy.service
|
||||
[Unit]
|
||||
Description=Rauthy
|
||||
After=network-online.target
|
||||
Wants=network-online.target
|
||||
|
||||
[Service]
|
||||
Type=simple
|
||||
User=root
|
||||
WorkingDirectory=/opt/rauthy_data
|
||||
Environment=MALLOC_CONF=abort_conf:true,narenas:8,tcache_max:4096,dirty_decay_ms:5000,muzzy_decay_ms:5000
|
||||
ExecStart=/opt/rauthy/rauthy serve -c /opt/rauthy_data/config.toml
|
||||
Restart=on-failure
|
||||
RestartSec=5
|
||||
|
||||
[Install]
|
||||
WantedBy=multi-user.target
|
||||
EOF
|
||||
systemctl enable -q --now rauthy
|
||||
msg_ok "Created Service"
|
||||
|
||||
motd_ssh
|
||||
customize
|
||||
cleanup_lxc
|
||||
@@ -0,0 +1,83 @@
|
||||
#!/usr/bin/env bash
|
||||
|
||||
# Copyright (c) 2021-2026 community-scripts ORG
|
||||
# Author: MickLesk (CanbiZ)
|
||||
# License: MIT | https://github.com/community-scripts/ProxmoxVE/raw/main/LICENSE
|
||||
# Source: https://github.com/typecho/typecho
|
||||
|
||||
source /dev/stdin <<<"$FUNCTIONS_FILE_PATH"
|
||||
color
|
||||
verb_ip6
|
||||
catch_errors
|
||||
setting_up_container
|
||||
network_check
|
||||
update_os
|
||||
|
||||
msg_info "Installing Dependencies"
|
||||
$STD apt install -y \
|
||||
nginx \
|
||||
sqlite3
|
||||
msg_ok "Installed Dependencies"
|
||||
|
||||
PHP_FPM="YES" setup_php
|
||||
fetch_and_deploy_gh_release "typecho" "typecho/typecho" "prebuild" "latest" "/opt/typecho" "typecho.zip"
|
||||
fetch_and_deploy_from_url "https://github.com/typecho/languages/releases/download/ci/langs.zip" "/opt/typecho/usr/langs"
|
||||
|
||||
var_admin_user="${var_admin_user:-admin}"
|
||||
var_admin_pass="${var_admin_pass:-$(random_password 16)}"
|
||||
|
||||
msg_info "Installing Typecho"
|
||||
mkdir -p /opt/typecho_data
|
||||
mv /opt/typecho/usr /opt/typecho_data/usr
|
||||
ln -s /opt/typecho_data/usr /opt/typecho/usr
|
||||
cd /opt/typecho
|
||||
TYPECHO_SITE_URL="http://${LOCAL_IP}" \
|
||||
TYPECHO_LANG="en_US" \
|
||||
TYPECHO_DB_ADAPTER="Pdo_SQLite" \
|
||||
TYPECHO_DB_FILE="/opt/typecho_data/typecho.db" \
|
||||
TYPECHO_USER_NAME="${var_admin_user}" \
|
||||
TYPECHO_USER_PASSWORD="${var_admin_pass}" \
|
||||
$STD php install.php
|
||||
# PHP resolves symlinks in __FILE__, so a linked config has to name the root itself
|
||||
sed -i "s|dirname(__FILE__)|'/opt/typecho'|" config.inc.php
|
||||
mv config.inc.php /opt/typecho_data/config.inc.php
|
||||
ln -s /opt/typecho_data/config.inc.php /opt/typecho/config.inc.php
|
||||
rm -f install.php
|
||||
# upstream defaults to UTC+8 and index.php URLs; the vhost below handles rewritten ones
|
||||
sqlite3 /opt/typecho_data/typecho.db "UPDATE typecho_options SET value = '1' WHERE name = 'rewrite'; UPDATE typecho_options SET value = '0' WHERE name = 'timezone';"
|
||||
chown -R www-data:www-data /opt/typecho_data
|
||||
cat <<EOF >~/typecho.creds
|
||||
Typecho Admin
|
||||
URL: http://${LOCAL_IP}/admin/
|
||||
Username: ${var_admin_user}
|
||||
Password: ${var_admin_pass}
|
||||
EOF
|
||||
chmod 600 ~/typecho.creds
|
||||
msg_ok "Installed Typecho"
|
||||
|
||||
msg_info "Configuring Nginx"
|
||||
PHP_SOCK=$(get_php_fpm_socket)
|
||||
cat <<EOF >/etc/nginx/sites-available/typecho
|
||||
server {
|
||||
listen 80 default_server;
|
||||
server_name _;
|
||||
root /opt/typecho;
|
||||
index index.php;
|
||||
client_max_body_size 128M;
|
||||
|
||||
location / {
|
||||
try_files \$uri \$uri/ /index.php\$is_args\$args;
|
||||
}
|
||||
|
||||
location ~ [^/]\.php(/|\$) {
|
||||
include snippets/fastcgi-php.conf;
|
||||
fastcgi_pass unix:${PHP_SOCK};
|
||||
}
|
||||
}
|
||||
EOF
|
||||
nginx_enable_site "typecho"
|
||||
msg_ok "Configured Nginx"
|
||||
|
||||
motd_ssh
|
||||
customize
|
||||
cleanup_lxc
|
||||
@@ -0,0 +1,65 @@
|
||||
#!/usr/bin/env bash
|
||||
|
||||
# Copyright (c) 2021-2026 community-scripts ORG
|
||||
# Author: MickLesk (CanbiZ)
|
||||
# License: MIT | https://github.com/community-scripts/ProxmoxVE/raw/main/LICENSE
|
||||
# Source: https://github.com/windmill-labs/windmill
|
||||
|
||||
source /dev/stdin <<<"$FUNCTIONS_FILE_PATH"
|
||||
color
|
||||
verb_ip6
|
||||
catch_errors
|
||||
setting_up_container
|
||||
network_check
|
||||
update_os
|
||||
|
||||
PG_VERSION="18" setup_postgresql
|
||||
PG_DB_NAME="windmill" PG_DB_USER="windmill" setup_postgresql_db
|
||||
setup_uv
|
||||
NODE_VERSION="24" NODE_MODULE="bun" setup_nodejs
|
||||
fetch_and_deploy_gh_release "windmill" "windmill-labs/windmill" "singlefile" "latest" "/opt/windmill" "windmill-amd64"
|
||||
USE_ORIGINAL_FILENAME="true" fetch_and_deploy_gh_release "windmill-duckdb" "windmill-labs/windmill" "singlefile" "latest" "/opt/windmill" "windmill_duckdb_runner"
|
||||
|
||||
msg_info "Creating Windmill Database Roles"
|
||||
# Windmill's migrations can only create these as superuser (windmill_admin needs BYPASSRLS)
|
||||
$STD sudo -u postgres psql -c "CREATE ROLE windmill_user; CREATE ROLE windmill_admin WITH BYPASSRLS; GRANT windmill_user TO windmill_admin; GRANT windmill_admin, windmill_user TO windmill;"
|
||||
msg_ok "Created Windmill Database Roles"
|
||||
|
||||
msg_info "Configuring Windmill"
|
||||
mkdir -p /opt/windmill_data
|
||||
cat <<EOF >/opt/windmill_data/.env
|
||||
DATABASE_URL=postgres://windmill:${PG_DB_PASS}@127.0.0.1:5432/windmill?sslmode=disable
|
||||
MODE=standalone
|
||||
BASE_URL=http://${LOCAL_IP}:8000
|
||||
EOF
|
||||
chmod 600 /opt/windmill_data/.env
|
||||
msg_ok "Configured Windmill"
|
||||
|
||||
msg_info "Creating Windmill Service"
|
||||
cat <<EOF >/etc/systemd/system/windmill.service
|
||||
[Unit]
|
||||
Description=Windmill
|
||||
After=network.target postgresql.service
|
||||
Requires=postgresql.service
|
||||
|
||||
[Service]
|
||||
Type=simple
|
||||
User=root
|
||||
WorkingDirectory=/opt/windmill
|
||||
EnvironmentFile=/opt/windmill_data/.env
|
||||
# ~/.windmill is the version file, but Windmill keeps its standalone bundles in \$HOME/.windmill
|
||||
Environment=HOME=/opt/windmill_data
|
||||
Environment=WINDMILL_DIR=/opt/windmill_data
|
||||
ExecStart=/opt/windmill/windmill
|
||||
Restart=on-failure
|
||||
RestartSec=5
|
||||
|
||||
[Install]
|
||||
WantedBy=multi-user.target
|
||||
EOF
|
||||
systemctl enable -q --now windmill
|
||||
msg_ok "Created Windmill Service"
|
||||
|
||||
motd_ssh
|
||||
customize
|
||||
cleanup_lxc
|
||||
@@ -0,0 +1,114 @@
|
||||
#!/usr/bin/env bash
|
||||
|
||||
# Copyright (c) 2021-2026 community-scripts ORG
|
||||
# Author: MickLesk (CanbiZ)
|
||||
# License: MIT | https://github.com/community-scripts/ProxmoxVE/raw/main/LICENSE
|
||||
# Source: https://github.com/woodpecker-ci/woodpecker
|
||||
|
||||
source /dev/stdin <<<"$FUNCTIONS_FILE_PATH"
|
||||
color
|
||||
verb_ip6
|
||||
catch_errors
|
||||
setting_up_container
|
||||
network_check
|
||||
update_os
|
||||
|
||||
msg_info "Installing Dependencies"
|
||||
$STD apt install -y \
|
||||
git \
|
||||
git-lfs
|
||||
msg_ok "Installed Dependencies"
|
||||
|
||||
fetch_and_deploy_gh_release "woodpecker-server" "woodpecker-ci/woodpecker" "prebuild" "latest" "/opt/woodpecker" "woodpecker-server_linux_$(arch_resolve).tar.gz"
|
||||
fetch_and_deploy_gh_release "woodpecker-agent" "woodpecker-ci/woodpecker" "prebuild" "latest" "/opt/woodpecker" "woodpecker-agent_linux_$(arch_resolve).tar.gz"
|
||||
# The local backend clones with plugin-git from PATH; without it every workflow downloads it from the GitHub API
|
||||
fetch_and_deploy_gh_release "plugin-git" "woodpecker-ci/plugin-git" "singlefile" "latest" "/usr/local/bin" "linux-$(arch_resolve)_plugin-git"
|
||||
|
||||
msg_info "Configuring Woodpecker CI"
|
||||
mkdir -p /opt/woodpecker_data/workspaces
|
||||
AGENT_SECRET=$(openssl rand -hex 32)
|
||||
cat <<EOF >/opt/woodpecker_data/server.env
|
||||
WOODPECKER_HOST=http://${LOCAL_IP}:8000
|
||||
WOODPECKER_AGENT_SECRET=${AGENT_SECRET}
|
||||
WOODPECKER_GRPC_SECRET=$(openssl rand -hex 32)
|
||||
WOODPECKER_DATABASE_DRIVER=sqlite3
|
||||
WOODPECKER_DATABASE_DATASOURCE=/opt/woodpecker_data/woodpecker.sqlite
|
||||
WOODPECKER_OPEN=false
|
||||
WOODPECKER_ADMIN=${var_forge_admin:-}
|
||||
EOF
|
||||
if [[ -n "${var_forge:-}" ]]; then
|
||||
cat <<EOF >>/opt/woodpecker_data/server.env
|
||||
WOODPECKER_${var_forge^^}=true
|
||||
WOODPECKER_${var_forge^^}_URL=${var_forge_url:-}
|
||||
WOODPECKER_${var_forge^^}_CLIENT=${var_forge_client}
|
||||
WOODPECKER_${var_forge^^}_SECRET=${var_forge_secret}
|
||||
EOF
|
||||
else
|
||||
cat <<EOF >>/opt/woodpecker_data/server.env
|
||||
# Woodpecker CI signs users in through one forge. Create an OAuth app there with the
|
||||
# callback URL http://${LOCAL_IP}:8000/authorize, set your forge login in WOODPECKER_ADMIN
|
||||
# and fill in the block below. GitHub, Gitea, GitLab and Bitbucket use the same
|
||||
# WOODPECKER_<FORGE>_* names: https://woodpecker-ci.org/docs/administration/configuration/forges/overview
|
||||
# Then run: systemctl enable --now woodpecker-server woodpecker-agent
|
||||
#WOODPECKER_FORGEJO=true
|
||||
#WOODPECKER_FORGEJO_URL=https://forgejo.example.com
|
||||
#WOODPECKER_FORGEJO_CLIENT=
|
||||
#WOODPECKER_FORGEJO_SECRET=
|
||||
EOF
|
||||
fi
|
||||
# Debian 13 keeps /tmp in RAM, so workflows are checked out on disk instead
|
||||
cat <<EOF >/opt/woodpecker_data/agent.env
|
||||
WOODPECKER_SERVER=localhost:9000
|
||||
WOODPECKER_AGENT_SECRET=${AGENT_SECRET}
|
||||
WOODPECKER_BACKEND=local
|
||||
WOODPECKER_BACKEND_LOCAL_TEMP_DIR=/opt/woodpecker_data/workspaces
|
||||
WOODPECKER_AGENT_CONFIG_FILE=/opt/woodpecker_data/agent.conf
|
||||
EOF
|
||||
chmod 600 /opt/woodpecker_data/server.env /opt/woodpecker_data/agent.env
|
||||
msg_ok "Configured Woodpecker CI"
|
||||
|
||||
msg_info "Creating Woodpecker CI Services"
|
||||
cat <<EOF >/etc/systemd/system/woodpecker-server.service
|
||||
[Unit]
|
||||
Description=Woodpecker CI Server
|
||||
After=network-online.target
|
||||
Wants=network-online.target
|
||||
|
||||
[Service]
|
||||
Type=simple
|
||||
User=root
|
||||
WorkingDirectory=/opt/woodpecker_data
|
||||
EnvironmentFile=/opt/woodpecker_data/server.env
|
||||
ExecStart=/opt/woodpecker/woodpecker-server
|
||||
Restart=on-failure
|
||||
RestartSec=5
|
||||
|
||||
[Install]
|
||||
WantedBy=multi-user.target
|
||||
EOF
|
||||
cat <<EOF >/etc/systemd/system/woodpecker-agent.service
|
||||
[Unit]
|
||||
Description=Woodpecker CI Agent
|
||||
After=network-online.target woodpecker-server.service
|
||||
Wants=network-online.target
|
||||
|
||||
[Service]
|
||||
Type=simple
|
||||
User=root
|
||||
WorkingDirectory=/opt/woodpecker_data
|
||||
EnvironmentFile=/opt/woodpecker_data/agent.env
|
||||
ExecStart=/opt/woodpecker/woodpecker-agent
|
||||
Restart=on-failure
|
||||
RestartSec=5
|
||||
|
||||
[Install]
|
||||
WantedBy=multi-user.target
|
||||
EOF
|
||||
if [[ -n "${var_forge:-}" ]]; then
|
||||
systemctl enable -q --now woodpecker-server woodpecker-agent
|
||||
fi
|
||||
msg_ok "Created Woodpecker CI Services"
|
||||
|
||||
motd_ssh
|
||||
customize
|
||||
cleanup_lxc
|
||||
@@ -0,0 +1,174 @@
|
||||
#!/usr/bin/env bash
|
||||
|
||||
# community-scripts ORG | Immich Power Tools Addon Installer
|
||||
# Author: MickLesk (CanbiZ)
|
||||
# License: MIT | https://github.com/community-scripts/ProxmoxVE/raw/main/LICENSE
|
||||
# Source: https://github.com/immich-power-tools/immich-power-tools
|
||||
|
||||
if command -v curl >/dev/null 2>&1; then
|
||||
source <(curl -fsSL "${COMMUNITY_SCRIPTS_CORE_URL:-https://raw.githubusercontent.com/community-scripts/core/main}/core/core.func")
|
||||
load_functions
|
||||
elif command -v wget >/dev/null 2>&1; then
|
||||
source <(wget -qO- "${COMMUNITY_SCRIPTS_CORE_URL:-https://raw.githubusercontent.com/community-scripts/core/main}/core/core.func")
|
||||
load_functions
|
||||
fi
|
||||
source <(curl -fsSL "${COMMUNITY_SCRIPTS_CORE_URL:-https://raw.githubusercontent.com/community-scripts/core/main}/lib/tools.func")
|
||||
source <(curl -fsSL "${COMMUNITY_SCRIPTS_CORE_URL:-https://raw.githubusercontent.com/community-scripts/core/main}/core/error_handler.func")
|
||||
|
||||
APP="Immich Power Tools"
|
||||
APP_TYPE="addon"
|
||||
|
||||
header_info "$APP"
|
||||
color
|
||||
catch_errors
|
||||
|
||||
if [[ ! -f /opt/immich/.env ]] || ! systemctl is-active --quiet immich-web; then
|
||||
msg_error "Immich is not installed or not running. Install the Immich LXC first, then run this addon inside it."
|
||||
exit 1
|
||||
fi
|
||||
|
||||
if [[ "$(cut -d. -f1 ~/.immich 2>/dev/null)" -lt 3 ]]; then
|
||||
msg_error "Immich Power Tools needs Immich 3.0 or newer. Update the Immich LXC first."
|
||||
exit 1
|
||||
fi
|
||||
|
||||
MEM_MB=$(awk '/MemTotal/ {printf "%.0f", $2/1024}' /proc/meminfo)
|
||||
if ((MEM_MB < 4096)); then
|
||||
msg_error "Insufficient memory: ${MEM_MB} MB detected. At least 4096 MB RAM is required to build Immich Power Tools."
|
||||
exit 1
|
||||
fi
|
||||
|
||||
get_lxc_ip
|
||||
|
||||
function build_power_tools() {
|
||||
cd /opt/immich-power-tools || exit 1
|
||||
$STD bun install --frozen-lockfile
|
||||
VERSION="$(cat ~/.immich-power-tools)" NEXT_TELEMETRY_DISABLED=1 $STD npm run build
|
||||
cp -r public .next/standalone/
|
||||
cp -r .next/static .next/standalone/.next/
|
||||
mkdir -p .next/standalone/src/db
|
||||
cp -r src/db/migrations .next/standalone/src/db/
|
||||
cp -r node_modules/@libsql node_modules/libsql .next/standalone/node_modules/
|
||||
rm -rf node_modules .next/cache
|
||||
$STD bun pm cache rm
|
||||
}
|
||||
|
||||
function install_ui() {
|
||||
if [[ -z "${var_immich_api_key:-}" ]]; then
|
||||
var_immich_api_key=$(prompt_input "Immich API key (empty = log in with your Immich account):" "" 120)
|
||||
fi
|
||||
|
||||
NODE_VERSION="24" NODE_MODULE="bun" setup_nodejs
|
||||
fetch_and_deploy_gh_release "immich-power-tools" "immich-power-tools/immich-power-tools" "tarball"
|
||||
|
||||
msg_info "Building Immich Power Tools"
|
||||
build_power_tools
|
||||
msg_ok "Built Immich Power Tools"
|
||||
|
||||
msg_info "Configuring Immich Power Tools"
|
||||
IMMICH_PORT=$(sed -n 's/^IMMICH_PORT=//p' /opt/immich/.env)
|
||||
DB_PORT=$(sed -n 's/^DB_PORT=//p' /opt/immich/.env)
|
||||
mkdir -p /opt/immich-power-tools_data
|
||||
cat <<EOF >/opt/immich-power-tools_data/.env
|
||||
NODE_ENV=production
|
||||
NEXT_TELEMETRY_DISABLED=1
|
||||
PORT=8001
|
||||
HOSTNAME=0.0.0.0
|
||||
APP_DB_PATH=/opt/immich-power-tools_data/app.db
|
||||
|
||||
IMMICH_URL=http://127.0.0.1:${IMMICH_PORT:-2283}
|
||||
EXTERNAL_IMMICH_URL=http://${LOCAL_IP}:${IMMICH_PORT:-2283}
|
||||
# Immich > Account Settings > API Keys (all permissions). Empty = log in with an Immich account.
|
||||
# With a key there is no login: everyone reaching port 8001 acts as the key's owner.
|
||||
IMMICH_API_KEY=${var_immich_api_key}
|
||||
|
||||
DB_HOST=$(sed -n 's/^DB_HOSTNAME=//p' /opt/immich/.env)
|
||||
DB_PORT=${DB_PORT:-5432}
|
||||
$(grep -E '^DB_(USERNAME|PASSWORD|DATABASE_NAME)=' /opt/immich/.env)
|
||||
|
||||
SECURE_COOKIE=false
|
||||
JWT_SECRET=$(openssl rand -hex 32)
|
||||
POWER_TOOLS_ENDPOINT_URL=http://${LOCAL_IP}:8001
|
||||
|
||||
# Optional, any OpenAI-compatible API for "Find"
|
||||
# AI_API_KEY=
|
||||
# AI_BASE_URL=https://api.openai.com/v1
|
||||
# AI_MODEL=gpt-4o-mini
|
||||
EOF
|
||||
chmod 600 /opt/immich-power-tools_data/.env
|
||||
|
||||
cat <<EOF >/etc/systemd/system/immich-power-tools.service
|
||||
[Unit]
|
||||
Description=Immich Power Tools
|
||||
After=network.target postgresql.service immich-web.service
|
||||
|
||||
[Service]
|
||||
Type=simple
|
||||
User=root
|
||||
WorkingDirectory=/opt/immich-power-tools/.next/standalone
|
||||
EnvironmentFile=/opt/immich-power-tools_data/.env
|
||||
ExecStart=/usr/bin/node /opt/immich-power-tools/.next/standalone/server.js
|
||||
Restart=on-failure
|
||||
RestartSec=5
|
||||
|
||||
[Install]
|
||||
WantedBy=multi-user.target
|
||||
EOF
|
||||
systemctl enable -q --now immich-power-tools
|
||||
msg_ok "Configured Immich Power Tools"
|
||||
|
||||
msg_ok "Immich Power Tools installed at http://${LOCAL_IP}:8001"
|
||||
if [[ -n "$var_immich_api_key" ]]; then
|
||||
msg_warn "Immich Power Tools has no login with an API key: everyone reaching port 8001 acts as the key's owner"
|
||||
else
|
||||
echo -e "${INFO}${YW} Log in with your Immich account, or set IMMICH_API_KEY in /opt/immich-power-tools_data/.env and run: systemctl restart immich-power-tools${CL}"
|
||||
fi
|
||||
}
|
||||
|
||||
function uninstall_ui() {
|
||||
msg_info "Uninstalling Immich Power Tools"
|
||||
systemctl disable -q --now immich-power-tools
|
||||
rm -f /etc/systemd/system/immich-power-tools.service
|
||||
systemctl daemon-reload
|
||||
rm -rf /opt/immich-power-tools /opt/immich-power-tools_data ~/.immich-power-tools
|
||||
msg_ok "Uninstalled Immich Power Tools"
|
||||
}
|
||||
|
||||
function update_ui() {
|
||||
if check_for_gh_release "immich-power-tools" "immich-power-tools/immich-power-tools"; then
|
||||
msg_info "Stopping Immich Power Tools"
|
||||
systemctl stop immich-power-tools
|
||||
msg_ok "Stopped Immich Power Tools"
|
||||
|
||||
NODE_VERSION="24" NODE_MODULE="bun" setup_nodejs
|
||||
CLEAN_INSTALL=1 fetch_and_deploy_gh_release "immich-power-tools" "immich-power-tools/immich-power-tools" "tarball"
|
||||
|
||||
msg_info "Building Immich Power Tools"
|
||||
build_power_tools
|
||||
msg_ok "Built Immich Power Tools"
|
||||
|
||||
msg_info "Starting Immich Power Tools"
|
||||
systemctl start immich-power-tools
|
||||
msg_ok "Started Immich Power Tools"
|
||||
msg_ok "Updated Immich Power Tools"
|
||||
fi
|
||||
}
|
||||
|
||||
if [[ -f /etc/systemd/system/immich-power-tools.service ]]; then
|
||||
read -r -p "Update (1), Uninstall (2), Cancel (3)? [1/2/3]: " action
|
||||
action="${action//[[:space:]]/}"
|
||||
case "$action" in
|
||||
1) update_ui ;;
|
||||
2) uninstall_ui ;;
|
||||
3) msg_warn "Cancelled" ;;
|
||||
*) msg_error "Invalid input" ;;
|
||||
esac
|
||||
else
|
||||
read -r -p "Install Immich Power Tools? (y/n): " answer
|
||||
answer="${answer//[[:space:]]/}"
|
||||
if [[ "${answer,,}" =~ ^(y|yes)$ ]]; then
|
||||
install_ui
|
||||
else
|
||||
msg_warn "Installation of Immich Power Tools skipped"
|
||||
fi
|
||||
fi
|
||||
@@ -0,0 +1,114 @@
|
||||
#!/usr/bin/env bash
|
||||
|
||||
# community-scripts ORG | VueTorrent Addon Installer
|
||||
# Author: MickLesk (CanbiZ)
|
||||
# License: MIT | https://github.com/community-scripts/ProxmoxVE/raw/main/LICENSE
|
||||
# Source: https://github.com/VueTorrent/VueTorrent
|
||||
|
||||
if command -v curl >/dev/null 2>&1; then
|
||||
source <(curl -fsSL "${COMMUNITY_SCRIPTS_CORE_URL:-https://raw.githubusercontent.com/community-scripts/core/main}/core/core.func")
|
||||
load_functions
|
||||
elif command -v wget >/dev/null 2>&1; then
|
||||
source <(wget -qO- "${COMMUNITY_SCRIPTS_CORE_URL:-https://raw.githubusercontent.com/community-scripts/core/main}/core/core.func")
|
||||
load_functions
|
||||
fi
|
||||
source <(curl -fsSL "${COMMUNITY_SCRIPTS_CORE_URL:-https://raw.githubusercontent.com/community-scripts/core/main}/lib/tools.func")
|
||||
source <(curl -fsSL "${COMMUNITY_SCRIPTS_CORE_URL:-https://raw.githubusercontent.com/community-scripts/core/main}/core/error_handler.func")
|
||||
|
||||
color
|
||||
catch_errors
|
||||
|
||||
APP="VueTorrent"
|
||||
APP_TYPE="addon"
|
||||
QBT_CONF="/root/.config/qBittorrent/qBittorrent.conf"
|
||||
|
||||
header_info "$APP"
|
||||
require_debian_like
|
||||
get_lxc_ip
|
||||
|
||||
if [[ ! -f /etc/systemd/system/qbittorrent-nox.service || ! -f "$QBT_CONF" ]]; then
|
||||
msg_error "qBittorrent is not installed. Install the qBittorrent LXC first, then run the VueTorrent addon inside it."
|
||||
exit 1
|
||||
fi
|
||||
|
||||
QBT_PORT=$(sed -nE '/^(WebUI\\)?Port=/{s/^[^=]*=//p;q}' "$QBT_CONF")
|
||||
|
||||
# qBittorrent 5.3 moved the WebUI keys from [Preferences] (WebUI\Key) to their own [WebUI] section
|
||||
function qbt_webui_set() {
|
||||
local section="Preferences" key="WebUI\\$1" tmp
|
||||
if grep -q '^\[WebUI\]' "$QBT_CONF"; then
|
||||
section="WebUI"
|
||||
key="$1"
|
||||
fi
|
||||
tmp=$(mktemp)
|
||||
SECTION="[${section}]" KEY="${key}=" LINE="${key}=$2" awk '
|
||||
/^\[/ { in_section = ($0 == ENVIRON["SECTION"]) }
|
||||
in_section && index($0, ENVIRON["KEY"]) == 1 { next }
|
||||
{ print }
|
||||
in_section && $0 == ENVIRON["SECTION"] && !done { print ENVIRON["LINE"]; done = 1 }
|
||||
END { if (!done) printf "\n%s\n%s\n", ENVIRON["SECTION"], ENVIRON["LINE"] }
|
||||
' "$QBT_CONF" >"$tmp"
|
||||
cat "$tmp" >"$QBT_CONF"
|
||||
rm -f "$tmp"
|
||||
}
|
||||
|
||||
function install_vuetorrent() {
|
||||
fetch_and_deploy_gh_release "vuetorrent" "VueTorrent/VueTorrent" "prebuild" "latest" "/opt/vuetorrent" "vuetorrent.zip"
|
||||
|
||||
# qBittorrent writes its config back on shutdown, so it has to be stopped before editing
|
||||
msg_info "Enabling VueTorrent in qBittorrent"
|
||||
systemctl stop qbittorrent-nox
|
||||
qbt_webui_set AlternativeUIEnabled true
|
||||
qbt_webui_set RootFolder /opt/vuetorrent
|
||||
systemctl start qbittorrent-nox
|
||||
msg_ok "Enabled VueTorrent in qBittorrent"
|
||||
|
||||
echo ""
|
||||
msg_ok "VueTorrent is reachable at: ${BL}http://${LOCAL_IP}:${QBT_PORT:-8080}${CL}"
|
||||
echo -e "${INFO}${YW} Log in with your qBittorrent WebUI credentials${CL}"
|
||||
}
|
||||
|
||||
function update_vuetorrent() {
|
||||
if check_for_gh_release "vuetorrent" "VueTorrent/VueTorrent"; then
|
||||
# qBittorrent turns the alternative UI off for good if index.html is missing on a request, so swap instead of wiping in place
|
||||
CLEAN_INSTALL=1 fetch_and_deploy_gh_release "vuetorrent" "VueTorrent/VueTorrent" "prebuild" "latest" "/opt/vuetorrent.new" "vuetorrent.zip"
|
||||
rm -rf /opt/vuetorrent.old
|
||||
mv /opt/vuetorrent /opt/vuetorrent.old
|
||||
mv /opt/vuetorrent.new /opt/vuetorrent
|
||||
rm -rf /opt/vuetorrent.old
|
||||
msg_ok "Updated VueTorrent"
|
||||
fi
|
||||
}
|
||||
|
||||
function uninstall_vuetorrent() {
|
||||
msg_info "Uninstalling VueTorrent"
|
||||
systemctl stop qbittorrent-nox
|
||||
qbt_webui_set AlternativeUIEnabled false
|
||||
qbt_webui_set RootFolder ""
|
||||
rm -rf /opt/vuetorrent "$HOME/.vuetorrent"
|
||||
systemctl start qbittorrent-nox
|
||||
msg_ok "Uninstalled VueTorrent, qBittorrent is back on its built-in WebUI"
|
||||
}
|
||||
|
||||
if [[ -d /opt/vuetorrent ]]; then
|
||||
if [[ "${type:-}" == "update" ]]; then
|
||||
update_vuetorrent
|
||||
exit 0
|
||||
fi
|
||||
read -r -p "${TAB}Update (1), Uninstall (2), Cancel (3)? [1/2/3]: " action || action=""
|
||||
action="${action//[[:space:]]/}"
|
||||
case "$action" in
|
||||
1) update_vuetorrent ;;
|
||||
2) uninstall_vuetorrent ;;
|
||||
3) msg_warn "No changes made to VueTorrent" ;;
|
||||
*) msg_error "Invalid input - no changes made to VueTorrent" ;;
|
||||
esac
|
||||
else
|
||||
read -r -p "${TAB}Install VueTorrent? (y/n): " answer || answer=""
|
||||
answer="${answer//[[:space:]]/}"
|
||||
if [[ "${answer,,}" =~ ^(y|yes)$ ]]; then
|
||||
install_vuetorrent
|
||||
else
|
||||
msg_warn "VueTorrent installation skipped"
|
||||
fi
|
||||
fi
|
||||
@@ -111,9 +111,18 @@ while true; do
|
||||
continue
|
||||
fi
|
||||
# Read the IP from the host side; pct exec depends on tools inside the
|
||||
# guest, which minimal/OCI images may lack.
|
||||
IP=$(lxc-info -n "$instance" -iH 2>/dev/null | awk '/^[0-9.]+$/ && !/^(127|169\.254)\./ {print; exit}')
|
||||
if [ -z "$IP" ] || ! ping -c 1 -W 2 "$IP" >/dev/null 2>&1; then
|
||||
# guest, which minimal/OCI images may lack. net0's address comes first:
|
||||
# lxc-info lists Docker bridges and VPN tunnels too, often before it.
|
||||
net0=$(value_of net0)
|
||||
IP=$(grep -oP '(^|,)ip=\K[0-9.]+(?=/)' <<<"$net0" || true)
|
||||
if [ -z "$IP" ]; then
|
||||
iface=$(grep -oP '(^|,)name=\K[^,]+' <<<"$net0" || true)
|
||||
pid=$(lxc-info -n "$instance" -pH 2>/dev/null)
|
||||
[ -n "$pid" ] && IP=$(nsenter -t "$pid" -n ip -4 -o addr show dev "${iface:-eth0}" scope global 2>/dev/null | awk '{sub(/\/.*/, "", $4); print $4; exit}')
|
||||
fi
|
||||
[ -z "$IP" ] && IP=$(lxc-info -n "$instance" -iH 2>/dev/null | awk '/^[0-9.]+$/ && !/^(127|169\.254)\./ {print; exit}')
|
||||
# Two rounds of three pings, so one lost packet does not restart it.
|
||||
if [ -z "$IP" ] || ! { ping -c 3 -W 2 "$IP" >/dev/null 2>&1 || { sleep 5 && ping -c 3 -W 2 "$IP" >/dev/null 2>&1; }; }; then
|
||||
echo "$(date): CT $instance is not responding, restarting..."
|
||||
pct stop "$instance" >/dev/null 2>&1
|
||||
sleep 5
|
||||
|
||||
Reference in new issue
Block a user