A
A
Alexey Vladimirovich2015-05-12 21:26:38
PHP
Alexey Vladimirovich, 2015-05-12 21:26:38

How to organize a Node.JS server for a ready-made nginx site in PHP?

The task is the following, there is a site in php, it works in conjunction with Apache and nginx.
I want to connect a node to the site, for some processes.
The problem is that the node connects to the domain on a specific port, for example 8082.
Thus, I need to connect to the site through example.ru:8082, I want it to be simple by example.ru I
broke my head, googled, I can’t find a solution.
If it finds - it was not possible to put

Answer the question

In order to leave comments, you need to log in

1 answer(s)
U
un1t, 2015-05-12
@Genocide

In nginx write proxy_pass for the desired location

server {
    location /foo/ {
        proxy_pass http://example.ru:8082;
    }

}

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question