Professional Documents
Culture Documents
Install LAMP On Ubuntu
Install LAMP On Ubuntu
Once the installation is finished you need to allow the http traffic through firewall. Here UFW is different
application profile. Which can be help to allow the application traffic pass through the firewall.
The configuration files of apache2 are located in /etc/apache2 directory and main configuration are
located in /etc/apache2/apache2.conf and the default document root for starting your web files is
/var/www/html
You can confirm the apache2 service are up and enabled on boot using the following commands.
In order to remove the package from Ubuntu Server use the following command.
Now confirm that the mariaDB database services are up and enabled at boot.
On Production servers you need to enable some security measures for mariaDB database installation by
running the below command.
/etc/php/7.4/
In order to install the PHP extension required by the application use the following command.
After installing the php extension you need to restart the apache server to do so, use the below
command.
To test if apache is working in conjunction with php. Create info.php page under Web document root.
/var/www/html/info.php
Installing PHPmyadmin in Ubuntu 20.04
Once the installation process is complete, the configuration files of phpmyadmin is located in
/etc/phpmyadmin/
/etc/phpmyadmin/config.inc.php (main configuration file)
/etc/phpmyadmin/apache.conf (another main configuration file)
Next we need to configure the apache2 server to server the phpmyadmin dashboard.
Then enable the phpmyadmin.conf configuration files for Apache2 and restart the Apache2 service to
apply the recent changes.
sudo ln -s /etc/phpmyadmin/apache.conf /etc/apache2/conf-
available/phpmyadmin.conf
sudo a2enconf phpmyadmin.conf
sudo systemctl reload apache2.service
Note: In MySQL 5.7 (released Oct 2015) and MySQL 8, the root MySQL user is set to authenticate using
the auth_socket or caching_sha2_password plugin rather than with mysql_native_password. This will
prevent programs like phpMyAdmin from logging in with the root account.
Now open the sudo vim /etc/phpmyadmin/config-db.php and change the username and
password of new super user
Flask python virtual environment.
In Windows
Now Open the command prompt and create a directory called my_proj
Now Virtual Environment has been activated. After that install the Flask development environment
in this virtual environment. Follow the below commands.
Now Create a working directory where you want to install the virtual environment.
Mkdir my_proj
Cd my_proj
python@ubuntu:~/my_proj$ python3 -m venv venv