gt metric

You should add that inside of an existing server block. Usually that will be in /etc/nginx/sites-enabled/default

server {

listen       80;

server_name  localhost;

 

location / {

root   /usr/share/nginx/html;

index  index.html index.htm;

}

 

location ~*  \.(jpg|jpeg|png|gif|ico|css|js)$ {

expires 365d;

}

 

location ~*  \.(pdf)$ {

expires 30d;

}

}

read also nginx vs apache

0/5 (0 Reviews)

LEAVE A REPLY

Please enter your comment!
Please enter your name here

This site uses Akismet to reduce spam. Learn how your comment data is processed.