mirror of
https://github.com/community-scripts/ProxmoxVE.git
synced 2025-07-02 20:17:37 +00:00
Compare commits
29 Commits
2025-06-18
...
2025-06-19
Author | SHA1 | Date | |
---|---|---|---|
ad8462bc10 | |||
39b18ea011 | |||
76c99518b1 | |||
8fb0a16568 | |||
9bbc0c90e3 | |||
b5012c4225 | |||
204ec64f14 | |||
451608b445 | |||
94ad4f2e40 | |||
5db3d92286 | |||
796aaaa1d4 | |||
5042f6edb0 | |||
0c1fad54b6 | |||
fe1df0b344 | |||
3ca014b757 | |||
db7a13fced | |||
ab1f4c1196 | |||
14ffff4c6a | |||
bada204f64 | |||
1c42a2016e | |||
0cd347d3b6 | |||
63713c6489 | |||
49153887dc | |||
c46d543c43 | |||
dbd2af91b5 | |||
86183c638d | |||
aec9af49a0 | |||
791eca99b9 | |||
4190582659 |
BIN
.gitattributes
vendored
BIN
.gitattributes
vendored
Binary file not shown.
4
.github/CONTRIBUTOR_AND_GUIDES/CODE-AUDIT.md
generated
vendored
4
.github/CONTRIBUTOR_AND_GUIDES/CODE-AUDIT.md
generated
vendored
@ -5,10 +5,10 @@
|
||||
|
||||
1) [adguard.sh](https://github.com/community-scripts/ProxmoxVE/blob/main/ct/adguard.sh): This script collects system parameters. (Also holds the function to update the application.)
|
||||
2) [build.func](https://github.com/community-scripts/ProxmoxVE/blob/main/misc/build.func): Adds user settings and integrates collected information.
|
||||
3) [create_lxc.sh](https://github.com/community-scripts/ProxmoxVE/blob/main/ct/create_lxc.sh): Constructs the LXC container.
|
||||
3) [create_lxc.sh](https://github.com/community-scripts/ProxmoxVE/blob/main/misc/create_lxc.sh): Constructs the LXC container.
|
||||
4) [adguard-install.sh](https://github.com/community-scripts/ProxmoxVE/blob/main/install/adguard-install.sh): Executes functions from [install.func](https://github.com/community-scripts/ProxmoxVE/blob/main/misc/install.func), and installs the application.
|
||||
5) [adguard.sh](https://github.com/community-scripts/ProxmoxVE/blob/main/ct/adguard.sh) (again): To display the completion message.
|
||||
|
||||
The installation process uses reusable scripts: [build.func](https://github.com/community-scripts/ProxmoxVE/blob/main/misc/build.func), [create_lxc.sh](https://github.com/community-scripts/ProxmoxVE/blob/main/ct/create_lxc.sh), and [install.func](https://github.com/community-scripts/ProxmoxVE/blob/main/misc/install.func), which are not specific to any particular application.
|
||||
The installation process uses reusable scripts: [build.func](https://github.com/community-scripts/ProxmoxVE/blob/main/misc/build.func), [create_lxc.sh](https://github.com/community-scripts/ProxmoxVE/blob/main/misc/create_lxc.sh), and [install.func](https://github.com/community-scripts/ProxmoxVE/blob/main/misc/install.func), which are not specific to any particular application.
|
||||
|
||||
To gain a better understanding, focus on reviewing [adguard-install.sh](https://github.com/community-scripts/ProxmoxVE/blob/main/install/adguard-install.sh). This script contains the commands and configurations for installing and configuring AdGuard Home within the LXC container.
|
||||
|
61
.github/autolabeler-config.json
generated
vendored
61
.github/autolabeler-config.json
generated
vendored
@ -2,21 +2,43 @@
|
||||
"new script": [
|
||||
{
|
||||
"fileStatus": "added",
|
||||
"includeGlobs": ["ct/**", "install/**", "misc/**", "turnkey/**", "vm/**"],
|
||||
"includeGlobs": [
|
||||
"ct/**",
|
||||
"install/**",
|
||||
"misc/**",
|
||||
"turnkey/**",
|
||||
"vm/**"
|
||||
],
|
||||
"excludeGlobs": []
|
||||
}
|
||||
],
|
||||
"update script": [
|
||||
{
|
||||
"fileStatus": "modified",
|
||||
"includeGlobs": ["ct/**", "install/**", "misc/**", "turnkey/**", "vm/**"],
|
||||
"excludeGlobs": ["misc/build.func", "misc/install.func", "misc/api.func"]
|
||||
"includeGlobs": [
|
||||
"ct/**",
|
||||
"install/**",
|
||||
"misc/**",
|
||||
"turnkey/**",
|
||||
"vm/**"
|
||||
],
|
||||
"excludeGlobs": [
|
||||
"misc/build.func",
|
||||
"misc/install.func",
|
||||
"misc/api.func"
|
||||
]
|
||||
}
|
||||
],
|
||||
"delete script": [
|
||||
{
|
||||
"fileStatus": "removed",
|
||||
"includeGlobs": ["ct/**", "install/**", "misc/**", "turnkey/**", "vm/**"],
|
||||
"includeGlobs": [
|
||||
"ct/**",
|
||||
"install/**",
|
||||
"misc/**",
|
||||
"turnkey/**",
|
||||
"vm/**"
|
||||
],
|
||||
"excludeGlobs": []
|
||||
}
|
||||
],
|
||||
@ -27,7 +49,7 @@
|
||||
"*.md",
|
||||
".github/**",
|
||||
"misc/*.func",
|
||||
"ct/create_lxc.sh",
|
||||
"misc/create_lxc.sh",
|
||||
"api/**"
|
||||
],
|
||||
"excludeGlobs": []
|
||||
@ -36,46 +58,57 @@
|
||||
"core": [
|
||||
{
|
||||
"fileStatus": null,
|
||||
"includeGlobs": ["misc/*.func", "ct/create_lxc.sh"],
|
||||
"includeGlobs": [
|
||||
"misc/*.func",
|
||||
"misc/create_lxc.sh"
|
||||
],
|
||||
"excludeGlobs": []
|
||||
}
|
||||
],
|
||||
"website": [
|
||||
{
|
||||
"fileStatus": null,
|
||||
"includeGlobs": ["frontend/**"],
|
||||
"includeGlobs": [
|
||||
"frontend/**"
|
||||
],
|
||||
"excludeGlobs": []
|
||||
}
|
||||
],
|
||||
"api": [
|
||||
{
|
||||
"fileStatus": null,
|
||||
"includeGlobs": ["api/**", "misc/api.func"],
|
||||
"includeGlobs": [
|
||||
"api/**",
|
||||
"misc/api.func"
|
||||
],
|
||||
"excludeGlobs": []
|
||||
}
|
||||
],
|
||||
"github": [
|
||||
{
|
||||
"fileStatus": null,
|
||||
"includeGlobs": [".github/**"],
|
||||
"includeGlobs": [
|
||||
".github/**"
|
||||
],
|
||||
"excludeGlobs": []
|
||||
}
|
||||
],
|
||||
"json": [
|
||||
{
|
||||
"fileStatus": "modified",
|
||||
"includeGlobs": ["frontend/public/json/**"],
|
||||
"includeGlobs": [
|
||||
"frontend/public/json/**"
|
||||
],
|
||||
"excludeGlobs": []
|
||||
}
|
||||
],
|
||||
|
||||
"high risk": [
|
||||
{
|
||||
"fileStatus": null,
|
||||
"includeGlobs": [
|
||||
"misc/build.func",
|
||||
"misc/install.func",
|
||||
"ct/create_lxc.sh"
|
||||
"misc/create_lxc.sh"
|
||||
],
|
||||
"excludeGlobs": []
|
||||
}
|
||||
@ -83,7 +116,9 @@
|
||||
"documentation": [
|
||||
{
|
||||
"fileStatus": null,
|
||||
"includeGlobs": ["*.md"],
|
||||
"includeGlobs": [
|
||||
"*.md"
|
||||
],
|
||||
"excludeGlobs": []
|
||||
}
|
||||
]
|
||||
|
4
.github/workflows/validate-filenames.yml
generated
vendored
4
.github/workflows/validate-filenames.yml
generated
vendored
@ -51,8 +51,8 @@ jobs:
|
||||
|
||||
NON_COMPLIANT_FILES=""
|
||||
for FILE in $CHANGED_FILES; do
|
||||
# Datei "ct/create_lxc.sh" explizit überspringen
|
||||
if [[ "$FILE" == "ct/create_lxc.sh" ]]; then
|
||||
# Skip File "misc/create_lxc.sh"
|
||||
if [[ "$FILE" == "misc/create_lxc.sh" ]]; then
|
||||
continue
|
||||
fi
|
||||
BASENAME=$(echo "$(basename "${FILE%.*}")")
|
||||
|
28
CHANGELOG.md
28
CHANGELOG.md
@ -14,8 +14,36 @@ Exercise vigilance regarding copycat or coat-tailing sites that seek to exploit
|
||||
All LXC instances created using this repository come pre-installed with Midnight Commander, which is a command-line tool (`mc`) that offers a user-friendly file and directory management interface for the terminal environment.
|
||||
|
||||
|
||||
## 2025-06-20
|
||||
|
||||
## 2025-06-19
|
||||
|
||||
### 🆕 New Scripts
|
||||
|
||||
- Ubuntu 25.04 VM [@MickLesk](https://github.com/MickLesk) ([#5284](https://github.com/community-scripts/ProxmoxVE/pull/5284))
|
||||
- PLANKA ([#5277](https://github.com/community-scripts/ProxmoxVE/pull/5277))
|
||||
- Wizarr ([#5273](https://github.com/community-scripts/ProxmoxVE/pull/5273))
|
||||
|
||||
### 🚀 Updated Scripts
|
||||
|
||||
- #### 🐞 Bug Fixes
|
||||
|
||||
- immich-install.sh: restore pgvector module install [@vhsdream](https://github.com/vhsdream) ([#5286](https://github.com/community-scripts/ProxmoxVE/pull/5286))
|
||||
- Immich: prepare for v1.135.0 [@vhsdream](https://github.com/vhsdream) ([#5025](https://github.com/community-scripts/ProxmoxVE/pull/5025))
|
||||
|
||||
### 🧰 Maintenance
|
||||
|
||||
- #### ✨ New Features
|
||||
|
||||
- [core]: Feature - Check Quorum Status in create_lxc to prevent issues [@MickLesk](https://github.com/MickLesk) ([#5278](https://github.com/community-scripts/ProxmoxVE/pull/5278))
|
||||
- [core]: add validation and replace recursion for invalid inputs in adv. settings [@MickLesk](https://github.com/MickLesk) ([#5291](https://github.com/community-scripts/ProxmoxVE/pull/5291))
|
||||
|
||||
### 🌐 Website
|
||||
|
||||
- #### 📝 Script Information
|
||||
|
||||
- cloudflare-ddns: fix typo in info-text [@LukaZagar](https://github.com/LukaZagar) ([#5263](https://github.com/community-scripts/ProxmoxVE/pull/5263))
|
||||
|
||||
## 2025-06-18
|
||||
|
||||
### 🆕 New Scripts
|
||||
|
6
ct/headers/planka
Normal file
6
ct/headers/planka
Normal file
@ -0,0 +1,6 @@
|
||||
____ __ ___ _ ____ __ ___
|
||||
/ __ \/ / / | / | / / //_// |
|
||||
/ /_/ / / / /| | / |/ / ,< / /| |
|
||||
/ ____/ /___/ ___ |/ /| / /| |/ ___ |
|
||||
/_/ /_____/_/ |_/_/ |_/_/ |_/_/ |_|
|
||||
|
6
ct/headers/wizarr
Normal file
6
ct/headers/wizarr
Normal file
@ -0,0 +1,6 @@
|
||||
_ ___
|
||||
| | / (_)___ ____ ___________
|
||||
| | /| / / /_ / / __ `/ ___/ ___/
|
||||
| |/ |/ / / / /_/ /_/ / / / /
|
||||
|__/|__/_/ /___/\__,_/_/ /_/
|
||||
|
88
ct/immich.sh
88
ct/immich.sh
@ -27,6 +27,9 @@ function update_script() {
|
||||
msg_error "No ${APP} Installation Found!"
|
||||
exit
|
||||
fi
|
||||
|
||||
setup_uv
|
||||
|
||||
STAGING_DIR=/opt/staging
|
||||
BASE_DIR=${STAGING_DIR}/base-images
|
||||
SOURCE_DIR=${STAGING_DIR}/image-source
|
||||
@ -40,7 +43,7 @@ function update_script() {
|
||||
for url in "${INTEL_URLS[@]}"; do
|
||||
curl -fsSLO "$url"
|
||||
done
|
||||
$STD dpkg -i ./*.deb
|
||||
$STD apt install -y ./*.deb
|
||||
rm ./*.deb
|
||||
msg_ok "Intel iGPU dependencies updated"
|
||||
fi
|
||||
@ -177,54 +180,42 @@ function update_script() {
|
||||
msg_ok "Image-processing libraries compiled"
|
||||
fi
|
||||
fi
|
||||
RELEASE=$(curl -s https://api.github.com/repos/immich-app/immich/releases?per_page=1 | grep "tag_name" | awk '{print substr($2, 3, length($2)-4) }')
|
||||
RELEASE=$(curl -fsSL https://api.github.com/repos/immich-app/immich/releases?per_page=1 | grep "tag_name" | awk '{print substr($2, 3, length($2)-4) }')
|
||||
if [[ "${RELEASE}" != "$(cat /opt/${APP}_version.txt)" ]] || [[ ! -f /opt/${APP}_version.txt ]]; then
|
||||
msg_info "Stopping ${APP} services"
|
||||
systemctl stop immich-web
|
||||
systemctl stop immich-ml
|
||||
msg_ok "Stopped ${APP}"
|
||||
if [[ "$(cat /opt/${APP}_version.txt)" < "1.133.0" ]]; then
|
||||
msg_info "Upgrading to the VectorChord PostgreSQL extension"
|
||||
NUMBER="$(
|
||||
sed -n '2p' <(
|
||||
sudo -u postgres psql -A -d immich <<EOF
|
||||
SELECT atttypmod as dimsize
|
||||
FROM pg_attribute f
|
||||
JOIN pg_class c ON c.oid = f.attrelid
|
||||
WHERE c.relkind = 'r'::char
|
||||
AND f.attnum > 0
|
||||
AND c.relname = 'smart_search'::text
|
||||
AND f.attname = 'embedding'::text;
|
||||
EOF
|
||||
)
|
||||
)"
|
||||
$STD sudo -u postgres psql -d immich <<EOF
|
||||
DROP INDEX IF EXISTS clip_index;
|
||||
DROP INDEX IF EXISTS face_index;
|
||||
ALTER TABLE smart_search ALTER COLUMN embedding SET DATA TYPE real[];
|
||||
ALTER TABLE face_search ALTER COLUMN embedding SET DATA TYPE real[];
|
||||
EOF
|
||||
$STD apt-get update
|
||||
$STD apt-get install postgresql-16-pgvector -y
|
||||
curl -fsSL https://github.com/tensorchord/VectorChord/releases/download/0.3.0/postgresql-16-vchord_0.3.0-1_amd64.deb -o vchord.deb
|
||||
$STD dpkg -i vchord.deb
|
||||
rm vchord.deb
|
||||
sed -i "s|vectors.so|vchord.so|" /etc/postgresql/16/main/postgresql.conf
|
||||
systemctl restart postgresql.service
|
||||
$STD sudo -u postgres psql -d immich <<EOF
|
||||
CREATE EXTENSION IF NOT EXISTS vchord CASCADE;
|
||||
ALTER TABLE smart_search ALTER COLUMN embedding SET DATA TYPE vector($NUMBER);
|
||||
ALTER TABLE face_search ALTER COLUMN embedding SET DATA TYPE vector(512);
|
||||
EOF
|
||||
$STD apt purge vectors-pg16 -y
|
||||
msg_ok "Database upgrade complete"
|
||||
fi
|
||||
INSTALL_DIR="/opt/${APP}"
|
||||
UPLOAD_DIR="$(sed -n '/^IMMICH_MEDIA_LOCATION/s/[^=]*=//p' /opt/immich/.env)"
|
||||
SRC_DIR="${INSTALL_DIR}/source"
|
||||
APP_DIR="${INSTALL_DIR}/app"
|
||||
ML_DIR="${APP_DIR}/machine-learning"
|
||||
GEO_DIR="${INSTALL_DIR}/geodata"
|
||||
VCHORD_RELEASE="$(curl -fsSL https://api.github.com/repos/tensorchord/vectorchord/releases/latest | grep "tag_name" | awk '{print substr($2, 2, length($2)-3) }')"
|
||||
|
||||
if [[ ! -f ~/.vchord_version ]] || [[ "$VCHORD_RELEASE" != "$(cat ~/.vchord_version)" ]]; then
|
||||
msg_info "Updating VectorChord"
|
||||
if [[ ! -f ~/.vchord_version ]] || [[ ! "$(cat ~/.vchord_version)" > "0.3.0" ]]; then
|
||||
$STD sudo -u postgres pg_dumpall --clean --if-exists --username=postgres | gzip >/etc/postgresql/immich-db-vchord0.3.0.sql.gz
|
||||
chown postgres /etc/postgresql/immich-db-vchord0.3.0.sql.gz
|
||||
$STD sudo -u postgres gunzip --stdout /etc/postgresql/immich-db-vchord0.3.0.sql.gz |
|
||||
sed -e "s/SELECT pg_catalog.set_config('search_path', '', false);/SELECT pg_catalog.set_config('search_path', 'public, pg_catalog', true);/g" \
|
||||
-e "/vchordrq.prewarm_dim/d" |
|
||||
sudo -u postgres psql
|
||||
fi
|
||||
curl -fsSL "https://github.com/tensorchord/vectorchord/releases/download/${VCHORD_RELEASE}/postgresql-16-vchord_${VCHORD_RELEASE}-1_amd64.deb" -o vchord.deb
|
||||
$STD apt install -y ./vchord.deb
|
||||
$STD sudo -u postgres psql -d immich -c "ALTER EXTENSION vchord UPDATE;"
|
||||
systemctl restart postgresql
|
||||
if [[ ! -f ~/.vchord-version ]] || [[ ! "$(cat ~/.vchord_version)" > "0.3.0" ]]; then
|
||||
$STD sudo -u postgres psql -d immich -c "REINDEX DATABASE;"
|
||||
fi
|
||||
echo "$VCHORD_RELEASE" >~/.vchord_version
|
||||
rm ./vchord.deb
|
||||
msg_ok "Updated VectorChord to v${VCHORD_RELEASE}"
|
||||
fi
|
||||
|
||||
cp "$ML_DIR"/ml_start.sh "$INSTALL_DIR"
|
||||
rm -rf "${APP_DIR:?}"/*
|
||||
rm -rf "$SRC_DIR"
|
||||
@ -252,28 +243,21 @@ EOF
|
||||
msg_ok "Updated ${APP} web and microservices"
|
||||
|
||||
cd "$SRC_DIR"/machine-learning
|
||||
$STD python3 -m venv "$ML_DIR"/ml-venv
|
||||
export VIRTUAL_ENV="${ML_DIR}"/ml-venv
|
||||
$STD /usr/local/bin/uv venv "$VIRTUAL_ENV"
|
||||
if [[ -f ~/.openvino ]]; then
|
||||
msg_info "Updating HW-accelerated machine-learning"
|
||||
(
|
||||
source "$ML_DIR"/ml-venv/bin/activate
|
||||
$STD pip3 install -U uv
|
||||
uv -q sync --extra openvino --no-cache --active
|
||||
)
|
||||
patchelf --clear-execstack "$ML_DIR"/ml-venv/lib/python3.11/site-packages/onnxruntime/capi/onnxruntime_pybind11_state.cpython-311-x86_64-linux-gnu.so
|
||||
/usr/local/bin/uv -q sync --extra openvino --no-cache --active
|
||||
patchelf --clear-execstack "${VIRTUAL_ENV}/lib/python3.11/site-packages/onnxruntime/capi/onnxruntime_pybind11_state.cpython-311-x86_64-linux-gnu.so"
|
||||
msg_ok "Updated HW-accelerated machine-learning"
|
||||
else
|
||||
msg_info "Updating machine-learning"
|
||||
(
|
||||
source "$ML_DIR"/ml-venv/bin/activate
|
||||
$STD pip3 install -U uv
|
||||
uv -q sync --extra cpu --no-cache --active
|
||||
)
|
||||
/usr/local/bin/uv -q sync --extra cpu --no-cache --active
|
||||
msg_ok "Updated machine-learning"
|
||||
fi
|
||||
cd "$SRC_DIR"
|
||||
cp -a machine-learning/{ann,immich_ml} "$ML_DIR"
|
||||
cp "$INSTALL_DIR"/ml_start.sh "$ML_DIR"
|
||||
mv "$INSTALL_DIR"/ml_start.sh "$ML_DIR"
|
||||
if [[ -f ~/.openvino ]]; then
|
||||
sed -i "/intra_op/s/int = 0/int = os.cpu_count() or 0/" "$ML_DIR"/immich_ml/config.py
|
||||
fi
|
||||
@ -292,8 +276,6 @@ EOF
|
||||
$STD npm i -g @immich/cli
|
||||
msg_ok "Updated Immich CLI"
|
||||
|
||||
sed -i "s|pgvecto.rs|vectorchord|" /opt/"${APP}"/.env
|
||||
|
||||
chown -R immich:immich "$INSTALL_DIR"
|
||||
echo "$RELEASE" >/opt/"${APP}"_version.txt
|
||||
msg_ok "Updated ${APP} to v${RELEASE}"
|
||||
|
77
ct/planka.sh
Normal file
77
ct/planka.sh
Normal file
@ -0,0 +1,77 @@
|
||||
#!/usr/bin/env bash
|
||||
source <(curl -fsSL https://raw.githubusercontent.com/community-scripts/ProxmoxVE/refs/heads/main/misc/build.func)
|
||||
# Copyright (c) 2021-2025 community-scripts ORG
|
||||
# Author: Slaviša Arežina (tremor021)
|
||||
# License: MIT | https://github.com/community-scripts/ProxmoxVE/raw/main/LICENSE
|
||||
# Source: https://github.com/plankanban/planka
|
||||
|
||||
APP="PLANKA"
|
||||
var_tags="${var_tags:-Arr}"
|
||||
var_cpu="${var_cpu:-1}"
|
||||
var_ram="${var_ram:-1024}"
|
||||
var_disk="${var_disk:-4}"
|
||||
var_os="${var_os:-debian}"
|
||||
var_version="${var_version:-12}"
|
||||
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 /etc/systemd/system/planka.service ]]; then
|
||||
msg_error "No ${APP} Installation Found!"
|
||||
exit
|
||||
fi
|
||||
RELEASE=$(curl -s https://api.github.com/repos/plankanban/planka/releases/latest | grep "tag_name" | awk '{print substr($2, 2, length($2)-3) }')
|
||||
if [[ "${RELEASE}" != "$(cat ~/.planka 2>/dev/null)" ]] || [[ ! -f ~/.planka ]]; then
|
||||
msg_info "Stopping $APP"
|
||||
systemctl stop planka
|
||||
msg_ok "Stopped $APP"
|
||||
|
||||
msg_info "Updating $APP to ${RELEASE}"
|
||||
mkdir -p /opt/planka-backup
|
||||
mkdir -p /opt/planka-backup/favicons
|
||||
mkdir -p /opt/planka-backup/user-avatars
|
||||
mkdir -p /opt/planka-backup/background-images
|
||||
mkdir -p /opt/planka-backup/attachments
|
||||
mv /opt/planka/planka/.env /opt/planka-backup
|
||||
mv /opt/planka/planka/public/favicons/* /opt/planka-backup/favicons/
|
||||
mv /opt/planka/planka/public/user-avatars/* /opt/planka-backup/user-avatars/
|
||||
mv /opt/planka/planka/public/background-images/* /opt/planka-backup/background-images/
|
||||
mv /opt/planka/planka/private/attachments/* /opt/planka-backup/attachments/
|
||||
rm -rf /opt/planka
|
||||
fetch_and_deploy_gh_release "planka" "plankanban/planka" "prebuild" "latest" "/opt/planka" "planka-prebuild.zip"
|
||||
cd /opt/planka/planka
|
||||
$STD npm install
|
||||
mv /opt/planka-backup/.env /opt/planka/planka/
|
||||
mv /opt/planka-backup/favicons/* /opt/planka/planka/public/favicons/
|
||||
mv /opt/planka-backup/user-avatars/* /opt/planka/planka/public/user-avatars/
|
||||
mv /opt/planka-backup/background-images/* /opt/planka/planka/public/background-images/
|
||||
mv /opt/planka-backup/attachments/* /opt/planka/planka/private/attachments/
|
||||
msg_ok "Updated $APP to ${RELEASE}"
|
||||
|
||||
msg_info "Starting $APP"
|
||||
systemctl start planka
|
||||
msg_ok "Started $APP"
|
||||
|
||||
msg_ok "Update Successful"
|
||||
else
|
||||
msg_ok "No update required. ${APP} is already at ${RELEASE}"
|
||||
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 "${TAB}${GATEWAY}${BGN}http://${IP}:1337${CL}"
|
79
ct/wizarr.sh
Normal file
79
ct/wizarr.sh
Normal file
@ -0,0 +1,79 @@
|
||||
#!/usr/bin/env bash
|
||||
source <(curl -fsSL https://raw.githubusercontent.com/community-scripts/ProxmoxVE/main/misc/build.func)
|
||||
# Copyright (c) 2021-2025 community-scripts ORG
|
||||
# Author: vhsdream
|
||||
# License: MIT | https://github.com/community-scripts/ProxmoxVE/raw/main/LICENSE
|
||||
# Source: https://github.com/wizarrrr/wizarr
|
||||
|
||||
APP="Wizarr"
|
||||
var_tags="${var_tags:-media;arr}"
|
||||
var_cpu="${var_cpu:-1}"
|
||||
var_ram="${var_ram:-1024}"
|
||||
var_disk="${var_disk:-4}"
|
||||
var_os="${var_os:-debian}"
|
||||
var_version="${var_version:-12}"
|
||||
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/wizarr ]]; then
|
||||
msg_error "No ${APP} Installation Found!"
|
||||
exit
|
||||
fi
|
||||
|
||||
RELEASE=$(curl -fsSL https://api.github.com/repos/wizarrrr/wizarr/releases/latest | grep "tag_name" | awk '{print substr($2, 2, length($2)-3) }')
|
||||
if [[ "${RELEASE}" != "$(cat ~/.wizarr 2>/dev/null)" ]] || [[ ! -f ~/.wizarr ]]; then
|
||||
msg_info "Stopping $APP"
|
||||
systemctl stop wizarr
|
||||
msg_ok "Stopped $APP"
|
||||
|
||||
msg_info "Creating Backup"
|
||||
BACKUP_FILE="/opt/wizarr_backup_$(date +%F).tar.gz"
|
||||
$STD tar -czf "$BACKUP_FILE" /opt/wizarr/{.env,start.sh} /opt/wizarr/database/ &>/dev/null
|
||||
msg_ok "Backup Created"
|
||||
|
||||
setup_uv
|
||||
fetch_and_deploy_gh_release "wizarr" "wizarrrr/wizarr"
|
||||
|
||||
msg_info "Updating $APP to v${RELEASE}"
|
||||
cd /opt/wizarr
|
||||
uv -q sync --locked
|
||||
$STD uv -q run pybabel compile -d app/translations
|
||||
$STD npm --prefix app/static install
|
||||
$STD npm --prefix app/static run build:css
|
||||
mkdir -p ./.cache
|
||||
$STD tar -xf "$BACKUP_FILE" --directory=/
|
||||
$STD uv -q run flask db upgrade
|
||||
msg_ok "Updated $APP to v${RELEASE}"
|
||||
|
||||
msg_info "Starting $APP"
|
||||
systemctl start wizarr
|
||||
msg_ok "Started $APP"
|
||||
|
||||
msg_info "Cleaning Up"
|
||||
rm -rf "$BACKUP_FILE"
|
||||
rm /tmp/"$RELEASE".zip
|
||||
msg_ok "Cleanup Completed"
|
||||
msg_ok "Update Successful"
|
||||
else
|
||||
msg_ok "No update required. ${APP} is already at v${RELEASE}"
|
||||
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 "${TAB}${GATEWAY}${BGN}http://${IP}:5690${CL}"
|
2
frontend/public/json/cloudflare-ddns.json
generated
2
frontend/public/json/cloudflare-ddns.json
generated
@ -37,7 +37,7 @@
|
||||
"type": "warning"
|
||||
},
|
||||
{
|
||||
"text": "To update the configuration edit `/etc/systemd/system/cloudflare-ddns.service`. After edit please restard with `systemctl restart cloudflare-ddns`",
|
||||
"text": "To update the configuration edit `/etc/systemd/system/cloudflare-ddns.service`. After edit please restart with `systemctl restart cloudflare-ddns`",
|
||||
"type": "info"
|
||||
}
|
||||
]
|
||||
|
4
frontend/public/json/immich.json
generated
4
frontend/public/json/immich.json
generated
@ -43,6 +43,10 @@
|
||||
{
|
||||
"text": "To change upload location, edit 'IMMICH_MEDIA_LOCATION' in `/opt/immich/.env`, and create the symlink 'upload' in /opt/immich/app & /opt/immich/app/machine-learning to your new upload location",
|
||||
"type": "info"
|
||||
},
|
||||
{
|
||||
"text": "Logs: `/var/log/immich`",
|
||||
"type": "info"
|
||||
}
|
||||
]
|
||||
}
|
||||
|
40
frontend/public/json/planka.json
generated
Normal file
40
frontend/public/json/planka.json
generated
Normal file
@ -0,0 +1,40 @@
|
||||
{
|
||||
"name": "PLANKA",
|
||||
"slug": "planka",
|
||||
"categories": [
|
||||
12
|
||||
],
|
||||
"date_created": "2025-06-19",
|
||||
"type": "ct",
|
||||
"updateable": true,
|
||||
"privileged": false,
|
||||
"interface_port": 1337,
|
||||
"documentation": "https://docs.planka.cloud/",
|
||||
"website": "https://planka.app/",
|
||||
"logo": "https://cdn.jsdelivr.net/gh/selfhst/icons/webp/planka.webp",
|
||||
"config_path": "/opt/planka/planka/.env",
|
||||
"description": "Planka is a powerful, project management platform that transforms how teams collaborate. Create projects with multiple boards, organize tasks with intuitive drag-and-drop cards, attach files, write rich markdown descriptions, set due dates, assign team members, and keep conversations flowing with comments and labels—all with seamless real-time updates and smart notifications.",
|
||||
"install_methods": [
|
||||
{
|
||||
"type": "default",
|
||||
"script": "ct/planka.sh",
|
||||
"resources": {
|
||||
"cpu": 1,
|
||||
"ram": 1024,
|
||||
"hdd": 4,
|
||||
"os": "debian",
|
||||
"version": "12"
|
||||
}
|
||||
}
|
||||
],
|
||||
"default_credentials": {
|
||||
"username": null,
|
||||
"password": null
|
||||
},
|
||||
"notes": [
|
||||
{
|
||||
"text": "Type `cat ~/planka.creds` inside LXC to see admin user and database credentials.",
|
||||
"type": "info"
|
||||
}
|
||||
]
|
||||
}
|
40
frontend/public/json/ubuntu2504-vm.json
generated
Normal file
40
frontend/public/json/ubuntu2504-vm.json
generated
Normal file
@ -0,0 +1,40 @@
|
||||
{
|
||||
"name": "Ubuntu 25.04",
|
||||
"slug": "ubuntu2504-vm",
|
||||
"categories": [
|
||||
2
|
||||
],
|
||||
"date_created": "2025-06-19",
|
||||
"type": "vm",
|
||||
"updateable": false,
|
||||
"privileged": false,
|
||||
"interface_port": null,
|
||||
"documentation": null,
|
||||
"website": "https://ubuntu.com/",
|
||||
"logo": "https://cdn.jsdelivr.net/gh/selfhst/icons/webp/ubuntu.webp",
|
||||
"config_path": "",
|
||||
"description": "Ubuntu is a distribution based on Debian, designed to have regular releases and a consistent user experience.",
|
||||
"install_methods": [
|
||||
{
|
||||
"type": "default",
|
||||
"script": "vm/ubuntu2504-vm.sh",
|
||||
"resources": {
|
||||
"cpu": 2,
|
||||
"ram": 2048,
|
||||
"hdd": 8,
|
||||
"os": null,
|
||||
"version": null
|
||||
}
|
||||
}
|
||||
],
|
||||
"default_credentials": {
|
||||
"username": null,
|
||||
"password": null
|
||||
},
|
||||
"notes": [
|
||||
{
|
||||
"text": "after installation, checkout: ´https://github.com/community-scripts/ProxmoxVE/discussions/272´",
|
||||
"type": "info"
|
||||
}
|
||||
]
|
||||
}
|
150
frontend/public/json/versions.json
generated
150
frontend/public/json/versions.json
generated
@ -1,23 +1,88 @@
|
||||
[
|
||||
{
|
||||
"name": "plexguide/Huntarr.io",
|
||||
"version": "8.1.3",
|
||||
"date": "2025-06-19T23:45:15Z"
|
||||
},
|
||||
{
|
||||
"name": "go-gitea/gitea",
|
||||
"version": "v1.24.1",
|
||||
"date": "2025-06-19T19:38:29Z"
|
||||
},
|
||||
{
|
||||
"name": "paperless-ngx/paperless-ngx",
|
||||
"version": "v2.17.1",
|
||||
"date": "2025-06-19T19:35:01Z"
|
||||
},
|
||||
{
|
||||
"name": "pocket-id/pocket-id",
|
||||
"version": "v1.4.0",
|
||||
"date": "2025-06-19T18:30:11Z"
|
||||
},
|
||||
{
|
||||
"name": "immich-app/immich",
|
||||
"version": "v1.135.1",
|
||||
"date": "2025-06-19T17:55:06Z"
|
||||
},
|
||||
{
|
||||
"name": "rclone/rclone",
|
||||
"version": "v1.70.1",
|
||||
"date": "2025-06-19T13:19:02Z"
|
||||
},
|
||||
{
|
||||
"name": "fallenbagel/jellyseerr",
|
||||
"version": "preview-dns-cache-manager",
|
||||
"date": "2025-06-19T12:05:10Z"
|
||||
},
|
||||
{
|
||||
"name": "icereed/paperless-gpt",
|
||||
"version": "v0.21.0",
|
||||
"date": "2025-06-19T11:54:59Z"
|
||||
},
|
||||
{
|
||||
"name": "neo4j/neo4j",
|
||||
"version": "2025.05.1",
|
||||
"date": "2025-06-19T11:28:36Z"
|
||||
},
|
||||
{
|
||||
"name": "mattermost/mattermost",
|
||||
"version": "v9.11.17",
|
||||
"date": "2025-06-18T08:12:05Z"
|
||||
},
|
||||
{
|
||||
"name": "n8n-io/n8n",
|
||||
"version": "n8n@1.98.2",
|
||||
"date": "2025-06-18T18:20:16Z"
|
||||
},
|
||||
{
|
||||
"name": "redis/redis",
|
||||
"version": "8.2-m01-int2",
|
||||
"date": "2025-06-12T08:52:10Z"
|
||||
},
|
||||
{
|
||||
"name": "Jackett/Jackett",
|
||||
"version": "v0.22.2029",
|
||||
"date": "2025-06-19T05:56:19Z"
|
||||
},
|
||||
{
|
||||
"name": "prometheus-pve/prometheus-pve-exporter",
|
||||
"version": "v3.5.5",
|
||||
"date": "2025-06-19T05:43:47Z"
|
||||
},
|
||||
{
|
||||
"name": "docmost/docmost",
|
||||
"version": "v0.21.0",
|
||||
"date": "2025-06-18T21:43:27Z"
|
||||
},
|
||||
{
|
||||
"name": "immich-app/immich",
|
||||
"version": "v1.135.0",
|
||||
"date": "2025-06-18T20:37:30Z"
|
||||
},
|
||||
{
|
||||
"name": "ipfs/kubo",
|
||||
"version": "v0.35.0",
|
||||
"date": "2025-05-21T18:00:32Z"
|
||||
},
|
||||
{
|
||||
"name": "n8n-io/n8n",
|
||||
"version": "n8n@1.98.2",
|
||||
"date": "2025-06-18T18:20:16Z"
|
||||
"name": "keycloak/keycloak",
|
||||
"version": "26.2.5",
|
||||
"date": "2025-05-28T06:49:43Z"
|
||||
},
|
||||
{
|
||||
"name": "pterodactyl/panel",
|
||||
@ -54,11 +119,6 @@
|
||||
"version": "7.2.8",
|
||||
"date": "2025-06-18T13:46:00Z"
|
||||
},
|
||||
{
|
||||
"name": "plexguide/Huntarr.io",
|
||||
"version": "8.0.9",
|
||||
"date": "2025-06-18T13:12:23Z"
|
||||
},
|
||||
{
|
||||
"name": "Bubka/2FAuth",
|
||||
"version": "v5.6.0",
|
||||
@ -69,11 +129,6 @@
|
||||
"version": "v10.7.0",
|
||||
"date": "2025-06-18T11:57:05Z"
|
||||
},
|
||||
{
|
||||
"name": "rclone/rclone",
|
||||
"version": "v1.70.0",
|
||||
"date": "2025-06-18T10:31:28Z"
|
||||
},
|
||||
{
|
||||
"name": "esphome/esphome",
|
||||
"version": "2025.6.0",
|
||||
@ -94,16 +149,6 @@
|
||||
"version": "2.0.0-pre3",
|
||||
"date": "2025-06-18T08:01:24Z"
|
||||
},
|
||||
{
|
||||
"name": "mattermost/mattermost",
|
||||
"version": "v9.11.17",
|
||||
"date": "2025-06-18T08:12:05Z"
|
||||
},
|
||||
{
|
||||
"name": "Jackett/Jackett",
|
||||
"version": "v0.22.2026",
|
||||
"date": "2025-06-18T05:51:39Z"
|
||||
},
|
||||
{
|
||||
"name": "cross-seed/cross-seed",
|
||||
"version": "v6.12.7",
|
||||
@ -119,11 +164,6 @@
|
||||
"version": "v11.5.6",
|
||||
"date": "2025-06-17T22:00:40Z"
|
||||
},
|
||||
{
|
||||
"name": "keycloak/keycloak",
|
||||
"version": "26.2.5",
|
||||
"date": "2025-05-28T06:49:43Z"
|
||||
},
|
||||
{
|
||||
"name": "jenkinsci/jenkins",
|
||||
"version": "jenkins-2.515",
|
||||
@ -144,11 +184,6 @@
|
||||
"version": "v2.1.5",
|
||||
"date": "2025-06-17T18:04:11Z"
|
||||
},
|
||||
{
|
||||
"name": "fallenbagel/jellyseerr",
|
||||
"version": "preview-sort-userlist",
|
||||
"date": "2025-06-17T18:02:25Z"
|
||||
},
|
||||
{
|
||||
"name": "BookStackApp/BookStack",
|
||||
"version": "v25.05.1",
|
||||
@ -216,8 +251,8 @@
|
||||
},
|
||||
{
|
||||
"name": "runtipi/runtipi",
|
||||
"version": "nightly",
|
||||
"date": "2025-06-16T17:35:17Z"
|
||||
"version": "v4.2.1",
|
||||
"date": "2025-06-03T20:04:28Z"
|
||||
},
|
||||
{
|
||||
"name": "emqx/emqx",
|
||||
@ -389,11 +424,6 @@
|
||||
"version": "v2.37.1",
|
||||
"date": "2025-06-12T09:00:21Z"
|
||||
},
|
||||
{
|
||||
"name": "redis/redis",
|
||||
"version": "8.2-m01-int2",
|
||||
"date": "2025-06-12T08:52:10Z"
|
||||
},
|
||||
{
|
||||
"name": "zitadel/zitadel",
|
||||
"version": "v3.3.0",
|
||||
@ -459,11 +489,6 @@
|
||||
"version": "v0.8.4",
|
||||
"date": "2025-06-10T07:57:14Z"
|
||||
},
|
||||
{
|
||||
"name": "go-gitea/gitea",
|
||||
"version": "v1.24.0",
|
||||
"date": "2025-06-10T02:00:38Z"
|
||||
},
|
||||
{
|
||||
"name": "Sonarr/Sonarr",
|
||||
"version": "v4.0.14.2939",
|
||||
@ -474,11 +499,6 @@
|
||||
"version": "v1.84.2",
|
||||
"date": "2025-06-09T23:43:27Z"
|
||||
},
|
||||
{
|
||||
"name": "pocket-id/pocket-id",
|
||||
"version": "v1.3.1",
|
||||
"date": "2025-06-09T21:07:27Z"
|
||||
},
|
||||
{
|
||||
"name": "pocketbase/pocketbase",
|
||||
"version": "v0.28.3",
|
||||
@ -499,11 +519,6 @@
|
||||
"version": "v0.10.0",
|
||||
"date": "2025-06-09T13:37:07Z"
|
||||
},
|
||||
{
|
||||
"name": "neo4j/neo4j",
|
||||
"version": "5.26.8",
|
||||
"date": "2025-06-08T22:50:58Z"
|
||||
},
|
||||
{
|
||||
"name": "Forceu/Gokapi",
|
||||
"version": "v2.0.1",
|
||||
@ -549,11 +564,6 @@
|
||||
"version": "10.1.42",
|
||||
"date": "2025-06-05T22:39:40Z"
|
||||
},
|
||||
{
|
||||
"name": "paperless-ngx/paperless-ngx",
|
||||
"version": "v2.16.3",
|
||||
"date": "2025-06-05T21:16:59Z"
|
||||
},
|
||||
{
|
||||
"name": "netbox-community/netbox",
|
||||
"version": "v4.3.2",
|
||||
@ -649,11 +659,6 @@
|
||||
"version": "v0.14.1",
|
||||
"date": "2024-08-29T22:32:51Z"
|
||||
},
|
||||
{
|
||||
"name": "icereed/paperless-gpt",
|
||||
"version": "v0.20.0",
|
||||
"date": "2025-05-30T14:39:51Z"
|
||||
},
|
||||
{
|
||||
"name": "binwiederhier/ntfy",
|
||||
"version": "v2.12.0",
|
||||
@ -899,11 +904,6 @@
|
||||
"version": "v0.9.80",
|
||||
"date": "2025-05-02T16:48:15Z"
|
||||
},
|
||||
{
|
||||
"name": "prometheus-pve/prometheus-pve-exporter",
|
||||
"version": "v3.5.4",
|
||||
"date": "2025-05-02T13:42:06Z"
|
||||
},
|
||||
{
|
||||
"name": "WordPress/WordPress",
|
||||
"version": "6.8.1",
|
||||
|
36
frontend/public/json/wizarr.json
generated
Normal file
36
frontend/public/json/wizarr.json
generated
Normal file
@ -0,0 +1,36 @@
|
||||
{
|
||||
"name": "Wizarr",
|
||||
"slug": "wizarr",
|
||||
"categories": [
|
||||
14,
|
||||
13
|
||||
],
|
||||
"date_created": "2025-06-19",
|
||||
"type": "ct",
|
||||
"updateable": true,
|
||||
"privileged": false,
|
||||
"interface_port": 5690,
|
||||
"documentation": "https://docs.wizarr.dev/",
|
||||
"website": "https://docs.wizarr.dev/",
|
||||
"logo": "https://cdn.jsdelivr.net/gh/selfhst/icons/webp/wizarr.webp",
|
||||
"config_path": "/opt/wizarr/.env",
|
||||
"description": "Wizarr is an automatic user invitation system for Plex, Jellyfin and Emby. Create a unique link and share it to a user and they will automatically be invited to your media Server",
|
||||
"install_methods": [
|
||||
{
|
||||
"type": "default",
|
||||
"script": "ct/wizarr.sh",
|
||||
"resources": {
|
||||
"cpu": 1,
|
||||
"ram": 1024,
|
||||
"hdd": 4,
|
||||
"os": "debian",
|
||||
"version": "12"
|
||||
}
|
||||
}
|
||||
],
|
||||
"default_credentials": {
|
||||
"username": null,
|
||||
"password": null
|
||||
},
|
||||
"notes": []
|
||||
}
|
@ -13,6 +13,8 @@ setting_up_container
|
||||
network_check
|
||||
update_os
|
||||
|
||||
setup_uv
|
||||
|
||||
msg_info "Configuring apt and installing dependencies"
|
||||
echo "deb http://deb.debian.org/debian testing main contrib" >/etc/apt/sources.list.d/immich.list
|
||||
cat <<EOF >/etc/apt/preferences.d/immich
|
||||
@ -27,7 +29,6 @@ $STD apt-get install --no-install-recommends -y \
|
||||
redis \
|
||||
autoconf \
|
||||
build-essential \
|
||||
python3-venv \
|
||||
python3-dev \
|
||||
cmake \
|
||||
jq \
|
||||
@ -63,6 +64,7 @@ $STD apt-get install --no-install-recommends -y \
|
||||
mesa-utils \
|
||||
mesa-va-drivers \
|
||||
mesa-vulkan-drivers \
|
||||
ocl-icd-libopencl1 \
|
||||
tini \
|
||||
zlib1g
|
||||
$STD apt-get install -y \
|
||||
@ -88,14 +90,13 @@ read -r -p "Install OpenVINO dependencies for Intel HW-accelerated machine-learn
|
||||
if [[ ${prompt,,} =~ ^(y|yes)$ ]]; then
|
||||
msg_info "Installing OpenVINO dependencies"
|
||||
touch ~/.openvino
|
||||
$STD apt-get -y install --no-install-recommends ocl-icd-libopencl1
|
||||
tmp_dir=$(mktemp -d)
|
||||
$STD pushd "$tmp_dir"
|
||||
curl -fsSL https://github.com/intel/intel-graphics-compiler/releases/download/igc-1.0.17384.11/intel-igc-core_1.0.17384.11_amd64.deb -O
|
||||
curl -fsSL https://github.com/intel/intel-graphics-compiler/releases/download/igc-1.0.17384.11/intel-igc-opencl_1.0.17384.11_amd64.deb -O
|
||||
curl -fsSL https://github.com/intel/compute-runtime/releases/download/24.31.30508.7/intel-opencl-icd_24.31.30508.7_amd64.deb -O
|
||||
curl -fsSL https://github.com/intel/compute-runtime/releases/download/24.31.30508.7/libigdgmm12_22.4.1_amd64.deb -O
|
||||
$STD dpkg -i ./*.deb
|
||||
curl -fsSLO https://github.com/intel/intel-graphics-compiler/releases/download/igc-1.0.17384.11/intel-igc-core_1.0.17384.11_amd64.deb
|
||||
curl -fsSLO https://github.com/intel/intel-graphics-compiler/releases/download/igc-1.0.17384.11/intel-igc-opencl_1.0.17384.11_amd64.deb
|
||||
curl -fsSLO https://github.com/intel/compute-runtime/releases/download/24.31.30508.7/intel-opencl-icd_24.31.30508.7_amd64.deb
|
||||
curl -fsSLO https://github.com/intel/compute-runtime/releases/download/24.31.30508.7/libigdgmm12_22.4.1_amd64.deb
|
||||
$STD apt install -y ./*.deb
|
||||
$STD popd
|
||||
rm -rf "$tmp_dir"
|
||||
dpkg -l | grep "intel-opencl-icd" | awk '{print $3}' >~/.intel_version
|
||||
@ -110,13 +111,14 @@ if [[ ${prompt,,} =~ ^(y|yes)$ ]]; then
|
||||
fi
|
||||
|
||||
NODE_VERSION="22" setup_nodejs
|
||||
PG_VERSION="16" setup_postgresql
|
||||
PG_VERSION="16" PG_MODULES="pgvector" setup_postgresql
|
||||
|
||||
msg_info "Setting up Postgresql Database"
|
||||
$STD apt-get install postgresql-16-pgvector
|
||||
curl -fsSL https://github.com/tensorchord/VectorChord/releases/download/0.3.0/postgresql-16-vchord_0.3.0-1_amd64.deb -o vchord.deb
|
||||
$STD dpkg -i vchord.deb
|
||||
VCHORD_RELEASE="$(curl -fsSL https://api.github.com/repos/tensorchord/vectorchord/releases/latest | grep "tag_name" | awk '{print substr($2, 2, length($2)-3) }')"
|
||||
curl -fsSL "https://github.com/tensorchord/VectorChord/releases/download/${VCHORD_RELEASE}/postgresql-16-vchord_${VCHORD_RELEASE}-1_amd64.deb" -o vchord.deb
|
||||
$STD apt install -y ./vchord.deb
|
||||
rm vchord.deb
|
||||
echo "$VCHORD_RELEASE" >~/.vchord_version
|
||||
DB_NAME="immich"
|
||||
DB_USER="immich"
|
||||
DB_PASS=$(openssl rand -base64 18 | tr -dc 'a-zA-Z0-9' | head -c18)
|
||||
@ -273,7 +275,7 @@ msg_ok "Custom Photo-processing Library Compiled"
|
||||
|
||||
msg_info "Installing ${APPLICATION} (more patience please)"
|
||||
tmp_file=$(mktemp)
|
||||
RELEASE=$(curl -s https://api.github.com/repos/immich-app/immich/releases?per_page=1 | grep "tag_name" | awk '{print substr($2, 3, length($2)-4) }')
|
||||
RELEASE=$(curl -fsSL https://api.github.com/repos/immich-app/immich/releases?per_page=1 | grep "tag_name" | awk '{print substr($2, 3, length($2)-4) }')
|
||||
curl -fsSL "https://github.com/immich-app/immich/archive/refs/tags/v${RELEASE}.zip" -o "$tmp_file"
|
||||
unzip -q "$tmp_file"
|
||||
INSTALL_DIR="/opt/${APPLICATION}"
|
||||
@ -304,23 +306,16 @@ cp LICENSE "$APP_DIR"
|
||||
msg_ok "Installed Immich Web Components"
|
||||
|
||||
cd "$SRC_DIR"/machine-learning
|
||||
$STD python3 -m venv "$ML_DIR/ml-venv"
|
||||
export VIRTUAL_ENV="${ML_DIR}/ml-venv"
|
||||
$STD uv venv "$VIRTUAL_ENV"
|
||||
if [[ -f ~/.openvino ]]; then
|
||||
msg_info "Installing HW-accelerated machine-learning"
|
||||
(
|
||||
source "$ML_DIR"/ml-venv/bin/activate
|
||||
$STD pip3 install uv
|
||||
uv -q sync --extra openvino --no-cache --active
|
||||
)
|
||||
patchelf --clear-execstack "$ML_DIR"/ml-venv/lib/python3.11/site-packages/onnxruntime/capi/onnxruntime_pybind11_state.cpython-311-x86_64-linux-gnu.so
|
||||
uv -q sync --extra openvino --no-cache --active
|
||||
patchelf --clear-execstack "${VIRTUAL_ENV}/lib/python3.11/site-packages/onnxruntime/capi/onnxruntime_pybind11_state.cpython-311-x86_64-linux-gnu.so"
|
||||
msg_ok "Installed HW-accelerated machine-learning"
|
||||
else
|
||||
msg_info "Installing machine-learning"
|
||||
(
|
||||
source "$ML_DIR"/ml-venv/bin/activate
|
||||
$STD pip3 install uv
|
||||
uv -q sync --extra cpu --no-cache --active
|
||||
)
|
||||
uv -q sync --extra cpu --no-cache --active
|
||||
msg_ok "Installed machine-learning"
|
||||
fi
|
||||
cd "$SRC_DIR"
|
||||
@ -351,7 +346,9 @@ URL_LIST=(
|
||||
https://download.geonames.org/export/dump/cities500.zip
|
||||
https://raw.githubusercontent.com/nvkelso/natural-earth-vector/v5.1.2/geojson/ne_10m_admin_0_countries.geojson
|
||||
)
|
||||
echo "${URL_LIST[@]}" | xargs -n1 -P 8 wget -q
|
||||
for geo in "${URL_LIST[@]}"; do
|
||||
curl -fsSLO "$geo"
|
||||
done
|
||||
unzip -q cities500.zip
|
||||
date --iso-8601=seconds | tr -d "\n" >geodata-date.txt
|
||||
rm cities500.zip
|
||||
@ -390,13 +387,13 @@ cat <<EOF >"${ML_DIR}"/ml_start.sh
|
||||
#!/usr/bin/env bash
|
||||
|
||||
cd ${ML_DIR}
|
||||
. ml-venv/bin/activate
|
||||
. ${VIRTUAL_ENV}/bin/activate
|
||||
|
||||
set -a
|
||||
. ${INSTALL_DIR}/.env
|
||||
set +a
|
||||
|
||||
python -m immich_ml
|
||||
python3 -m immich_ml
|
||||
EOF
|
||||
chmod +x "$ML_DIR"/ml_start.sh
|
||||
cat <<EOF >/etc/systemd/system/"${APPLICATION}"-web.service
|
||||
|
103
install/planka-install.sh
Normal file
103
install/planka-install.sh
Normal file
@ -0,0 +1,103 @@
|
||||
#!/usr/bin/env bash
|
||||
|
||||
# Copyright (c) 2021-2025 community-scripts ORG
|
||||
# Author: Slaviša Arežina (tremor021)
|
||||
# License: MIT | https://github.com/community-scripts/ProxmoxVE/raw/main/LICENSE
|
||||
# Source: https://github.com/plankanban/planka
|
||||
|
||||
source /dev/stdin <<<"$FUNCTIONS_FILE_PATH"
|
||||
color
|
||||
verb_ip6
|
||||
catch_errors
|
||||
setting_up_container
|
||||
network_check
|
||||
update_os
|
||||
|
||||
msg_info "Installing dependencies"
|
||||
$STD apt-get install -y \
|
||||
unzip \
|
||||
build-essential \
|
||||
python3-venv
|
||||
msg_ok "Installed dependencies"
|
||||
|
||||
NODE_VERSION="22" setup_nodejs
|
||||
PG_VERSION="16" setup_postgresql
|
||||
|
||||
msg_info "Setting up PostgreSQL Database"
|
||||
DB_NAME=planka
|
||||
DB_USER=planka
|
||||
DB_PASS="$(openssl rand -base64 18 | cut -c1-13)"
|
||||
$STD sudo -u postgres psql -c "CREATE ROLE $DB_USER WITH LOGIN PASSWORD '$DB_PASS';"
|
||||
$STD sudo -u postgres psql -c "CREATE DATABASE $DB_NAME WITH OWNER $DB_USER ENCODING 'UTF8' TEMPLATE template0;"
|
||||
$STD sudo -u postgres psql -c "ALTER ROLE $DB_USER SET client_encoding TO 'utf8';"
|
||||
$STD sudo -u postgres psql -c "ALTER ROLE $DB_USER SET default_transaction_isolation TO 'read committed';"
|
||||
$STD sudo -u postgres psql -c "ALTER ROLE $DB_USER SET timezone TO 'UTC'"
|
||||
{
|
||||
echo "PLANKA DB Credentials"
|
||||
echo "PLANKA Database User: $DB_USER"
|
||||
echo "PLANKA Database Password: $DB_PASS"
|
||||
echo "PLANKA Database Name: $DB_NAME"
|
||||
} >>~/planka.creds
|
||||
msg_ok "Set up PostgreSQL Database"
|
||||
|
||||
fetch_and_deploy_gh_release "planka" "plankanban/planka" "prebuild" "latest" "/opt/planka" "planka-prebuild.zip"
|
||||
|
||||
msg_info "Configuring PLANKA"
|
||||
LOCAL_IP=$(hostname -I | awk '{print $1}')
|
||||
SECRET_KEY=$(openssl rand -hex 64)
|
||||
cd /opt/planka/planka
|
||||
$STD npm install
|
||||
cp .env.sample .env
|
||||
sed -i "s#http://localhost:1337#http://$LOCAL_IP:1337#g" /opt/planka/planka/.env
|
||||
sed -i "s#postgres@localhost#planka:$DB_PASS@localhost#g" /opt/planka/planka/.env
|
||||
sed -i "s#notsecretkey#$SECRET_KEY#g" /opt/planka/planka/.env
|
||||
$STD npm run db:init
|
||||
msg_ok "Configured PLANKA"
|
||||
|
||||
msg_info "Creating Admin User"
|
||||
ADMIN_EMAIL="admin@planka.local"
|
||||
ADMIN_PASSWORD="$(openssl rand -base64 12)"
|
||||
ADMIN_NAME="Administrator"
|
||||
ADMIN_USERNAME="admin"
|
||||
echo "" >>.env
|
||||
echo "# Temporary admin user creation settings" >>.env
|
||||
echo "DEFAULT_ADMIN_EMAIL=$ADMIN_EMAIL" >>.env
|
||||
echo "DEFAULT_ADMIN_PASSWORD=$ADMIN_PASSWORD" >>.env
|
||||
echo "DEFAULT_ADMIN_NAME=$ADMIN_NAME" >>.env
|
||||
echo "DEFAULT_ADMIN_USERNAME=$ADMIN_USERNAME" >>.env
|
||||
$STD npm run db:seed
|
||||
sed -i '/# Temporary admin user creation settings/,$d' .env
|
||||
{
|
||||
echo ""
|
||||
echo "PLANKA Admin Credentials"
|
||||
echo "Admin Email: $ADMIN_EMAIL"
|
||||
echo "Admin Password: $ADMIN_PASSWORD"
|
||||
echo "Admin Name: $ADMIN_NAME"
|
||||
echo "Admin Username: $ADMIN_USERNAME"
|
||||
} >>~/planka.creds
|
||||
msg_ok "Created Admin User"
|
||||
|
||||
msg_info "Creating Service"
|
||||
cat <<EOF >/etc/systemd/system/planka.service
|
||||
[Unit]
|
||||
Description=planka Service
|
||||
After=network.target
|
||||
|
||||
[Service]
|
||||
WorkingDirectory=/opt/planka/planka
|
||||
ExecStart=/usr/bin/npm start --prod
|
||||
Restart=always
|
||||
|
||||
[Install]
|
||||
WantedBy=multi-user.target
|
||||
EOF
|
||||
systemctl enable -q --now planka
|
||||
msg_ok "Created Service"
|
||||
|
||||
motd_ssh
|
||||
customize
|
||||
|
||||
msg_info "Cleaning up"
|
||||
$STD apt-get -y autoremove
|
||||
$STD apt-get -y autoclean
|
||||
msg_ok "Cleaned"
|
79
install/wizarr-install.sh
Normal file
79
install/wizarr-install.sh
Normal file
@ -0,0 +1,79 @@
|
||||
#!/usr/bin/env bash
|
||||
|
||||
# Copyright (c) 2021-2025 community-scripts ORG
|
||||
# Author: vhsdream
|
||||
# License: MIT | https://github.com/community-scripts/ProxmoxVE/raw/main/LICENSE
|
||||
# Source: https://github.com/wizarrrr/wizarr
|
||||
|
||||
source /dev/stdin <<<"$FUNCTIONS_FILE_PATH"
|
||||
color
|
||||
verb_ip6
|
||||
catch_errors
|
||||
setting_up_container
|
||||
network_check
|
||||
update_os
|
||||
|
||||
msg_info "Installing Dependencies"
|
||||
$STD apt-get install -y sqlite3
|
||||
msg_ok "Installed Dependencies"
|
||||
|
||||
setup_uv
|
||||
NODE_VERSION="22" setup_nodejs
|
||||
fetch_and_deploy_gh_release "wizarr" "wizarrrr/wizarr"
|
||||
|
||||
msg_info "Configure ${APPLICATION}"
|
||||
cd /opt/wizarr
|
||||
uv -q sync --locked
|
||||
$STD uv -q run pybabel compile -d app/translations
|
||||
$STD npm --prefix app/static install
|
||||
$STD npm --prefix app/static run build:css
|
||||
mkdir -p ./.cache
|
||||
$STD uv -q run flask db upgrade
|
||||
msg_ok "Configure ${APPLICATION}"
|
||||
|
||||
msg_info "Creating env, start script and service"
|
||||
LOCAL_IP="$(hostname -I | awk '{print $1}')"
|
||||
cat <<EOF >/opt/wizarr/.env
|
||||
APP_URL=http://${LOCAL_IP}
|
||||
DISABLE_BUILTIN_AUTH=false
|
||||
LOG_LEVEL=INFO
|
||||
EOF
|
||||
|
||||
cat <<EOF >/opt/wizarr/start.sh
|
||||
#!/usr/bin/env bash
|
||||
|
||||
uv run gunicorn \
|
||||
--config gunicorn.conf.py \
|
||||
--preload \
|
||||
--workers 4 \
|
||||
--bind 0.0.0.0:5690 \
|
||||
--umask 007 \
|
||||
run:app
|
||||
EOF
|
||||
chmod u+x /opt/wizarr/start.sh
|
||||
|
||||
cat <<EOF >/etc/systemd/system/wizarr.service
|
||||
[Unit]
|
||||
Description=${APPLICATION} Service
|
||||
After=network.target
|
||||
|
||||
[Service]
|
||||
Type=simple
|
||||
WorkingDirectory=/opt/wizarr
|
||||
EnvironmentFile=/opt/wizarr/.env
|
||||
ExecStart=/opt/wizarr/start.sh
|
||||
Restart=on-abnormal
|
||||
|
||||
[Install]
|
||||
WantedBy=multi-user.target
|
||||
EOF
|
||||
systemctl enable -q --now wizarr
|
||||
msg_ok "Created env, start script and service"
|
||||
|
||||
motd_ssh
|
||||
customize
|
||||
|
||||
msg_info "Cleaning up"
|
||||
$STD apt-get -y autoremove
|
||||
$STD apt-get -y autoclean
|
||||
msg_ok "Cleaned"
|
@ -370,7 +370,7 @@ base_settings() {
|
||||
write_config() {
|
||||
mkdir -p /opt/community-scripts
|
||||
# This function writes the configuration to a file.
|
||||
if whiptail --backtitle "[dev] Proxmox VE Helper Scripts" --defaultno --title "Write configfile" --yesno "Do you want to write the selections to a config file?" 10 60; then
|
||||
if whiptail --backtitle "Proxmox VE Helper Scripts" --defaultno --title "Write configfile" --yesno "Do you want to write the selections to a config file?" 10 60; then
|
||||
FILEPATH="/opt/community-scripts/${NSAPP}.conf"
|
||||
if [[ ! -f $FILEPATH ]]; then
|
||||
cat <<EOF >"$FILEPATH"
|
||||
@ -403,7 +403,7 @@ EOF
|
||||
echo -e "${INFO}${BOLD}${GN}Writing configuration to ${FILEPATH}${CL}"
|
||||
else
|
||||
echo -e "${INFO}${BOLD}${RD}Configuration file already exists at ${FILEPATH}${CL}"
|
||||
if whiptail --backtitle "[dev] Proxmox VE Helper Scripts" --defaultno --title "Overwrite configfile" --yesno "Do you want to overwrite the existing config file?" 10 60; then
|
||||
if whiptail --backtitle "Proxmox VE Helper Scripts" --defaultno --title "Overwrite configfile" --yesno "Do you want to overwrite the existing config file?" 10 60; then
|
||||
rm -f "$FILEPATH"
|
||||
cat <<EOF >"$FILEPATH"
|
||||
# ${NSAPP} Configuration File
|
||||
@ -558,53 +558,72 @@ advanced_settings() {
|
||||
exit_script
|
||||
fi
|
||||
|
||||
if CT_NAME=$(whiptail --backtitle "Proxmox VE Helper Scripts" --inputbox "Set Hostname" 8 58 "$NSAPP" --title "HOSTNAME" 3>&1 1>&2 2>&3); then
|
||||
if [ -z "$CT_NAME" ]; then
|
||||
HN="$NSAPP"
|
||||
else
|
||||
HN=$(echo "${CT_NAME,,}" | tr -d ' ')
|
||||
fi
|
||||
echo -e "${HOSTNAME}${BOLD}${DGN}Hostname: ${BGN}$HN${CL}"
|
||||
else
|
||||
exit_script
|
||||
fi
|
||||
while true; do
|
||||
if CT_NAME=$(whiptail --backtitle "Proxmox VE Helper Scripts" --inputbox "Set Hostname" 8 58 "$NSAPP" --title "HOSTNAME" 3>&1 1>&2 2>&3); then
|
||||
if [ -z "$CT_NAME" ]; then
|
||||
HN="$NSAPP"
|
||||
else
|
||||
HN=$(echo "${CT_NAME,,}" | tr -d ' ')
|
||||
fi
|
||||
|
||||
if [[ "$HN" =~ ^[a-z0-9]([-a-z0-9]*[a-z0-9])?$ ]]; then
|
||||
echo -e "${HOSTNAME}${BOLD}${DGN}Hostname: ${BGN}$HN${CL}"
|
||||
break
|
||||
else
|
||||
whiptail --backtitle "Proxmox VE Helper Scripts" \
|
||||
--msgbox "❌ Invalid hostname: '$HN'\n\nOnly lowercase letters, digits and hyphens (-) are allowed.\nUnderscores (_) or other characters are not permitted!" 10 70
|
||||
fi
|
||||
else
|
||||
exit_script
|
||||
fi
|
||||
done
|
||||
|
||||
while true; do
|
||||
DISK_SIZE=$(whiptail --backtitle "Proxmox VE Helper Scripts" --inputbox "Set Disk Size in GB" 8 58 "$var_disk" --title "DISK SIZE" 3>&1 1>&2 2>&3) || exit_script
|
||||
|
||||
if DISK_SIZE=$(whiptail --backtitle "Proxmox VE Helper Scripts" --inputbox "Set Disk Size in GB" 8 58 "$var_disk" --title "DISK SIZE" 3>&1 1>&2 2>&3); then
|
||||
if [ -z "$DISK_SIZE" ]; then
|
||||
DISK_SIZE="$var_disk"
|
||||
echo -e "${DISKSIZE}${BOLD}${DGN}Disk Size: ${BGN}${DISK_SIZE} GB${CL}"
|
||||
else
|
||||
if ! [[ $DISK_SIZE =~ $INTEGER ]]; then
|
||||
echo -e "{INFO}${HOLD}${RD} DISK SIZE MUST BE AN INTEGER NUMBER!${CL}"
|
||||
advanced_settings
|
||||
fi
|
||||
echo -e "${DISKSIZE}${BOLD}${DGN}Disk Size: ${BGN}${DISK_SIZE} GB${CL}"
|
||||
fi
|
||||
else
|
||||
exit_script
|
||||
fi
|
||||
|
||||
if CORE_COUNT=$(whiptail --backtitle "Proxmox VE Helper Scripts" --inputbox "Allocate CPU Cores" 8 58 "$var_cpu" --title "CORE COUNT" 3>&1 1>&2 2>&3); then
|
||||
if [[ "$DISK_SIZE" =~ ^[1-9][0-9]*$ ]]; then
|
||||
echo -e "${DISKSIZE}${BOLD}${DGN}Disk Size: ${BGN}${DISK_SIZE} GB${CL}"
|
||||
break
|
||||
else
|
||||
whiptail --msgbox "Disk size must be a positive integer!" 8 58
|
||||
fi
|
||||
done
|
||||
|
||||
while true; do
|
||||
CORE_COUNT=$(whiptail --backtitle "Proxmox VE Helper Scripts" \
|
||||
--inputbox "Allocate CPU Cores" 8 58 "$var_cpu" --title "CORE COUNT" 3>&1 1>&2 2>&3) || exit_script
|
||||
|
||||
if [ -z "$CORE_COUNT" ]; then
|
||||
CORE_COUNT="$var_cpu"
|
||||
echo -e "${CPUCORE}${BOLD}${DGN}CPU Cores: ${BGN}$CORE_COUNT${CL}"
|
||||
else
|
||||
echo -e "${CPUCORE}${BOLD}${DGN}CPU Cores: ${BGN}$CORE_COUNT${CL}"
|
||||
fi
|
||||
else
|
||||
exit_script
|
||||
fi
|
||||
|
||||
if RAM_SIZE=$(whiptail --backtitle "Proxmox VE Helper Scripts" --inputbox "Allocate RAM in MiB" 8 58 "$var_ram" --title "RAM" 3>&1 1>&2 2>&3); then
|
||||
if [[ "$CORE_COUNT" =~ ^[1-9][0-9]*$ ]]; then
|
||||
echo -e "${CPUCORE}${BOLD}${DGN}CPU Cores: ${BGN}$CORE_COUNT${CL}"
|
||||
break
|
||||
else
|
||||
whiptail --msgbox "CPU core count must be a positive integer!" 8 58
|
||||
fi
|
||||
done
|
||||
|
||||
while true; do
|
||||
RAM_SIZE=$(whiptail --backtitle "Proxmox VE Helper Scripts" \
|
||||
--inputbox "Allocate RAM in MiB" 8 58 "$var_ram" --title "RAM" 3>&1 1>&2 2>&3) || exit_script
|
||||
|
||||
if [ -z "$RAM_SIZE" ]; then
|
||||
RAM_SIZE="$var_ram"
|
||||
echo -e "${RAMSIZE}${BOLD}${DGN}RAM Size: ${BGN}${RAM_SIZE} MiB${CL}"
|
||||
else
|
||||
echo -e "${RAMSIZE}${BOLD}${DGN}RAM Size: ${BGN}${RAM_SIZE} MiB${CL}"
|
||||
fi
|
||||
else
|
||||
exit_script
|
||||
fi
|
||||
|
||||
if [[ "$RAM_SIZE" =~ ^[1-9][0-9]*$ ]]; then
|
||||
echo -e "${RAMSIZE}${BOLD}${DGN}RAM Size: ${BGN}${RAM_SIZE} MiB${CL}"
|
||||
break
|
||||
else
|
||||
whiptail --msgbox "RAM size must be a positive integer!" 8 58
|
||||
fi
|
||||
done
|
||||
|
||||
BRIDGES=""
|
||||
IFACE_FILEPATH_LIST="/etc/network/interfaces"$'\n'$(find "/etc/network/interfaces.d/" -type f)
|
||||
@ -779,14 +798,14 @@ advanced_settings() {
|
||||
exit_script
|
||||
fi
|
||||
|
||||
SSH_AUTHORIZED_KEY="$(whiptail --backtitle "[dev] Proxmox VE Helper Scripts" --inputbox "SSH Authorized key for root (leave empty for none)" 8 58 --title "SSH Key" 3>&1 1>&2 2>&3)"
|
||||
SSH_AUTHORIZED_KEY="$(whiptail --backtitle "Proxmox VE Helper Scripts" --inputbox "SSH Authorized key for root (leave empty for none)" 8 58 --title "SSH Key" 3>&1 1>&2 2>&3)"
|
||||
|
||||
if [[ -z "${SSH_AUTHORIZED_KEY}" ]]; then
|
||||
SSH_AUTHORIZED_KEY=""
|
||||
fi
|
||||
|
||||
if [[ "$PW" == -password* || -n "$SSH_AUTHORIZED_KEY" ]]; then
|
||||
if (whiptail --backtitle "[dev] Proxmox VE Helper Scripts" --defaultno --title "SSH ACCESS" --yesno "Enable Root SSH Access?" 10 58); then
|
||||
if (whiptail --backtitle "Proxmox VE Helper Scripts" --defaultno --title "SSH ACCESS" --yesno "Enable Root SSH Access?" 10 58); then
|
||||
SSH="yes"
|
||||
else
|
||||
SSH="no"
|
||||
@ -1124,7 +1143,7 @@ build_container() {
|
||||
$PW
|
||||
"
|
||||
# This executes create_lxc.sh and creates the container and .conf file
|
||||
bash -c "$(curl -fsSL https://raw.githubusercontent.com/community-scripts/ProxmoxVE/main/ct/create_lxc.sh)" $?
|
||||
bash -c "$(curl -fsSL https://raw.githubusercontent.com/community-scripts/ProxmoxVE/main/misc/create_lxc.sh)" $?
|
||||
|
||||
LXC_CONFIG=/etc/pve/lxc/${CTID}.conf
|
||||
if [ "$CT_TYPE" == "0" ]; then
|
||||
|
@ -207,6 +207,17 @@ msg_ok "Using ${BL}$TEMPLATE_STORAGE${CL} ${GN}for Template Storage."
|
||||
CONTAINER_STORAGE=$(select_storage container)
|
||||
msg_ok "Using ${BL}$CONTAINER_STORAGE${CL} ${GN}for Container Storage."
|
||||
|
||||
# Check Cluster Quorum if in Cluster
|
||||
if [ -f /etc/pve/corosync.conf ]; then
|
||||
msg_info "Checking Proxmox cluster quorum status"
|
||||
if ! pvecm status | awk -F':' '/^Quorate/ { exit ($2 ~ /Yes/) ? 0 : 1 }'; then
|
||||
printf "\e[?25h"
|
||||
msg_error "Cluster is not quorate. Start all nodes or configure quorum device (QDevice)."
|
||||
exit 210
|
||||
fi
|
||||
msg_ok "Cluster is quorate"
|
||||
fi
|
||||
|
||||
# Update LXC template list
|
||||
msg_info "Updating LXC Template List"
|
||||
#check_network
|
6
package-lock.json
generated
6
package-lock.json
generated
@ -1,6 +0,0 @@
|
||||
{
|
||||
"name": "ProxmoxVE",
|
||||
"lockfileVersion": 3,
|
||||
"requires": true,
|
||||
"packages": {}
|
||||
}
|
6
tools/headers/filebrowser-quantum
Normal file
6
tools/headers/filebrowser-quantum
Normal file
@ -0,0 +1,6 @@
|
||||
_______ __ ____ ____ __
|
||||
/ ____(_) /__ / __ )_________ _ __________ _____ / __ \__ ______ _____ / /___ ______ ___
|
||||
/ /_ / / / _ \/ __ / ___/ __ \ | /| / / ___/ _ \/ ___/ / / / / / / / __ `/ __ \/ __/ / / / __ `__ \
|
||||
/ __/ / / / __/ /_/ / / / /_/ / |/ |/ (__ ) __/ / / /_/ / /_/ / /_/ / / / / /_/ /_/ / / / / / /
|
||||
/_/ /_/_/\___/_____/_/ \____/|__/|__/____/\___/_/ \___\_\__,_/\__,_/_/ /_/\__/\__,_/_/ /_/ /_/
|
||||
|
6
vm/headers/owncloud-vm
Normal file
6
vm/headers/owncloud-vm
Normal file
@ -0,0 +1,6 @@
|
||||
______ __ __ ________ __ _ ____ ___
|
||||
/_ __/_ ___________ / //_/__ __ __ ____ _ ______ / ____/ /___ __ ______/ / | | / / |/ /
|
||||
/ / / / / / ___/ __ \/ ,< / _ \/ / / / / __ \ | /| / / __ \/ / / / __ \/ / / / __ / | | / / /|_/ /
|
||||
/ / / /_/ / / / / / / /| / __/ /_/ / / /_/ / |/ |/ / / / / /___/ / /_/ / /_/ / /_/ / | |/ / / / /
|
||||
/_/ \__,_/_/ /_/ /_/_/ |_\___/\__, / \____/|__/|__/_/ /_/\____/_/\____/\__,_/\__,_/ |___/_/ /_/
|
||||
/____/
|
@ -8,6 +8,7 @@
|
||||
source /dev/stdin <<<$(curl -fsSL https://raw.githubusercontent.com/community-scripts/ProxmoxVE/main/misc/api.func)
|
||||
|
||||
function header_info {
|
||||
clear
|
||||
cat <<"EOF"
|
||||
__ ____ __ __ _ __ ____ __ ____ _____ ________ ______
|
||||
/ |/ (_) /___________ / /_(_) /__ / __ \____ __ __/ /____ _____/ __ \/ ___/ / ____/ / / / __ \
|
||||
@ -17,7 +18,6 @@ function header_info {
|
||||
|
||||
EOF
|
||||
}
|
||||
clear
|
||||
header_info
|
||||
echo -e "Loading..."
|
||||
GEN_MAC=$(echo '00 60 2f'$(od -An -N3 -t xC /dev/urandom) | sed -e 's/ /:/g' | tr '[:lower:]' '[:upper:]')
|
||||
@ -108,7 +108,7 @@ function cleanup() {
|
||||
|
||||
TEMP_DIR=$(mktemp -d)
|
||||
pushd $TEMP_DIR >/dev/null
|
||||
if whiptail --backtitle "Proxmox VE Helper Scripts" --title "Debian 12 VM" --yesno "This will create a New Debian 12 VM. Proceed?" 10 58; then
|
||||
if whiptail --backtitle "Proxmox VE Helper Scripts" --title "Mikrotik RouterOS CHR VM" --yesno "This will create a Mikrotik RouterOS CHR VM. Proceed?" 10 58; then
|
||||
:
|
||||
else
|
||||
header_info && echo -e "${CROSS}${RD}User exited script${CL}\n" && exit
|
||||
@ -309,9 +309,9 @@ function advanced_settings() {
|
||||
exit-script
|
||||
fi
|
||||
|
||||
if VM_NAME=$(whiptail --backtitle "Proxmox VE Helper Scripts" --inputbox "Set Hostname" 8 58 debian --title "HOSTNAME" --cancel-button Exit-Script 3>&1 1>&2 2>&3); then
|
||||
if VM_NAME=$(whiptail --backtitle "Proxmox VE Helper Scripts" --inputbox "Set Hostname" 8 58 mikrotik-routeros-chr --title "HOSTNAME" --cancel-button Exit-Script 3>&1 1>&2 2>&3); then
|
||||
if [ -z $VM_NAME ]; then
|
||||
HN="debian"
|
||||
HN="mikrotik-routeros-chr"
|
||||
echo -e "${HOSTNAME}${BOLD}${DGN}Hostname: ${BGN}$HN${CL}"
|
||||
else
|
||||
HN=$(echo ${VM_NAME,,} | tr -d ' ')
|
||||
|
@ -116,7 +116,7 @@ function cleanup() {
|
||||
|
||||
TEMP_DIR=$(mktemp -d)
|
||||
pushd $TEMP_DIR >/dev/null
|
||||
if whiptail --backtitle "Proxmox VE Helper Scripts" --title "Debian 12 VM" --yesno "This will create a New Debian 12 VM. Proceed?" 10 58; then
|
||||
if whiptail --backtitle "Proxmox VE Helper Scripts" --title "Pimox Homeassistant OS VM" --yesno "This will create a New Pimox Homeassistant OS VM. Proceed?" 10 58; then
|
||||
:
|
||||
else
|
||||
header_info && echo -e "${CROSS}${RD}User exited script${CL}\n" && exit
|
||||
|
528
vm/ubuntu2504-vm.sh
Normal file
528
vm/ubuntu2504-vm.sh
Normal file
@ -0,0 +1,528 @@
|
||||
#!/usr/bin/env bash
|
||||
|
||||
# Copyright (c) 2021-2025 community-scripts ORG
|
||||
# Author: MickLesk (CanbiZ)
|
||||
# License: MIT | https://github.com/community-scripts/ProxmoxVE/raw/main/LICENSE
|
||||
|
||||
source /dev/stdin <<<$(curl -fsSL https://raw.githubusercontent.com/community-scripts/ProxmoxVE/main/misc/api.func)
|
||||
|
||||
function header_info {
|
||||
clear
|
||||
cat <<"EOF"
|
||||
__ ____ __ ___ ______ ____ __ __ _ ____ ___
|
||||
/ / / / /_ __ ______ / /___ __ |__ \ / ____// __ \/ // / | | / / |/ /
|
||||
/ / / / __ \/ / / / __ \/ __/ / / / __/ //___ \ / / / / // /_ | | / / /|_/ /
|
||||
/ /_/ / /_/ / /_/ / / / / /_/ /_/ / / __/____/ // /_/ /__ __/ | |/ / / / /
|
||||
\____/_.___/\__,_/_/ /_/\__/\__,_/ /____/_____(_)____/ /_/ |___/_/ /_/ (Plucky Puffin)
|
||||
|
||||
EOF
|
||||
}
|
||||
header_info
|
||||
echo -e "\n Loading..."
|
||||
GEN_MAC=02:$(openssl rand -hex 5 | awk '{print toupper($0)}' | sed 's/\(..\)/\1:/g; s/.$//')
|
||||
RANDOM_UUID="$(cat /proc/sys/kernel/random/uuid)"
|
||||
METHOD=""
|
||||
NSAPP="ubuntu-2504-vm"
|
||||
var_os="ubuntu"
|
||||
var_version="2504"
|
||||
|
||||
YW=$(echo "\033[33m")
|
||||
BL=$(echo "\033[36m")
|
||||
RD=$(echo "\033[01;31m")
|
||||
BGN=$(echo "\033[4;92m")
|
||||
GN=$(echo "\033[1;92m")
|
||||
DGN=$(echo "\033[32m")
|
||||
CL=$(echo "\033[m")
|
||||
|
||||
CL=$(echo "\033[m")
|
||||
BOLD=$(echo "\033[1m")
|
||||
BFR="\\r\\033[K"
|
||||
HOLD=" "
|
||||
TAB=" "
|
||||
|
||||
CM="${TAB}✔️${TAB}${CL}"
|
||||
CROSS="${TAB}✖️${TAB}${CL}"
|
||||
INFO="${TAB}💡${TAB}${CL}"
|
||||
OS="${TAB}🖥️${TAB}${CL}"
|
||||
CONTAINERTYPE="${TAB}📦${TAB}${CL}"
|
||||
DISKSIZE="${TAB}💾${TAB}${CL}"
|
||||
CPUCORE="${TAB}🧠${TAB}${CL}"
|
||||
RAMSIZE="${TAB}🛠️${TAB}${CL}"
|
||||
CONTAINERID="${TAB}🆔${TAB}${CL}"
|
||||
HOSTNAME="${TAB}🏠${TAB}${CL}"
|
||||
BRIDGE="${TAB}🌉${TAB}${CL}"
|
||||
GATEWAY="${TAB}🌐${TAB}${CL}"
|
||||
DEFAULT="${TAB}⚙️${TAB}${CL}"
|
||||
MACADDRESS="${TAB}🔗${TAB}${CL}"
|
||||
VLANTAG="${TAB}🏷️${TAB}${CL}"
|
||||
CREATING="${TAB}🚀${TAB}${CL}"
|
||||
ADVANCED="${TAB}🧩${TAB}${CL}"
|
||||
|
||||
THIN="discard=on,ssd=1,"
|
||||
set -e
|
||||
trap 'error_handler $LINENO "$BASH_COMMAND"' ERR
|
||||
trap cleanup EXIT
|
||||
trap 'post_update_to_api "failed" "INTERRUPTED"' SIGINT
|
||||
trap 'post_update_to_api "failed" "TERMINATED"' SIGTERM
|
||||
function error_handler() {
|
||||
local exit_code="$?"
|
||||
local line_number="$1"
|
||||
local command="$2"
|
||||
post_update_to_api "failed" "$command"
|
||||
local error_message="${RD}[ERROR]${CL} in line ${RD}$line_number${CL}: exit code ${RD}$exit_code${CL}: while executing command ${YW}$command${CL}"
|
||||
echo -e "\n$error_message\n"
|
||||
cleanup_vmid
|
||||
}
|
||||
|
||||
function get_valid_nextid() {
|
||||
local try_id
|
||||
try_id=$(pvesh get /cluster/nextid)
|
||||
while true; do
|
||||
if [ -f "/etc/pve/qemu-server/${try_id}.conf" ] || [ -f "/etc/pve/lxc/${try_id}.conf" ]; then
|
||||
try_id=$((try_id + 1))
|
||||
continue
|
||||
fi
|
||||
if lvs --noheadings -o lv_name | grep -qE "(^|[-_])${try_id}($|[-_])"; then
|
||||
try_id=$((try_id + 1))
|
||||
continue
|
||||
fi
|
||||
break
|
||||
done
|
||||
echo "$try_id"
|
||||
}
|
||||
|
||||
function cleanup_vmid() {
|
||||
if qm status $VMID &>/dev/null; then
|
||||
qm stop $VMID &>/dev/null
|
||||
qm destroy $VMID &>/dev/null
|
||||
fi
|
||||
}
|
||||
|
||||
function cleanup() {
|
||||
popd >/dev/null
|
||||
rm -rf $TEMP_DIR
|
||||
}
|
||||
|
||||
TEMP_DIR=$(mktemp -d)
|
||||
pushd $TEMP_DIR >/dev/null
|
||||
if whiptail --backtitle "Proxmox VE Helper Scripts" --title "Ubuntu 25.04 VM" --yesno "This will create a New Ubuntu 25.04 VM. Proceed?" 10 58; then
|
||||
:
|
||||
else
|
||||
header_info && echo -e "${CROSS}${RD}User exited script${CL}\n" && exit
|
||||
fi
|
||||
|
||||
function msg_info() {
|
||||
local msg="$1"
|
||||
echo -ne "${TAB}${YW}${HOLD}${msg}${HOLD}"
|
||||
}
|
||||
|
||||
function msg_ok() {
|
||||
local msg="$1"
|
||||
echo -e "${BFR}${CM}${GN}${msg}${CL}"
|
||||
}
|
||||
|
||||
function msg_error() {
|
||||
local msg="$1"
|
||||
echo -e "${BFR}${CROSS}${RD}${msg}${CL}"
|
||||
}
|
||||
|
||||
function check_root() {
|
||||
if [[ "$(id -u)" -ne 0 || $(ps -o comm= -p $PPID) == "sudo" ]]; then
|
||||
clear
|
||||
msg_error "Please run this script as root."
|
||||
echo -e "\nExiting..."
|
||||
sleep 2
|
||||
exit
|
||||
fi
|
||||
}
|
||||
|
||||
function pve_check() {
|
||||
if ! pveversion | grep -Eq "pve-manager/8\.[1-4](\.[0-9]+)*"; then
|
||||
msg_error "${CROSS}${RD}This version of Proxmox Virtual Environment is not supported"
|
||||
echo -e "Requires Proxmox Virtual Environment Version 8.1 or later."
|
||||
echo -e "Exiting..."
|
||||
sleep 2
|
||||
exit
|
||||
fi
|
||||
}
|
||||
|
||||
function arch_check() {
|
||||
if [ "$(dpkg --print-architecture)" != "amd64" ]; then
|
||||
echo -e "\n ${INFO}${YWB}This script will not work with PiMox! \n"
|
||||
echo -e "\n ${YWB}Visit https://github.com/asylumexp/Proxmox for ARM64 support. \n"
|
||||
echo -e "Exiting..."
|
||||
sleep 2
|
||||
exit
|
||||
fi
|
||||
}
|
||||
|
||||
function ssh_check() {
|
||||
if command -v pveversion >/dev/null 2>&1; then
|
||||
if [ -n "${SSH_CLIENT:+x}" ]; then
|
||||
if whiptail --backtitle "Proxmox VE Helper Scripts" --defaultno --title "SSH DETECTED" --yesno "It's suggested to use the Proxmox shell instead of SSH, since SSH can create issues while gathering variables. Would you like to proceed with using SSH?" 10 62; then
|
||||
echo "you've been warned"
|
||||
else
|
||||
clear
|
||||
exit
|
||||
fi
|
||||
fi
|
||||
fi
|
||||
}
|
||||
|
||||
function exit-script() {
|
||||
clear
|
||||
echo -e "\n${CROSS}${RD}User exited script${CL}\n"
|
||||
exit
|
||||
}
|
||||
|
||||
function default_settings() {
|
||||
VMID=$(get_valid_nextid)
|
||||
FORMAT=",efitype=4m"
|
||||
MACHINE=""
|
||||
DISK_SIZE="7G"
|
||||
DISK_CACHE=""
|
||||
HN="ubuntu"
|
||||
CPU_TYPE=""
|
||||
CORE_COUNT="2"
|
||||
RAM_SIZE="2048"
|
||||
BRG="vmbr0"
|
||||
MAC="$GEN_MAC"
|
||||
VLAN=""
|
||||
MTU=""
|
||||
START_VM="yes"
|
||||
METHOD="default"
|
||||
echo -e "${CONTAINERID}${BOLD}${DGN}Virtual Machine ID: ${BGN}${VMID}${CL}"
|
||||
echo -e "${CONTAINERTYPE}${BOLD}${DGN}Machine Type: ${BGN}i440fx${CL}"
|
||||
echo -e "${DISKSIZE}${BOLD}${DGN}Disk Size: ${BGN}${DISK_SIZE}${CL}"
|
||||
echo -e "${DISKSIZE}${BOLD}${DGN}Disk Cache: ${BGN}None${CL}"
|
||||
echo -e "${HOSTNAME}${BOLD}${DGN}Hostname: ${BGN}${HN}${CL}"
|
||||
echo -e "${OS}${BOLD}${DGN}CPU Model: ${BGN}KVM64${CL}"
|
||||
echo -e "${CPUCORE}${BOLD}${DGN}CPU Cores: ${BGN}${CORE_COUNT}${CL}"
|
||||
echo -e "${RAMSIZE}${BOLD}${DGN}RAM Size: ${BGN}${RAM_SIZE}${CL}"
|
||||
echo -e "${BRIDGE}${BOLD}${DGN}Bridge: ${BGN}${BRG}${CL}"
|
||||
echo -e "${MACADDRESS}${BOLD}${DGN}MAC Address: ${BGN}${MAC}${CL}"
|
||||
echo -e "${VLANTAG}${BOLD}${DGN}VLAN: ${BGN}Default${CL}"
|
||||
echo -e "${DEFAULT}${BOLD}${DGN}Interface MTU Size: ${BGN}Default${CL}"
|
||||
echo -e "${GATEWAY}${BOLD}${DGN}Start VM when completed: ${BGN}yes${CL}"
|
||||
echo -e "${CREATING}${BOLD}${DGN}Creating a Ubuntu 25.04 VM using the above default settings${CL}"
|
||||
}
|
||||
|
||||
function advanced_settings() {
|
||||
METHOD="advanced"
|
||||
[ -z "${VMID:-}" ] && VMID=$(get_valid_nextid)
|
||||
while true; do
|
||||
if VMID=$(whiptail --backtitle "Proxmox VE Helper Scripts" --inputbox "Set Virtual Machine ID" 8 58 $VMID --title "VIRTUAL MACHINE ID" --cancel-button Exit-Script 3>&1 1>&2 2>&3); then
|
||||
if [ -z "$VMID" ]; then
|
||||
VMID=$(get_valid_nextid)
|
||||
fi
|
||||
if pct status "$VMID" &>/dev/null || qm status "$VMID" &>/dev/null; then
|
||||
echo -e "${CROSS}${RD} ID $VMID is already in use${CL}"
|
||||
sleep 2
|
||||
continue
|
||||
fi
|
||||
echo -e "${CONTAINERID}${BOLD}${DGN}Virtual Machine ID: ${BGN}$VMID${CL}"
|
||||
break
|
||||
else
|
||||
exit-script
|
||||
fi
|
||||
done
|
||||
|
||||
if MACH=$(whiptail --backtitle "Proxmox VE Helper Scripts" --title "MACHINE TYPE" --radiolist --cancel-button Exit-Script "Choose Type" 10 58 2 \
|
||||
"i440fx" "Machine i440fx" ON \
|
||||
"q35" "Machine q35" OFF \
|
||||
3>&1 1>&2 2>&3); then
|
||||
if [ $MACH = q35 ]; then
|
||||
echo -e "${CONTAINERTYPE}${BOLD}${DGN}Machine Type: ${BGN}$MACH${CL}"
|
||||
FORMAT=""
|
||||
MACHINE=" -machine q35"
|
||||
else
|
||||
echo -e "${CONTAINERTYPE}${BOLD}${DGN}Machine Type: ${BGN}$MACH${CL}"
|
||||
FORMAT=",efitype=4m"
|
||||
MACHINE=""
|
||||
fi
|
||||
else
|
||||
exit-script
|
||||
fi
|
||||
|
||||
if DISK_SIZE=$(whiptail --backtitle "Proxmox VE Helper Scripts" --inputbox "Set Disk Size in GiB (e.g., 10, 20)" 8 58 "$DISK_SIZE" --title "DISK SIZE" --cancel-button Exit-Script 3>&1 1>&2 2>&3); then
|
||||
DISK_SIZE=$(echo "$DISK_SIZE" | tr -d ' ')
|
||||
if [[ "$DISK_SIZE" =~ ^[0-9]+$ ]]; then
|
||||
DISK_SIZE="${DISK_SIZE}G"
|
||||
echo -e "${DISKSIZE}${BOLD}${DGN}Disk Size: ${BGN}$DISK_SIZE${CL}"
|
||||
elif [[ "$DISK_SIZE" =~ ^[0-9]+G$ ]]; then
|
||||
echo -e "${DISKSIZE}${BOLD}${DGN}Disk Size: ${BGN}$DISK_SIZE${CL}"
|
||||
else
|
||||
echo -e "${DISKSIZE}${BOLD}${RD}Invalid Disk Size. Please use a number (e.g., 10 or 10G).${CL}"
|
||||
exit-script
|
||||
fi
|
||||
else
|
||||
exit-script
|
||||
fi
|
||||
|
||||
if DISK_CACHE=$(whiptail --backtitle "Proxmox VE Helper Scripts" --title "DISK CACHE" --radiolist "Choose" --cancel-button Exit-Script 10 58 2 \
|
||||
"0" "None (Default)" ON \
|
||||
"1" "Write Through" OFF \
|
||||
3>&1 1>&2 2>&3); then
|
||||
if [ $DISK_CACHE = "1" ]; then
|
||||
echo -e "${DISKSIZE}${BOLD}${DGN}Disk Cache: ${BGN}Write Through${CL}"
|
||||
DISK_CACHE="cache=writethrough,"
|
||||
else
|
||||
echo -e "${DISKSIZE}${BOLD}${DGN}Disk Cache: ${BGN}None${CL}"
|
||||
DISK_CACHE=""
|
||||
fi
|
||||
else
|
||||
exit-script
|
||||
fi
|
||||
|
||||
if VM_NAME=$(whiptail --backtitle "Proxmox VE Helper Scripts" --inputbox "Set Hostname" 8 58 ubuntu --title "HOSTNAME" --cancel-button Exit-Script 3>&1 1>&2 2>&3); then
|
||||
if [ -z $VM_NAME ]; then
|
||||
HN="ubuntu"
|
||||
echo -e "${HOSTNAME}${BOLD}${DGN}Hostname: ${BGN}$HN${CL}"
|
||||
else
|
||||
HN=$(echo ${VM_NAME,,} | tr -d ' ')
|
||||
echo -e "${HOSTNAME}${BOLD}${DGN}Hostname: ${BGN}$HN${CL}"
|
||||
fi
|
||||
else
|
||||
exit-script
|
||||
fi
|
||||
|
||||
if CPU_TYPE1=$(whiptail --backtitle "Proxmox VE Helper Scripts" --title "CPU MODEL" --radiolist "Choose" --cancel-button Exit-Script 10 58 2 \
|
||||
"0" "KVM64 (Default)" ON \
|
||||
"1" "Host" OFF \
|
||||
3>&1 1>&2 2>&3); then
|
||||
if [ $CPU_TYPE1 = "1" ]; then
|
||||
echo -e "${OS}${BOLD}${DGN}CPU Model: ${BGN}Host${CL}"
|
||||
CPU_TYPE=" -cpu host"
|
||||
else
|
||||
echo -e "${OS}${BOLD}${DGN}CPU Model: ${BGN}KVM64${CL}"
|
||||
CPU_TYPE=""
|
||||
fi
|
||||
else
|
||||
exit-script
|
||||
fi
|
||||
|
||||
if CORE_COUNT=$(whiptail --backtitle "Proxmox VE Helper Scripts" --inputbox "Allocate CPU Cores" 8 58 2 --title "CORE COUNT" --cancel-button Exit-Script 3>&1 1>&2 2>&3); then
|
||||
if [ -z $CORE_COUNT ]; then
|
||||
CORE_COUNT="2"
|
||||
echo -e "${CPUCORE}${BOLD}${DGN}CPU Cores: ${BGN}$CORE_COUNT${CL}"
|
||||
else
|
||||
echo -e "${CPUCORE}${BOLD}${DGN}CPU Cores: ${BGN}$CORE_COUNT${CL}"
|
||||
fi
|
||||
else
|
||||
exit-script
|
||||
fi
|
||||
|
||||
if RAM_SIZE=$(whiptail --backtitle "Proxmox VE Helper Scripts" --inputbox "Allocate RAM in MiB" 8 58 2048 --title "RAM" --cancel-button Exit-Script 3>&1 1>&2 2>&3); then
|
||||
if [ -z $RAM_SIZE ]; then
|
||||
RAM_SIZE="2048"
|
||||
echo -e "${RAMSIZE}${BOLD}${DGN}RAM Size: ${BGN}$RAM_SIZE${CL}"
|
||||
else
|
||||
echo -e "${RAMSIZE}${BOLD}${DGN}RAM Size: ${BGN}$RAM_SIZE${CL}"
|
||||
fi
|
||||
else
|
||||
exit-script
|
||||
fi
|
||||
|
||||
if BRG=$(whiptail --backtitle "Proxmox VE Helper Scripts" --inputbox "Set a Bridge" 8 58 vmbr0 --title "BRIDGE" --cancel-button Exit-Script 3>&1 1>&2 2>&3); then
|
||||
if [ -z $BRG ]; then
|
||||
BRG="vmbr0"
|
||||
echo -e "${BRIDGE}${BOLD}${DGN}Bridge: ${BGN}$BRG${CL}"
|
||||
else
|
||||
echo -e "${BRIDGE}${BOLD}${DGN}Bridge: ${BGN}$BRG${CL}"
|
||||
fi
|
||||
else
|
||||
exit-script
|
||||
fi
|
||||
|
||||
if MAC1=$(whiptail --backtitle "Proxmox VE Helper Scripts" --inputbox "Set a MAC Address" 8 58 $GEN_MAC --title "MAC ADDRESS" --cancel-button Exit-Script 3>&1 1>&2 2>&3); then
|
||||
if [ -z $MAC1 ]; then
|
||||
MAC="$GEN_MAC"
|
||||
echo -e "${MACADDRESS}${BOLD}${DGN}MAC Address: ${BGN}$MAC${CL}"
|
||||
else
|
||||
MAC="$MAC1"
|
||||
echo -e "${MACADDRESS}${BOLD}${DGN}MAC Address: ${BGN}$MAC1${CL}"
|
||||
fi
|
||||
else
|
||||
exit-script
|
||||
fi
|
||||
|
||||
if VLAN1=$(whiptail --backtitle "Proxmox VE Helper Scripts" --inputbox "Set a Vlan(leave blank for default)" 8 58 --title "VLAN" --cancel-button Exit-Script 3>&1 1>&2 2>&3); then
|
||||
if [ -z $VLAN1 ]; then
|
||||
VLAN1="Default"
|
||||
VLAN=""
|
||||
echo -e "${VLANTAG}${BOLD}${DGN}VLAN: ${BGN}$VLAN1${CL}"
|
||||
else
|
||||
VLAN=",tag=$VLAN1"
|
||||
echo -e "${VLANTAG}${BOLD}${DGN}VLAN: ${BGN}$VLAN1${CL}"
|
||||
fi
|
||||
else
|
||||
exit-script
|
||||
fi
|
||||
|
||||
if MTU1=$(whiptail --backtitle "Proxmox VE Helper Scripts" --inputbox "Set Interface MTU Size (leave blank for default)" 8 58 --title "MTU SIZE" --cancel-button Exit-Script 3>&1 1>&2 2>&3); then
|
||||
if [ -z $MTU1 ]; then
|
||||
MTU1="Default"
|
||||
MTU=""
|
||||
echo -e "${DEFAULT}${BOLD}${DGN}Interface MTU Size: ${BGN}$MTU1${CL}"
|
||||
else
|
||||
MTU=",mtu=$MTU1"
|
||||
echo -e "${DEFAULT}${BOLD}${DGN}Interface MTU Size: ${BGN}$MTU1${CL}"
|
||||
fi
|
||||
else
|
||||
exit-script
|
||||
fi
|
||||
|
||||
if (whiptail --backtitle "Proxmox VE Helper Scripts" --title "START VIRTUAL MACHINE" --yesno "Start VM when completed?" 10 58); then
|
||||
echo -e "${GATEWAY}${BOLD}${DGN}Start VM when completed: ${BGN}yes${CL}"
|
||||
START_VM="yes"
|
||||
else
|
||||
echo -e "${GATEWAY}${BOLD}${DGN}Start VM when completed: ${BGN}no${CL}"
|
||||
START_VM="no"
|
||||
fi
|
||||
|
||||
if (whiptail --backtitle "Proxmox VE Helper Scripts" --title "ADVANCED SETTINGS COMPLETE" --yesno "Ready to create a Ubuntu 25.04 VM?" --no-button Do-Over 10 58); then
|
||||
echo -e "${CREATING}${BOLD}${DGN}Creating a Ubuntu 25.04 VM using the above advanced settings${CL}"
|
||||
else
|
||||
header_info
|
||||
echo -e "${ADVANCED}${BOLD}${RD}Using Advanced Settings${CL}"
|
||||
advanced_settings
|
||||
fi
|
||||
}
|
||||
|
||||
function start_script() {
|
||||
if (whiptail --backtitle "Proxmox VE Helper Scripts" --title "SETTINGS" --yesno "Use Default Settings?" --no-button Advanced 10 58); then
|
||||
header_info
|
||||
echo -e "${DEFAULT}${BOLD}${BL}Using Default Settings${CL}"
|
||||
default_settings
|
||||
else
|
||||
header_info
|
||||
echo -e "${ADVANCED}${BOLD}${RD}Using Advanced Settings${CL}"
|
||||
advanced_settings
|
||||
fi
|
||||
}
|
||||
check_root
|
||||
arch_check
|
||||
pve_check
|
||||
ssh_check
|
||||
start_script
|
||||
post_to_api_vm
|
||||
|
||||
msg_info "Validating Storage"
|
||||
while read -r line; do
|
||||
TAG=$(echo $line | awk '{print $1}')
|
||||
TYPE=$(echo $line | awk '{printf "%-10s", $2}')
|
||||
FREE=$(echo $line | numfmt --field 4-6 --from-unit=K --to=iec --format %.2f | awk '{printf( "%9sB", $6)}')
|
||||
ITEM=" Type: $TYPE Free: $FREE "
|
||||
OFFSET=2
|
||||
if [[ $((${#ITEM} + $OFFSET)) -gt ${MSG_MAX_LENGTH:-} ]]; then
|
||||
MSG_MAX_LENGTH=$((${#ITEM} + $OFFSET))
|
||||
fi
|
||||
STORAGE_MENU+=("$TAG" "$ITEM" "OFF")
|
||||
done < <(pvesm status -content images | awk 'NR>1')
|
||||
VALID=$(pvesm status -content images | awk 'NR>1')
|
||||
if [ -z "$VALID" ]; then
|
||||
msg_error "Unable to detect a valid storage location."
|
||||
exit
|
||||
elif [ $((${#STORAGE_MENU[@]} / 3)) -eq 1 ]; then
|
||||
STORAGE=${STORAGE_MENU[0]}
|
||||
else
|
||||
while [ -z "${STORAGE:+x}" ]; do
|
||||
STORAGE=$(whiptail --backtitle "Proxmox VE Helper Scripts" --title "Storage Pools" --radiolist \
|
||||
"Which storage pool would you like to use for ${HN}?\nTo make a selection, use the Spacebar.\n" \
|
||||
16 $(($MSG_MAX_LENGTH + 23)) 6 \
|
||||
"${STORAGE_MENU[@]}" 3>&1 1>&2 2>&3)
|
||||
done
|
||||
fi
|
||||
msg_ok "Using ${CL}${BL}$STORAGE${CL} ${GN}for Storage Location."
|
||||
msg_ok "Virtual Machine ID is ${CL}${BL}$VMID${CL}."
|
||||
msg_info "Retrieving the URL for the Ubuntu 25.04 Disk Image"
|
||||
URL=https://cloud-images.ubuntu.com/plucky/current/plucky-server-cloudimg-amd64.img
|
||||
sleep 2
|
||||
msg_ok "${CL}${BL}${URL}${CL}"
|
||||
curl -f#SL -o "$(basename "$URL")" "$URL"
|
||||
echo -en "\e[1A\e[0K"
|
||||
FILE=$(basename $URL)
|
||||
msg_ok "Downloaded ${CL}${BL}${FILE}${CL}"
|
||||
|
||||
STORAGE_TYPE=$(pvesm status -storage $STORAGE | awk 'NR>1 {print $2}')
|
||||
case $STORAGE_TYPE in
|
||||
nfs | dir | cifs)
|
||||
DISK_EXT=".qcow2"
|
||||
DISK_REF="$VMID/"
|
||||
DISK_IMPORT="-format qcow2"
|
||||
THIN=""
|
||||
;;
|
||||
btrfs)
|
||||
DISK_EXT=".raw"
|
||||
DISK_REF="$VMID/"
|
||||
DISK_IMPORT="-format raw"
|
||||
FORMAT=",efitype=4m"
|
||||
THIN=""
|
||||
;;
|
||||
esac
|
||||
for i in {0,1}; do
|
||||
disk="DISK$i"
|
||||
eval DISK${i}=vm-${VMID}-disk-${i}${DISK_EXT:-}
|
||||
eval DISK${i}_REF=${STORAGE}:${DISK_REF:-}${!disk}
|
||||
done
|
||||
|
||||
msg_info "Creating a Ubuntu 25.04 VM"
|
||||
qm create $VMID -agent 1${MACHINE} -tablet 0 -localtime 1 -bios ovmf${CPU_TYPE} -cores $CORE_COUNT -memory $RAM_SIZE \
|
||||
-name $HN -tags community-script -net0 virtio,bridge=$BRG,macaddr=$MAC$VLAN$MTU -onboot 1 -ostype l26 -scsihw virtio-scsi-pci
|
||||
pvesm alloc $STORAGE $VMID $DISK0 4M 1>&/dev/null
|
||||
qm importdisk $VMID ${FILE} $STORAGE ${DISK_IMPORT:-} 1>&/dev/null
|
||||
qm set $VMID \
|
||||
-efidisk0 ${DISK0_REF}${FORMAT} \
|
||||
-scsi0 ${DISK1_REF},${DISK_CACHE}${THIN}size=${DISK_SIZE} \
|
||||
-ide2 ${STORAGE}:cloudinit \
|
||||
-boot order=scsi0 \
|
||||
-serial0 socket >/dev/null
|
||||
DESCRIPTION=$(
|
||||
cat <<EOF
|
||||
<div align='center'>
|
||||
<a href='https://Helper-Scripts.com' target='_blank' rel='noopener noreferrer'>
|
||||
<img src='https://raw.githubusercontent.com/community-scripts/ProxmoxVE/main/misc/images/logo-81x112.png' alt='Logo' style='width:81px;height:112px;'/>
|
||||
</a>
|
||||
|
||||
<h2 style='font-size: 24px; margin: 20px 0;'>ubuntu VM</h2>
|
||||
|
||||
<p style='margin: 16px 0;'>
|
||||
<a href='https://ko-fi.com/community_scripts' target='_blank' rel='noopener noreferrer'>
|
||||
<img src='https://img.shields.io/badge/☕-Buy us a coffee-blue' alt='spend Coffee' />
|
||||
</a>
|
||||
</p>
|
||||
|
||||
<span style='margin: 0 10px;'>
|
||||
<i class="fa fa-github fa-fw" style="color: #f5f5f5;"></i>
|
||||
<a href='https://github.com/community-scripts/ProxmoxVE' target='_blank' rel='noopener noreferrer' style='text-decoration: none; color: #00617f;'>GitHub</a>
|
||||
</span>
|
||||
<span style='margin: 0 10px;'>
|
||||
<i class="fa fa-comments fa-fw" style="color: #f5f5f5;"></i>
|
||||
<a href='https://github.com/community-scripts/ProxmoxVE/discussions' target='_blank' rel='noopener noreferrer' style='text-decoration: none; color: #00617f;'>Discussions</a>
|
||||
</span>
|
||||
<span style='margin: 0 10px;'>
|
||||
<i class="fa fa-exclamation-circle fa-fw" style="color: #f5f5f5;"></i>
|
||||
<a href='https://github.com/community-scripts/ProxmoxVE/issues' target='_blank' rel='noopener noreferrer' style='text-decoration: none; color: #00617f;'>Issues</a>
|
||||
</span>
|
||||
</div>
|
||||
EOF
|
||||
)
|
||||
qm set "$VMID" -description "$DESCRIPTION" >/dev/null
|
||||
if [ -n "$DISK_SIZE" ]; then
|
||||
msg_info "Resizing disk to $DISK_SIZE GB"
|
||||
qm resize $VMID scsi0 ${DISK_SIZE} >/dev/null
|
||||
else
|
||||
msg_info "Using default disk size of $DEFAULT_DISK_SIZE GB"
|
||||
qm resize $VMID scsi0 ${DEFAULT_DISK_SIZE} >/dev/null
|
||||
fi
|
||||
|
||||
msg_ok "Created a Ubuntu 25.04 VM ${CL}${BL}(${HN})"
|
||||
if [ "$START_VM" == "yes" ]; then
|
||||
msg_info "Starting Ubuntu 25.04 VM"
|
||||
qm start $VMID
|
||||
msg_ok "Started Ubuntu 25.04 VM"
|
||||
fi
|
||||
post_update_to_api "done" "none"
|
||||
msg_ok "Completed Successfully!\n"
|
||||
echo -e "Setup Cloud-Init before starting \n
|
||||
More info at https://github.com/community-scripts/ProxmoxVE/discussions/272 \n"
|
Reference in New Issue
Block a user