Apache reverse proxy

classic Classic list List threaded Threaded
7 messages Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Apache reverse proxy

Stefan Pernar
Hi everyone,

I am running a node.js app on port 3000 and am serving PHP on port 3001. Now I am trying to use Apache reverse proxy with the following .conf but it just does not work. What am I doing wrong?

<Directory "/Users/vrv/Sites/">
Options Indexes MultiViews
Require all granted
</Directory>

LoadModule proxy_module libexec/apache2/mod_proxy.so
LoadModule proxy_http_module libexec/apache2/mod_proxy_http.so

<Location "/blog/">
  ProxyPass "http://127.0.0.1:3001/"
  ProxyPassReverse "http://127.0.0.1:3001/"
</Location>

<Location "/dapp/">
  ProxyPass "http://127.0.0.1:3000/"
  ProxyPassReverse "http://127.0.0.0:3000/"
</Location>

--
Would you like to send me an encrypted message? I recommend GnuPG - you can find my public key here.
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Apache reverse proxy

Rainer Canavan
> [...] What am I doing wrong?

[...]
> <Location "/dapp/">
>   ProxyPass "http://127.0.0.1:3000/"
>   ProxyPassReverse "http://127.0.0.0:3000/"
                                    ^
That should be a 127.0.0.1.


rainer
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Apache reverse proxy

Stefan Pernar
Good catch - unfortunately it is still not working...

On Fri, Jul 21, 2017 at 6:23 PM, Rainer Canavan <[hidden email]> wrote:
> [...] What am I doing wrong?

[...]
> <Location "/dapp/">
>   ProxyPass "http://127.0.0.1:3000/"
>   ProxyPassReverse "http://127.0.0.0:3000/"
                                    ^
That should be a 127.0.0.1.


rainer



--
Would you like to send me an encrypted message? I recommend GnuPG - you can find my public key here.
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Apache reverse proxy

Yann Ylavic
On Fri, Jul 21, 2017 at 6:26 PM, Stefan Pernar <[hidden email]> wrote:
> Good catch - unfortunately it is still not working...

Please define not working...

Regards,
Yann.
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Apache reverse proxy

Stefan Pernar
Thanks everyone. Got it done with nodejs, express and http-proxy.
Cheers

On 21 Jul 2017 6:41 PM, "Yann Ylavic" <[hidden email]> wrote:
On Fri, Jul 21, 2017 at 6:26 PM, Stefan Pernar <[hidden email]> wrote:
> Good catch - unfortunately it is still not working...

Please define not working...

Regards,
Yann.
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Apache reverse proxy

Helmut K. C. Tessarek
On 2017-07-21 15:28, Stefan Pernar wrote:
> Thanks everyone. Got it done with nodejs, express and http-proxy.

You know, it is utterly useless to say you have fixed it without telling
people how you did it.

--
regards Helmut K. C. Tessarek              KeyID 0xF7832007C11F128D
Key fingerprint = 28A3 1666 4FE8 D72C CFD5 8B23 F783 2007 C11F 128D

/*
   Thou shalt not follow the NULL pointer for chaos and madness
   await thee at its end.
*/
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Apache reverse proxy

Stefan Pernar
This worked for me: https://codeforgeek.com/2015/12/reverse-proxy-using-expressjs/

On 21 Jul 2017 9:32 PM, "Helmut K. C. Tessarek" <[hidden email]> wrote:
On 2017-07-21 15:28, Stefan Pernar wrote:
> Thanks everyone. Got it done with nodejs, express and http-proxy.

You know, it is utterly useless to say you have fixed it without telling
people how you did it.

--
regards Helmut K. C. Tessarek              KeyID 0xF7832007C11F128D
Key fingerprint = 28A3 1666 4FE8 D72C CFD5 8B23 F783 2007 C11F 128D

/*
   Thou shalt not follow the NULL pointer for chaos and madness
   await thee at its end.
*/

Loading...