mirror of
https://github.com/usmannasir/cyberpanel.git
synced 2025-11-08 06:16:08 +01:00
bug fix: fix permissions on cent8
This commit is contained in:
@@ -497,7 +497,7 @@ class FileManager:
|
|||||||
website = Websites.objects.get(domain=domainName)
|
website = Websites.objects.get(domain=domainName)
|
||||||
externalApp = website.externalApp
|
externalApp = website.externalApp
|
||||||
|
|
||||||
if ProcessUtilities.decideDistro() == ProcessUtilities.centos:
|
if ProcessUtilities.decideDistro() == ProcessUtilities.centos or ProcessUtilities.decideDistro() == ProcessUtilities.cent8:
|
||||||
groupName = 'nobody'
|
groupName = 'nobody'
|
||||||
else:
|
else:
|
||||||
groupName = 'nogroup'
|
groupName = 'nogroup'
|
||||||
|
|||||||
60
install.sh
60
install.sh
@@ -1,42 +1,36 @@
|
|||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
|
|
||||||
if [ -f "/etc/os-release" ]; then
|
OUTPUT=$(cat /etc/*release)
|
||||||
. /etc/os-release
|
if echo $OUTPUT | grep -q "CentOS Linux 7" ; then
|
||||||
else
|
echo "Checking and installing curl and wget"
|
||||||
ID="unsupported"
|
yum install curl wget -y 1> /dev/null
|
||||||
PRETTY_NAME="Your OS does not have a /etc/os-release file"
|
yum update curl wget ca-certificates -y 1> /dev/null
|
||||||
fi
|
|
||||||
|
|
||||||
if [ "$ID" = "ubuntu" ] && [ "$UBUNTU_CODENAME" = "bionic" ]; then
|
|
||||||
export DEBIAN_FRONTEND=noninteractive
|
|
||||||
apt -q -y -o Dpkg::Options::=--force-confnew update
|
|
||||||
apt -q -y -o Dpkg::Options::=--force-confnew install wget curl
|
|
||||||
SERVER_OS="Ubuntu"
|
|
||||||
elif [ "$ID" = "centos" ] || [ "$ID" = "cloudlinux" ]; then
|
|
||||||
case "$VERSION_ID" in
|
|
||||||
7|7.*)
|
|
||||||
yum install curl wget -y 1> /dev/null
|
|
||||||
yum update curl wget ca-certificates -y 1> /dev/null
|
|
||||||
if [ "$ID" = "centos" ]; then
|
|
||||||
SERVER_OS="CentOS"
|
SERVER_OS="CentOS"
|
||||||
else
|
elif echo $OUTPUT | grep -q "CentOS Linux 8" ; then
|
||||||
SERVER_OS="CloudLinux"
|
echo -e "\nDetecting Centos 8...\n"
|
||||||
fi
|
|
||||||
;;
|
|
||||||
8|8.*)
|
|
||||||
printf >&2 '\nCentOS 8/CloudLinux 8 support is currently experimental!\n'
|
|
||||||
yum install curl wget -y 1> /dev/null
|
|
||||||
yum update curl wget ca-certificates -y 1> /dev/null
|
|
||||||
SERVER_OS="CentOS8"
|
SERVER_OS="CentOS8"
|
||||||
;;
|
yum install curl wget -y 1> /dev/null
|
||||||
esac
|
yum update curl wget ca-certificates -y 1> /dev/null
|
||||||
|
elif echo $OUTPUT | grep -q "CloudLinux 7" ; then
|
||||||
|
echo "Checking and installing curl and wget"
|
||||||
|
yum install curl wget -y 1> /dev/null
|
||||||
|
yum update curl wget ca-certificates -y 1> /dev/null
|
||||||
|
SERVER_OS="CloudLinux"
|
||||||
|
elif echo $OUTPUT | grep -q "Ubuntu 18.04" ; then
|
||||||
|
apt install -y -qq wget curl
|
||||||
|
SERVER_OS="Ubuntu"
|
||||||
|
elif echo $OUTPUT | grep -q "Ubuntu 20.04" ; then
|
||||||
|
apt install -y -qq wget curl
|
||||||
|
SERVER_OS="Ubuntu"
|
||||||
else
|
else
|
||||||
printf >&2 '\nYour OS -- %s -- is not currently supported!\n' "$PRETTY_NAME"
|
|
||||||
printf >&2 '\nCyberPanel is currently supported on Ubuntu 18.04, CentOS 7 and CloudLinux 7.\n'
|
echo -e "\nUnable to detect your OS...\n"
|
||||||
|
echo -e "\nCyberPanel is supported on Ubuntu 18.04, CentOS 7.x and CloudLinux 7.x...\n"
|
||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
|
|
||||||
rm -f cyberpanel.sh install.tar.gz
|
rm -f cyberpanel.sh
|
||||||
curl --silent -o cyberpanel.sh "https://cyberpanel.sh/?dl&${SERVER_OS}" 2>/dev/null
|
rm -f install.tar.gz
|
||||||
|
curl --silent -o cyberpanel.sh "https://cyberpanel.sh/?dl&$SERVER_OS" 2>/dev/null
|
||||||
chmod +x cyberpanel.sh
|
chmod +x cyberpanel.sh
|
||||||
./cyberpanel.sh "$@"
|
./cyberpanel.sh $@
|
||||||
Reference in New Issue
Block a user