How to install Magento 2.3 on Ubuntu with Nginx, PHP 7.2, MySQL 5.7

preview_player
Показать описание
► Skype: cuongnq87

Hi everybody, I am Cuong, Welcome back to my Magento 2 tutorial video series.

Today, I am going to show everybody the best practice, How to install Magento 2.3 on Ubuntu with Nginx.

In this video, I will show everybody steps by step to install Magento 2.3 on Ubuntu 16.04 with Nginx 1.10.x, PHP 7.2.x and MySQL 5.7.

Okie, let's go.

Let's do this practice, you need to follow steps by step:

Step 1: Installing the server.
- cat /etc/*release (check your current Ubuntu version)
I have Ubuntu 16.04 on my localhost.
- Install the softwares:
apt-get update
apt-get -y install git wget curl nano unzip sudo vim net-tools openssh-server
- Install the Nginx 1.10.x:
apt-get -y install nginx
service nginx start
nginx -v
- Install PHP 7.2.x and the required PHP extensions:
apt-get install software-properties-common
add-apt-repository ppa:ondrej/php
apt-get update
apt-cache search php7.2
apt-get install php7.2 libapache2-mod-php7.2 php7.2-common php7.2-gd php7.2-mysql php7.2-curl php7.2-intl php7.2-xsl php7.2-mbstring php7.2-zip php7.2-bcmath php7.2-soap php-xdebug php-imagick
php -v
- Install PHP 7.2 FPM:
apt-get install php7.2-fpm
press ctrl + w for searching
memory_limit = 2G
max_execution_time = 3600
max_input_time = 1800
upload_max_filesize = 10M
press ctrl + O for saving.
service php7.2-fpm start
- Install MySQL 5.7
apt-get install -y mysql-server mysql-client
enter the password for the root user: giaphugroup
service mysql start
mysql_secure_installation
SHOW VARIABLES LIKE "%version%";
- Install Composer:
composer --version
- Install phpMyAdmin
Create the new folder named phpmyadmin in the path /var/www/html/
mkdir phpmyadmin

Download phpMyAdmin:

Create a new virtual host for accessing to phpmyadmin
nano /etc/nginx/sites-available/phpmyadmin
server {
listen 9000;
root /var/www/html/phpmyadmin/phpMyAdmin-4.8.5-all-languages;
server_name localhost;

location / {
}

location ~ \.php$ {
}
location ~ /\.ht {
deny all;
}
}
ln -s /etc/nginx/sites-available/phpmyadmin /etc/nginx/sites-enabled
- Restart Nginx:
nginx -t
service nginx restart
netstat -plnt
3306 is of mysql service
9000 of the phpmyadmin site

Step 2: Install and configure Magento 2.3.0
- cd /var/www/html
- cd magento2.3.0
find var generated vendor pub/static pub/media app/etc -type f -exec chmod g+w {} +
find var generated vendor pub/static pub/media app/etc -type d -exec chmod g+ws {} +
chown -R :www-data .
chmod u+x bin/magento
php bin/magento setup:di:compile
- Create a new virtual host for accessing to the Magento2.3.0 site
nano /etc/nginx/sites-available/magento2.3.0
upstream fastcgi_backend {
}

server {
listen 86;
server_name localhost;
set $MAGE_ROOT /var/www/html/magento2.3.0;
}
ln -s /etc/nginx/sites-available/magento2.3.0 /etc/nginx/sites-enabled
- Restart Nginx:
nginx -t
service nginx restart
netstat -plnt
86 is of the magento 2.3.0 site.

- cd /var/www/html/magento2.3.0
php bin/magento setup:static-content:deploy -f

Thank you for watching guide. If you have any questions about this practice, please feel free to leave a comment below.

Don't forget to like, comment, share my videos and subscribe to my channel for getting the latest videos.

Please do not hesitate to contact me, if you need me to join your Magento project. My rate is $25/hour in Magento 1 and $30/hour in Magento 2.
Рекомендации по теме
Комментарии
Автор

Cảm ơn anh, bài hướng dẫn rất hữu ích và thực tế sau cả ngày mò mà không cài được. Cho em hỏi, em đang cài local: nếu em muốn cài thêm site khác thì phải config như nào ạ? Theo như em làm mò tạo file /etc/nginx/sites-available mới thì sẽ bị duplicate upstream.

nguyentienlong
Автор

Please help me to reach 10.000 subscribers by subscribing to my channel and sharing my videos.

MagentoTutorial
Автор

I'm doing it in ubuntu 18.04 LTS and it doesn't work, the nginx file is not loading after installation.

shotalekashvili
Автор

i follow your tutorial, yet i still got 403 error in Nginx. Please suggest

genexisvalte
visit shbcf.ru