Last active
April 18, 2018 01:41
-
-
Save ncole458/9d7e8742a4e064b17e86773d10f49c58 to your computer and use it in GitHub Desktop.
Fix Nginx fonts not working
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
# add below to /etc/nginx/mime.types | |
application/x-font-ttf ttc ttf; | |
application/x-font-otf otf; | |
application/font-woff woff; | |
application/font-woff2 woff2; | |
application/vnd.ms-fontobject eot; | |
# add below to /sites/available/your-site | |
location ~* \.(eot|otf|ttf|woff|woff2)$ { | |
add_header Access-Control-Allow-Origin *; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment