NGINX Proxy pass replace PNG file
Jason Prouty
jprouty at jcius.com
Thu Jun 23 17:01:35 UTC 2022
Is it possible to replace an PNG file with a local image
I want to reverse proxy to site and then change the image returned
I have tried the sub_filter setting but nothing changes.
server {
server_name test1.example1.com;
location /{
proxy_ssl_server_name on;
proxy_pass https://test1.example2.com;
sub_filter '<img src="https://test1.example2.com/assets/images/image1.png' '<img src="https://test1.example1.com/image1.png';
sub_filter_once on;
}
I just want to replace the image of the proxied https://test1.example2.com;<https://esim.jcius.com/assets/images/powered-by-dark.png>
https://test1.example2.com/assets/images/image1.png
with
a new image hosted locally on my nginx
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.nginx.org/pipermail/nginx/attachments/20220623/b888fe73/attachment.htm>
More information about the nginx
mailing list