summaryrefslogtreecommitdiff
path: root/nginx/sites/vainsocial.dev.conf
blob: 6592db6bdbf20ce3afd617cd4c2ec27af2db3e2c (plain)
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
37
38
39
40
41
42
43
44
45
46
47
48
server {

    listen 80 default_server;
    listen [::]:80 default_server;

    server_name vainsocial.dev;
    root /var/www/vainsocial/public;
    index index.php index.html index.htm;

    location /bot {
        return 404;
    }

    location /bridge {
        # proxy_pass http://192.168.1.34:8880/api;
        proxy_pass http://bridge1/api;
    }

    location /ws {
        proxy_pass http://websocket;
        proxy_http_version 1.1;
        proxy_set_header Upgrade $http_upgrade;
        proxy_set_header Connection $connection_upgrade;    
    }

    location /stomp {
        proxy_pass http://websocket;
        proxy_http_version 1.1;
        proxy_set_header Upgrade $http_upgrade;
        proxy_set_header Connection $connection_upgrade;    
    }

    location / {
         try_files $uri $uri/ /index.php$is_args$args;
    }

    location ~ \.php$ {
        try_files $uri /index.php =404;
        fastcgi_pass php-upstream;
        fastcgi_index index.php;
        fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
        include fastcgi_params;
    }

    location ~ /\.ht {
        deny all;
    }
}