1,405 questions
0 votes
0 answers
101 views
NGINX auth_request does not work with return 204
I'm trying to create an NGINX endpoint that will validate the session using auth_request directive and return the auth-token in a header without a response body. location /whoami block in config below....
0 votes
0 answers
138 views
How to exclude http requests for static files from nginx rate limiting
I'm using below nginx block. I want to exclude all requests for js and CSS files from nginx rate limiting. With my below nginx directives, rate limiting is excluded to all files apart from /api route. ...
0 votes
0 answers
55 views
Upload Progress Not Working with Nginx and ExpressJS
I have a simple expressjs app set up behind the Nginx server to take requests to upload the files. When uploading files without Nginx server, the upload progress is obtained through XMLHttpRequest ...
0 votes
0 answers
27 views
nginx proxy pass issue
map $arg_internal $redirect { default 0; "true" 1; } server { #Swap the following two lines to get the redirect working again server_name developer-nonprod.com; listen ...
0 votes
0 answers
20 views
nginx route config to support react app and static/marketing html site on one URL
On a VM host which is at https://myhost.com/, I have a docker container running a (react) app which listens on :3000. Separately, I have a static/marketing html page at /var/www/html/index.html. I am ...
0 votes
1 answer
50 views
Defining locations with and without trailing slash in modern nginx
INFO I have below directories structure: . ├── fruits │ └── index.html ├── index.html ├── styles.css and the content of my /etc/nginx/nginx.conf file is: http { include mime.types; server {...
0 votes
0 answers
100 views
Nginx : Invalid condition "yes" in nginx.conf
I have an environment variable set as vod_enable_encryption = yes which I'm attempting to check using an If block in nginx.conf. Nginx isn't able to resolve the condition and throwing the following ...
0 votes
0 answers
25 views
Handle HTTP Response For iframe - 405 on OPTIONS
I'm adding in an iframe onto a page and when it makes a CORS request to another static file on my server, it always responds with a 405 response. I've tried editing my sites-enabled\domain file to ...
0 votes
0 answers
67 views
How do I return a response from the destination server in case of an error in Nginx?
I need to always return in case of errors. 400, 401, 403, 404, 500... my html pages with errors if the response is from the destination server is text/html, otherwise I can return the server's ...
0 votes
0 answers
42 views
Nginx serves files at root (/) but not at subpaths (/admin, /user)
I have set up Nginx on my server to serve static files for a front-end application. The root URL (http://xxx.85.127.14/) correctly serves files, but when I try to access http://xxx.85.127.14/admin I ...
0 votes
2 answers
132 views
Block URLs with query strings in Nginx [closed]
I'm trying to use Nginx Location to block requests similar to this, which are causing load issues with WordPress (and the multilingual WPML plugin): GET /foo/bar/?s=/?s=/?s=/?s=/?s=/?s=/?s=/?s=/?s=/?s=...
-1 votes
1 answer
72 views
Nginx DNS Resolver in docker depend on the conditions of the transformation
I want to understand why this happens. When I use proxy_pass without regular expressions, everything works great, the DNS is resolved, and so on. location /images/ { proxy_pass http://sfs-...
0 votes
0 answers
40 views
Returns 404 for only 1 route via nginx
this is my nginx.conf file, my react app is hosted on nginx and calling api endpoints, my api end points starts something like this https://export. https://report. etc. 9 out of 10 endpoints are ...
0 votes
0 answers
79 views
In Safari, requests without a trailing slash are not redirected to those with a trailing slash
I am serving static content with Nginx, and I have a question about the behavior of requests without a trailing slash. While everything works fine in Chrome, Safari behaves differently. When I access ...
0 votes
0 answers
52 views
Backend fails after adding SSL certificate. Nest/Nginx
My backend is not working after adding the SSL certificate. The backend worked with http before but after adding SSL certificate it stopped working. I thought the problem is with nginx configurations ...