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

learn more… | top users | synonyms

1
vote
0answers
39 views

Nginx performance when running multiple instances on the same machine

I'm trying to understand the performance impact of having multiple nginx instances (masters) running on the same machine, rather than having them all load into a single instance using different server ...
0
votes
0answers
54 views

Nginx throws a 404 error when trying to access a CodeIgniter (PHP) controller

I'm trying to use CodeIgniter with Nginx. I'm on development so I'm running on localhost. This is my /etc/nginx/sites-avaiable/default file: # You may add here your # server { # ... # } # ...
0
votes
2answers
43 views

connecting domain name to nginx server

I'm having a lot of problems to connect a domain name with an nginx server. over /etc/nginx/sites-available/ I have a file called rsmweb: server { # this is only 1 of the many configs I've ...
0
votes
0answers
24 views

Dockerized nginx / php-fpm with custom ports: 500 error

I'm using an Nginx / php-fpm web app with custom ports in a Docker container (with the intention of running multiple containers with the same set-up, that I can access them using different port ...
1
vote
2answers
43 views

Modify HTML pages returned by nginx reverse proxy

I have a reverse proxy setup for access to a third party application located inside a intranet from the internet. Let's say this application is on the URL: https://internalserver:8080/ (reachable ...
0
votes
2answers
55 views

Nginx: redirect default website http to https

I have a website, that could have unknown amount of CNAME DNS records linked to it. What I need is to have ANY http requests to be redirected to https. We will be using a default certificate. No ...
1
vote
1answer
38 views

Nginx config - forbidden files and page not rendering properly [closed]

I've set up a (previously working with apache) magento site on a nginx set up. Now the page doesn't load properly and the skin directory is generating errors. From within the browser you can see this ...
0
votes
0answers
15 views

How can multiple users share their (uwsgi) sockets with nginx, but not with each other?

On a shared domain, currently, each linux user sets up his website through his www-data-writable directory + uwsgi socket - one nginx instance serves them all. However, I do not like the idea of one ...
0
votes
0answers
35 views

NGINX Dynamic hostname internal proxy

I have been working with nginx for a while now, however I cannot find how to do the task below, I have this record, pointing to my nginx server. x.x.x.x.cloud.example.co.nz -> My Public IP (NGINX ...
0
votes
1answer
69 views

Why I cannot connect to my website in HTTP using curl?

I have a web site @ www.eshipp.com, all the domain is secured by SSL so any HTTP traffic is redirected by NGINX to HTTPS equivalent URL. However it seems that some users are not redirected and then ...
0
votes
1answer
22 views

How can I deploy a 503 maintenance page when upgrading a Digital Ocean droplet?

Usually when I perform maintenance that requires briefly taking my site down, I put up a 503 page using something similar to How can I make Nginx return HTTP 503 when my proxied app server is down?. ...
0
votes
0answers
14 views

Nginx Rewrite Rule Query String redirect

I want when someone requests this url http://domain.com/5.ts?u=admin:p=123 to go to /file.php?id=5&username=admin&p=123 I did that rewrite ^/(.*)\.ts\?u=(.*)\:p=(.*)$ ...
0
votes
0answers
22 views

nginx reverse proxy only changes first request

I am running docker with an Owncloud Container which listens on an internal network. Now I would like to use nginx as a reverse proxy to access my owncloud instance from outside. So I installed nginx ...
0
votes
0answers
30 views

NGINX rewrite IP.Board URLs for Xenforo

I am having a hell of a time getting rewrites working under NGINX to rewrite old URL's to point at a new file. XenForo's forums offer up this config: location /ipb/ { if ($uri ~* ...
0
votes
2answers
52 views

Nginx throws 502 intermittently on every page when using fastcgi_finish_request()

I recently inherited administration over 2 Nginx boxes in AWS and am very unfamiliar with how PHP-FPM works (and doens't work). I recently integrated Keen.IO for backend user logging, using: ...
0
votes
1answer
33 views

pacemaker failover nginx only once

I setup a cluster with two nodes with pacemaker 1.1.10 on CentOS 7. Then I downloaded a resource agent for nginx from github I tested my setup like this: Node 1 is started with the nginx and vip, ...
0
votes
0answers
22 views

RTMP request parameters for stream settings

I'm using nginx-rtmp module for streaming ip-camera, it works fine untill camera address is hardcoded. But when i trying to send address in RTMP PLAY request things goes messy. Example of request: ...
1
vote
0answers
42 views

Getting 404 on Nginx configuration for SSL on subfolder only

I need to keep the root of a domain strictly running non SSL but allow a subfolder to use SSL. The current configuration I took from ...
0
votes
0answers
21 views

Different location for each language

Our server is set up like this: /var /www /website /language1 /public /language2 /public /language3 ...
0
votes
1answer
36 views

How can i configure reverse-proxy server using nginx on centos 7?

I'm trying to construct reverse proxy server using nginx on centos 7. I installed nginx and also nodejs for local web server. I would like to redirect requests on nginx to local nodejs server ...
-2
votes
0answers
49 views

True Apache MultiViews on nginx [closed]

I've seen this asked before but is never correctly answered. I am looking for a true MultiViews alternative for nginx. Here is an example of things MultiViews does that I need: /test -> /test.php ...
0
votes
1answer
20 views

How to configure nginx to force download on a query param

So that /media/file.jpg opens in browser and /media/file.jpg?dl=1 forces browser to download. Here's my current config, that doesn't work: location /media/ { autoindex off; root ...
0
votes
2answers
64 views

NGINX - Failing to restart

After installing an SSL through Laravel Forge, my site does not load at all. When trying to restart NGINX, it fails. If I run sudo nginx -t, I get the following: nginx: the configuration file ...
0
votes
0answers
26 views

Yii2 subfolder configuration in Nginx

I would like to create configuration for such serverside folder structure: So I would like to have main site available at site.com/ and separate site available at site.com/subdirectory. I'm using ...
0
votes
1answer
67 views

Nginx Magento config not working, 404 on installation

This is my stack: Nginx 1.7, MariaDB 10, PHP 5.6 (FPM) and CentOS 7. I have used Centminmod for the installation of the above mentioned software. I created a vhost for the magento installation. ...
-1
votes
1answer
41 views

Nginx load balancer returns bad gateway error

I have three servers; two web servers running nginx and a load balancer also running nginx. I can ping/telnet/curl between the load balancer and web servers but when I try to go to the load balancer ...
0
votes
1answer
47 views

Change Nginx redirection rules based on content-type of request

I'm having a reverse-proxied Nginx server. I just wanted to know if it is possible to redirect the request in Nginx based on the content-type of the request? Right now, I'm checking the URL for a ...
0
votes
1answer
48 views

Why does my server running nginx/php-fpm keep losing session capability without generating any errors?

I am managing a server that has a couple dozen websites on it and they have all been working fine until last week when it was noticed that one site had seemingly lost the ability to maintain session ...
1
vote
1answer
37 views

Remove query strings only on requests requiring PHP (ignoring static files and certain urls)

One of my sites keeps getting spammed with fake URL requests containing query strings. I have caching in place but unfortunately query strings are ignored. Now every time I get a flood of query ...
0
votes
0answers
105 views

“No 'Access-Control-Allow-Origin' header is present” nginx even though it is in the configuration file

This has me going around in circles. Here's the setup: Ubuntu, running django rest framework and nginx. I am using the Wide-open CORS config for nginx, and posting the form data using basic ...
0
votes
2answers
43 views

If file does not exists, rewrite

If the user types www.mysite.com/foo.php, if the file foo exist the server respond with foo, but if the file does not exist, it needs to rewrite like this: www.mysite.com/url.php?url=foo.php Im ...
0
votes
1answer
28 views

Stop nginx reverse proxy from redirecting

There are several similar questions but I haven't been able to figure out how to fix my problem. I am running an instance of nginx on port 80 which acts as a reverse proxy for some other instances of ...
0
votes
1answer
16 views

Nginx - Cached Welcome page on domain

I have an interesting issue. So I installed nginx to try it out and now I'm regretting it. The initial setup wasn't bad, but once I removed nginx and rebuilt the server (it was a clean install to ...
1
vote
1answer
34 views

nginx - serve only with backend or 404, no static files in root

I am trying to serve all requests with the backend (uwsgi for flask in this case) and if the backend has no such path, nginx should return 404. Somehow I only can get the backend to take over when I ...
0
votes
0answers
21 views

Ubuntu 14.04 | Docker: security implications in run NginX in a container

I was surfing around Docker Hub to find the NginX built-in image and i noticed the example commands to run NginX as web server in a container. I wonder if this way, suggested on Docker Hub, to load ...
0
votes
0answers
42 views

mywebsite.com/wp-admin it redirects to /wp-login.php and displays “File not found”

On mywebsite.com, I have running docker container with wordpress. I started it as docker run -p 8000:80 --name docker-wordpress-nginx -d and docker ps shows 0.0.0.0:8000->80/tcp and on my ...
1
vote
1answer
62 views

504 Gateway Time-out with PHP on nginx [duplicate]

I am trying to move a PHP Laravel application from my development computer running apache to a server running nginx. I have configured the database connection, and my Laravel app (mostly) responds ...
1
vote
2answers
29 views

Disable gzip for a specific directory

For training purposes I would like to deactivate gzip for a specific directory. The following config doesn't do the trick. How can I deactivate it? location /webperf/disabledgzip/ { gzip_disable ...
0
votes
0answers
21 views

Nginx websockets and location

I've been stuck for 2 days in a problem with nginx. This is working (dedicated vhost) : server { listen 80 default_server; root /var/www/; index index.php index.xhtml index.html; ...
0
votes
1answer
33 views

Nginx setting server gives installation page

I'm trying to set up Nginx for the first time and in following a tutorial I have come to the point that I'm getting the Welcome page to Nginx. I removed the last two includes in the ...
0
votes
1answer
26 views

Nginx 301 redirect if string is given

I would like to create a permanent redirect for specific querys inside my nginx server block. As example on my current url links to the php script have been: website.com/?hash=12345 So i need to ...
0
votes
1answer
21 views

get dev.domain.tld to rewrite to correct app with nginx

I have two node.js instances running behind nginx proxy I also have a rewrite rule to push everything to https. My issue is that I would like to split dev.domain.tld to go to the second node.js ...
0
votes
1answer
45 views

Nginx Configuration:504 Gateway Time-out error

We are using Nginx as a Load balancer. Nginx having IP address of :10.110.0.200 and address of host machines are 10.110.3.20|10.110.3.21 this is the configuration file: upstream test1 { server ...
1
vote
1answer
39 views

How to configure nginx to add a query parameter only when the requested uri is / and the specific query parameter doesn't already exist? [closed]

Suppose the query parameter I'm interested in is arg1=val1. I would like nginx to add the query parameter only when the requested uri is / and the query parameter arg1 doesn't already exist. ...
0
votes
0answers
9 views

Uwsgi Fallback Strategies

I'm giving some thought to application redundancy, and I was wondering what the best-practices are for improved reliability using uwsgi fallback features. Specifically, I had two thoughts: 1) We ...
3
votes
1answer
165 views

why is partial content not being served in nginx (mp4)?

i am running nginx v.1.9.3 here to serve my site and also video files for streaming. i am seeing that the mp4 files are always served with a code of 200 and that partial content requests are ignored. ...
0
votes
1answer
57 views

What is my nginx + php server bottleneck?

I am running some siege tests on my nginx server. The bottleneck doesn't seem to be cpu or memory so what is it? I try to do this on my macbook: sudo siege -t 10s -c 500 server_ip/test.php The ...
0
votes
1answer
11 views

Nginx try_files with name from query

'm trying to find way how to serve cached files with nginx. I have stored search results to json file in shared memory. Next time when user tries to look up the same search, it supposed to be served ...
0
votes
1answer
38 views

How make SEO friendly url without .php

I want to use SEO friendly url`s like site.com/page So i looking for a (nginx) rewrite to change /page.php to /page. My server is running Nginx + PHP-FPM 5.6 I also use images,js,css in the map ...
0
votes
1answer
23 views

Nginx rewrite issue with sub folder

I'm try to redirect an URL but nothings happen. :( The source URL example like this: http://example.com/download.php?shortURL=MJdcqV Where the MJdcqV is a variable parameter, all others constant. I ...