1+ # DO NOT MODIFIED ALL CHNAGES LOST AFTER UPDATE EasyEngine
12# Common Locations
23
34
@@ -21,35 +22,25 @@ location ~* \.(ogg|ogv|svg|svgz|eot|otf|woff|mp4|ttf|css|rss|atom|js|jpg|jpeg|gi
2122}
2223
2324
24- # EasyEngine Shared Settings
25- location /ee/ {
26- autoindex on;
27- alias /var/www/shared/;
28- include common/acl.conf;
29- index index.php index.html index.htm;
30-
31- location ~ ^/ee(.+\.php)$ {
32- alias /var/www/shared$1;
33- fastcgi_pass php;
34- include /etc/nginx/fastcgi_params;
35- }
36-
37- location ~* ^/ee(.+\.(jpg|jpeg|gif|css|png|js|ico|html|xml|txt))$ {
38- alias /var/www/shared$1;
39- }
40- }
25+ # Security Settings For Better Privacy
4126
42- # PMA Settings
43- location /pma {
44- rewrite ^/* /ee/pma last;
27+ # Deny Hidden Files
28+ location ~ /\. {
29+ deny all;
30+ access_log off;
31+ log_not_found off;
4532}
4633
47- location /phpMyAdmin {
48- rewrite ^/* /ee/pma last;
34+ # Deny Backup Extensions & Log Files
35+ location ~* ^.+\.(bak|log|old|orig|original|php#|php~|php_bak|save|swo|swp)$ {
36+ deny all;
37+ access_log off;
38+ log_not_found off;
4939}
5040
51- location /phpmyadmin {
52- rewrite ^/* /ee/pma last;
41+ # Return 403 Forbidden For readme.(txt|html) or license.(txt|html)
42+ if ($request_uri ~* "^.+(readme|license)\.(txt|html)$") {
43+ return 403;
5344}
5445
5546
@@ -67,23 +58,32 @@ location ~ ^/(status|ping) {
6758}
6859
6960
70- # Security Settings For Better Privacy
61+ # EasyEngine Admin Tools
7162
72- # Deny Hidden Files
73- location ~ /\. {
74- deny all;
75- access_log off;
76- log_not_found off;
63+ # PMA Settings
64+ location /pma {
65+ return 301 https://$host:22222/db/pma;
7766}
7867
79- # Deny Backup Extensions & Log Files
80- location ~* ^.+\.(bak|log|old|orig|original|php#|php~|php_bak|save|swo|swp)$ {
81- deny all;
82- access_log off;
83- log_not_found off;
68+ location /phpMyAdmin {
69+ return 301 https://$host:22222/db/pma;
8470}
8571
86- # Return 403 Forbidden For readme.(txt|html) or license.(txt|html)
87- if ($request_uri ~* "^.+(readme|license)\.(txt|html)$") {
88- return 403;
72+ location /phpmyadmin {
73+ return 301 https://$host:22222/db/pma;
74+ }
75+
76+ # Adminer Settings
77+ location /adminer {
78+ return 301 https://$host:22222/db/adminer/;
79+ }
80+
81+ # Memcache Settings
82+ location /memcache {
83+ return 301 https://$host:22222/php/memcache/;
84+ }
85+
86+ # Opcache Settings
87+ location /opcache {
88+ return 301 https://$host:22222/php/opcache/;
8989}
0 commit comments