B
B
Beshelmek2014-09-28 19:44:03
linux
Beshelmek, 2014-09-28 19:44:03

How to do IP forwarding in Debian?

Good afternoon. It is necessary for me that at request on a certain IP or the domain there was a redirection on another. The scheme is as follows - a Java application launched under Debian 7 sends a request to a PHP file of one domain, and gets to my domain where I am already redirecting using .htaccess. Waiting for an answer.

Answer the question

In order to leave comments, you need to log in

2 answer(s)
A
Alex Chistyakov, 2014-09-28
@alexclear

I usually use nginx to solve such problems, which I advise everyone else.
It looks something like this:

server {
        listen       80;
        server_name  test.ru www.test.ru;

        location  / {
           rewrite ^ http://www.example.com$uri;
        }
}

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question