Advertisement
Guest User

Untitled

a guest
Dec 9th, 2019
108
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 12.80 KB | None | 0 0
  1. # configuration file /etc/nginx/nginx.conf:
  2. user www-data;
  3. worker_processes auto;
  4. pid /run/nginx.pid;
  5.  
  6. events {
  7. worker_connections 768;
  8. # multi_accept on;
  9. }
  10.  
  11. http {
  12.  
  13. ##
  14. # Basic Settings
  15. ##
  16.  
  17. sendfile on;
  18. tcp_nopush on;
  19. tcp_nodelay on;
  20. keepalive_timeout 65;
  21. types_hash_max_size 2048;
  22. # server_tokens off;
  23.  
  24. # server_names_hash_bucket_size 64;
  25. # server_name_in_redirect off;
  26.  
  27. include /etc/nginx/mime.types;
  28. default_type application/octet-stream;
  29.  
  30. ##
  31. # SSL Settings
  32. ##
  33.  
  34. ssl_protocols TLSv1 TLSv1.1 TLSv1.2; # Dropping SSLv3, ref: POODLE
  35. ssl_prefer_server_ciphers on;
  36.  
  37. ##
  38. # Logging Settings
  39. ##
  40.  
  41. access_log /var/log/nginx/access.log;
  42. error_log /var/log/nginx/error.log;
  43.  
  44. ##
  45. # Gzip Settings
  46. ##
  47.  
  48. gzip on;
  49. gzip_disable "msie6";
  50.  
  51. # gzip_vary on;
  52. # gzip_proxied any;
  53. # gzip_comp_level 6;
  54. # gzip_buffers 16 8k;
  55. # gzip_http_version 1.1;
  56. # gzip_types text/plain text/css application/json application/javascript text/xml application/xml application/xml+rss text/javascript;
  57.  
  58. ##
  59. # Virtual Host Configs
  60. ##
  61.  
  62. include /etc/nginx/conf.d/*.conf;
  63. include /etc/nginx/sites-enabled/*;
  64. }
  65.  
  66.  
  67. #mail {
  68. # # See sample authentication script at:
  69. # # http://wiki.nginx.org/ImapAuthenticateWithApachePhpScript
  70. #
  71. # # auth_http localhost/auth.php;
  72. # # pop3_capabilities "TOP" "USER";
  73. # # imap_capabilities "IMAP4rev1" "UIDPLUS";
  74. #
  75. # server {
  76. # listen localhost:110;
  77. # protocol pop3;
  78. # proxy on;
  79. # }
  80. #
  81. # server {
  82. # listen localhost:143;
  83. # protocol imap;
  84. # proxy on;
  85. # }
  86. #}
  87.  
  88. # configuration file /etc/nginx/mime.types:
  89.  
  90. types {
  91. text/html html htm shtml;
  92. text/css css;
  93. text/xml xml;
  94. image/gif gif;
  95. image/jpeg jpeg jpg;
  96. application/javascript js;
  97. application/atom+xml atom;
  98. application/rss+xml rss;
  99.  
  100. text/mathml mml;
  101. text/plain txt;
  102. text/vnd.sun.j2me.app-descriptor jad;
  103. text/vnd.wap.wml wml;
  104. text/x-component htc;
  105.  
  106. image/png png;
  107. image/tiff tif tiff;
  108. image/vnd.wap.wbmp wbmp;
  109. image/x-icon ico;
  110. image/x-jng jng;
  111. image/x-ms-bmp bmp;
  112. image/svg+xml svg svgz;
  113. image/webp webp;
  114.  
  115. application/font-woff woff;
  116. application/java-archive jar war ear;
  117. application/json json;
  118. application/mac-binhex40 hqx;
  119. application/msword doc;
  120. application/pdf pdf;
  121. application/postscript ps eps ai;
  122. application/rtf rtf;
  123. application/vnd.apple.mpegurl m3u8;
  124. application/vnd.ms-excel xls;
  125. application/vnd.ms-fontobject eot;
  126. application/vnd.ms-powerpoint ppt;
  127. application/vnd.wap.wmlc wmlc;
  128. application/vnd.google-earth.kml+xml kml;
  129. application/vnd.google-earth.kmz kmz;
  130. application/x-7z-compressed 7z;
  131. application/x-cocoa cco;
  132. application/x-java-archive-diff jardiff;
  133. application/x-java-jnlp-file jnlp;
  134. application/x-makeself run;
  135. application/x-perl pl pm;
  136. application/x-pilot prc pdb;
  137. application/x-rar-compressed rar;
  138. application/x-redhat-package-manager rpm;
  139. application/x-sea sea;
  140. application/x-shockwave-flash swf;
  141. application/x-stuffit sit;
  142. application/x-tcl tcl tk;
  143. application/x-x509-ca-cert der pem crt;
  144. application/x-xpinstall xpi;
  145. application/xhtml+xml xhtml;
  146. application/xspf+xml xspf;
  147. application/zip zip;
  148.  
  149. application/octet-stream bin exe dll;
  150. application/octet-stream deb;
  151. application/octet-stream dmg;
  152. application/octet-stream iso img;
  153. application/octet-stream msi msp msm;
  154.  
  155. application/vnd.openxmlformats-officedocument.wordprocessingml.document docx;
  156. application/vnd.openxmlformats-officedocument.spreadsheetml.sheet xlsx;
  157. application/vnd.openxmlformats-officedocument.presentationml.presentation pptx;
  158.  
  159. audio/midi mid midi kar;
  160. audio/mpeg mp3;
  161. audio/ogg ogg;
  162. audio/x-m4a m4a;
  163. audio/x-realaudio ra;
  164.  
  165. video/3gpp 3gpp 3gp;
  166. video/mp2t ts;
  167. video/mp4 mp4;
  168. video/mpeg mpeg mpg;
  169. video/quicktime mov;
  170. video/webm webm;
  171. video/x-flv flv;
  172. video/x-m4v m4v;
  173. video/x-mng mng;
  174. video/x-ms-asf asx asf;
  175. video/x-ms-wmv wmv;
  176. video/x-msvideo avi;
  177. }
  178.  
  179. # configuration file /etc/nginx/sites-enabled/adminer:
  180. server {
  181. listen 80;
  182. server_name ticketydb.vanishedmc.com;
  183.  
  184. root /var/www/html/adminer;
  185. index index.html index.htm index.php;
  186. charset utf-8;
  187.  
  188. location / {
  189. try_files $uri $uri/ /index.php?$query_string;
  190. }
  191.  
  192. location = /favicon.ico { access_log off; log_not_found off; }
  193. location = /robots.txt { access_log off; log_not_found off; }
  194.  
  195. access_log off;
  196. error_log /var/log/nginx/phpmyadmin.app-error.log error;
  197.  
  198. # allow larger file uploads and longer script runtimes
  199. client_max_body_size 100m;
  200. client_body_timeout 120s;
  201.  
  202. sendfile off;
  203.  
  204. location ~ \.php$ {
  205. fastcgi_split_path_info ^(.+\.php)(/.+)$;
  206. fastcgi_pass unix:/run/php/php7.3-fpm.sock;
  207. fastcgi_index index.php;
  208. include fastcgi_params;
  209. fastcgi_param PHP_VALUE "upload_max_filesize = 100M \n post_max_size=100M";
  210. fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
  211. fastcgi_param HTTP_PROXY "";
  212. fastcgi_intercept_errors off;
  213. fastcgi_buffer_size 16k;
  214. fastcgi_buffers 4 16k;
  215. fastcgi_connect_timeout 300;
  216. fastcgi_send_timeout 300;
  217. fastcgi_read_timeout 300;
  218. }
  219.  
  220. location ~ /\.ht {
  221. deny all;
  222. }
  223. }
  224.  
  225. # configuration file /etc/nginx/fastcgi_params:
  226.  
  227. fastcgi_param QUERY_STRING $query_string;
  228. fastcgi_param REQUEST_METHOD $request_method;
  229. fastcgi_param CONTENT_TYPE $content_type;
  230. fastcgi_param CONTENT_LENGTH $content_length;
  231.  
  232. fastcgi_param SCRIPT_NAME $fastcgi_script_name;
  233. fastcgi_param REQUEST_URI $request_uri;
  234. fastcgi_param DOCUMENT_URI $document_uri;
  235. fastcgi_param DOCUMENT_ROOT $document_root;
  236. fastcgi_param SERVER_PROTOCOL $server_protocol;
  237. fastcgi_param REQUEST_SCHEME $scheme;
  238. fastcgi_param HTTPS $https if_not_empty;
  239.  
  240. fastcgi_param GATEWAY_INTERFACE CGI/1.1;
  241. fastcgi_param SERVER_SOFTWARE nginx/$nginx_version;
  242.  
  243. fastcgi_param REMOTE_ADDR $remote_addr;
  244. fastcgi_param REMOTE_PORT $remote_port;
  245. fastcgi_param SERVER_ADDR $server_addr;
  246. fastcgi_param SERVER_PORT $server_port;
  247. fastcgi_param SERVER_NAME $server_name;
  248.  
  249. # PHP only, required if PHP was built with --enable-force-cgi-redirect
  250. fastcgi_param REDIRECT_STATUS 200;
  251.  
  252. # configuration file /etc/nginx/sites-enabled/ticketyweb:
  253. server_tokens off;
  254.  
  255. server {
  256. listen 80;
  257. server_name panel.tickety.xyz;
  258. return 301 https://$server_name$request_uri;
  259. }
  260.  
  261. server {
  262. listen 443 ssl http2;
  263. server_name panel.tickety.xyz;
  264.  
  265. root /var/www/html/tickety-web/public;
  266. index index.php;
  267.  
  268. access_log /var/log/nginx/tickety.app-access.log;
  269. error_log /var/log/nginx/tickety.app-error.log error;
  270.  
  271. # allow larger file uploads and longer script runtimes
  272. client_max_body_size 100m;
  273. client_body_timeout 120s;
  274.  
  275. sendfile off;
  276.  
  277. # SSL Configuration
  278. ssl_certificate /etc/letsencrypt/live/panel.tickety.xyz/fullchain.pem;
  279. ssl_certificate_key /etc/letsencrypt/live/panel.tickety.xyz/privkey.pem;
  280. ssl_session_cache shared:SSL:10m;
  281. ssl_protocols TLSv1.2;
  282. ssl_ciphers 'ECDHE-ECDSA-AES256-GCM-SHA384:ECDHE-RSA-AES256-GCM-SHA384:ECDHE-ECDSA-CHACHA20-POLY1305:ECDHE-RSA-CHACHA20-POLY1305:ECDHE-ECDSA-AES128-GCM-SHA256:ECDHE-RSA-AES128-GCM-SHA256:ECDHE-ECDSA-AES256-SHA384:ECDHE-RSA-AES256-SHA384:ECDHE-ECDSA-AES128-SHA256:ECDHE-RSA-AES128-SHA256';
  283. ssl_prefer_server_ciphers on;
  284.  
  285. # See https://hstspreload.org/ before uncommenting the line below.
  286. # add_header Strict-Transport-Security "max-age=15768000; preload;";
  287. add_header X-Content-Type-Options nosniff;
  288. add_header X-XSS-Protection "1; mode=block";
  289. add_header X-Robots-Tag none;
  290. add_header Content-Security-Policy "frame-ancestors 'self'";
  291. add_header X-Frame-Options DENY;
  292. add_header Referrer-Policy same-origin;
  293.  
  294. location / {
  295. try_files $uri $uri/ /index.php?$query_string;
  296. }
  297.  
  298. location ~ \.php$ {
  299. fastcgi_split_path_info ^(.+\.php)(/.+)$;
  300. fastcgi_pass unix:/run/php/php7.2-fpm.sock;
  301. fastcgi_index index.php;
  302. include fastcgi_params;
  303. fastcgi_param PHP_VALUE "upload_max_filesize = 100M \n post_max_size=100M";
  304. fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
  305. fastcgi_param HTTP_PROXY "";
  306. fastcgi_intercept_errors off;
  307. fastcgi_buffer_size 16k;
  308. fastcgi_buffers 4 16k;
  309. fastcgi_connect_timeout 300;
  310. fastcgi_send_timeout 300;
  311. fastcgi_read_timeout 300;
  312. include /etc/nginx/fastcgi_params;
  313. }
  314.  
  315. location ~ /\.ht {
  316. deny all;
  317. }
  318. }
  319.  
  320. # configuration file /etc/nginx/fastcgi_params:
  321.  
  322. fastcgi_param QUERY_STRING $query_string;
  323. fastcgi_param REQUEST_METHOD $request_method;
  324. fastcgi_param CONTENT_TYPE $content_type;
  325. fastcgi_param CONTENT_LENGTH $content_length;
  326.  
  327. fastcgi_param SCRIPT_NAME $fastcgi_script_name;
  328. fastcgi_param REQUEST_URI $request_uri;
  329. fastcgi_param DOCUMENT_URI $document_uri;
  330. fastcgi_param DOCUMENT_ROOT $document_root;
  331. fastcgi_param SERVER_PROTOCOL $server_protocol;
  332. fastcgi_param REQUEST_SCHEME $scheme;
  333. fastcgi_param HTTPS $https if_not_empty;
  334.  
  335. fastcgi_param GATEWAY_INTERFACE CGI/1.1;
  336. fastcgi_param SERVER_SOFTWARE nginx/$nginx_version;
  337.  
  338. fastcgi_param REMOTE_ADDR $remote_addr;
  339. fastcgi_param REMOTE_PORT $remote_port;
  340. fastcgi_param SERVER_ADDR $server_addr;
  341. fastcgi_param SERVER_PORT $server_port;
  342. fastcgi_param SERVER_NAME $server_name;
  343.  
  344. # PHP only, required if PHP was built with --enable-force-cgi-redirect
  345. fastcgi_param REDIRECT_STATUS 200;
  346.  
  347. # configuration file /etc/nginx/fastcgi_params:
  348.  
  349. fastcgi_param QUERY_STRING $query_string;
  350. fastcgi_param REQUEST_METHOD $request_method;
  351. fastcgi_param CONTENT_TYPE $content_type;
  352. fastcgi_param CONTENT_LENGTH $content_length;
  353.  
  354. fastcgi_param SCRIPT_NAME $fastcgi_script_name;
  355. fastcgi_param REQUEST_URI $request_uri;
  356. fastcgi_param DOCUMENT_URI $document_uri;
  357. fastcgi_param DOCUMENT_ROOT $document_root;
  358. fastcgi_param SERVER_PROTOCOL $server_protocol;
  359. fastcgi_param REQUEST_SCHEME $scheme;
  360. fastcgi_param HTTPS $https if_not_empty;
  361.  
  362. fastcgi_param GATEWAY_INTERFACE CGI/1.1;
  363. fastcgi_param SERVER_SOFTWARE nginx/$nginx_version;
  364.  
  365. fastcgi_param REMOTE_ADDR $remote_addr;
  366. fastcgi_param REMOTE_PORT $remote_port;
  367. fastcgi_param SERVER_ADDR $server_addr;
  368. fastcgi_param SERVER_PORT $server_port;
  369. fastcgi_param SERVER_NAME $server_name;
  370.  
  371. # PHP only, required if PHP was built with --enable-force-cgi-redirect
  372. fastcgi_param REDIRECT_STATUS 200;
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement