I'm interested in knowing if I can force a redirect to different ip's for those clients that pass into certain port of my web server. Specifically I'm attempting to get all web(80) traffic to goto server one on domain.com whilst every client connecting on say port 27015, 55565, 21, 22, etc. of same domain routed IP are forwarded to different server on unconnected network. I'm fine with this working vice-verca if I need to, where the apache server running on game boxes forward to website host. Any Ideas?
Well port 21 is supposed to be FTP unsecure. Not sure if you're running that on a "game box." If you're using Apache as the external server and trying to map it to other servers and ports, your best bet is to use apache mod_proxy and mod reverse proxy. Here's a sample config:
Just be sure to uncomment mod_proxy and its reverse from the apache modules section of the config. And change the 127.0.0.1:port to the port and local IP of the "game boxes"
And for the port thing, all of these requests are served on the external IP/port of the apache server. If you are trying to serve non-HTTP requests (a real game server) then you are better off using a NAT or DNS load balancer for this, and the client should connect to the default port. (Example: connecting to a minecraft server at mc.domain.com with no port specified, assumes port 25565. Http traffic assumes port 80, ssl is 443, etc.)