mirror of https://github.com/tteck/Proxmox.git
Compare commits
No commits in common. "0b604d204a174e567477e38ef75c6e4f1e90a9a2" and "c0e3edc0c90479922583d98078b8fc43024e0946" have entirely different histories.
0b604d204a
...
c0e3edc0c9
|
@ -25,7 +25,7 @@ if [[ "$CTTYPE" == "0" ]]; then
|
|||
msg_info "Setting Up Hardware Acceleration"
|
||||
$STD apt-get -y install \
|
||||
va-driver-all \
|
||||
ocl-icd-libopencl1 \
|
||||
ocl-icd-libopencl1 \
|
||||
intel-opencl-icd
|
||||
chgrp video /dev/dri
|
||||
chmod 755 /dev/dri
|
||||
|
@ -38,7 +38,7 @@ fi
|
|||
msg_info "Installing Channels DVR Server (Patience)"
|
||||
cd /opt
|
||||
$STD bash <(curl -fsSL https://getchannels.com/dvr/setup.sh)
|
||||
sed -i -e 's/^sgx:x:104:$/render:x:104:root/' -e 's/^render:x:106:root$/sgx:x:106:/' /etc/group
|
||||
# adduser $(id -u -n) video && adduser $(id -u -n) render
|
||||
msg_ok "Installed Channels DVR Server"
|
||||
|
||||
motd_ssh
|
||||
|
|
|
@ -110,7 +110,6 @@ fi
|
|||
|
||||
msg_info "Installing Scrypted"
|
||||
$STD npx -y scrypted@latest install-server
|
||||
sed -i -e 's/^sgx:x:104:$/render:x:104:root/' -e 's/^render:x:106:root$/sgx:x:106:/' /etc/group
|
||||
msg_ok "Installed Scrypted"
|
||||
|
||||
msg_info "Creating Service"
|
||||
|
|
|
@ -42,7 +42,6 @@ $STD unzip Tdarr_Updater.zip
|
|||
rm -rf Tdarr_Updater.zip
|
||||
chmod +x Tdarr_Updater
|
||||
./Tdarr_Updater &>/dev/null
|
||||
sed -i -e 's/^sgx:x:104:$/render:x:104:root/' -e 's/^render:x:106:root$/sgx:x:106:/' /etc/group
|
||||
msg_ok "Installed Tdarr"
|
||||
|
||||
msg_info "Creating Service"
|
||||
|
|
|
@ -37,7 +37,6 @@ fi
|
|||
|
||||
msg_info "Installing Unmanic"
|
||||
$STD pip3 install unmanic
|
||||
sed -i -e 's/^sgx:x:104:$/render:x:104:root/' -e 's/^render:x:106:root$/sgx:x:106:/' /etc/group
|
||||
msg_ok "Installed Unmanic"
|
||||
|
||||
msg_info "Creating Service"
|
||||
|
|
|
@ -71,19 +71,8 @@ msg_error() {
|
|||
echo -e "${BFR} ${CROSS} ${RD}${msg}${CL}"
|
||||
}
|
||||
|
||||
# Check if the shell is using bash
|
||||
shell_check() {
|
||||
if [[ "$(basename "$SHELL")" != "bash" ]]; then
|
||||
clear
|
||||
msg_error "Your current shell is not Bash. To utilize these scripts, please switch to the Bash shell."
|
||||
echo -e "\nExiting..."
|
||||
sleep 2
|
||||
exit
|
||||
fi
|
||||
}
|
||||
|
||||
# Run as root only
|
||||
root_check() {
|
||||
check_root() {
|
||||
if [[ "$(id -u)" -ne 0 || $(ps -o comm= -p $PPID) == "sudo" ]]; then
|
||||
clear
|
||||
msg_error "Please run this script as root."
|
||||
|
@ -461,12 +450,10 @@ advanced_settings() {
|
|||
}
|
||||
|
||||
install_script() {
|
||||
pve_check
|
||||
shell_check
|
||||
root_check
|
||||
arch_check
|
||||
check_root
|
||||
ssh_check
|
||||
|
||||
arch_check
|
||||
pve_check
|
||||
if systemctl is-active -q ping-instances.service; then
|
||||
systemctl -q stop ping-instances.service
|
||||
fi
|
||||
|
|
|
@ -112,33 +112,35 @@ setting_up_container() {
|
|||
network_check() {
|
||||
set +e
|
||||
trap - ERR
|
||||
ipv4_connected=false
|
||||
ipv6_connected=false
|
||||
|
||||
# Check IPv4 connectivity
|
||||
if ping -c 1 -W 1 1.1.1.1 &>/dev/null; then
|
||||
msg_ok "IPv4 Internet Connected";
|
||||
ipv4_connected=true
|
||||
else
|
||||
msg_error "IPv4 Internet Not Connected";
|
||||
fi
|
||||
|
||||
# Check IPv6 connectivity
|
||||
if ping6 -c 1 -W 1 2606:4700:4700::1111 &>/dev/null; then
|
||||
msg_ok "IPv6 Internet Connected";
|
||||
ipv6_connected=true
|
||||
else
|
||||
msg_error "IPv6 Internet Not Connected";
|
||||
fi
|
||||
|
||||
# If both IPv4 and IPv6 checks fail, prompt the user
|
||||
if [[ $ipv4_connected == false && $ipv6_connected == false ]]; then
|
||||
read -r -p "No Internet detected,would you like to continue anyway? <y/N> " prompt
|
||||
if [[ "${prompt,,}" =~ ^(y|yes)$ ]]; then
|
||||
echo -e " ⚠️ ${RD}Expect Issues Without Internet${CL}"
|
||||
# Check if IPv4 is being used
|
||||
if ip -o -4 addr show | grep -q "scope global"; then
|
||||
if ping -c 1 -W 1 1.1.1.1 &>/dev/null; then
|
||||
msg_ok "IPv4 Internet Connected";
|
||||
else
|
||||
echo -e " 🖧 Check Network Settings"
|
||||
exit 1
|
||||
msg_error "IPv4 Internet Not Connected";
|
||||
read -r -p "Would you like to continue anyway? <y/N> " prompt
|
||||
if [[ "${prompt,,}" =~ ^(y|yes)$ ]]; then
|
||||
echo -e " ⚠️ ${RD}Expect Issues Without Internet${CL}"
|
||||
else
|
||||
echo -e " 🖧 Check Network Settings"
|
||||
exit 1
|
||||
fi
|
||||
fi
|
||||
fi
|
||||
|
||||
# Check if IPv6 is being used
|
||||
if ip -o -6 addr show | grep -q "scope global"; then
|
||||
if ping -6 google.com &>/dev/null; then
|
||||
msg_ok "IPv6 Internet Connected";
|
||||
else
|
||||
msg_error "IPv6 Internet Not Connected";
|
||||
read -r -p "Would you like to continue anyway? <y/N> " prompt
|
||||
if [[ "${prompt,,}" =~ ^(y|yes)$ ]]; then
|
||||
echo -e " ⚠️ ${RD}Expect Issues Without Internet${CL}"
|
||||
else
|
||||
echo -e " 🖧 Check Network Settings"
|
||||
exit 1
|
||||
fi
|
||||
fi
|
||||
fi
|
||||
|
||||
|
|
Loading…
Reference in New Issue