nginx (pronounced "engine-x") is a lightweight, high-performance Web server and reverse proxy as well as IMAP/POP3 proxy server.

learn more… | top users | synonyms

-1
votes
0answers
39 views

Serve multiple programming languages with Nginx [closed]

I'd like to have multiple sections on my website, each serving a specific programming language. For example, example.com/php would serve PHP, example.com/python would serve Python, and ...
0
votes
0answers
15 views

nginx different root based on host ip

Does anyone know of a method to use a different server root based on the remote host's IP? This fails with a "root not allowed here" message: if ($remote_addr = myip) { root /some/other/root } ...
1
vote
1answer
20 views

Nginx Access.log status results according to different file

nginx access.log, I want to do status="200" access_log /var/log/access.log main; status="444" access_log /var/log/access444.log main; status="401" access_log /var/log/access401.log main; this can ...
0
votes
0answers
15 views

How do I troubleshoot a nginx 413 error?

I'm getting a 413 error on my laravel forge site using nginx. I updated php.ini for cli and ftp to 1000m and updated my nginx config for client_max_body_size = 1000m. Still getting that 413. The file ...
0
votes
0answers
11 views

“No input file specified” [closed]

Good evening, I've just set up my second server to learn somewhat about them. The first one was a LAMP stack on a raspberry pi, but had to be replaced by a LEMP one because of the needed performance. ...
1
vote
1answer
21 views

Nginx: request files without extension

How can I request html pages on a nginx server without the extension? Ie: example.com/about should return example.com/about.html. This should be true for all the html pages. I have something along ...
0
votes
1answer
39 views

nginx php-fpm not fully working

I'm using nginx-1.6.2_1,2 with php5-5.4.36 on: # uname -a FreeBSD X.X.X 9.2-RELEASE-p5 FreeBSD 9.2-RELEASE-p5 #0 r265974: Wed May 14 07:57:04 PDT 2014 root@X.X.X:/usr/obj/usr/src/sys/R610 amd64 ...
2
votes
1answer
27 views

Serving Landing page using nginx. Unable to get '/' to work while other urls are working fine

I am trying to set up a landing page for my site( say example.com) and I want to serve my own html as the page to load when someone types 'example.com' on their browser. I am using nginx as my ...
-2
votes
0answers
26 views

Nginx times out after 1 minute [closed]

I've been googling this for like 2 hours now, but couldn't find solution. Im running nginx on windows 10 tech preview on my local network laptop as a server, and I'm developing a php app, so I'm the ...
1
vote
0answers
36 views

Can't go to route using nginx and Express.JS

So I have express.js set up behind nginx and when I go to website.com/users, I get a 404. But when I go to website.com, the page loads fine. This appears to be all other routes too, I can't get to ...
2
votes
1answer
28 views

Different server response time for 2 web pages with the same view and template?

I've recently been facing hugely increased server response time for some of my web pages (response time in the range of 10-20 seconds). For example, for the page http://www.edmhunters.com/afrojack/ - ...
0
votes
0answers
28 views

How to enable apache userdir when using nginx as reverse proxy

I have a setup using apache 2.4, php-fpm, and nginx. I need to enable the apache userdir module so http://ip-of-server/~user would be equivalent to the http://example.com normal site. I can't get it ...
-2
votes
2answers
37 views

Nginx as a proxy server for a local network

I'm currently using squid as a proxy server for my local network, but I'm not entirely satisfied with it. Is Nginx also suitable for use as a proxy server on a local network? Is it actively being used ...
1
vote
0answers
15 views

Risks of letting ZNC have my private SSL key

I have a single VPS running a few websites and also my ZNC IRC bouncer. I purchased a wildcard SSL certificate for all my subdomains (this was silly; it would've been much cheaper just to purchase ...
1
vote
0answers
28 views

Nginx - branch on parameter in location context

I'm trying to use the HttpEchoModule to sleep for a random amount of time when i hit a location with a specific parameter: location = /api/shouldSend { if ($arg_blah = "test") { ...
0
votes
1answer
55 views

Rate limit new connections in IPTables instead of Nginx or HAProxy?

I would like to use some form of rate-limiting both 1) new TCP connections and 2) requests over an existing connection to HTTP(S). I will probably handle #2 with nginx or HAProxy (because I have more ...
0
votes
1answer
35 views

Nginx ip_hash behind proxy (Cloudflare)

We use nginx for our load balancing, and we need ip_hash to guarantee our server work fine. When we started using cloudflare, most our requests go for one server as it seems all of them are ...
0
votes
0answers
4 views

How to deactivate sendfile() in Django runserver [migrated]

I am running a Django development environment using Vagrant/VirtualBox. I am using runserver for my local testing. However, I have encountered this bug: ...
1
vote
0answers
56 views

Nginx : How to set 'limit_conn' and 'limit_req'?

I'm using nginx version 1.6.2 on ubuntu 14.04 I've tried to input limit_conn and limit_req at configuration file with referencing nginx documentation. Nginx is well working without limit_conn and ...
0
votes
1answer
32 views

Nginx ngx_http_access_module deny being trumped by redirect

When I put a deny in the http context, a server -> location context is still executing its redirect. Given this very basic nginx.conf: events { worker_connections 1024; } http { deny ...
2
votes
1answer
47 views

Nginx cache not updating

So my coworker set us up a fancy new caching proxy system and then promptly went on vacation. Now I'm getting complaints from our developers/designers that many static resources are being cached for ...
2
votes
1answer
32 views

Nginx doesn't decrement max-age

I'm trying to set up Nginx as a reverse proxy for my Rails application running on Unicorn. My app has some public pages that I'd like to cache for a duration for 60 minutes, so I set the max-age ...
1
vote
1answer
30 views

nginx - no ssl for crawlers / bots

In a server directive for port 80 in nginx I want to redirect all requests to https if the user agent is not a bot. I tried using this: ... location / { if ($http_user_agent !~* ...
-3
votes
0answers
18 views

Nginx http authentication with python

I have following Apache configuration (excerpt): <Location /api> AuthType Basic AuthName "Top Secret" AuthBasicProvider wsgi ...
0
votes
1answer
25 views

Block a unique hash in URL through NGINX

I need to block a hash which is inside a URL through nginx. The URL which requires to be blocked is ht tp:/ /mp3s tri ng.c ...
0
votes
1answer
21 views

Nginx Load Balancer having two load balanced nginx+php-fpm (Primary script unknown) error

We have two web servers with nginx+php-fpm ( 10.0.0.10 and 10.0.0.20 ), which is load balanced behind another nginx server ( just nginx ), when we try to browse we get file not found error, with error ...
0
votes
3answers
30 views

NGINX Not showing my index.html - Stays default

server { listen 80 default_server; listen [::]:80 default_server ipv6only=on; root /var/www/apexnetwork.org/public_html/; index index.html index.htm; # Make site accessible from ...
0
votes
1answer
43 views

nginx logs to syslog - connection refused

I'm trying to setup nginx 1.7.3 to send logs to syslog, but when I this configuration: server { access_log syslog:server=localhost; } this shows up in nginx's error log: 2015/01/15 21:42:47 ...
0
votes
2answers
36 views

Which directories does nginx need access to?

I'm writing a systemd service file for nginx and an internet facing service running as root is a bad idea, however I need nginx to access a certain directory in each user's home directory. e.g. ...
0
votes
0answers
44 views

Jenkins publish over ssh success to connect the server but failed put file

I have a problem that when I do build to my job, its cannot put my file on the server directory in console output i get the message "ERROR: Exception when publishing, exception message [Permission ...
0
votes
2answers
30 views

nginx with php5-fpm and multiple Wordpress in subdirectories

I have a running nginx server with php5-fpm on a debian wheezy. I want /var/www/devel/ to be my development folder served at http://devel.example.com. In this directory I have multiple projects like ...
0
votes
1answer
56 views

Nginx Pagespeed does not Combine or Minify JS or CSS

I am using Mod_Pagespeed Filters for Nginx and the combine and minify javascipt or css is not working. I checked everything and could not find the reason: 1) There are no errors in the error log 2) ...
0
votes
0answers
45 views

Is it really possible to use PHP sessions for authentication with nginx fastcgi cache?

I have recently switched an opencart instance from Apache+mod_php to nginx+fastcgi+php-fpm. I have been trying to leverage caching for most pages through fastcgi-cache. Unfortunately, many users ...
2
votes
3answers
1k views

How to disallow external access to 127.0.0.1? [closed]

I use tcp socket on 127.0.0.1:9000 to connect nginx to php5-cgi. However I want make sure that no extrnal request can be made to this IP, so that no attacker can obfuscate IP and bypass nginx to do ...
0
votes
0answers
37 views

Keepalive best practices for Nginx-Haproxy-Apache chain

I am using Nginx to serve static content, and Haproxy to proxy requests to multiple Apache2 backends discovered via Zookeeper. Nginx -> Haproxy -> Apache2 According to the official Nginx website, it ...
0
votes
0answers
42 views

Configure nginx to proxy pass when some conditions occurs or to use php fastcgi otherwise

I have a particular case on which I want to redirect visitors to a "prerender" server when I found out the visitor is a crawler (to give a SEO-optimised website) and to a standard php fast-cgi ...
0
votes
0answers
24 views

In nginx logs: SSL3_GET_CLIENT_HELLO:required cipher missing

We disabled SSLv3 several months ago, and on Sunday I noticed this filling our nginx logs. It's been continuing ever since and users are emailing us saying they cannot connect to our site. 2015/01/13 ...
0
votes
0answers
34 views

Nginx redirecting site index requests

Existing functionality: try_files along with rewrite are being used to allow requests for foo.html and foo/ to redirect to foo. Problem: If I specify try_files $uri.html $uri @noextension =404;, then ...
0
votes
1answer
29 views

Protect /analytics on Nginx with basic authentication, but allow access to .php and .js files?

Hope this is the right place to ask. I have Piwik setup and running on a Nginx webserver that I protected with HTTP basic authentication, as seen below. location /analytics { alias ...
0
votes
1answer
100 views

How to solve nginx reverse proxy mixed content(http, https)

New to nginx. Played with it for 2 days and cannot figure out how to solve this: I have a bunch of VMs running in one box, the box is behind my router obviously, one of the VMs is running nginx(my ...
1
vote
0answers
21 views

Convertion of htaccess rewrite rule to nginx [closed]

Through searching the internet with "converting htaccess to nginx rule" I came up with anilcetin and winginx .htaccess to nginx converter which I doubt it doesn't correctly output what I need. Which ...
0
votes
0answers
24 views

Bad HTTP Location: header with nginx proxying couchdb

I'm using nginx as a reverse proxy for CouchDB. I'd like to use a prefix for the proxy, e.g. http://[ip]:8080/proxy/testdb -> http://localhost:5984/testdb. I'm getting Location: headers in the HTTP ...
0
votes
1answer
41 views

Nginx rewriting files that do not exist

Nginx is returning the site root index instead of a 404 response for non-existent files, i.e. attempting to rewrite files that do not exist which is undesired. While I see the topic was answered here, ...
0
votes
0answers
12 views

php_flag engine off directive in nginx? [duplicate]

I am wondering how to apply this recommended apache dirctive into nginx rules? <IfModule mod_php5.c> php_flag engine off </IfModule>
0
votes
1answer
27 views

nginx: routing multiple URLs to one html file

we render part of our site to static files, similar to what jekyll does. For instance, we have files: index.html about-us.html the problem is, sometimes the names change and we end up with: ...
3
votes
2answers
1k views

Continuous POST requests on wordpress login page - hacking attempt?

From today morning, I am witnessing a series of continuous POST requests hitting on one of blog running on wordpress software on my server. Few things about this pattern: These continuous requests ...
0
votes
0answers
18 views

Nginx - Empty Path Info

I was trying to configure Nginx to support restful URLs. I used a perl wrapper that will run as a FastCGI. Here is my nginx configuration: location ^~ /books{ root ...
-5
votes
0answers
31 views

nginx and apache on diff ports

I have a shared server with apache running on :80 and nginx running :8080. I would like to enable APC for HTTP requests coming from nginx. For this I need to enable apc in php.ini or apc.ini. If I do ...
1
vote
0answers
74 views

Why is this nginx www redirect not working?

I'm having trouble with www redirects on an nginx server. The server is running 2 sites: example.com and blog.example.com. Server config: nginx/1.4.6 (Ubuntu) Ubuntu 14.04.1 LTS Relevant DNS ...
0
votes
1answer
28 views

nginx handle multiple locations for one server

I need to setup a virtual host to run my users.example.com website. It needs PHP support via php-fpm. The ideia is to have a mapping like this: users.example.com/~user1/folder/file.php -> ...