mirror of https://github.com/tteck/Proxmox.git
Compare commits
No commits in common. "ef6abf4bd6b20d94d00828e0dc659a976340a540" and "f20d65a606f6b6cd5f524f3f6151a9045591767d" have entirely different histories.
ef6abf4bd6
...
f20d65a606
|
@ -1,69 +0,0 @@
|
||||||
#!/usr/bin/env bash
|
|
||||||
source <(curl -s https://raw.githubusercontent.com/tteck/Proxmox/main/misc/build.func)
|
|
||||||
# Copyright (c) 2021-2024 tteck
|
|
||||||
# Author: tteck (tteckster)
|
|
||||||
# License: MIT
|
|
||||||
# https://github.com/tteck/Proxmox/raw/main/LICENSE
|
|
||||||
|
|
||||||
function header_info {
|
|
||||||
clear
|
|
||||||
cat <<"EOF"
|
|
||||||
______
|
|
||||||
/_ __/________ _______________ ______
|
|
||||||
/ / / ___/ __ `/ ___/ ___/ __ `/ ___/
|
|
||||||
/ / / / / /_/ / /__/ /__/ /_/ / /
|
|
||||||
/_/ /_/ \__,_/\___/\___/\__,_/_/
|
|
||||||
|
|
||||||
EOF
|
|
||||||
}
|
|
||||||
header_info
|
|
||||||
echo -e "Loading..."
|
|
||||||
APP="Traccar"
|
|
||||||
var_disk="2"
|
|
||||||
var_cpu="1"
|
|
||||||
var_ram="1024"
|
|
||||||
var_os="debian"
|
|
||||||
var_version="12"
|
|
||||||
variables
|
|
||||||
color
|
|
||||||
catch_errors
|
|
||||||
|
|
||||||
function default_settings() {
|
|
||||||
CT_TYPE="1"
|
|
||||||
PW=""
|
|
||||||
CT_ID=$NEXTID
|
|
||||||
HN=$NSAPP
|
|
||||||
DISK_SIZE="$var_disk"
|
|
||||||
CORE_COUNT="$var_cpu"
|
|
||||||
RAM_SIZE="$var_ram"
|
|
||||||
BRG="vmbr0"
|
|
||||||
NET="dhcp"
|
|
||||||
GATE=""
|
|
||||||
APT_CACHER=""
|
|
||||||
APT_CACHER_IP=""
|
|
||||||
DISABLEIP6="no"
|
|
||||||
MTU=""
|
|
||||||
SD=""
|
|
||||||
NS=""
|
|
||||||
MAC=""
|
|
||||||
VLAN=""
|
|
||||||
SSH="no"
|
|
||||||
VERB="no"
|
|
||||||
echo_default
|
|
||||||
}
|
|
||||||
|
|
||||||
function update_script() {
|
|
||||||
header_info
|
|
||||||
if [[ ! -d /opt/traccar ]]; then msg_error "No ${APP} Installation Found!"; exit; fi
|
|
||||||
msg_error "There is currently no update path available."
|
|
||||||
exit
|
|
||||||
exit
|
|
||||||
}
|
|
||||||
|
|
||||||
start
|
|
||||||
build_container
|
|
||||||
description
|
|
||||||
|
|
||||||
msg_ok "Completed Successfully!\n"
|
|
||||||
echo -e "${APP} should be reachable by going to the following URL.
|
|
||||||
${BL}http://${IP}:8082${CL} \n"
|
|
|
@ -1,37 +0,0 @@
|
||||||
#!/usr/bin/env bash
|
|
||||||
|
|
||||||
# Copyright (c) 2021-2024 tteck
|
|
||||||
# Author: tteck (tteckster)
|
|
||||||
# License: MIT
|
|
||||||
# https://github.com/tteck/Proxmox/raw/main/LICENSE
|
|
||||||
|
|
||||||
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 curl
|
|
||||||
$STD apt-get install -y sudo
|
|
||||||
$STD apt-get install -y mc
|
|
||||||
msg_ok "Installed Dependencies"
|
|
||||||
|
|
||||||
RELEASE=$(curl -s https://api.github.com/repos/traccar/traccar/releases/latest | grep "tag_name" | awk '{print substr($2, 3, length($2)-4) }')
|
|
||||||
msg_info "Installing Traccar v${RELEASE}"
|
|
||||||
wget -q https://github.com/traccar/traccar/releases/download/v${RELEASE}/traccar-linux-64-${RELEASE}.zip
|
|
||||||
$STD unzip traccar-linux-64-${RELEASE}.zip
|
|
||||||
$STD ./traccar.run
|
|
||||||
systemctl enable -q --now traccar
|
|
||||||
rm -rf README.txt traccar-linux-64-${RELEASE}.zip traccar.run
|
|
||||||
msg_ok "Installed Traccar v${RELEASE}"
|
|
||||||
|
|
||||||
motd_ssh
|
|
||||||
customize
|
|
||||||
|
|
||||||
msg_info "Cleaning up"
|
|
||||||
$STD apt-get autoremove
|
|
||||||
$STD apt-get autoclean
|
|
||||||
msg_ok "Cleaned"
|
|
|
@ -98,7 +98,7 @@ pve_check() {
|
||||||
if [ $(pveversion | grep "pve-manager/8" | wc -l) -ne 1 ]; then
|
if [ $(pveversion | grep "pve-manager/8" | wc -l) -ne 1 ]; then
|
||||||
whiptail --backtitle "Proxmox VE Helper Scripts" --msgbox --title "Proxmox VE 7 Detected" "You are currently using Proxmox VE 7 (EOL 2024-07), refrain from creating Debian 12 LXCs. \nDefault distribution for $APP LXC is ${var_os} ${var_version}" 10 60
|
whiptail --backtitle "Proxmox VE Helper Scripts" --msgbox --title "Proxmox VE 7 Detected" "You are currently using Proxmox VE 7 (EOL 2024-07), refrain from creating Debian 12 LXCs. \nDefault distribution for $APP LXC is ${var_os} ${var_version}" 10 60
|
||||||
fi
|
fi
|
||||||
if ! pveversion | grep -Eq "pve-manager/(7\.4-(1[3-8])|8\.[1-2])"; then
|
if ! pveversion | grep -Eq "pve-manager/(7.4-[1][3-9]|8.1.[1-9])"; then
|
||||||
msg_error "This version of Proxmox Virtual Environment is not supported"
|
msg_error "This version of Proxmox Virtual Environment is not supported"
|
||||||
echo -e "Requires PVE7 Version 7.4-13 or later, or PVE8 Version 8.1.1 or later."
|
echo -e "Requires PVE7 Version 7.4-13 or later, or PVE8 Version 8.1.1 or later."
|
||||||
echo -e "Exiting..."
|
echo -e "Exiting..."
|
||||||
|
|
|
@ -92,7 +92,7 @@ function check_root() {
|
||||||
}
|
}
|
||||||
|
|
||||||
function pve_check() {
|
function pve_check() {
|
||||||
if ! pveversion | grep -Eq "pve-manager/(7\.4-(1[3-8])|8\.[1-2])"; then
|
if ! pveversion | grep -Eq "pve-manager/(7.4-[1][3-9]|8.1.[1-9])"; then
|
||||||
msg_error "This version of Proxmox Virtual Environment is not supported"
|
msg_error "This version of Proxmox Virtual Environment is not supported"
|
||||||
echo -e "Requires PVE7 Version 7.4-13 or later, or PVE8 Version 8.1.1 or later."
|
echo -e "Requires PVE7 Version 7.4-13 or later, or PVE8 Version 8.1.1 or later."
|
||||||
echo -e "Exiting..."
|
echo -e "Exiting..."
|
||||||
|
|
|
@ -115,7 +115,7 @@ function check_root() {
|
||||||
}
|
}
|
||||||
|
|
||||||
function pve_check() {
|
function pve_check() {
|
||||||
if ! pveversion | grep -Eq "pve-manager/(7\.4-(1[3-8])|8\.[1-2])"; then
|
if ! pveversion | grep -Eq "pve-manager/(7.4-[1][3-9]|8.1.[1-9])"; then
|
||||||
msg_error "This version of Proxmox Virtual Environment is not supported"
|
msg_error "This version of Proxmox Virtual Environment is not supported"
|
||||||
echo -e "Requires PVE7 Version 7.4-13 or later, or PVE8 Version 8.1.1 or later."
|
echo -e "Requires PVE7 Version 7.4-13 or later, or PVE8 Version 8.1.1 or later."
|
||||||
echo -e "Exiting..."
|
echo -e "Exiting..."
|
||||||
|
|
|
@ -91,7 +91,7 @@ function check_root() {
|
||||||
}
|
}
|
||||||
|
|
||||||
function pve_check() {
|
function pve_check() {
|
||||||
if ! pveversion | grep -Eq "pve-manager/(7\.4-(1[3-8])|8\.[1-2])"; then
|
if ! pveversion | grep -Eq "pve-manager/(7.4-[1][3-9]|8.1.[1-9])"; then
|
||||||
msg_error "This version of Proxmox Virtual Environment is not supported"
|
msg_error "This version of Proxmox Virtual Environment is not supported"
|
||||||
echo -e "Requires PVE7 Version 7.4-13 or later, or PVE8 Version 8.1.1 or later."
|
echo -e "Requires PVE7 Version 7.4-13 or later, or PVE8 Version 8.1.1 or later."
|
||||||
echo -e "Exiting..."
|
echo -e "Exiting..."
|
||||||
|
|
|
@ -157,7 +157,7 @@ function msg_error() {
|
||||||
}
|
}
|
||||||
|
|
||||||
function pve_check() {
|
function pve_check() {
|
||||||
if ! pveversion | grep -Eq "pve-manager/(7\.4-(1[3-8])|8\.[1-2])"; then
|
if ! pveversion | grep -Eq "pve-manager/(7.4-[1][3-9]|8.1.[1-9])"; then
|
||||||
echo -e "${CROSS} This version of Proxmox Virtual Environment is not supported"
|
echo -e "${CROSS} This version of Proxmox Virtual Environment is not supported"
|
||||||
echo -e "Requires PVE7 Version 7.4-13 or later, or PVE8 Version 8.1.1 or later."
|
echo -e "Requires PVE7 Version 7.4-13 or later, or PVE8 Version 8.1.1 or later."
|
||||||
echo -e "Exiting..."
|
echo -e "Exiting..."
|
||||||
|
|
|
@ -91,7 +91,7 @@ function check_root() {
|
||||||
}
|
}
|
||||||
|
|
||||||
function pve_check() {
|
function pve_check() {
|
||||||
if ! pveversion | grep -Eq "pve-manager/(7\.4-(1[3-8])|8\.[1-2])"; then
|
if ! pveversion | grep -Eq "pve-manager/(7.4-[1][3-9]|8.1.[1-9])"; then
|
||||||
msg_error "This version of Proxmox Virtual Environment is not supported"
|
msg_error "This version of Proxmox Virtual Environment is not supported"
|
||||||
echo -e "Requires PVE7 Version 7.4-13 or later, or PVE8 Version 8.1.1 or later."
|
echo -e "Requires PVE7 Version 7.4-13 or later, or PVE8 Version 8.1.1 or later."
|
||||||
echo -e "Exiting..."
|
echo -e "Exiting..."
|
||||||
|
|
|
@ -92,7 +92,7 @@ function check_root() {
|
||||||
}
|
}
|
||||||
|
|
||||||
function pve_check() {
|
function pve_check() {
|
||||||
if ! pveversion | grep -Eq "pve-manager/(7\.4-(1[3-8])|8\.[1-2])"; then
|
if ! pveversion | grep -Eq "pve-manager/(7.4-[1][3-9]|8.1.[1-9])"; then
|
||||||
msg_error "This version of Proxmox Virtual Environment is not supported"
|
msg_error "This version of Proxmox Virtual Environment is not supported"
|
||||||
echo -e "Requires PVE7 Version 7.4-13 or later, or PVE8 Version 8.1.1 or later."
|
echo -e "Requires PVE7 Version 7.4-13 or later, or PVE8 Version 8.1.1 or later."
|
||||||
echo -e "Exiting..."
|
echo -e "Exiting..."
|
||||||
|
|
Loading…
Reference in New Issue