forked from forkanization/Proxmox-arm64
[Several] Disable scripts & Update notices
This commit is contained in:
@@ -5,7 +5,7 @@
|
|||||||
# # License: MIT
|
# # License: MIT
|
||||||
# # https://github.com/tteck/Proxmox/raw/main/LICENSE
|
# # https://github.com/tteck/Proxmox/raw/main/LICENSE
|
||||||
|
|
||||||
echo "Unsupported. View Compability table on GitHub."
|
echo "Unsupported. View notes on GitHub."
|
||||||
|
|
||||||
# function header_info {
|
# function header_info {
|
||||||
# clear
|
# clear
|
||||||
|
|||||||
+1
-1
@@ -5,7 +5,7 @@
|
|||||||
# License: MIT
|
# License: MIT
|
||||||
# https://github.com/tteck/Proxmox/raw/main/LICENSE
|
# https://github.com/tteck/Proxmox/raw/main/LICENSE
|
||||||
|
|
||||||
echo "Unsupported, view GitHub for reason."
|
echo "Unsupported. View notes on GitHub."
|
||||||
|
|
||||||
# function header_info {
|
# function header_info {
|
||||||
# clear
|
# clear
|
||||||
|
|||||||
+1
-1
@@ -1,4 +1,4 @@
|
|||||||
echo "Unsupported, view notes on GitHub"
|
echo "Unsupported. View notes on GitHub."
|
||||||
# #!/usr/bin/env bash
|
# #!/usr/bin/env bash
|
||||||
# source <(curl -s https://raw.githubusercontent.com/asylumexp/Proxmox/main/misc/build.func)
|
# source <(curl -s https://raw.githubusercontent.com/asylumexp/Proxmox/main/misc/build.func)
|
||||||
# # Copyright (c) 2021-2024 tteck
|
# # Copyright (c) 2021-2024 tteck
|
||||||
|
|||||||
+68
-67
@@ -1,73 +1,74 @@
|
|||||||
#!/usr/bin/env bash
|
echo "Unsupported. View notes on GitHub."
|
||||||
source <(curl -s https://raw.githubusercontent.com/asylumexp/Proxmox/main/misc/build.func)
|
# #!/usr/bin/env bash
|
||||||
# Copyright (c) 2021-2024 tteck
|
# source <(curl -s https://raw.githubusercontent.com/asylumexp/Proxmox/main/misc/build.func)
|
||||||
# Authors: tteck (tteckster)
|
# # Copyright (c) 2021-2024 tteck
|
||||||
# License: MIT
|
# # Authors: tteck (tteckster)
|
||||||
# https://github.com/tteck/Proxmox/raw/main/LICENSE
|
# # License: MIT
|
||||||
|
# # https://github.com/tteck/Proxmox/raw/main/LICENSE
|
||||||
|
|
||||||
function header_info {
|
# function header_info {
|
||||||
clear
|
# clear
|
||||||
cat <<"EOF"
|
# cat <<"EOF"
|
||||||
______ _ __
|
# ______ _ __
|
||||||
/ ____/____(_)___ _____ _/ /____
|
# / ____/____(_)___ _____ _/ /____
|
||||||
/ /_ / ___/ / __ `/ __ `/ __/ _ \
|
# / /_ / ___/ / __ `/ __ `/ __/ _ \
|
||||||
/ __/ / / / / /_/ / /_/ / /_/ __/
|
# / __/ / / / / /_/ / /_/ / /_/ __/
|
||||||
/_/ /_/ /_/\__, /\__,_/\__/\___/
|
# /_/ /_/ /_/\__, /\__,_/\__/\___/
|
||||||
/____/
|
# /____/
|
||||||
|
|
||||||
EOF
|
# EOF
|
||||||
}
|
# }
|
||||||
header_info
|
# header_info
|
||||||
echo -e "Loading..."
|
# echo -e "Loading..."
|
||||||
APP="Frigate"
|
# APP="Frigate"
|
||||||
var_disk="20"
|
# var_disk="20"
|
||||||
var_cpu="4"
|
# var_cpu="4"
|
||||||
var_ram="4096"
|
# var_ram="4096"
|
||||||
var_os="debian"
|
# var_os="debian"
|
||||||
var_version="11"
|
# var_version="11"
|
||||||
variables
|
# variables
|
||||||
color
|
# color
|
||||||
catch_errors
|
# catch_errors
|
||||||
|
|
||||||
function default_settings() {
|
# function default_settings() {
|
||||||
CT_TYPE="0"
|
# CT_TYPE="0"
|
||||||
PW=""
|
# PW=""
|
||||||
CT_ID=$NEXTID
|
# CT_ID=$NEXTID
|
||||||
HN=$NSAPP
|
# HN=$NSAPP
|
||||||
DISK_SIZE="$var_disk"
|
# DISK_SIZE="$var_disk"
|
||||||
CORE_COUNT="$var_cpu"
|
# CORE_COUNT="$var_cpu"
|
||||||
RAM_SIZE="$var_ram"
|
# RAM_SIZE="$var_ram"
|
||||||
BRG="vmbr0"
|
# BRG="vmbr0"
|
||||||
NET="dhcp"
|
# NET="dhcp"
|
||||||
GATE=""
|
# GATE=""
|
||||||
APT_CACHER=""
|
# APT_CACHER=""
|
||||||
APT_CACHER_IP=""
|
# APT_CACHER_IP=""
|
||||||
DISABLEIP6="no"
|
# DISABLEIP6="no"
|
||||||
MTU=""
|
# MTU=""
|
||||||
SD=""
|
# SD=""
|
||||||
NS=""
|
# NS=""
|
||||||
MAC=""
|
# MAC=""
|
||||||
VLAN=""
|
# VLAN=""
|
||||||
SSH="no"
|
# SSH="no"
|
||||||
VERB="no"
|
# VERB="no"
|
||||||
echo_default
|
# echo_default
|
||||||
}
|
# }
|
||||||
|
|
||||||
function update_script() {
|
# function update_script() {
|
||||||
if [[ ! -f /etc/systemd/system/frigate.service ]]; then msg_error "No ${APP} Installation Found!"; exit; fi
|
# if [[ ! -f /etc/systemd/system/frigate.service ]]; then msg_error "No ${APP} Installation Found!"; exit; fi
|
||||||
msg_error "There is currently no update path available."
|
# msg_error "There is currently no update path available."
|
||||||
exit
|
# exit
|
||||||
}
|
# }
|
||||||
|
|
||||||
start
|
# start
|
||||||
build_container
|
# build_container
|
||||||
description
|
# description
|
||||||
|
|
||||||
msg_info "Setting Container to Normal Resources"
|
# msg_info "Setting Container to Normal Resources"
|
||||||
pct set $CTID -memory 1024
|
# pct set $CTID -memory 1024
|
||||||
msg_ok "Set Container to Normal Resources"
|
# msg_ok "Set Container to Normal Resources"
|
||||||
msg_ok "Completed Successfully!\n"
|
# msg_ok "Completed Successfully!\n"
|
||||||
echo -e "${APP} should be reachable by going to the following URL.
|
# echo -e "${APP} should be reachable by going to the following URL.
|
||||||
${BL}http://${IP}:5000${CL} \n"
|
# ${BL}http://${IP}:5000${CL} \n"
|
||||||
echo -e "go2rtc should be reachable by going to the following URL.
|
# echo -e "go2rtc should be reachable by going to the following URL.
|
||||||
${BL}http://${IP}:1984${CL} \n"
|
# ${BL}http://${IP}:1984${CL} \n"
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
echo "Unsupported. View notes on GitHub"
|
echo "Unsupported. View notes on GitHub."
|
||||||
# #!/usr/bin/env bash
|
# #!/usr/bin/env bash
|
||||||
# source <(curl -s https://raw.githubusercontent.com/asylumexp/Proxmox/main/misc/build.func)
|
# source <(curl -s https://raw.githubusercontent.com/asylumexp/Proxmox/main/misc/build.func)
|
||||||
# # Copyright (c) 2021-2024 tteck
|
# # Copyright (c) 2021-2024 tteck
|
||||||
|
|||||||
+1
-1
@@ -5,7 +5,7 @@
|
|||||||
# # License: MIT
|
# # License: MIT
|
||||||
# # https://github.com/tteck/Proxmox/raw/main/LICENSE
|
# # https://github.com/tteck/Proxmox/raw/main/LICENSE
|
||||||
|
|
||||||
echo "Not supported"
|
echo "Unsupported. View notes on GitHub."
|
||||||
|
|
||||||
# function header_info {
|
# function header_info {
|
||||||
# clear
|
# clear
|
||||||
|
|||||||
+133
-132
@@ -1,147 +1,148 @@
|
|||||||
#!/usr/bin/env bash
|
echo "Unsupported. View notes on GitHub."
|
||||||
source <(curl -s https://raw.githubusercontent.com/asylumexp/Proxmox/main/misc/build.func)
|
# #!/usr/bin/env bash
|
||||||
# Copyright (c) 2021-2024 tteck
|
# source <(curl -s https://raw.githubusercontent.com/asylumexp/Proxmox/main/misc/build.func)
|
||||||
# Author: tteck (tteckster)
|
# # Copyright (c) 2021-2024 tteck
|
||||||
# License: MIT
|
# # Author: tteck (tteckster)
|
||||||
# https://github.com/tteck/Proxmox/raw/main/LICENSE
|
# # License: MIT
|
||||||
|
# # https://github.com/tteck/Proxmox/raw/main/LICENSE
|
||||||
|
|
||||||
function header_info {
|
# function header_info {
|
||||||
clear
|
# clear
|
||||||
cat <<"EOF"
|
# cat <<"EOF"
|
||||||
_ __ ____ _ __ __
|
# _ __ ____ _ __ __
|
||||||
| | / /___ ___ __/ / /| | / /___ __________/ /__ ____
|
# | | / /___ ___ __/ / /| | / /___ __________/ /__ ____
|
||||||
| | / / __ `/ / / / / __/ | /| / / __ `/ ___/ __ / _ \/ __ \
|
# | | / / __ `/ / / / / __/ | /| / / __ `/ ___/ __ / _ \/ __ \
|
||||||
| |/ / /_/ / /_/ / / /_ | |/ |/ / /_/ / / / /_/ / __/ / / /
|
# | |/ / /_/ / /_/ / / /_ | |/ |/ / /_/ / / / /_/ / __/ / / /
|
||||||
|___/\__,_/\__,_/_/\__/ |__/|__/\__,_/_/ \__,_/\___/_/ /_/
|
# |___/\__,_/\__,_/_/\__/ |__/|__/\__,_/_/ \__,_/\___/_/ /_/
|
||||||
|
|
||||||
EOF
|
# EOF
|
||||||
}
|
# }
|
||||||
header_info
|
# header_info
|
||||||
echo -e "Loading..."
|
# echo -e "Loading..."
|
||||||
APP="Vaultwarden"
|
# APP="Vaultwarden"
|
||||||
var_disk="6"
|
# var_disk="6"
|
||||||
var_cpu="4"
|
# var_cpu="4"
|
||||||
var_ram="4096"
|
# var_ram="4096"
|
||||||
var_os="debian"
|
# var_os="debian"
|
||||||
var_version="12"
|
# var_version="12"
|
||||||
variables
|
# variables
|
||||||
color
|
# color
|
||||||
catch_errors
|
# catch_errors
|
||||||
|
|
||||||
function default_settings() {
|
# function default_settings() {
|
||||||
CT_TYPE="1"
|
# CT_TYPE="1"
|
||||||
PW=""
|
# PW=""
|
||||||
CT_ID=$NEXTID
|
# CT_ID=$NEXTID
|
||||||
HN=$NSAPP
|
# HN=$NSAPP
|
||||||
DISK_SIZE="$var_disk"
|
# DISK_SIZE="$var_disk"
|
||||||
CORE_COUNT="$var_cpu"
|
# CORE_COUNT="$var_cpu"
|
||||||
RAM_SIZE="$var_ram"
|
# RAM_SIZE="$var_ram"
|
||||||
BRG="vmbr0"
|
# BRG="vmbr0"
|
||||||
NET="dhcp"
|
# NET="dhcp"
|
||||||
GATE=""
|
# GATE=""
|
||||||
APT_CACHER=""
|
# APT_CACHER=""
|
||||||
APT_CACHER_IP=""
|
# APT_CACHER_IP=""
|
||||||
DISABLEIP6="no"
|
# DISABLEIP6="no"
|
||||||
MTU=""
|
# MTU=""
|
||||||
SD=""
|
# SD=""
|
||||||
NS=""
|
# NS=""
|
||||||
MAC=""
|
# MAC=""
|
||||||
VLAN=""
|
# VLAN=""
|
||||||
SSH="no"
|
# SSH="no"
|
||||||
VERB="no"
|
# VERB="no"
|
||||||
echo_default
|
# echo_default
|
||||||
}
|
# }
|
||||||
|
|
||||||
function update_script() {
|
# function update_script() {
|
||||||
if [[ ! -f /etc/systemd/system/vaultwarden.service ]]; then
|
# if [[ ! -f /etc/systemd/system/vaultwarden.service ]]; then
|
||||||
msg_error "No ${APP} Installation Found!"
|
# msg_error "No ${APP} Installation Found!"
|
||||||
exit
|
# exit
|
||||||
fi
|
# fi
|
||||||
VAULT=$(curl -s https://api.github.com/repos/dani-garcia/vaultwarden/releases/latest |
|
# VAULT=$(curl -s https://api.github.com/repos/dani-garcia/vaultwarden/releases/latest |
|
||||||
grep "tag_name" |
|
# grep "tag_name" |
|
||||||
awk '{print substr($2, 2, length($2)-3) }')
|
# awk '{print substr($2, 2, length($2)-3) }')
|
||||||
WVRELEASE=$(curl -s https://api.github.com/repos/dani-garcia/bw_web_builds/releases/latest |
|
# WVRELEASE=$(curl -s https://api.github.com/repos/dani-garcia/bw_web_builds/releases/latest |
|
||||||
grep "tag_name" |
|
# grep "tag_name" |
|
||||||
awk '{print substr($2, 2, length($2)-3) }')
|
# awk '{print substr($2, 2, length($2)-3) }')
|
||||||
|
|
||||||
UPD=$(whiptail --backtitle "Proxmox VE Helper Scripts" --title "SUPPORT" --radiolist --cancel-button Exit-Script "Spacebar = Select" 11 58 3 \
|
# UPD=$(whiptail --backtitle "Proxmox VE Helper Scripts" --title "SUPPORT" --radiolist --cancel-button Exit-Script "Spacebar = Select" 11 58 3 \
|
||||||
"1" "VaultWarden $VAULT" ON \
|
# "1" "VaultWarden $VAULT" ON \
|
||||||
"2" "Web-Vault $WVRELEASE" OFF \
|
# "2" "Web-Vault $WVRELEASE" OFF \
|
||||||
"3" "Set Admin Token" OFF \
|
# "3" "Set Admin Token" OFF \
|
||||||
3>&1 1>&2 2>&3)
|
# 3>&1 1>&2 2>&3)
|
||||||
|
|
||||||
header_info
|
# header_info
|
||||||
if [ "$UPD" == "1" ]; then
|
# if [ "$UPD" == "1" ]; then
|
||||||
echo -e "\n ⚠️ Ensure you set 4vCPU & 4096MiB RAM minimum!!! \n"
|
# echo -e "\n ⚠️ Ensure you set 4vCPU & 4096MiB RAM minimum!!! \n"
|
||||||
msg_info "Stopping Vaultwarden"
|
# msg_info "Stopping Vaultwarden"
|
||||||
systemctl stop vaultwarden.service
|
# systemctl stop vaultwarden.service
|
||||||
msg_ok "Stopped Vaultwarden"
|
# msg_ok "Stopped Vaultwarden"
|
||||||
|
|
||||||
msg_info "Updating VaultWarden to $VAULT (Patience)"
|
# msg_info "Updating VaultWarden to $VAULT (Patience)"
|
||||||
cd ~ && rm -rf vaultwarden
|
# cd ~ && rm -rf vaultwarden
|
||||||
git clone https://github.com/dani-garcia/vaultwarden &>/dev/null
|
# git clone https://github.com/dani-garcia/vaultwarden &>/dev/null
|
||||||
cd vaultwarden
|
# cd vaultwarden
|
||||||
cargo build --features "sqlite,mysql,postgresql" --release &>/dev/null
|
# cargo build --features "sqlite,mysql,postgresql" --release &>/dev/null
|
||||||
DIR=/usr/bin/vaultwarden
|
# DIR=/usr/bin/vaultwarden
|
||||||
if [ -d "$DIR" ]; then
|
# if [ -d "$DIR" ]; then
|
||||||
cp target/release/vaultwarden /usr/bin/
|
# cp target/release/vaultwarden /usr/bin/
|
||||||
else
|
# else
|
||||||
cp target/release/vaultwarden /opt/vaultwarden/bin/
|
# cp target/release/vaultwarden /opt/vaultwarden/bin/
|
||||||
fi
|
# fi
|
||||||
msg_ok "Updated VaultWarden"
|
# msg_ok "Updated VaultWarden"
|
||||||
|
|
||||||
msg_info "Cleaning up"
|
# msg_info "Cleaning up"
|
||||||
cd ~ && rm -rf vaultwarden
|
# cd ~ && rm -rf vaultwarden
|
||||||
msg_ok "Cleaned"
|
# msg_ok "Cleaned"
|
||||||
|
|
||||||
msg_info "Starting Vaultwarden"
|
# msg_info "Starting Vaultwarden"
|
||||||
systemctl start vaultwarden.service
|
# systemctl start vaultwarden.service
|
||||||
msg_ok "Started Vaultwarden"
|
# msg_ok "Started Vaultwarden"
|
||||||
|
|
||||||
msg_ok "$VAULT Update Successful"
|
# msg_ok "$VAULT Update Successful"
|
||||||
echo -e "\n ⚠️ Ensure you set resources back to normal settings \n"
|
# echo -e "\n ⚠️ Ensure you set resources back to normal settings \n"
|
||||||
exit
|
# exit
|
||||||
fi
|
# fi
|
||||||
if [ "$UPD" == "2" ]; then
|
# if [ "$UPD" == "2" ]; then
|
||||||
msg_info "Stopping Vaultwarden"
|
# msg_info "Stopping Vaultwarden"
|
||||||
systemctl stop vaultwarden.service
|
# systemctl stop vaultwarden.service
|
||||||
msg_ok "Stopped Vaultwarden"
|
# msg_ok "Stopped Vaultwarden"
|
||||||
|
|
||||||
msg_info "Updating Web-Vault to $WVRELEASE"
|
# msg_info "Updating Web-Vault to $WVRELEASE"
|
||||||
curl -fsSLO https://github.com/dani-garcia/bw_web_builds/releases/download/$WVRELEASE/bw_web_$WVRELEASE.tar.gz &>/dev/null
|
# curl -fsSLO https://github.com/dani-garcia/bw_web_builds/releases/download/$WVRELEASE/bw_web_$WVRELEASE.tar.gz &>/dev/null
|
||||||
tar -zxf bw_web_$WVRELEASE.tar.gz -C /opt/vaultwarden/ &>/dev/null
|
# tar -zxf bw_web_$WVRELEASE.tar.gz -C /opt/vaultwarden/ &>/dev/null
|
||||||
msg_ok "Updated Web-Vault"
|
# msg_ok "Updated Web-Vault"
|
||||||
|
|
||||||
msg_info "Cleaning up"
|
# msg_info "Cleaning up"
|
||||||
rm bw_web_$WVRELEASE.tar.gz
|
# rm bw_web_$WVRELEASE.tar.gz
|
||||||
msg_ok "Cleaned"
|
# msg_ok "Cleaned"
|
||||||
|
|
||||||
msg_info "Starting Vaultwarden"
|
# msg_info "Starting Vaultwarden"
|
||||||
systemctl start vaultwarden.service
|
# systemctl start vaultwarden.service
|
||||||
msg_ok "Started Vaultwarden"
|
# msg_ok "Started Vaultwarden"
|
||||||
msg_ok "$WVRELEASE Update Successful"
|
# msg_ok "$WVRELEASE Update Successful"
|
||||||
exit
|
# exit
|
||||||
fi
|
# fi
|
||||||
if [ "$UPD" == "3" ]; then
|
# if [ "$UPD" == "3" ]; then
|
||||||
if NEWTOKEN=$(whiptail --backtitle "Proxmox VE Helper Scripts" --passwordbox "Set the ADMIN_TOKEN" 10 58 3>&1 1>&2 2>&3); then
|
# if NEWTOKEN=$(whiptail --backtitle "Proxmox VE Helper Scripts" --passwordbox "Set the ADMIN_TOKEN" 10 58 3>&1 1>&2 2>&3); then
|
||||||
if [[ -z "$NEWTOKEN" ]]; then exit; fi
|
# if [[ -z "$NEWTOKEN" ]]; then exit; fi
|
||||||
if ! command -v argon2 >/dev/null 2>&1; then apt-get install -y argon2 &>/dev/null; fi
|
# if ! command -v argon2 >/dev/null 2>&1; then apt-get install -y argon2 &>/dev/null; fi
|
||||||
TOKEN=$(echo -n ${NEWTOKEN} | argon2 "$(openssl rand -base64 32)" -t 2 -m 16 -p 4 -l 64 -e)
|
# TOKEN=$(echo -n ${NEWTOKEN} | argon2 "$(openssl rand -base64 32)" -t 2 -m 16 -p 4 -l 64 -e)
|
||||||
sed -i "s|ADMIN_TOKEN=.*|ADMIN_TOKEN='${TOKEN}'|" /opt/vaultwarden/.env
|
# sed -i "s|ADMIN_TOKEN=.*|ADMIN_TOKEN='${TOKEN}'|" /opt/vaultwarden/.env
|
||||||
systemctl restart vaultwarden
|
# systemctl restart vaultwarden
|
||||||
fi
|
# fi
|
||||||
exit
|
# exit
|
||||||
fi
|
# fi
|
||||||
}
|
# }
|
||||||
|
|
||||||
start
|
# start
|
||||||
build_container
|
# build_container
|
||||||
description
|
# description
|
||||||
|
|
||||||
msg_info "Setting Container to Normal Resources"
|
# msg_info "Setting Container to Normal Resources"
|
||||||
pct set $CTID -memory 512
|
# pct set $CTID -memory 512
|
||||||
pct set $CTID -cores 1
|
# pct set $CTID -cores 1
|
||||||
msg_ok "Set Container to Normal Resources"
|
# msg_ok "Set Container to Normal Resources"
|
||||||
msg_ok "Completed Successfully!\n"
|
# msg_ok "Completed Successfully!\n"
|
||||||
echo -e "${APP} should be reachable by going to the following URL.
|
# echo -e "${APP} should be reachable by going to the following URL.
|
||||||
${BL}http://${IP}:8000${CL} \n"
|
# ${BL}http://${IP}:8000${CL} \n"
|
||||||
|
|||||||
Reference in New Issue
Block a user