0
votes
2answers
48 views

Enable nginx browser catching for specific url

How can I enable nginx catch for specific URL? I have a django web app and I put my static files such as CSS, JavaScript and ... in a folder called static and I can access them via ...
1
vote
1answer
27 views

Optimizing nginx site configuration

First time working with nginx. Due to my limited knowledge of location directive precedence I had to repeat the code at two places (fastcgi). Can I optimize this file and not repeat code? This is my ...
0
votes
0answers
162 views

Nginx load balancing redirects to upstream “name”

Introduction: Please read this serverfault question on nginx load balancing issue with 301 from backend. Somewhat similar to my problem, but the answer doesn't work. Nginx is redirecting to the ...
0
votes
1answer
23 views

Nginx global config inherits from named config?

I've got two nginx configs, one is a global catchall config without a server name set that should handle any request. And i got a second configuration that has a server name set that handles only the ...
2
votes
2answers
81 views

Nginx conf.d files via puppet

I'm trying to determine where to draw the line between what goes in puppet and what is part of an 'application'. One place I'm a bit perplexed is nginx conf.d files. In apache, I'd have these files ...
0
votes
1answer
60 views

nginx ssl basic setup

Im relatively new to the server side and have very little idea about configuration so please excuse me if the question seems really basic I have a nginx+uwsgi server up and running an i would like to ...
1
vote
1answer
124 views

Phpmyadmin cant seem to read config

I'm in the process of setting up a LEMP (Linux, Nginx, MySQL, PHP) server with phpMyAdmin. I installed and followed the various instructions including the create_tables script they provide etc (I've ...
0
votes
2answers
46 views

why is my nginx catchall conf not catching all?

I have a wildcard DNS entry so *.mydomain.tld is directed to my server. Using nginx I have 2 conf files title: default myconf.conf My conf files look like this: default: server { listen 80; ...
0
votes
1answer
146 views

Running roundcube alongside passenger on nginx

I have recently tried to install passenger on nginx. The installation works and everything is good. However I would like to run roundcube webmail on my server as well. Basically my problem is that ...
0
votes
1answer
345 views

nginx won't serve zip files for download

I am having trouble serving zip files from my nginx server. I am testing this out by putting a zip file in the html root director (for simplicity) and then trying to download it. When I go to the ...
0
votes
1answer
193 views

Nginx: Rewriting entire URI to query string

Still pretty new to nginx here, trying to get a simple rewrite to work, but the server just responds '404 not found' My server block server { listen 80; listen [::]:80; server_name ...
0
votes
1answer
109 views

Nginx config rewriting subdomain name to 1st URI segment

I'm unable to do the following nginx.conf rewrite: test.mysite.info to: mysite.info/test here's what i've tried: server { server_name test.mysite.info; rewrite ^ ...
1
vote
1answer
836 views

Nginx rewrite to eliminate “www” not working

I've looked at many SE threads and done various google searches and can't figure out why i can't redirect www.mysite.com to mysite.com on my nginx server. The 1st server block does the ...
0
votes
0answers
616 views

Configure Nginx to run Codeigniter/PHP app?

I'm totally stumped. I've looked at about a dozen tutorials explaining how to configure Nginx to run PHP and a Codeigniter app. I can't get anything to work and worse yet typing mysite.com into the ...
0
votes
1answer
1k views

Location directive in nginx configuration

I have an nginx server setup to act as a fileserver. I want to set the expires directive on images. This is how a part of my config file looks like. http { include /etc/nginx/mime.types; ...
1
vote
1answer
1k views

nginx: How can I set proxy_* directives only for matching URIs?

I've been at this for hours and I can't figure out a clean solution. Basically, I have an nginx proxy setup, which works really well, but I'd like to handle a few urls more manually. Specifically, ...
2
votes
1answer
178 views

Using nginx's try_files with behaviour on HTTP method

I've cleaned up my nginx config replacing all the ifs with try_files but I've got this last one that is bugging me. I wan't it to behave like try_files only if the HTTP method is not DELETE. Delete is ...
1
vote
1answer
221 views

Is it possible to reduce this nginx proxy configuration?

I'm having an hard time trying to find out how to reduce this "repeated lines" for my NGinx configuration, just to change one property : server { #listen [::]:443 ipv6only=on; ## listen for ...
1
vote
2answers
2k views

How do you conditionally include files in Nginx vhost?

In the lines below, I might have a site-specific configuration file that contains additional fastcgi_params unique to that site. If this file exists I want to load it. server { listen 80 ...
6
votes
3answers
6k views

Why cache static files with Varnish, why not pass

I have a system runnning nginx / php-fpm / varnish / wordpress and amazon s3. Now I have looked at a lot of configuration files while setting up the system, and in all of them I found something like ...
0
votes
1answer
490 views

Cleaning up my configs with try_files in Nginx 0.8.54-4

After following the Pitfalls guide I am trying to cleanup my URL rewrites using the try_files directive. However, when using this on my install of Nginx 0.8.54-4 (from dotdeb) I get a prompt to ...
1
vote
1answer
249 views

Nginx language redirect: /de/test/test.php to /test/test.php?

I'm trying to configure Nginx on a new server. I have a number of PHP scripts (f.e. /test/test.php) and I want to use this scripts "as is" (default language, English), as well as with language ...
1
vote
1answer
269 views

Stop nginx from trimming file name in directory list?

Just a quick question: How can I prevent nginx from trimming file name with ... in listing directory?
0
votes
1answer
147 views

NGINX and local-hosted custom domain names

I'm setting up a nginx webserver locally with this config: server { server_name im; access_log /var/www/im/website.access_log; error_log /var/www/im/website.error_log; root /var/www/im; index ...
1
vote
1answer
141 views

nginx - config for several domains

So in the past, I've just had one nginx.conf file. I'd like to separate this out for each domain (right now there's two), but to stay organized in case there's more. How is this possible to let each ...
3
votes
2answers
3k views

Help needed setting up nginx to serve static files

I'm trying to setup nginx to serve static files. Basically all I need is to have http://mydomain.com/site_media/ point to /var/django/myproject/site_media. I have tried so many configurations and ...
2
votes
1answer
3k views

Any guide to set values for fastcgi_buffers in Nginx config?

I just moved our blog-network to ngnix (from apache) which is powered by WPMU. Everything is running smoothly and fine. During my quest to optimize server to the max level - I came across this thread ...