Last active
April 17, 2019 03:21
-
-
Save nahidacm/7e781de7cedf1b6e4f9339bb5973706d to your computer and use it in GitHub Desktop.
Nginx server block configuration for magento 2
This file contains hidden or 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
# Only one server block may have `upstream fastcgi_backend` block. | |
# So if you already defined that for some virtual host of your server do not ad that again for other hosts. | |
# In that case only `server` block is required. | |
upstream fastcgi_backend { | |
server unix:/run/php/php7.2-fpm.sock; | |
} | |
server { | |
listen 80; | |
listen [::]:80; | |
server_name magento.loc; | |
set $MAGE_ROOT /var/www/magento.loc; | |
include /var/www/magento.loc/nginx.conf.sample; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment