piler/contrib/webserver/piler-nginx.conf
SJ 725a1a6155 gui path fixes
Change-Id: I3ea5773b1f1a55ac46e4f0e9b7ae661983f2784b
Signed-off-by: SJ <sj@acts.hu>
2016-12-31 15:55:51 +01:00

65 lines
2.3 KiB
Plaintext

server {
server_name HOSTNAME;
root /var/piler/www;
access_log /var/log/nginx/HOSTNAME-access.log;
error_log /var/log/nginx/HOSTNAME-error.log;
gzip on;
gzip_types text/plain application/xml text/css;
gzip_vary on;
location / {
index index.php index.html;
try_files $uri $uri/ /index.php;
}
#error_page 404 /404.html;
error_page 500 502 503 504 /50x.html;
location = /50x.html {
root html;
}
location ~ [^/]\.php(/|$) {
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
fastcgi_split_path_info ^(.+?\.php)(/.*)$;
if (!-f $document_root$fastcgi_script_name) {
return 404;
}
fastcgi_pass unix:/var/run/php5-fpm.sock;
fastcgi_index index.php;
include fastcgi_params;
}
location ~* \.(ico|css|js|gif|jpe?g|png)$ {
expires 2w;
}
rewrite /search.php /index.php?route=search/search&type=simple;
rewrite /advanced.php /index.php?route=search/search&type=advanced;
rewrite /expert.php /index.php?route=search/search&type=expert;
rewrite /search-helper.php /index.php?route=search/helper;
rewrite /audit-helper.php /index.php?route=audit/helper;
rewrite /message.php /index.php?route=message/view;
rewrite /bulkrestore.php /index.php?route=message/bulkrestore;
rewrite /bulkremove.php /index.php?route=message/bulkremove;
rewrite /bulkpdf.php /index.php?route=message/bulkpdf;
rewrite /folders.php /index.php?route=folder/list&;
rewrite /settings.php /index.php?route=user/settings;
rewrite /login.php /index.php?route=login/login;
rewrite /logout.php /index.php?route=login/logout;
rewrite /google.php /index.php?route=login/google;
rewrite /domain.php /index.php?route=domain/domain;
rewrite /ldap.php /index.php?route=ldap/list;
rewrite /customer.php /index.php?route=customer/list;
rewrite /retention.php /index.php?route=policy/retention;
rewrite /archiving.php /index.php?route=policy/archiving;
rewrite /view/javascript/piler.js /js.php;
}