Questions tagged [nginx]

Nginx ("eNgine x") is a lightweight, high-performance HTTP server, reverse proxy, TCP stream proxy and mail proxy, released under a BSD-like license.

Filter by
Sorted by
Tagged with
0
votes
0answers
11 views

Redirect a subdomain DNS entry to an internal IP via router and server

I'm hoping someone here can help, firstly, apologies, I am not entirely familiar with networking protocols but I'll try explain as best I can. I have Jitsi video conferencing, installed on an internal ...
0
votes
0answers
10 views

Allow only certain hostname in Nginx block

how do you allow only certain hostname in Nginx so that one can only access myhostname.example.net but not example.net?
0
votes
0answers
9 views

Fail2ban regex not matching after site moved behind load balancer

I installed fail2ban with nginx and it's working untill i moved it behind load balancer. Bcoz after moving behind load balancer i found there is 2 IP's showing in Logs.I want that fail2ban detect ...
0
votes
0answers
18 views

I am running Tomcat behind NGINX SSL - Which setting to use?

I am running Tomcat behind NGINX SSL, Can anyone tell me what is the best setting for tomcat server.xml ? Should I add the properties : < secure="true" proxyName=&...
-1
votes
0answers
14 views

Installing PHP extensions for NGINX [closed]

I am attempting to install PHP extensions for PHP 7.2 on Ubuntu 18.04 with NGINX. Is there a simple way to do that?
1
vote
0answers
15 views

different behaviour per filename and backend routing in NGINX

It's few days i'm bouncing my head on this problem but i cannot find a "elegant" solution. I would like to use a NGINX server as streaming origin for some live channel to be distributed ...
0
votes
0answers
19 views

Laravel docker cron nginx 502 bad gateway issue

I am using my laravel app in a docker container. Everything worked fine until I added a cron to the dockerfile. I need to schedule a job so I need a cron. My compose file looks like this version: '3' ...
0
votes
1answer
22 views

I cannot use a variable in `fastcgi_pass` directive

I cannot use a variable for fastcgi_pass directive as below fastcgi_pass $image:9000; I get the following error. 2020/07/07 01:39:08 [error] 27#27: *1 no resolver defined to resolve php, client: 192....
-1
votes
0answers
19 views

Nginx changing configuration and auto generated files

I have VPS running several websites. Now I want to use VARNISH setup. Currently requests are served: Internet ----> nginx (port 80) ----> apache(port 8080) I want to setup Internet ----> ...
0
votes
0answers
13 views

High CPU load on EC2 with Nginx/Celery/Django causes server to fail

I am running a Django web app on an EC2 server using Nginx, and uWSGI. I also have Celery running some background tasks (no CRON jobs, just on occasional user actions). The app is in early closed Beta ...
0
votes
0answers
12 views

NGINX Calculate Buffering Time

I'm working on a PR for New Relic to calculate New Relic queuing time that ignores buffering time. When buffering requests with NGINX with proxy_request_buffering, is it possible to set a header with ...
-1
votes
1answer
60 views

What destination does underline mean?

I am using jwilder/nginx-proxy on a server, reachable on the public internet. But actually the only counting part should be that it is nginx. On a regular basis, I check all the logs of my various ...
0
votes
1answer
29 views

Nginx cache - pass through cache-control: max-age but cache for longer

I have an origin server behind a nginx proxy in a container, with a CDN in front. I want my HTML pages to cache on the CDN for 1 minute, so I set the cache-control: public and cache-control: max-age=...
0
votes
1answer
14 views

Always respond with a specific response for set of IPs

I'm running nginx server and I'm getting tons of bots who request /admin.php files, even though I never even installed PHP in the first place. So I decided that I will, instead of simply blocking ...
0
votes
1answer
21 views

Receive traffic from different sub-domains but send to backend as a single domain

I am having a server with Nginx as server & a rails application in the backend. At present, the rails application can only serve to a single domain at once. I will, however, be creating and ...
0
votes
0answers
25 views

NGINX conf file not loading static files

With the following .conf file, nginx is unable to load static files: my static files and my index.php are located both in /public. Also i'm using symfony 5 and ansible/ansistrano to provision and ...
0
votes
2answers
79 views

How do I use a PEM key that has key and cert in the same file in nginx?

I got a file (and a matching passphrase) from a client that is supposed to replace my letsencrypt setup. It looks like this: [domain.pem] subject=CN=Entrust Root Certification Authority - G2, OU="...
0
votes
0answers
49 views

How properly manage several webapps on one domain nginx

I'm trying to setup several webapps (nextcloud, roundcube) on one domain, let's say example.com, without using cname subdomains. I installed webapps in default location /usr/share/webapps/ and I want ...
0
votes
1answer
69 views

How to Block X forwarded-for IP in nginx

My website is running behind aws Load Balancer. Now if i try to deny any IP to access my website by using "deny 59.92.130.106" under location / nothing happened. That IP still getting 200 ...
0
votes
0answers
30 views

Nginx server configuration hosting an Angular app and proxying requests of the API calls

How one is able to proxy the requests (or the API calls) of an Angular app hosted on Nginx towards backend running on a docker container having another port value (the Angular app is also dokcerized)? ...
0
votes
0answers
19 views

Redirect subdirectory to root

I would like to redirect some subdirectory into the root, i.e., https://example.com/sub/* --[redirect]--> https://example.com/* How can I do that? Thanks!
0
votes
1answer
93 views

nginx, handle 404s in another location with proxy_pass location

I have a basic django application setup under nginx. So far everything runs fine. What I need is a setup so I can handle 404s under /media/ with my proxy_pass application. Currently, it shows a bare ...
0
votes
0answers
16 views

Nginx retry if backend it temporary down

I've got a websocket server running behind a nginx reverse proxy. But when I sometimes need to restart the node.js service and the clients directly get a connect() failed (111: Connection refused) ...
0
votes
1answer
34 views

A generic way to redirect all non-www https traffic to www https in nginx

Is it possible to put a redirect in 1 single server block to redirect any https (port 443) that do not have www to https://www...? I don't want to have to put that redirect in every single server ...
0
votes
0answers
18 views

Why does the Tomcat 7 virtual host become unresponsive (504) when a WebRTC webcam share session is on, with the nginx as reverse proxy

I am using nginx as the reverse proxy (correct me if I am wrong) server that runs the Tomcat 7 Java webapp. The complexity here is that there's two apps nginx is serving off Tomcat. The main one ...
0
votes
2answers
55 views

Turn off access_log for specific path while still allowing fallthrough to PHP

Here's my config: server { root /app/public; charset utf-8; server_tokens off; location / { try_files $uri @app; } location = /php-health { access_log off; ...
1
vote
2answers
246 views

NGINX reverse proxy SSH map issue

We have several virtual (Ubuntu) servers running in our company. Each has its network connection bridged, so it gets its own IP address from the router (DHCP-reserved). We need to run several websites ...
0
votes
2answers
416 views

High memory usage on digital ocean droplet by mysql 8

I have a laravel application which I've installed on a 1GB standard droplet running ubuntu 20.4, nginx, MySQL 8 and php 7.4 The application isn't even live yet and I notice it's already using over 60% ...
0
votes
1answer
14 views

Routing traffic in nginx according to received header

I'm trying to route traffic in my nginx proxy according to a received header. My infrastructure is built in a way that traffic is being sent to the proxy with a header that contains part of the ...
0
votes
1answer
51 views

nginx stream map with wildcard

I am really bad with regex. I am trying to do this in nginx: stream { map $ssl_preread_server_name $name { api.dom1.com dom1_backend; *.dom2.com dom2_backend; } upstream ...
0
votes
0answers
18 views

Is there an alternative for the error_page 497 option from nginx for haproxy?

When using nginx I can just use the 497 error code specific to nginx 497 HTTP Request Sent to HTTPS Port and redirect to https with this rule: error_page 497 https://$host:$server_port$request_uri; ...
0
votes
1answer
20 views

Nginx location matches the both subdomain and domain

I'm going to serve a webapp only on my subdomain admininstration.example.com but it is accessible from example.com too. This is my nginx config: http { server { server_name = _; listen 80 ...
0
votes
0answers
22 views

How to set Firewalld rules on first time and don't harm your self?

I'm running the server on CentOS and Nginx (nodejs application). I am experiencing too many connections to my mysql database and website goes down. My iotop log shows me that mysqld is taking to much ...
0
votes
0answers
34 views

curl: (60) Peer's Certificate issuer is not recognized

I have the following error when I try to curl a server : curl -u User:Pass 'https://mydomain/remote.php/dav/files/User/Folder' -X PROPFIND --data '<?xml version="1.0" encoding="UTF-8&...
0
votes
1answer
74 views

converting nginx from http to https

i am hosting a website on aws lighsail server. it is single server and i am running 4 docker container on it. 1-nginx , 2-node js, 3- spring bot, 4 - mysql. As for now my website is loading great with ...
1
vote
0answers
55 views

Avoid dnf update modification of /etc/php-fpm.d/www.conf

Yesterday I ran dnf update, which updated various php packages. I discovered some values that I had customized in /etc/php-fpm.d/www.conf were reset after the update. Specifically, I had these 3 ...
0
votes
0answers
99 views

My site's load times have become extremely slow or fails to load at all (Cloudflare 522 error), but minimal server load (Nginx + Apache + Wordpress)

I run multiple websites being served on a stand alone Ubuntu machine, all of them use same nginx + apache setup. However one of these sites has begun to act very strangely today. It's the only site on ...
0
votes
0answers
12 views

Nginx 502 bad gateway on reverse proxy on post method after distro debian update [duplicate]

After distro update to debian 9 my nginx reverse proxy stop working on all apps mostly dotnet one. It shows 502 bad gateway when app is trying to send post request Do you got any clue how to resolve ...
0
votes
0answers
47 views

nginx letsencrypt wildcard with ovh dns SSL_ERROR_BAD_CERT_DOMAIN

I have a problem with wildcard certificates for a subdomain. I wish to have one certificate for the domain example.com and the same cert for the same level of subdomains *.example.com. The problem is ...
0
votes
0answers
39 views

nginx connect() failed (111: Connection refused) while connecting to upstream [Mastodon]

I am setting up a Mastodon server on Docker on Ubuntu. The server is up and running but when I try to access the site from a browser I get the error 502 Bad Gateway. I have checked that ufw is ...
0
votes
0answers
17 views

Nginx load balancer throws 502 error on proxy passing SSL traffic

I have two debian 10 servers configured as follows. 10.0.0.3 is loadbalancer based on nginx and port forwarded (80, 443). 10.0.0.2 is one of the servers behind proxy which I want to proxy traffic in. ...
0
votes
1answer
105 views

Can't access Nginx webserver after configuring SSL (Certbot, LetsEncrypt)

I'm brand new to AWS and web servers, using nginx for this project & MERN stack for the code. Anyways I got my website up and running using this tutorial, and used this tutorial (uses letsencrypt ...
0
votes
0answers
22 views

Kibana+nginx reverse_proxy issue

Greetings! I had to face issue with NginX reverse_proxy and Kibana. If I make Kibana index - nothing shows until I clear browser cache or visit page from Private Tab in browser. Here is my server.conf ...
0
votes
0answers
36 views

NGINX serving by IP only, not by server name [closed]

A Raspbery Pi running (arm-)Arch sits behind my router NAT. The RasPi has a static IP 192.168.1.6 and an nginx serving on port 8093. (The nginx is listening on port 80 for another webpage.) The ...
0
votes
1answer
44 views

Possible to reverse proxy WP multisite to a separate server with NGINX?

Recently migrated a multisite network, only to discover some of the sites are using a theme that's incompatible with the server's PHP version. While I work on a longterm fix, what I'd like to is use ...
0
votes
2answers
61 views

How rewrite (most) subdomains in nginx to a virtual path for an API/proxy

I have a tenant setup where a unknown number of companies could create accounts, of the kind company.app.com. The backend server them as : 5000/company/...., so how do a rewrite (not a redirect!) in ...
1
vote
0answers
28 views

Nginx secure link with rewrite

I want to make a secure URL with Nginx secure-link model and rewrite. So the secured link be like: http://example.com/media/ZYSwFWTSM8DHh8CNupbbzw/1593525536/videos/tmp/793.mp4 And the Rewrite convert ...
0
votes
0answers
22 views

Elastic Beanstalk Puma NGINX - Ruby on Rails Load Issues

I have an Elastic Beanstalk instance running Ruby on Rails using Puma with Ruby 2.6 running on 64bit Amazon Linux/2.11.7, the instance is scaled to a c5.2xlarge and a database of db.m5.large. The ...
1
vote
0answers
31 views

Nginx with only TLS1.3 cipher suites

I am trying to configure Nginx to use only TLS1.3 with 2 ciphers: TLS-AES-256-GCM-SHA384:TLS-AES-128-GCM-SHA256. So, I tried this configuration: ssl_protocols TLSv1.3; ssl_ciphers TLS-AES-256-GCM-...
0
votes
1answer
28 views

NGINX Dynamic Proxy Location with ID in the URL

I have this kind of URL in my web app - /sample/company/123/invoices/download/123 location /sample/company/ { root /myapp/public; include fastcgi_params; fastcgi_param SCRIPT_FILENAME $...

1
2 3 4 5
286