How to Install Nginx, MariaDB | Ubuntu Nginx PHP MariaDB
ThisisawaytoinstallandsetupNginx,MariaDBandPHP-FPMonUbuntu20.04.NOTE:Thishasbeenpreparedforeaseofuseinmind,notsecurity,mostlyindevelopmentmachine.Pleasedonotusetheseinstructionstosetuponapublicserverenvironment.Useotherpropermanualsinstead.$sudoaptupdateNginx$sudoaptinstallnginx-y$sudosystemctlstartnginx$sudosystemctlenablenginxFirewallSetup$sudoufwallowssh$sudoufwallowhttp$sudoufwenableMariaDB$sudoaptinstallmariadb-server-y$sudomysql_secure_installationFollowtheinstructiontowhatyouneed.Afte...
This is a way to install and set up Nginx, MariaDB and PHP-FPM on Ubuntu 20.04.
NOTE: This has been prepared for ease of use in mind, not security, mostly in development machine. Please do not use these instructions to setup on a public server environment. Use other proper manuals instead.
$ sudo apt update Nginx $ sudo apt install nginx -y $ sudo systemctl start nginx $ sudo systemctl enable nginx Firewall Setup $ sudo ufw allow ssh $ sudo ufw allow http $ sudo ufw enable MariaDB $ sudo apt install mariadb-server -y $ sudo mysql_secure_installationFollow the instruction to what you need. After it ends, try to login:
$ sudo mysql -u root -pAnd if you can not login with error message like Access denied for user root@localhost lets log in to mysql using sudo first
$ sudo mysql -u root -pIn order to create a password, first we have to hash the string first:
SELECT PASSWORD(verysecretchang...