Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Next revision
Previous revision
wiki:nginx [2024/05/08 07:49] – created 5.152.82.90wiki:nginx [2024/05/08 08:03] (current) 5.152.82.90
Line 1: Line 1:
 +[[wiki:nginx_php|PHP]]\\
 +[[wiki:nginx_security:Security]]
 +
 +**Gen DH**
 +<code>openssl dhparam -out /etc/nginx/ssl/dhparam4096.pem 4096</code>
 **Basic Auth** **Basic Auth**
 <code>printf "${username}:`openssl passwd -apr1`\n" >> .htpasswd</code> <code>printf "${username}:`openssl passwd -apr1`\n" >> .htpasswd</code>
 +
 +=====Locations=====
 +<code>
 +location  = / {
 +  # matches the query / only.
 +}
 +location ^~ /images/ {
 +  # matches any query beginning with /images/ and halts searching,
 +  # so regular expressions will not be checked.
 +}
 +location ~* \.(gif|jpg|jpeg)$ {
 +  # matches any request ending in gif, jpg, or jpeg. However, all
 +  # requests to the /images/ directory will be handled by
 +  # Configuration D.   
 +  [ configuration E ] 
 +}
 +location  / {
 +  # matches any query, since all queries begin with /, but regular
 +  # expressions and any longer conventional blocks will be
 +  # matched first.
 +  [ configuration B ] 
 +}
 +location /documents/ {
 +  # matches any query beginning with /documents/ and continues searching,
 +  # so regular expressions will be checked. This will be matched only if
 +  # regular expressions don't find a match.
 +  [ configuration C ] 
 +}
 +</code>
 +
Navigation
Print/export
QR Code
QR Code wiki:nginx (generated for current page)