Forward udp for minecraft query protocol

master
Robert Gerus 2014-08-30 11:44:50 +02:00
parent 614f4e4433
commit 888c2f3090
1 changed files with 5 additions and 0 deletions

View File

@ -1,8 +1,13 @@
#!/bin/bash
rules() {
iptables --table nat $append PREROUTING -p tcp --dport 2220 -j DNAT --to-destination 10.24.20.20:22
# minecraft
iptables --table nat $flag PREROUTING -p tcp --dport 25566 -j DNAT --to-destination 10.24.20.100:25566
iptables --table nat $flag PREROUTING -p tcp --dport 25567 -j DNAT --to-destination 10.24.20.100:25567
# minecraft queries
iptables --table nat $flag PREROUTING -p udp --dport 25566 -j DNAT --to-destination 10.24.20.100:25566
iptables --table nat $flag PREROUTING -p udp --dport 25567 -j DNAT --to-destination 10.24.20.100:25567
# amanojaku ssh
iptables --table nat $flag PREROUTING -p tcp --dport 10022 -j DNAT --to-destination 10.24.20.100:22
iptables --table nat $flag PREROUTING -p tcp --dport 51413 -j DNAT --to-destination 10.24.20.100:51413
}