Created
November 11, 2016 06:31
-
-
Save jbutko/459a9a3ddd9f02739f5b4fe797b73ae5 to your computer and use it in GitHub Desktop.
Nginx
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# upgrade nginx | |
sudo add-apt-repository ppa:nginx/stable | |
sudo apt-get update | |
sudo apt-get install nginx | |
# cache | |
proxy_cache_path /path/to/cache levels=1:2 keys_zone=my_cache:10m max_size=10g | |
inactive=60m use_temp_path=off; | |
server { | |
... | |
location / { | |
proxy_cache my_cache; | |
proxy_pass http://my_upstream; | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment