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
20 views

nginx close a location with auth_basic, if a certain argument was passed

There is the URL /index.php. Access to it should be restricted, if it has argument ‘foo’ set to, say, ‘bar’, i.e. /index.php should open freely by anyone, and opening /index.php?foo=bar should proceed ...
1
vote
0answers
30 views

How to split the nginx config across multiple lines?

Especially when configuring HPKP header (or other long headers in general) it would be useful to split a line in an nginx config over multiple lines. This is the desired result: pin-sha256="...
0
votes
1answer
41 views

Nginx - too many redirects [duplicate]

Sorry of the messy conf file. I have been trying everything, so it's become a mess. I want to enable SSL and redirect all traffic to https. Currently, with the below conf file, I can navigate to HTTP ...
0
votes
1answer
37 views

Apache won't start Centos 7, no errors journal -xe

I cannot say when it started because I recently moved and just finished setting up my lab. Though when booting up the VM w/ my NGINX / Apache Server I did a yum update and Apache was upgraded, now it ...
-1
votes
1answer
40 views

How to re-write non-WWW to WWW whilst also enforcing HTTPS in Nginx

I have a client who I am tidying things up for after a migration to a newer/faster server. One of the inclusions is to bring in SSL support, and also standardize links/URLs. The goal is to force ...
-2
votes
0answers
21 views

Get Parameter to URL using nginx re-write

I'm trying rewrite my nginx to use http://domain.com/main instead of using http://domain.com/?page=main I've done: try_files $uri $uri/ /index.php?page=$uri; Returns blank page rewrite ^/(\w+)$ /...
0
votes
0answers
38 views

Nginx reverse proxy https -> http

I'm attempting to reverse proxy from one domain to another, across the internet. Let's say I have https://www.primarydomain.com. I'm attempting reverse proxy https://www.primarydomain.com/blog to a ...
0
votes
0answers
29 views

nginx / node server TTFB very high sometimes

I currently have 2 nodes app on a nginx server behind is a mongo db and a elastic search instance. I currently face serious performance issue, this is not related to an overload of number of user, ...
0
votes
1answer
94 views

AWS Elastick Beanstalk + Node JS + HTTPS = Connection Refused

I have a node js app deployed on AWS, using Elastic Beanstalk with a single instance. It works well with HTTP but I am having trouble setting up the HTTPS access. I created my certificate and ...
0
votes
1answer
110 views

Two domains on one IP, added a subdomain and different domain's SSL gets protocol error

I've been running two domains on one IP for years using SSL. One is example.com and the other is other.com. example.com has three names with its SSL cert; example.com, www.example.com and dev.example....
0
votes
0answers
18 views

Nginx and Ghost issue on a DigitalOcean droplet with older snapshot

I have looked across several forums and StackExchange questions but I'm truly at a loss here as to why this is not working. I was running a Ghost.org blog on a Digital Ocean droplet and had ...
0
votes
2answers
48 views

What is this strange nginx running on 8088?

I recently made a nmap scan to my server, and I discovered that there was some strange instance of nginx running on port 8088. 8088/tcp open http nginx 1.0.11 | http-methods: |_ ...
0
votes
0answers
136 views

Magento2 Varnish + Nginx (SSL not caching)

I move the question on serverfault instead of Magento (https://magento.stackexchange.com/questions/117075/m2-varnish-nginx-ssl-not-caching) since I consider this topic more on server side ...
1
vote
1answer
63 views

Nginx HTTP not working - downloads a file called “download”

if I visit my nginx site with https it is working, but with http it is downloading a file called "download" (no extension whatsoever), 57 bytes and opening it with notepad etc just shows gibberish ...
0
votes
1answer
84 views

Nginx, proxy_cache and badly behaving app (wordpress)

I've been fighting with configuring Nginx as a reverse proxy. I've got most of the mechanics working, but I've been fighting for the last 3 days to control cache headers and being newbie to nginx this ...
0
votes
0answers
26 views

uwsgi does not create PID file

I have the following ini file under /etc/uwsgi/apps-enabled/ cat /etc/uwsgi/apps-enabled/live.ini [uwsgi] uid = www-data gid = www-data socket = /opt/sockets/live.sock master = true processes = 4 ...
0
votes
1answer
107 views

phpMyAdmin on CentOS 7 with NGINX returns blank page

I have installed CentOS 7 in Virtual Machine with NGINX. PHP, MariaDB and everything else is installed and working fine. However, when I access the http://localhost/phpMyAdmin it shows blank page. ...
1
vote
1answer
40 views

GoAccess date/time/log format error

When running GoAccess with my Nginx log file I'm getting this error: Fatal error has occurred Error occured at: src/goaccess.c - main - 1017 Nothing valid to process. Verify your date/time/log format....
2
votes
1answer
44 views

How to properly refuse ssl connections to subdomains that don't have a certificate

I'm currently setting up a (semi-serious) server with nginx for the first time. I have a couple of domains and subdomains and want to use SSL as much as possible to keep the traffic to and from my ...
0
votes
1answer
64 views

How to get nixos configuration.nix to configure nginx?

In my configuration.nix, it says services.nginx.enable=true; services.nginx.httpConfig="a"; (I tried a normal file and empty string and neither worked) upon running nixos-rebuild switch, it says ...
0
votes
1answer
56 views

Nginx only recognises files in root dir (Permission denied on symlink'ed dir/files)

UPDATE -- This is driving me nuts (or back to Apache...) The issue is definitely symlinks and permissions When I setup symlinks to directories in the same tree, for example /var/www/html/html2 --> /...
0
votes
1answer
43 views

Nginx upstream never flagged as down in vts status

We have 2 physical server which are basically identical (for load balancing and failover) One physical server consist of a bunch of docker containers including 1 x NginX 2 x WebSphere 8.5.5.8 ...
0
votes
1answer
34 views

Single front NGINX to proxy pass SSL to sites with their own certificates

Current setup: Front NGINX proxy passes 80 and 443 to local VM Local VM's NGINX redirects everything to HTTPS (if request is HTTP/80) Local VM's NGINX listens to 443 and proxy passes to the upstream ...
0
votes
1answer
64 views

How to config nginx as sticky loadbalancer for both http and https

I have the config below. However, when user switch from http to https, the session doesn't stick no more. Eg. homepage http but payment page is https. How do I solve this? upstream backend { ...
3
votes
2answers
74 views

Nginx subdomain SSL certs

I have a site that needs to answer on any number of arbitrary subdomains, e.g. client1.example.com, client2.example.com, etc. Everything is behind SSL. I'd really like to use Let's Encrypt which, of ...
0
votes
1answer
51 views

Why does docker pull from private Docker registry using nginx SSL reverse proxy work on registry host, but not remote host?

Why does docker pull from a private Docker registry using an nginx SSL reverse proxy work on registry host, but not remote host? Successful docker pull From registry host: admin@vps58622:~/docker-...
0
votes
2answers
76 views

nginx check if filename with different extension exists

If a file with ".html" extension doesn't exist I need to know if the same file exists with ".th.html" extension and make a redirect. Right now on 404 I'm doing a rewrite and if $request_filename ...
0
votes
0answers
59 views

Fail2ban 0.9.3 not working on centos7.2

I'm really struggling with this. The default [sshd] jail works fine. Status for the jail: sshd |- Filter | |- Currently failed: 0 | |- Total failed: 0 | `- File list: /var/log/secure `- Actions ...
0
votes
2answers
40 views

How do i configure nginx to use part of a URL as a header?

I am trying to get a server application running which supports multiple customers. They should each access the app with their own URL, e.g. http://localhost:8082/customer1/config, but the application ...
0
votes
0answers
27 views

set log level for 404'ed requests in nginx

I am analyzing my server log via journalctl: journalctl --since '24 hours ago' -p err and there are a lot of error messages from nginx for the simple reason that someone requested an invalid/not-...
0
votes
0answers
64 views

Site unreachable due to attack - xmlrpc.php

Today our server was not reachable. It was returning a 502. We are running Nginx 1.10 on Ubuntu 14.04. We also use PHP7 (only, no PHP5). In the logs, we got the same error from the same client (2 ...
1
vote
1answer
45 views

Websocket reverse proxy with nginx: Error about request in server log, but works in browser

The situation I am running Etherpad, which is proxied via nginx. Etherpad uses Websockets with Socket.io. My nginx config is more or less this one. The location block for socket.io is this: rewrite ...
1
vote
1answer
62 views

Nginx reverse proxy in docker container - wrong IP logged

I am running Nginx in a Docker container as a reverse proxy using the configuration below. It basically redirects the request to another docker container running on the same machine Problem The ...
0
votes
2answers
70 views

Nginx - subdomains to Apache, index to WP

I am trying to deploy our new Wordpress (with Apache2 in Docker) one-pager over our existing setup. Right below the LB we have an Nginx server that terminates SSL and proxies plain HTTP requests to ...
0
votes
1answer
76 views

Pass host from nginx to rsyslog

I have a cluster of nginx web servers and a separate syslog server running rsyslog. The nginx vhost looks like this: access_log syslog:server=10.0.0.51,facility=local1,severity=info combined; ...
1
vote
1answer
49 views

how set separate log file, to log 400 bad request errors in nginx

I have a nginx to host a django application. I need to log 400 Bad Request errors from my web page to a separate log file in nginx configuration. The docs I found was to give separate response in ...
1
vote
1answer
105 views

Configuring nginx reverse proxy to send TCP keep alive packets to server

We have IIS servers in Azure behind load balancer. Load balancer has unconfigurable timeout of 4 minutes after which inactive connection is killed. We're trying to setup nginx as a reverse proxy to ...
0
votes
0answers
9 views

High cpu usage by 'root' in Ubuntu VPS server [duplicate]

My server was working fine until last week. But I don't know how someone have changed by ssh root password. After that when I checked the CPU usage, it always 160-190% on executing 'top' command. Some ...
0
votes
0answers
16 views

How To Log TLS Mutual Authentication Details?

Is there a way to log the low-level details of the TLS mutual authentication flow (most importantly - the challenge that is sent to the client and the signed response). Solution for any tool is ...
-2
votes
2answers
24 views

Nginx config not redirecting

I have my nginx config and I am trying to redirect from a non www. version of the site to the www. version. server { listen 80; server_name *.example.com example.com; rewrite ^ https://www....
0
votes
1answer
18 views

Nginx Redirecting from file list

I would like nginx to perform redirects (302) on certain urls while changing part of the url to another based on a file (lets say a csv). For example: https://localhost/foo/100/bar.html to redirect ...
0
votes
0answers
51 views

Haproxy Nginx : How not to forward the local port?

I have haproxy which listening on ports 80 and 443 and behind Nginx listening locally on ports 8000, 8001, 8002 etc... By default, all works fine but when an application web made a redirect 301, it ...
0
votes
0answers
45 views

Can NGINX inspect the TLS request to look for SNI like HAProxy (etc) does?

It seems that, when configuring HAProxy for hostname routing on HTTPS connections, it is crucial to include a tcp-request inspect-delay directive to "give HAProxy a chance to look into the connection"....
1
vote
1answer
48 views

Nginx & PHP in a subdirectory

I have an app behind nginx. But i need a specific path in this app redirect to a Wordpress Blog Example : example.com/ -------> Redirect to my app example.com/whatever/ -------> Redirect to ...
0
votes
1answer
117 views

nginx: FastCGI sent in stderr: “Primary script unknown”

Using the latest version of nginx (1.10.0) and php-fpm (PHP 7.0.6) on 64-bit arch linux. When attempting to request index.php for a DokuWiki installation, I get the following error: 2016/05/21 22:...
1
vote
1answer
21 views

NGINX password protection for everything, but a single endpoint

I have two EC2 instances on AWS. I'm using NGINX 1.6 for both. The two instances are connected to an AWS load balancer. In order for the instances to be considered "up and running" the load balanced ...
0
votes
1answer
14 views

Django uwsgi deploy. Unable to find 'application'

Has a problem when starting uwsgi: unable to find "application" callable in file dashboard/wsgi.py unable to load app 0 (mountpoint='') (callable not found or import error) uwsgi.ini: [uwsgi] ...
0
votes
1answer
31 views

ssl curl not working

I set up my site I have ssl setup and working, works fine in chrome, works fine for postman. For whatever reason it does not work when twilio or curl trys to access it. It gives me a unable to get ...
2
votes
1answer
91 views

Does NGINX support SNI or does it not?

EDIT New question: Can NGINX inspect the TLS request to look for SNI like HAProxy (etc) does? According to what I've read around (and I've been told), NGINX should not support SNI and I should go for ...
0
votes
0answers
26 views

Nginx subdomain redirection

I have a site that is subdomain intensive. Each client has their own subdomain and "unknown" subdomains display a landing page asking the user to associate themselves with a client. Basically, ...