Created
January 13, 2019 03:57
-
-
Save JayWood/dbe84556ff2b5a4b451fc90dc7144339 to your computer and use it in GitHub Desktop.
Don't want to download your uploads from the remote, me either...
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
# Directives to send expires headers and turn off 404 error logging. | |
location ~* .(js|css|png|jpg|jpeg|gif|ico|mp3|mov|tif|tiff|swf|txt|html)$ { | |
expires 24h; | |
log_not_found off; | |
try_files $uri $uri/ @production; | |
} | |
location @production { | |
resolver 8.8.8.8; | |
# replace www.livesite.com with the production site URL | |
proxy_pass https://example.com/$uri; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment