Welcome! Log In Create A New Profile

Advanced

Re: Using the mirror module

August 09, 2018 07:04PM
Hi Francis--

We got this working to wrap up the day. My ignorance of nginx meant that I was interpreting the example literally--I viewed the "/mirror" as the name for the internal route, but that actually becomes part of the URL the mirror location proxy forwards to.

http {
server {
listen 3333;
server_name localhost;

location / {
mirror /;
resolver 8.8.8.8; # I shouldn't need this, will test tomorrow
proxy_pass http://1.2.3.4:3001;
}

location = / {
internal;
resolver 8.8.8.8;
set $upstream_endpoint http://1.2.3.4:3002;
proxy_pass $upstream_endpoint$request_uri;
}
}
}

That works like a champ. Initially I was trying to use localhost as the proxy_pass destination, and had turned on port forwarding at my router, but for whatever reason that was having troubles.

Many thanks in any case!

Jeff
Subject Author Posted

Using the mirror module

Kenny Meyer March 13, 2018 04:40PM

Re: Using the mirror module

Roman Arutyunyan March 13, 2018 05:36PM

Re: Using the mirror module

Kenny Meyer March 13, 2018 06:06PM

Re: Using the mirror module

pbooth March 13, 2018 06:32PM

Re: Using the mirror module

Roman Arutyunyan March 13, 2018 06:38PM

Re: Using the mirror module

Kenny Meyer March 14, 2018 07:58AM

Re: Using the mirror module

Roman Arutyunyan March 14, 2018 08:34AM

Re: Using the mirror module

pbooth March 14, 2018 08:32AM

Re: Using the mirror module

jlangr August 09, 2018 03:14PM

Re: Using the mirror module

jlangr August 09, 2018 05:08PM

Re: Using the mirror module

Francis Daly August 09, 2018 06:30PM

Re: Using the mirror module

jlangr August 09, 2018 07:04PM

Re: Using the mirror module

jlangr August 09, 2018 07:05PM

Re: Using the mirror module

Francis Daly August 14, 2018 03:46AM

Re: Using the mirror module

jlangr August 14, 2018 10:02AM



Sorry, only registered users may post in this forum.

Click here to login

Online Users

Guests: 141
Record Number of Users: 8 on April 13, 2023
Record Number of Guests: 421 on December 02, 2018
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready