relevance / etc

bash scripts, aliases, other misc things go here

This URL has Read+Write access

etc / conf / cruisecontrol
100644 36 lines (28 sloc) 0.751 kb
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
upstream domain1 {
  server 127.0.0.1:3333;
}
 
server {
  listen 80;
 
  access_log /var/log/nginx/access.log;
  error_log /var/log/nginx/error.log;
 
  root /home/cruise/cruisecontrolrb/public/;
  index index.html;
 
  location / {
    #auth_basic "Cruise: Restricted";
    #auth_basic_user_file /etc/nginx/passwd;
    proxy_set_header X-Real-IP $remote_addr;
    proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
    proxy_set_header Host $http_host;
    proxy_redirect false;
 
    if (-f $request_filename/index.html) {
      rewrite (.*) $1/index.html break;
    }
 
    if (-f $request_filename.html) {
      rewrite (.*) $1.html break;
    }
 
    if (!-f $request_filename) {
      proxy_pass http://domain1;
      break;
    }
  }
}