1 Commits

Author SHA1 Message Date
cc2e8fbc4f debug version, do not use 2020-04-26 17:47:52 -04:00

View File

@@ -627,10 +627,10 @@ EOF'
# Update packages and install JRiver Media Center # Update packages and install JRiver Media Center
if [[ -n $_debug ]]; then if [[ -n $_debug ]]; then
_pkg_update && \ _pkg_update && \
_pkg_install "$_mcpkg" _installPackage "$_mcpkg"
else else
_pkg_update > /dev/null 2>&1 && \ _pkg_update > /dev/null 2>&1 && \
_pkg_install "$_mcpkg" > /dev/null 2>&1 _installPackage "$_mcpkg" > /dev/null 2>&1
fi fi
# shellcheck disable=SC2181 # shellcheck disable=SC2181
@@ -940,7 +940,8 @@ EOF"
fi fi
# Open the ports # Open the ports
if [[ "$ID" =~ ^(fedora|centos)$ ]] && [[ -x $(command -v firewall-cmd) ]]; then if [[ "$ID" =~ ^(fedora|centos)$ ]]; then
[[ ! -x $(command -v firewall-cmd) ]] && _installPackage firewalld
if ! _firewall_cmd --get-services | grep -q "$1"; then if ! _firewall_cmd --get-services | grep -q "$1"; then
_firewall_cmd --permanent --new-service="$1" > /dev/null 2>&1 _firewall_cmd --permanent --new-service="$1" > /dev/null 2>&1
_firewall_cmd --permanent --service="$1" --set-description="$1 installed by installJRMC" > /dev/null 2>&1 _firewall_cmd --permanent --service="$1" --set-description="$1 installed by installJRMC" > /dev/null 2>&1
@@ -951,7 +952,8 @@ EOF"
_firewall-cmd --add-service "$1" --permanent > /dev/null 2>&1 _firewall-cmd --add-service "$1" --permanent > /dev/null 2>&1
_firewall_cmd --reload > /dev/null 2>&1 _firewall_cmd --reload > /dev/null 2>&1
fi fi
elif [[ "$ID" =~ ^(ubuntu|debian)$ ]] && [[ -x $(command -v ufw) ]]; then elif [[ "$ID" =~ ^(ubuntu|debian)$ ]]; then
[[ ! -x $(command -v ufw) ]] && _installPackage ufw
if [[ ! -f "/etc/ufw/applications.d/$1.service" ]]; then if [[ ! -f "/etc/ufw/applications.d/$1.service" ]]; then
_bash_cmd "cat <<-EOF > /etc/ufw/applications.d/$1.service _bash_cmd "cat <<-EOF > /etc/ufw/applications.d/$1.service
[$1] [$1]