Use port range

This commit is contained in:
Mo 2022-12-14 19:18:30 +01:00
parent 930ef02c3b
commit 2670572788

View file

@ -29,15 +29,17 @@ firewall-cmd --add-masquerade
set -l minisforum_ip 134.93.77.73
firewall-cmd --add-forward-port=port=80:proto=tcp:toport=8000:toaddr=$minisforum_ip # HTTP
firewall-cmd --add-forward-port=port=443:proto=tcp:toport=4430:toaddr=$minisforum_ip # HTTPS
# HTTP
firewall-cmd --add-forward-port=port=80:proto=tcp:toport=8000:toaddr=$minisforum_ip
# HTTPS
firewall-cmd --add-forward-port=port=443:proto=tcp:toport=4430:toaddr=$minisforum_ip
# TCP
for port in \
# Git SSH
2222 \
# Rustdesk
(seq 21115 21119)
21115-21119
firewall-cmd --add-forward-port=port=$port:proto=tcp:toport=$port:toaddr=$minisforum_ip
end