Questions tagged [proxypass]

ProxyPass in Apache, and proxy_pass in nginx, are directives used to specify which backend or remote server should process the request

ProxyPass in , and proxy_pass in , are directives of the default module that are used to specify which or server should process the .


ProxyPass in :

https://httpd.apache.org/docs/current/mod/mod_proxy.html#proxypass


proxy_pass in :

http://nginx.org/r/proxy_pass

http://ngx.su/src/http/modules/ngx_http_proxy_module.c#ngx_http_proxy_pass

565 questions
9
votes
2 answers

Apache ProxyPass ignore static files

Having an issue with Apache front server connecting to a Jetty application server. I thought that ProxyPass ! in a location block was supposed to NOT pass on processing to the application server, but for some reason that is not happening in my case,…
virtualeyes
  • 665
  • 3
  • 10
  • 28
9
votes
1 answer

Apache ProxyPass or ProxyPassMatch to exclude a file from proxying

I have a VirtualHost set to proxy all requests to another server running on port 9000. What I have : ProxyPass / http://localhost:9000/ ProxyPassReverse / http://localhost:9000/ What I've tried : ! ProxyPass /test.html…
Andrei
  • 463
  • 2
  • 5
  • 12
8
votes
1 answer

Nginx proxy_pass root and specific url only

Working on a new version of an existing web app, I need nginx to forward root (/) and multiple specific URI to be forwarded to the v2 infrastructure (with proxy_pass) while not specified URI must be forwarded to v1. location = /specific_uri1 …
cyrilv
  • 305
  • 2
  • 3
  • 11
8
votes
1 answer

ProxyPass a WebSocket connection to a UNIX socket

In Apache 2.4 you can reverse proxy an HTTP connection to a local Unix socket with: [1] ProxyPass unix:/path/to/app.sock|http://example.com/app/name You can reverse proxy a WebSocket connection to a local TCP socket with: [2] ProxyPass…
kay
  • 191
  • 1
  • 8
8
votes
5 answers

How do I smoothly migrate a web server's DNS from one IP address to another?

I currently have a domain name registered for a Linux/Apache server that I am going to replace with another on a new IP address. Migrating the data will be relatively quick and a 5 minute disruption during that process is acceptable. The DNS…
Tom
  • 2,622
  • 1
  • 20
  • 12
8
votes
1 answer

Nginx dynamic proxy_pass doesn't resolve properly

I'm having problems configuring nginx, I've searched the web for solutions and I have some bits and pieces but I'm still not able to come up with proper configuration. I have registered a domain, let's say - www.example.com. I've configured…
Stugal
  • 193
  • 1
  • 1
  • 4
7
votes
2 answers

NGINX Dynamic Port proxy_pass

I need a way to proxy_pass a dynamic port through the location's URL. The proxy has the same IP but the port changes since the servers are created via docker on random port numbers. (Too many for me to add manually) I need a way to proxy_pass these…
Cory Fail
  • 173
  • 1
  • 5
7
votes
2 answers

Redirect traffic based on url to different ip address maintaining port and url information

We have a QA version, a UAT version, and a DEV version of webapp. Users need to access these via http://uat.company.com:41002/webapp, http://qa.company.com:41002/webapp, and http://dev.company.com:41002/webapp. There is also a different webapp on…
Mitch Kent
  • 251
  • 1
  • 2
  • 11
7
votes
4 answers

NGINX proxy_pass with URI modification

I need to pass some requests to proxy (running GlassFish) with removing one section of url. For example: https://xxx.net/jazz/MobileApi?id=2&make_id=4 Should be passed to proxy as: http://X.X.X.X:8080/MobileApi?id=2&make_id=4 I have following…
Andrey
  • 173
  • 1
  • 1
  • 6
7
votes
2 answers

In Apache how to define multiple ProxyPass to different servers with the same context-root?

** updated with workaround at bottom of this answer ** I have a requirement for my webapp to proxy to 2 external reporting servers. So I will have a menu-item for each external reporting server. But the browser-URL has too look like it's my server…
gotjee
  • 89
  • 1
  • 1
  • 5
7
votes
1 answer

Issues with ProxyPass and ProxyPassReverse when proxying to localhost and a different TCP port

I am attempting to use ProxyPass and ProxyPassReverse to proxy requests through Apache to another server instance that is bound to the localhost on a different TCP port that the Vhost exists (VHost is bound to :80, when the target is bound to…
mbrownnyc
  • 1,825
  • 8
  • 30
  • 50
6
votes
1 answer

Nginx variable in proxy pass does not work

Can proxy_pass work with variables? I am trying to make the below configuration work: http { ... map $http_user_agent $myvariable { default 'mobile'; } ... } The location configuration:…
Syed Osama Maruf
  • 103
  • 2
  • 2
  • 9
6
votes
0 answers

nginx proxy_pass one file

I have a single file that I want to appear to host but that I don't. So I write this in my nginx server block: location /d-p27.js { proxy_pass https://data.example.com/p/piwik.js; } After reloading nginx's config, when I test this with curl -I…
jma
  • 415
  • 5
  • 15
6
votes
3 answers

Duplicate max-age header

I'm using Apache 2.4.25 to expose a number of back-end services using proxy pass. Apache also sets the cache control headers based on mime type. The current cache configuration looks like this: ExpiresActive on ExpiresDefault "now" ExpiresByType…
6
votes
1 answer

Apache Remote proxy for a reverse proxy SNI mismatch

Having an issue with our setup of an Apache-2.2 and a reverse proxy which is proxied to via another device. flow is: Apache A -> proxy.abc.net -> Apache B The error we get on Apache B is Hostname proxy.abc.net provided via SNI and hostname…
1
2
3
37 38