-
Notifications
You must be signed in to change notification settings - Fork 3
/
getlancerv3.conf
74 lines (61 loc) · 2.96 KB
/
getlancerv3.conf
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
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
server {
listen 80;
server_name getlancerv3.localhost;
access_log /usr/share/nginx/html/getlancerv3/access.log main;
error_log /usr/share/nginx/html/getlancerv3/error.log;
root /usr/share/nginx/html/getlancerv3;
gzip on;
gzip_disable "msie6";
gzip_comp_level 6;
# gzip_comp_level 9;
gzip_min_length 1100;
gzip_buffers 16 8k;
gzip_proxied any;
# gzip_http_version 1.1;
gzip_types text/plain application/xml text/css text/js text/xml application/x-javascript text/javascript application/json application/xml+rss;
rewrite ^/api/ /server/php/Slim/public/index.php last;
rewrite ^/ipn/process_ipn/(.*)/(.*)/(.*)$ /server/php/Slim/public/process_ipn.php?model=$1&id=$2&hash=$3 last;
rewrite ^/ipn/hubtel_ipn/(.*)/(.*)/(.*)$ /server/php/Slim/public/hubtel_ipn.php?model=$1&id=$2&hash=$3 last;
rewrite ^/download/([a-zA-Z_]*)/([0-9]*)/(.*)$ /server/php/download.php?model=$1&id=$2&filename=$3 last;
if ($args ~ "_escaped_fragment_") {
rewrite ^ /server/php/Slim/public/seo.php?path=$1 last;
}
location / {
if ($http_user_agent ~* "googlebot|yahoo|bingbot|baiduspider|yandex|yeti|yodaobot|gigabot|ia_archiver|facebookexternalhit|twitterbot|developers\.google\.com") {
rewrite ^ /server/php/Slim/public/seo.php?path=$1;
}
root /usr/share/nginx/html/client;
try_files $uri $uri/ /index.html;
index index.html index.php;
}
# rewrite ^/payments/success/(.*)$ /server/php/Slim/plugins/Common/ZazPay/payment_ipn.php last;
# rewrite ^/payments/process/(.*)$ /server/php/Slim/plugins/Common/ZazPay/payment_ipn.php?print_raw_response=1 last;
# rewrite ^/payments/return/(.*)$ /server/php/Slim/plugins/Common/ZazPay/payment_ipn.php?print_raw_response=1 last;
# rewrite ^/payments/cancel/(.*)$ /server/php/Slim/plugins/Common/ZazPay/payment_ipn.php last;
# rewrite ^/payments/payu_cancel/(.*)$ /server/php/Slim/plugins/Common/ZazPay/payment_ipn.php last;
# rewrite ^/paypal_subscribe/process/(.*)$ /server/php/Slim/plugins/Common/ZazPay/payment_ipn.php?print_raw_response=1 last;
# rewrite ^/paypal_subscribe/success/(.*)$ /server/php/Slim/plugins/Common/ZazPay/payment_ipn.php last;
# rewrite ^/paypal_subscribe/cancel/(.*)$ /server/php/Slim/plugins/Common/ZazPay/payment_ipn.php last;
# location ~ /api_explorer {
# root /usr/share/nginx/html/getlancerv3;
# }
location ~ \.php$ {
try_files $uri =404;
fastcgi_pass 127.0.0.1:9001;
include fastcgi_params;
fastcgi_pass unix:/var/run/php5.6-fpm.sock;
fastcgi_index index.php;
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
}
location ~* \.(css|js|less|html|ttf|woff|jpg|jpeg|gif|png|bmp|ico|x\-wav) {
root /home/earntsks/html/client;
if (-f $request_filename) {
break;
}
rewrite ^/scripts/(plugins.[a-z0-9]*.js)$ /server/php/plugin.php?file=$1 last;
rewrite ^/images/([a-zA-Z_]*)/([a-zA-Z_]*)/(.*)$ /server/php/image.php?size=$1&model=$2&filename=$3 last;
add_header Cache-Control public;
add_header Cache-Control must-revalidate;
expires 7d;
}
}