mirror of
https://github.com/stefanpejcic/openpanel
synced 2025-06-26 18:28:26 +00:00
Update INSTALL.sh
This commit is contained in:
parent
2b638ea356
commit
6068bdb401
22
INSTALL.sh
22
INSTALL.sh
@ -705,20 +705,12 @@ setup_firewall_service() {
|
|||||||
|
|
||||||
if [ "$CSF_SETUP" = true ]; then
|
if [ "$CSF_SETUP" = true ]; then
|
||||||
echo "Installing ConfigServer Firewall.."
|
echo "Installing ConfigServer Firewall.."
|
||||||
|
|
||||||
read_email_address() {
|
|
||||||
email=$(grep -E "^e-mail=" /etc/openpanel/openpanel/conf/openpanel.config | cut -d "=" -f2)
|
|
||||||
echo "$email"
|
|
||||||
}
|
|
||||||
|
|
||||||
install_csf() {
|
install_csf() {
|
||||||
debug_log wget https://download.configserver.com/csf.tgz
|
debug_log wget https://download.configserver.com/csf.tgz
|
||||||
debug_log tar -xzf csf.tgz
|
debug_log tar -xzf csf.tgz && rm csf.tgz
|
||||||
rm csf.tgz
|
cd csf && debug_log sh install.sh
|
||||||
cd csf
|
cd .. && rm -rf csf
|
||||||
debug_log sh install.sh
|
|
||||||
cd ..
|
|
||||||
rm -rf csf
|
|
||||||
#perl /usr/local/csf/bin/csftest.pl
|
#perl /usr/local/csf/bin/csftest.pl
|
||||||
echo "Setting CSF auto-login from OpenAdmin interface.."
|
echo "Setting CSF auto-login from OpenAdmin interface.."
|
||||||
if [ "$PACKAGE_MANAGER" == "dnf" ]; then
|
if [ "$PACKAGE_MANAGER" == "dnf" ]; then
|
||||||
@ -797,7 +789,8 @@ setup_firewall_service() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
set_csf_email_address() {
|
set_csf_email_address() {
|
||||||
email_address=$(read_email_address)
|
email_address=$(grep -E "^e-mail=" /etc/openpanel/openpanel/conf/openpanel.config | cut -d "=" -f2)
|
||||||
|
|
||||||
if [[ -n "$email_address" ]]; then
|
if [[ -n "$email_address" ]]; then
|
||||||
sed -i "s/LF_ALERT_TO = \"\"/LF_ALERT_TO = \"$email_address\"/" /etc/csf/csf.conf
|
sed -i "s/LF_ALERT_TO = \"\"/LF_ALERT_TO = \"$email_address\"/" /etc/csf/csf.conf
|
||||||
fi
|
fi
|
||||||
@ -811,7 +804,6 @@ setup_firewall_service() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
read_email_address
|
|
||||||
install_csf
|
install_csf
|
||||||
edit_csf_conf
|
edit_csf_conf
|
||||||
open_out_port_csf
|
open_out_port_csf
|
||||||
@ -1433,8 +1425,8 @@ create_admin_and_show_logins_success_message() {
|
|||||||
opencli admin new "$new_username" "$new_password" > /dev/null 2>&1 &&
|
opencli admin new "$new_username" "$new_password" > /dev/null 2>&1 &&
|
||||||
|
|
||||||
opencli admin
|
opencli admin
|
||||||
echo "Username: $new_username"
|
echo -e "Username: ${GREEN} ${new_username} ${RESET}"
|
||||||
echo "Password: $new_password"
|
echo -e "Password: ${GREEN} ${new_password} ${RESET}"
|
||||||
echo " "
|
echo " "
|
||||||
print_space_and_line
|
print_space_and_line
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user