How to Install Joomla Server on Ubuntu 20.04 step by step tutorial. Joomla is a free, open source and one of the most popular content management system around the world. It is written in PHP and uses MySQL vs MariaDB as a database backend. It offers many features and thousands of plugins and templates or themes that help you to customize Joomla and extend its functionality. Joomla allows you to host different kinds of websites, blogs, and applications on the internet.
Joomla Features
Provides a lot of free and paid extensions and templates.
Supports a large community of developers, designers, etc.
Supports over 70 languages.
Used by 2 million websites around the world.
Supports two-factor authentication and advanced access control features.
In this post, we will explain how to install the Joomla server on Ubuntu 20.04.
First, you will require a web server to host the Joomla on the internet. You can install the Apache webserver with MariaDB database server using the following command:
apt-get install apache2 mariadb-server -y
After installing both packages, run the following command to install PHP and other necessary PHP extensions:
By default, the MariaDB database is not secured. So it is recommended to secure it by running the mysql_secure_installation script:
mysql_secure_installation
Answer all the questions to set a MariaDB root password and secure the installation:
Enter current password for root (enter for none):
OK, successfully used password, moving on...
Set root password? [Y/n] Y
New password:
Re-enter new password:
Password updated successfully!
Remove anonymous users? [Y/n] Y
Disallow root login remotely? [Y/n] Y
Remove test database and access to it? [Y/n] Y
Reload privilege tables now? [Y/n] Y
Next, connect to the MariaDB shell with the following command:
mysql -u root -p
Once you are connected, create a database and user for Joomla with the following command:
create database joomladb;
create user joomlauser@localhost identified by 'joomlapassword';
Next, grant all the privileges to Joomla database with the following command:
grant all on joomladb.* to joomlauser@localhost with grant option;
Next, reload the privileges and exit from the MariaDB shell with the following command:
Next, it is recommended to install the Let’s Encrypt SSL on the Joomla website. You can install the Certbot Let’s Encrypt client package using the following command:
apt-get install python3-certbot-apache -y
Once the Certbot package is installed, run the following command to download and install the Let’s Encrypt SSL for your website.
certbot --apache -d joomla.exampledomain.com
You will be asked to provide your email and accept the term of service as shown below:
Saving debug log to /var/log/letsencrypt/letsencrypt.log
Plugins selected: Authenticator standalone, Installer None
Enter email address (used for urgent renewal and security notices) (Enter 'c' to
cancel): hitjethva@gmail.com
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
Please read the Terms of Service at
https://letsencrypt.org/documents/LE-SA-v1.2-November-15-2017.pdf. You must
agree in order to register with the ACME server at
https://acme-v02.api.letsencrypt.org/directory
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
(A)gree/(C)ancel: A
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
Would you be willing to share your email address with the Electronic Frontier
Foundation, a founding partner of the Let's Encrypt project and the non-profit
organization that develops Certbot? We'd like to send you email about our work
encrypting the web, EFF news, campaigns, and ways to support digital freedom.
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
(Y)es/(N)o: Y
Plugins selected: Authenticator apache, Installer apache
Obtaining a new certificate
Performing the following challenges:
http-01 challenge for joomla.exampledomain.com
Enabled Apache rewrite module
Waiting for verification...
Cleaning up challenges
Created an SSL vhost at /etc/apache2/sites-available/joomla-le-ssl.conf
Enabled Apache socache_shmcb module
Enabled Apache ssl module
Deploying Certificate to VirtualHost /etc/apache2/sites-available/joomla-le-ssl.conf
Enabling available site: /etc/apache2/sites-available/joomla-le-ssl.conf
Next, select whether or not to redirect HTTP traffic to HTTPS as shown below:
Please choose whether or not to redirect HTTP traffic to HTTPS, removing HTTP access.
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
1: No redirect - Make no further changes to the webserver configuration.
2: Redirect - Make all requests redirect to secure HTTPS access. Choose this for
new sites, or if you're confident your site works on HTTPS. You can undo this
change by editing your web server's configuration.
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
Select the appropriate number [1-2] then [enter] (press 'c' to cancel): 2
Type 2 and hit Enter to install the Let’s Encrypt SSL for your website:
Enabled Apache rewrite module
Redirecting vhost in /etc/apache2/sites-enabled/joomla.conf to ssl vhost in /etc/apache2/sites-available/joomla-le-ssl.conf
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
Congratulations! You have successfully enabled https://joomla.exampledomain.com
You should test your configuration at:
https://www.ssllabs.com/ssltest/analyze.html?d=open.exampledomain.com
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
IMPORTANT NOTES:
- Congratulations! Your certificate and chain have been saved at:
/etc/letsencrypt/live/joomla.exampledomain.com/fullchain.pem
Your key file has been saved at:
/etc/letsencrypt/live/open.exampledomain.com/privkey.pem
Your cert will expire on 2022-04-11. To obtain a new or tweaked
version of this certificate in the future, simply run certbot again
with the "certonly" option. To non-interactively renew *all* of
your certificates, run "certbot renew"
- If you like Certbot, please consider supporting our work by:
Donating to ISRG / Let's Encrypt: https://letsencrypt.org/donate
Donating to EFF: https://eff.org/donate-le
Now, you can access your Joomla website securely using the URL https://joomla.exampledomain.com.
How to Install Joomla Server on Ubuntu 20.04 Conclusion
In the above guide, we explained how to install Joomla with Apache on Ubuntu 20.04. We also explained how to enable SSL on the Joomla website using Let’s Encrypt. I hope this will help you to deploy Joomla in the production environment.
I am a fan of open source technology and have more than 10 years of experience working with Linux and Open Source technologies. I am one of the Linux technical writers for Cloud Infrastructure Services.
00votes
Article Rating
Subscribe
Login and comment with
I allow to create an account
When you login first time using a Social Login button, we collect your account public profile information shared by Social Login provider, based on your privacy settings. We also get your email address to automatically create an account for you in our website. Once your account is created, you'll be logged-in to this account.
DisagreeAgree
Login and comment with
I allow to create an account
When you login first time using a Social Login button, we collect your account public profile information shared by Social Login provider, based on your privacy settings. We also get your email address to automatically create an account for you in our website. Once your account is created, you'll be logged-in to this account.