Servers

Using Joomla Bitnami Stack as an example

[This applys only after a Bitnami stack package installation in your local environment. Can be appropriated for any Bitnami Stack like Wordpress or Drupal for both Wamp, Mamp or Lamp installations]

 

Rename the Joomla! application folder. We are going to use joomla1 in this example. The sudo command would be only necessary if you installed it as root user (what happens in Cloud images and Virtual Machines). The /opt/bitnami path is the installation path in Cloud Images and Virtual Machines

sudo mv /opt/bitnami/apps/joomla /opt/bitnami/apps/joomla1

After that, you need to modify the joomla configuration files for Apache (in /opt/bitnami/apps/joomla/conf) to use the new path.

/opt/bitnami/apps/joomla1/conf/httpd-prefix.conf

Alias /joomla1/ "/opt/bitnami/apps/joomla1/htdocs/"

Alias /joomla1 "/opt/bitnami/apps/joomla1/htdocs"

Include "/opt/bitnami/apps/joomla1/conf/httpd-app.conf"

/opt/bitnami/apps/joomla1/conf/httpd-app.conf

....

<Directory "/opt/bitnami/apps/joomla1/htdocs">

...

Include "/opt/bitnami/apps/joomla1/conf/htaccess.conf"

/opt/bitnami/apps/joomla1/conf/htaccess.conf

<Directory "/opt/bitnami/apps/joomla1/htdocs">

/opt/bitnami/apps/joomla1/conf/httpd-vhosts.conf (just in case you want to use VirtualHost

...

DocumentRoot "/opt/bitnami/apps/joomla1/htdocs"

Include "/opt/bitnami/apps/joomla1/conf/httpd-app.conf"

...

To finish with the Apache configuration, we have to modify the path in the /opt/bitnami/apache2/conf/bitnami/bitnami-apps-prefix.conf file

Include "/opt/bitnami/apps/joomla1/conf/httpd-prefix.conf"

In case you are using VirtualHosts instead of prefix, comment the line above and add the following line to /opt/bitnami/apache2/conf/bitnami/bitnami-apps-vhosts.conf

Include "/opt/bitnami/apps/joomla1/conf/httpd-vhosts.conf"

MySQL Configuration

Now open phpMyAdmin (check this wiki entry to know how to access it remotely), select the bitnami_joomla database and rename it. We will use bitnami_joomla1.

phpmyadmin2.png

Rename Database using phpMyAdmin

After that, we have to modify the database configuration in Joomla! to use the new database.

/opt/bitnami/apps/joomla1/htdocs/configuration.php

...

public $user = 'bn_joomla1';

// DB username

public $password = 'DATABASE_PASSWORD';

// DB password

public $db = 'bitnami_joomla1';

// DB database name

...

public $ftp_root = '/opt/bitnami/apps/joomla1/htdocs';

public $ftp_enable = '1';

public $tmp_path = '/opt/bitnami/apps/joomla1/tmp';

public $log_path = '/opt/bitnami/apps/joomla1/logs';

...

Finally, to let the user bn_joomla1 use the new database, we have to give him access.

sudo /opt/bitnami/mysql/bin/mysql -u root -p

Password: ****

mysql> grant all privileges on bitnami_joomla1.* to 'bn_joomla1'@'localhost' identified by 'DATABASE_PASSWORD';

Where DATABASE_PASSWORD is taken from configuration.php (public $password = 'DATABASE_PASSWORD')

Now restart the apache server so that it uses the new configuration.

sudo /opt/bitnami/ctlscript.sh restart apache

Your first joomla should be accessible using http://YOUR_DOMAIN/joomla1.

Installing new Joomla! site

Now, download a new Joomla! module from the Bitnami Website and install it in the instance. While writing this guide, the latest version was Joomla! 3.3.0. Please, change the link below for the correct one.

wget https://bitnami.com/redirect/to/35442/bitnami-joomla-3.3.0-0-module-linux-x64-installer.run

chmod a+x bitnami-joomla-3.3.0-0-module-linux-x64-installer.run

sudo ./bitnami-joomla-3.3.0-0-module-linux-x64-installer.run

Choose /opt/bitnami as installation path when asked (or your own path if you are using a native installer).

And that's all, now you have two Joomla! sites using the same Apache and MySQL servers.

cyberpanelletencrypt-or-zerossl.png

Debugging certificate requesting issues when a self-signed certificate is created instead.

Run from SSH:

/root/.acme.sh/acme.sh --issue -d <YOUR_DOMAIN> -d www.<YOUR_DOMAIN> --cert-file /etc/letsencrypt/live/<YOUR_DOMAIN>/cert.pem --key-file /etc/letsencrypt/live/<YOUR_DOMAIN>/privkey.pem --fullchain-file /etc/letsencrypt/live/<YOUR_DOMAIN>/fullchain.pem -w /home/<YOUR_DOMAIN>/public_html --force --debug

 

You might find these lines of warning showing in a slightly different color [depending on your ssh terminal]:

[Friday 07:07:2021 00:00:11 PM UTC] No EAB credentials found for ZeroSSL, let's get one
[Friday 07:07:2021 00:00:11 PM UTC] acme.sh is using ZeroSSL as default CA now.
[Friday 07:07:2021 00:00:11 PM UTC] Please update your account with an email address first.
[Friday 07:07:2021 00:00:11 PM UTC] acme.sh --register-account -m [email protected]
[Friday 07:07:2021 00:00:11 PM UTC] See: https://github.com/acmesh-official/acme.sh/wiki/ZeroSSL.com-C

 

New CyberPanel 2.1+ has switched suddenly to use of zerossl as the default certificate authority instead of LetsEncrypt certificate authority.
This will likely limit your ssl certificate freedom as it is likely just acting as a third party between you and LetsEncrypt.org, to put a cap on and charge you when you reach a certain number of certificates for your cyberpanel deployment.

If you're ok with zerossl acting as default and go-between run the command the debugger recommended, substituting [email protected] with your actual email address:

/root/.acme.sh/acme.sh --register-account -m [email protected]

 Or change the default back to the legitimately preferred certificate authoritive LetsEncrypt, running this command:

/root/.acme.sh/acme.sh --set-default-ca --server letsencrypt
[Friday 07:07:2021 00:00:11 PM UTC] Changed default CA to: https://acme-v02.api.letsencrypt.org/directory

 

Tags:

Subcategories

CyberPanel The LiteSpeed Web-Server and postfix mail-server management GUI by LiteSpeed 

Comes in 3 packages CyberPanel + Open LiteSpeed, CyberPanel + LiteSpeed Enterprise and CyberPanel Cloud

Visit the official CyberPanel.net

Page 2 of 2