Advertisement
akurczyk

nginx

Feb 17th, 2013
70
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 11.33 KB | None | 0 0
  1. root@e00:~# cat /etc/nginx/nginx.conf
  2. user www-data;
  3. worker_processes 1;
  4.  
  5. error_log /var/log/nginx/error.log;
  6. pid /var/run/nginx.pid;
  7.  
  8. events {
  9. worker_connections 1024;
  10. # multi_accept on;
  11. }
  12.  
  13. http {
  14. include /etc/nginx/mime.types;
  15.  
  16. access_log /var/log/nginx/access.log;
  17.  
  18. sendfile on;
  19. #tcp_nopush on;
  20.  
  21. #keepalive_timeout 0;
  22. keepalive_timeout 65;
  23. tcp_nodelay on;
  24.  
  25. gzip on;
  26. gzip_disable "MSIE [1-6]\.(?!.*SV1)";
  27.  
  28. include /etc/nginx/conf.d/*.conf;
  29. include /etc/nginx/sites-enabled/*;
  30. }
  31.  
  32. # mail {
  33. # # See sample authentication script at:
  34. # # http://wiki.nginx.org/NginxImapAuthenticateWithApachePhpScript
  35. #
  36. # # auth_http localhost/auth.php;
  37. # # pop3_capabilities "TOP" "USER";
  38. # # imap_capabilities "IMAP4rev1" "UIDPLUS";
  39. #
  40. # server {
  41. # listen localhost:110;
  42. # protocol pop3;
  43. # proxy on;
  44. # }
  45. #
  46. # server {
  47. # listen localhost:143;
  48. # protocol imap;
  49. # proxy on;
  50. # }
  51. # }
  52.  
  53.  
  54.  
  55.  
  56.  
  57.  
  58.  
  59.  
  60.  
  61.  
  62. root@e00:~# cat /etc/nginx/sites-available/default
  63. # You may add here your
  64. # server {
  65. # ...
  66. # }
  67. # statements for each of your virtual hosts
  68.  
  69. server {
  70.  
  71. listen 80; ## listen for ipv4
  72. listen [::]:80 default ipv6only=on; ## listen for ipv6
  73.  
  74. server_name e00.eu; #localhost
  75. #server_name_in_redirect off;
  76.  
  77. access_log /var/log/nginx/localhost.access.log;
  78.  
  79. location / {
  80. root /var/www;
  81. index index.php index.html index.htm;
  82. }
  83.  
  84. location /doc {
  85. root /usr/share;
  86. autoindex on;
  87. allow 127.0.0.1;
  88. deny all;
  89. }
  90.  
  91. location /images {
  92. root /usr/share;
  93. autoindex on;
  94. }
  95.  
  96. location /phpmyadmin {
  97. root /usr/share/phpmyadmin;
  98. #
  99. # location ~ \.php$ {
  100. # include /etc/nginx/fastcgi_params;
  101. # fastcgi_pass 127.0.0.1:9000;
  102. # fastcgi_index index.php;
  103. # fastcgi_param SCRIPT_FILENAME /var/www$fastcgi_script_name;
  104. # }
  105. }
  106.  
  107. #error_page 404 /404.html;
  108.  
  109. # redirect server error pages to the static page /50x.html
  110. #
  111. #error_page 500 502 503 504 /50x.html;
  112. #location = /50x.html {
  113. # root /var/www/nginx-default;
  114. #}
  115.  
  116. # proxy the PHP scripts to Apache listening on 127.0.0.1:80
  117. #
  118. #location ~ \.php$ {
  119. #proxy_pass http://127.0.0.1;
  120. #}
  121.  
  122. # pass the PHP scripts to FastCGI server listening on 127.0.0.1:9000
  123. #
  124. #location ~ \.php$ {
  125. #fastcgi_pass 127.0.0.1:9000;
  126. #fastcgi_index index.php;
  127. #fastcgi_param SCRIPT_FILENAME /scripts$fastcgi_script_name;
  128. #includefastcgi_params;
  129. #}
  130.  
  131. location ~ \.php$ {
  132. include /etc/nginx/fastcgi_params;
  133. fastcgi_pass 127.0.0.1:9000;
  134. fastcgi_index index.php;
  135. fastcgi_param SCRIPT_FILENAME /var/www$fastcgi_script_name;
  136. }
  137.  
  138. # deny access to .htaccess files, if Apache's document root
  139. # concurs with nginx's one
  140. #
  141. #location ~ /\.ht {
  142. #deny all;
  143. #}
  144. }
  145.  
  146.  
  147. # another virtual host using mix of IP-, name-, and port-based configuration
  148. #
  149. #server {
  150. #listen 8000;
  151. #listen somename:8080;
  152. #server_name somename alias another.alias;
  153.  
  154. #location / {
  155. #root html;
  156. #index index.html index.htm;
  157. #}
  158. #}
  159.  
  160.  
  161. # HTTPS server
  162. #
  163. #server {
  164. #listen 443;
  165. #server_name localhost;
  166.  
  167. #ssl on;
  168. #ssl_certificate cert.pem;
  169. #ssl_certificate_key cert.key;
  170.  
  171. #ssl_session_timeout 5m;
  172.  
  173. #ssl_protocols SSLv3 TLSv1;
  174. #ssl_ciphers ALL:!ADH:!EXPORT56:RC4+RSA:+HIGH:+MEDIUM:+LOW:+SSLv3:+EXP;
  175. #ssl_prefer_server_ciphers on;
  176.  
  177. #location / {
  178. #root html;
  179. #index index.html index.htm;
  180. #}
  181. #}
  182.  
  183.  
  184.  
  185.  
  186.  
  187.  
  188.  
  189.  
  190.  
  191.  
  192. root@e00:~# cat /etc/nginx/sites-available/vps-admin.eu
  193. server {
  194. server_name www.vps-admin.eu vps-admin.eu;
  195. access_log /home/vps-admin.eu/logs/access.log;
  196. error_log /home/vps-admin.eu/logs/error.log;
  197. root /home/vps-admin.eu/htdocs;
  198.  
  199. location / {
  200. index index.php index.html index.htm;
  201. }
  202.  
  203. location ~ \.php$ {
  204. include /etc/nginx/fastcgi_params;
  205. fastcgi_pass 127.0.0.1:9000;
  206. fastcgi_index index.php;
  207. fastcgi_param SCRIPT_FILENAME /home/vps-admin.eu/htdocs$fastcgi_script_name;
  208. }
  209. }
  210.  
  211.  
  212.  
  213.  
  214.  
  215.  
  216.  
  217.  
  218.  
  219.  
  220. root@e00:~# cat /etc/nginx/sites-available/irc24.eu
  221. server {
  222. server_name www.irc24.eu irc24.eu;
  223. access_log /home/vps-admin.eu/logs/pma-access.log;
  224. error_log /home/vps-admin.eu/logs/pma-error.log;
  225. root /usr/share/phpmyadmin;
  226.  
  227. location / {
  228. index index.php index.html index.htm;
  229. }
  230.  
  231. location ~ \.php$ {
  232. include /etc/nginx/fastcgi_params;
  233. fastcgi_pass 127.0.0.1:9000;
  234. fastcgi_index index.php;
  235. fastcgi_param SCRIPT_FILENAME /usr/share/phpmyadmin$fastcgi_script_name;
  236. }
  237. }
  238.  
  239.  
  240.  
  241.  
  242.  
  243.  
  244.  
  245.  
  246.  
  247.  
  248. root@e00:~# ls -la /var/www
  249. total 12
  250. drwxr-xr-x 2 root root 4096 Feb 17 13:48 .
  251. drwxr-xr-x 14 root root 4096 Jan 4 19:17 ..
  252. -rw-r--r-- 1 root root 109 Feb 17 13:46 index.html
  253. lrwxrwxrwx 1 root root 22 Feb 17 13:48 phpmyadmin -> /usr/share/phpmyadmin/
  254.  
  255.  
  256.  
  257.  
  258.  
  259.  
  260.  
  261.  
  262.  
  263.  
  264. root@e00:~# ls -la /usr/share/php
  265. php5/ phpmyadmin/
  266. root@e00:~# ls -la /usr/share/phpmyadmin/
  267. total 1128
  268. drwxr-xr-x 8 root root 4096 Feb 17 01:32 .
  269. drwxr-xr-x 94 root root 4096 Feb 17 14:03 ..
  270. lrwxrwxrwx 1 root root 36 Feb 17 01:32 Documentation.html -> ../doc/phpmyadmin/Documentation.html
  271. -rw-r--r-- 1 root root 10829 Sep 7 2010 browse_foreigners.php
  272. -rw-r--r-- 1 root root 4354 Sep 7 2010 bs_change_mime_type.php
  273. -rw-r--r-- 1 root root 1797 Sep 7 2010 bs_disp_as_mime_type.php
  274. -rw-r--r-- 1 root root 2368 Sep 7 2010 bs_play_media.php
  275. -rw-r--r-- 1 root root 798 Sep 7 2010 calendar.php
  276. -rw-r--r-- 1 root root 3565 Sep 7 2010 changelog.php
  277. -rw-r--r-- 1 root root 473 Sep 7 2010 chk_rel.php
  278. -rw-r--r-- 1 root root 181 Jan 22 2012 config.footer.inc.php
  279. -rw-r--r-- 1 root root 181 Jan 22 2012 config.header.inc.php
  280. -rw-r--r-- 1 root root 1263 Jan 22 2012 config.inc.php
  281. -rw-r--r-- 1 root root 2162 Sep 7 2010 config.sample.inc.php
  282. -rw-r--r-- 1 root root 1458 Sep 7 2010 db_create.php
  283. -rw-r--r-- 1 root root 10415 Sep 7 2010 db_datadict.php
  284. -rw-r--r-- 1 root root 2336 Sep 7 2010 db_export.php
  285. -rw-r--r-- 1 root root 537 Sep 7 2010 db_import.php
  286. -rw-r--r-- 1 root root 27435 Sep 7 2010 db_operations.php
  287. -rw-r--r-- 1 root root 7389 Sep 7 2010 db_printview.php
  288. -rw-r--r-- 1 root root 30581 Sep 7 2010 db_qbe.php
  289. -rw-r--r-- 1 root root 13120 Sep 7 2010 db_search.php
  290. -rw-r--r-- 1 root root 980 Sep 7 2010 db_sql.php
  291. -rw-r--r-- 1 root root 25299 Jan 22 2012 db_structure.php
  292. -rw-r--r-- 1 root root 7277 Sep 7 2010 db_tracking.php
  293. lrwxrwxrwx 1 root root 26 Feb 17 01:32 docs.css -> ../doc/phpmyadmin/docs.css
  294. -rw-r--r-- 1 root root 25308 Sep 7 2010 export.php
  295. -rw-r--r-- 1 root root 18902 Sep 7 2010 favicon.ico
  296. -rw-r--r-- 1 root root 15614 Sep 7 2010 import.php
  297. -rw-r--r-- 1 root root 1077 Sep 7 2010 import_status.php
  298. -rw-r--r-- 1 root root 6789 Sep 7 2010 index.php
  299. drwxr-xr-x 3 root root 4096 Feb 17 01:32 js
  300. drwxr-xr-x 2 root root 4096 Feb 17 01:32 lang
  301. drwxr-xr-x 11 root root 4096 Feb 17 01:32 libraries
  302. -rw-r--r-- 1 root root 453 Sep 7 2010 license.php
  303. -rw-r--r-- 1 root root 13416 Jan 22 2012 main.php
  304. -rw-r--r-- 1 root root 27220 Sep 7 2010 navigation.php
  305. -rw-r--r-- 1 root root 27617 Sep 7 2010 pdf_pages.php
  306. -rw-r--r-- 1 root root 53336 Sep 7 2010 pdf_schema.php
  307. -rw-r--r-- 1 root root 366 Jan 22 2012 phpinfo.php
  308. -rw-r--r-- 1 root root 1079 Sep 7 2010 phpmyadmin.css.php
  309. drwxr-xr-x 5 root root 4096 Feb 17 01:31 pmd
  310. -rw-r--r-- 1 root root 9845 Sep 7 2010 pmd_common.php
  311. -rw-r--r-- 1 root root 1866 Sep 7 2010 pmd_display_field.php
  312. -rw-r--r-- 1 root root 18504 Sep 7 2010 pmd_general.php
  313. -rw-r--r-- 1 root root 829 Sep 7 2010 pmd_help.php
  314. -rw-r--r-- 1 root root 3762 Sep 7 2010 pmd_pdf.php
  315. -rw-r--r-- 1 root root 3994 Sep 7 2010 pmd_relation_new.php
  316. -rw-r--r-- 1 root root 1973 Sep 7 2010 pmd_relation_upd.php
  317. -rw-r--r-- 1 root root 2071 Sep 7 2010 pmd_save_pos.php
  318. -rw-r--r-- 1 root root 1063 Sep 7 2010 print.css
  319. -rw-r--r-- 1 root root 8252 Sep 7 2010 querywindow.php
  320. -rw-r--r-- 1 root root 7584 Sep 7 2010 server_binlog.php
  321. -rw-r--r-- 1 root root 2641 Sep 7 2010 server_collations.php
  322. -rw-r--r-- 1 root root 15336 Sep 7 2010 server_databases.php
  323. -rw-r--r-- 1 root root 4689 Sep 7 2010 server_engines.php
  324. -rw-r--r-- 1 root root 1615 Sep 7 2010 server_export.php
  325. -rw-r--r-- 1 root root 549 Sep 7 2010 server_import.php
  326. -rw-r--r-- 1 root root 98602 Sep 7 2010 server_privileges.php
  327. -rw-r--r-- 1 root root 2893 Sep 7 2010 server_processlist.php
  328. -rw-r--r-- 1 root root 16986 Sep 7 2010 server_replication.php
  329. -rw-r--r-- 1 root root 565 Sep 7 2010 server_sql.php
  330. -rw-r--r-- 1 root root 22147 Sep 7 2010 server_status.php
  331. -rw-r--r-- 1 root root 59483 Sep 7 2010 server_synchronize.php
  332. -rw-r--r-- 1 root root 2196 Sep 7 2010 server_variables.php
  333. drwxr-xr-x 4 root root 4096 Feb 17 01:32 setup
  334. -rw-r--r-- 1 root root 297 Sep 7 2010 show_config_errors.php
  335. -rw-r--r-- 1 root root 26846 Jan 22 2012 sql.php
  336. -rw-r--r-- 1 root root 8175 Sep 7 2010 tbl_addfield.php
  337. -rw-r--r-- 1 root root 7214 Sep 7 2010 tbl_alter.php
  338. -rw-r--r-- 1 root root 54017 Sep 7 2010 tbl_change.php
  339. -rw-r--r-- 1 root root 9781 Sep 7 2010 tbl_create.php
  340. -rw-r--r-- 1 root root 2573 Sep 7 2010 tbl_export.php
  341. -rw-r--r-- 1 root root 700 Sep 7 2010 tbl_import.php
  342. -rw-r--r-- 1 root root 7954 Sep 7 2010 tbl_indexes.php
  343. -rw-r--r-- 1 root root 2435 Sep 7 2010 tbl_move_copy.php
  344. -rw-r--r-- 1 root root 28324 Sep 7 2010 tbl_operations.php
  345. -rw-r--r-- 1 root root 16558 Jan 22 2012 tbl_printview.php
  346. -rw-r--r-- 1 root root 23511 Sep 7 2010 tbl_relation.php
  347. -rw-r--r-- 1 root root 15660 Jan 22 2012 tbl_replace.php
  348. -rw-r--r-- 1 root root 4825 Sep 7 2010 tbl_row_action.php
  349. -rw-r--r-- 1 root root 16286 Jan 22 2012 tbl_select.php
  350. -rw-r--r-- 1 root root 919 Sep 7 2010 tbl_sql.php
  351. -rw-r--r-- 1 root root 31945 Jan 22 2012 tbl_structure.php
  352. -rw-r--r-- 1 root root 26219 Jan 22 2012 tbl_tracking.php
  353. drwxr-xr-x 4 root root 4096 Feb 17 01:31 themes
  354. -rw-r--r-- 1 root root 1253 Sep 7 2010 themes.php
  355. -rw-r--r-- 1 root root 1625 Sep 7 2010 transformation_overview.php
  356. -rw-r--r-- 1 root root 3697 Jan 22 2012 transformation_wrapper.php
  357. lrwxrwxrwx 1 root root 34 Feb 17 01:32 translators.html -> ../doc/phpmyadmin/translators.html
  358. -rw-r--r-- 1 root root 4569 Sep 7 2010 user_password.php
  359. -rw-r--r-- 1 root root 5368 Sep 7 2010 view_create.php
  360. -rw-r--r-- 1 root root 1132 Sep 7 2010 webapp.php
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement