Questions tagged as ['reverse-proxy']

A reverse proxy is a type of proxy server that fetches resources from a specific defined set of servers for a client. It is used in cases when there is an advantage to not exposing the web server with the content directly whether it be for security reasons or because of a lack of available public IP addresses.
Score: 1
proxy_cache_bypass keeps serving old cached response if URL changes to non-cacheable
md flag

Under normal circumstances, when using proxy_cache_bypass nginx will fetch a fresh copy from upstream, and overwrite the cached response with the new one.

But if the URL changes from a cacheable to a non-cacheable response (for example to a 4xx response with Cache-Control: no-cache), then using proxy_cache_bypass will indeed serve a fresh copy from upstream, but it will leave the old copy in the c ...

Score: 0
ChrKoenig avatar
Reverse proxy and domain forwarding
cl flag

I'm trying to set up a VPS with a single IP address to run my static homepage and some additional services such as NextCloud. I already have a domain that points to the VPS's IP address. Reading through a number of tutorials on self-hosting, a common solution for this type of scenario is to set up a reverse proxy that forwards to different subdomains, e.g. nextcloud.mydomain.com. However, here's my ques ...

Score: 0
Nginx keeps trying to serve a file?
cn flag

This is my nginx.conf

events {
}
http {
    server {
        listen 80;

        rewrite_log on;

        if ($http_x_forwarded_proto = "http") {
            return 302 https://$host$request_uri;
        }

        location /.health {
            return 200 'OK';
        }

        location /.status {
            stub_status;
            server_tokens on;
        }

        location ~ ^\/([^.][^\/] ...
Score: 0
tab269 avatar
Proxy Redirect on NGINX not working as expected
cn flag

I set up nginx as a reverse proxy for two proxied servers. Each of them (proxy and proxied servers) is running as a container in a docker environment. Proxied server appalpha is simply an nginx:alpine serving a static webpage (just for demo and testing purposes). All works fine here because things are simple. The other proxied server's image is kanboard/kanboard. When I try to access this service through ...

Score: 2
Get Wordpress+Apache to work behind nginx reverse-proxy
mp flag

I'm trying to setup the following:

  • docker container with nginx on localhost as a reverse-proxy for Wordpress, listening on localhost:80. It is also used as a reverse-proxy for other microservices.
  • docker-compose container(s) with Wordpress+Apache, listening on localhost:4261. The docker-compose.yaml was taken from the official example. The 'ports' directive was changed from "8000:80" --> "4261:80".
Score: 0
Leopoldo Vasquez avatar
nginx reverse proxy doesn't work with POST request returning 404 error
vn flag

nginx reverse proxy doesn't work with POST request returning 404 error

the rule is

location /mio-bff {
    rewrite ^/mio-bff(.*)$ $1/ break;
    proxy_pass http://mio-bff.cl-milugar:80;
    proxy_redirect off;
}

and when try the URL with a POST request

https://milocation/mio-bff/pingfed/token

the response is 404:

{
    "code": "ResourceNotFound",
    "message": "/pingfed/token/ does not exist"
}
 ...
Score: 0
DUO Labs avatar
TLS certificate for SNIproxy, or a reverse proxy with virtual host with a TLS certificate
ro flag

I currently use SNIProxy (it's the simplest I've seen so far to set up virtual hosts). However, I can only set SSL certificates separately per virtual host with each service's configuration (each one is on a separate port), which can quickly become a problem, and not for the server as a whole, so I only need a certificate for the reverse proxy. So, is there a way to do it? Alternatively, is there a reve ...

Score: 0
Leopoldo Vasquez avatar
nginx rewrite rules: Rewrite https://Frontend/backend/Api/SelectAllBranch/ to https://Backend/Api/SelectAllBranch/ or .../SelectAllBranch
vn flag

I'm using this configuration to nginx proxy reverso

 location /backend {
      rewrite ^/backend(.*)$ $1/ break;
      proxy_pass http://credentials-web-bff.cl-milugar:5000;
      proxy_redirect off;
    }

and i don't have problem when Url like https://frontend/backend/mysite , but when the Url finish in "/" this rule didn't work.

can you guys help me ?

Score: 0
JWo avatar
Nginx: reverse proxy Influxdb can't find static files
cn flag
JWo

I have a setup where I have multiple service running with docker compose and one Nginx (nginx:1.19-alpine), which acts as a reverse proxy for all services and serves some static files.

One service is an Influxdb container (influxdb:2.1.0-alpine) which provides a UI for webbrowsers.
I want to reverse proxy to this container, but I get problems with the static files of this container.

This would be my rule  ...

Score: 0
Akshay B avatar
How to set maintenance page when using apache2.4 as reverse proxy
cn flag

We are using ProxyPass and ProxyPassReverse to redirect traffic to our application. how can I setup a maintenance page when we are performing deployments.

Thanks

Score: 1
nginx local reverse proxy with firewalld
sa flag

I am running a service on a docker container. The service is exposed on a given port (eg. 12345).

On top of it I added a nginx reverse proxy to get extra functionality like HTTPS and HTTP/2.

nginx configuration is the following:

worker_processes auto;

http {
    sendfile        on;

    gzip  on;

    server {
        listen 443 ssl http2;
        listen [::]:443 ssl ipv6only=on http2;
        
         ...
Score: 0
On a Debian 10 instance running multiple Docker containers to serve a web application, reverse proxy a URL path to another port
lr flag

This might be an easy one for experienced folks out there but I am stuck.

On a debian 10 machine, I got several containers running to serve a web application ✔

I also have a mailhog server to provide fake SMTP service. https://github.com/mailhog/MailHog/ Testing from the debian 10 machine with curl, mailhog is serving on 127.0.0.1:8025/mailhog/ as configured ✔

Outside my control and for securi ...

Score: 1
Apache ProxyPass to Shared Ip Address for Domain
pl flag

I have a case where I need to proxy pass a domain (domain1.com) to a different domain (domain2.com) hosted on a shared ip address (192.168.168.168), but domain2.com DNS is pointed other than the shared ip address, so domain2.com cannot be used as the proxy pass, only the shared ip address.

Since the shared ip address has multiple hostnames, is there a domain or hostname configuration option that  ...

Score: 0
Nginx config on reverse proxy for custom headers from backend to client
us flag

Nginx (19.x) is used as reverse proxy for nodejs backend server (ubuntu). Here is the nginx conf file for reverse proxy:

server {
  listen 80;

  location /api {
    proxy_pass http://127.0.0.1:5000;  //proxy pass for nodejs backend server. Will it pass value of non-empty custom headers as well?? 
  }
}

Both the client and backend server may set custom header for request and response. My understand ...

Score: 0
ehammer avatar
NGINX reverse proxy "if not" statements syntax?
us flag

I have an nginx reverse proxy that I want to basically redirect any url request that isn't my specific top level domain to 404.

So far I think I want something like this at the bottom of my /etc/nginx/sites-enabled/site.conf:

server {
        listen 80;
        if ($host != *domain.com) {
                return 404 http://$host$request_uri;
        }
}

but I don't know the exact syntax here. I already ...

Score: 1
cjones avatar
ProxyPass and ProxyPassReverse causing 500 error on server
in flag

We have the following:

  • WordPress static website at https://www.domain1.com.
  • React/Django Web application at https://www.domain2.com with three main URIs:
    • /
    • /admin
    • /api

We would like them to appear like they are the same domain at https://www.domain1.com. I was told this could be done by setting up a Reverse Proxy on the Apache web server that is at https://www.domain1.com. Due to this we'd ha ...

Score: 0
louis habert avatar
Nginx/proxy not working properly
de flag

I recently uninstalled apache2 for Nginx I'm trying to listen on 88, 808 and 888 for my sites and redirect different subdomains for each (and another domain to another server). the problem is that Nginx is giving bad gateway for all proxied requests and timeout for the direct ip access.

proxy conf : --> otherdomain.fr = eror 502 bad gateway

# HTTP
server {
    # Listen on ipv4
    listen 80;
    #lis ...
Score: 1
Asmodean avatar
Firewall to use when server has docker app hosted?
us flag

I use ubuntu 20.04 with portainer and nginxproxymanager to host my apps. Some are still being hosted bare metal but I am planning to transfer all to docker soon enough.

But the problem is ufw, which I have been using does not integrate with docker apps. The set up is:

portainer - docker compose/stacks - nginxproxymanager - Gateway IP with its web UI port - subdomain name and ssl.

  1. once ufw is up,  ...
Score: 0
Matthew Ewan-Laws avatar
Docker-compose 502 Error after adding Wiki.js
ng flag

I am having difficulty getting Wiki.js hosted on my server.

My current setup is using Docker Compose utilising a reverse proxy with the eventual aim to host some services for personal use. I have successfully managed to host Portainer (using a guide). And I can host Wiki.js in its own docker container (via Docker Compose), but adding the service together is failing with a 502 error. Portainer is stil ...

Score: 0
configure nginx to use a proxy when connecting to upstream
fr flag

it's very hard to find something on google - you get too many results from nginx and proxy alone.

so we have a nginx-docker-container which delivers some static files and should talk to a backend-server on specific locations. we gave http_proxy and https_proxy per docker-compose into the environment of the container

trying the connection with curl results in success - its because of the http_proxy/h ...

Score: 2
st00nks avatar
Docker: Isolate compose stacks on network level, while allowing a single service to be reverse proxied by Traefik
de flag

I'm trying to secure containers on my homelab.

The main goal is:

  • isolating nginxA and nginxB, so they are not able to talk to each other via 172.17.0.1 (eg. preventing nginxA from reaching nginxB via 172.17.0.1:5001)
  • isolating nginxA and nginxB from localhost, making them exclusively accessible via traefik
  • Allowing nginxA to talk to nginxA_DB, which are in the same stack, but without allowing other cont ...
Score: 0
Vadzim avatar
Connect to postgres database behind nginx reverse-proxy using docker containers
de flag

I have set up a postgres database container and can connect and query it directly using its published port 5434.

The goal is to deploy the test database later and access it via nginx reverse proxy. I don't know what is the best way to connect to a deployed test database. Please advise.

I have tried to connect to a postgres database via nginx reverse proxy using local containers.

Using command:

psql -h lo ...
Score: 1
x43 avatar
Apache2 websocket proxy fails
us flag
x43

I'm trying to proxy websockets through Apache 2.4. I found an online demo, and this is my config based off of it. I'm running an app that uses websockets on port 8089 and am using apache to proxy the site and the app.

<VirtualHost *:80>
        ServerAdmin webmaster@localhost
        ServerAlias mysitehere

        RewriteEngine on
        RewriteCond %{HTTP:Upgrade} websocket [NC]
        Re ...
Score: 1
aldegalan avatar
Grafana does not send notifications through reverse proxy
in flag

I am using Grafana on a server that does not have Internet, I need to send Telegram notifications, for that I am using Nginx server in another machine.

Server A:

  • Grafana installed / Running on port 3000.
  • Grafana url: www.example.grafana.com
  • IP of the server (example): 10.16.216.122
  • It uses this webhook to send telegram messages: api.telegram.org
  • I also configured /etc/hosts to send that notifications to ...
Score: 0
Dnd avatar
Squid: Connection reset by peer (TLS code: SQUID_ERR_SSL_HANDSHAKE)
sn flag
Dnd
Failed to establish a secure connection to *ip-address*

The system returned:

(104) Connection reset by peer (TLS code: SQUID_ERR_SSL_HANDSHAKE)

Handshake with SSL server failed: [No Error]

This proxy and the remote host failed to negotiate a mutually acceptable security settings for handling your request. It is possible that the remote host does not support secure connections, or the proxy is no ...

Score: 2
nulldevops avatar
Nginx Docker Container stops working irregularly
cn flag

The server:

I use Nginx as a ingress-proxy for my server. Nginx runs within a Docker container.

docker-compose.yml:

 nginx_ingress:
    image: nginx:latest
    ports:
      - "80:80"
      - "443:443"
    networks:
      front-tier: {}
      back-tier:
        ipv4_address: 172.28.1.1
    restart: always
    volumes:
      - /var/lib/my-server/config/nginx_ingress:/etc/nginx/conf.d
      - /var/li ...
Score: 0
HAProxy - Cannot chroot /var/lib/haproxy
in flag

I am trying to run haproxy in docker by following this article from the haproxy blog. https://www.haproxy.com/blog/haproxy-on-docker-swarm-load-balancing-and-dns-service-discovery/ I am getting the following error Cannot chroot /var/lib/haproxy

hap_haproxy.3.j24pbth7qsup@prox1    | [NOTICE]   (1) : New worker #1 (9) forked
hap_haproxy.3.j24pbth7qsup@prox1    | [NOTICE]   (9) : haproxy version is 2.4.7-b5 ...
Score: 0
Using NGINX to Access Synology services without port numbers?
it flag

First, I apologize if this isn't the right forum as this is somewhat of a networking question.

To give a brief explanation of what I want to achieve is basically have the services or apps provided by Synology be accessible via a simple URL without port numbers. I have a dedicated IP address, so I don't have to worry about setting up DDNS.

I thought all I would need to do is setup a very small NGINX s ...

Score: 0
CORS and Nginx in front of apache reverse proxy/proxy pass not working to access API server
id flag

I'm trying to set up a reverse proxy to my api server but getting a 404 error page.

Context: Whilst setting up a react.js application and trying to find a solution to the CORS problem, I've decided to use reverse proxy (proxy pass) with nginx to invoke the api server internally and trick the browser to think the api is on the same domain.

This is my intended setup:

https://example.com points to the websit ...

Score: 0
Allow access to webserver located in a LAN from remote server hosted at GoDaddy
th flag

I want to allow people to access a webserver located on acomputer in my LAN buy my ISP does not allow me to open any ports. I have a website hosted on a shared hosting that allows ssh access. Is there a way to tunnel via SSH and allow people to get into my LAN webserver from the shared hosting site? Both are ubuntu servers.