Octoleo State

This commit is contained in:
Llewellyn van der Merwe 2024-02-22 00:09:56 +02:00
parent 667ef17a8f
commit bfbe8cf855
Signed by: Llewellyn
GPG Key ID: A9201372263741E7
23 changed files with 602 additions and 104 deletions

View File

@ -208,6 +208,26 @@ if [[ "$1" == apache2* ]] || [ "$1" == php-fpm ]; then
echo >&2
echo >&2 "This server is now configured to run Joomla!"
# Check if smtp host exist
if [[ -n "${JOOMLA_SMTP_HOST}" && "${#JOOMLA_SMTP_HOST}" -gt 2 ]]; then
chmod +w configuration.php
sed -i "s/public \$mailer = 'mail';/public \$mailer = 'smtp';/g" configuration.php
sed -i "s/public \$smtphost = 'localhost';/public \$smtphost = '${JOOMLA_SMTP_HOST}';/g" configuration.php
sed -i "s/public \$smtpport = 25;/public \$smtpport = 1025;/g" configuration.php
chmod -w configuration.php
echo >&2
echo >&2 "This server has SMTP host set."
fi
# we install the patch tester
php cli/joomla.php extension:install --url "https://github.com/joomla-extensions/patchtester/releases/download/4.3.1/com_patchtester_4.3.1.zip"
# Check the exit status of the PHP command
if [ $? -eq 0 ]; then
# The PHP command succeeded
echo >&2
echo >&2 "The patch tester has been installed"
fi
# fix the configuration.php ownership
if [ "$uid" = '0' ] && [ "$(stat -c '%u:%g' configuration.php)" != "$user:$group" ]; then
# Set configuration to correct owner

View File

@ -208,6 +208,26 @@ if [[ "$1" == apache2* ]] || [ "$1" == php-fpm ]; then
echo >&2
echo >&2 "This server is now configured to run Joomla!"
# Check if smtp host exist
if [[ -n "${JOOMLA_SMTP_HOST}" && "${#JOOMLA_SMTP_HOST}" -gt 2 ]]; then
chmod +w configuration.php
sed -i "s/public \$mailer = 'mail';/public \$mailer = 'smtp';/g" configuration.php
sed -i "s/public \$smtphost = 'localhost';/public \$smtphost = '${JOOMLA_SMTP_HOST}';/g" configuration.php
sed -i "s/public \$smtpport = 25;/public \$smtpport = 1025;/g" configuration.php
chmod -w configuration.php
echo >&2
echo >&2 "This server has SMTP host set."
fi
# we install the patch tester
php cli/joomla.php extension:install --url "https://github.com/joomla-extensions/patchtester/releases/download/4.3.1/com_patchtester_4.3.1.zip"
# Check the exit status of the PHP command
if [ $? -eq 0 ]; then
# The PHP command succeeded
echo >&2
echo >&2 "The patch tester has been installed"
fi
# fix the configuration.php ownership
if [ "$uid" = '0' ] && [ "$(stat -c '%u:%g' configuration.php)" != "$user:$group" ]; then
# Set configuration to correct owner

View File

@ -208,6 +208,26 @@ if [[ "$1" == apache2* ]] || [ "$1" == php-fpm ]; then
echo >&2
echo >&2 "This server is now configured to run Joomla!"
# Check if smtp host exist
if [[ -n "${JOOMLA_SMTP_HOST}" && "${#JOOMLA_SMTP_HOST}" -gt 2 ]]; then
chmod +w configuration.php
sed -i "s/public \$mailer = 'mail';/public \$mailer = 'smtp';/g" configuration.php
sed -i "s/public \$smtphost = 'localhost';/public \$smtphost = '${JOOMLA_SMTP_HOST}';/g" configuration.php
sed -i "s/public \$smtpport = 25;/public \$smtpport = 1025;/g" configuration.php
chmod -w configuration.php
echo >&2
echo >&2 "This server has SMTP host set."
fi
# we install the patch tester
php cli/joomla.php extension:install --url "https://github.com/joomla-extensions/patchtester/releases/download/4.3.1/com_patchtester_4.3.1.zip"
# Check the exit status of the PHP command
if [ $? -eq 0 ]; then
# The PHP command succeeded
echo >&2
echo >&2 "The patch tester has been installed"
fi
# fix the configuration.php ownership
if [ "$uid" = '0' ] && [ "$(stat -c '%u:%g' configuration.php)" != "$user:$group" ]; then
# Set configuration to correct owner

View File

@ -208,6 +208,26 @@ if [[ "$1" == apache2* ]] || [ "$1" == php-fpm ]; then
echo >&2
echo >&2 "This server is now configured to run Joomla!"
# Check if smtp host exist
if [[ -n "${JOOMLA_SMTP_HOST}" && "${#JOOMLA_SMTP_HOST}" -gt 2 ]]; then
chmod +w configuration.php
sed -i "s/public \$mailer = 'mail';/public \$mailer = 'smtp';/g" configuration.php
sed -i "s/public \$smtphost = 'localhost';/public \$smtphost = '${JOOMLA_SMTP_HOST}';/g" configuration.php
sed -i "s/public \$smtpport = 25;/public \$smtpport = 1025;/g" configuration.php
chmod -w configuration.php
echo >&2
echo >&2 "This server has SMTP host set."
fi
# we install the patch tester
php cli/joomla.php extension:install --url "https://github.com/joomla-extensions/patchtester/releases/download/4.3.1/com_patchtester_4.3.1.zip"
# Check the exit status of the PHP command
if [ $? -eq 0 ]; then
# The PHP command succeeded
echo >&2
echo >&2 "The patch tester has been installed"
fi
# fix the configuration.php ownership
if [ "$uid" = '0' ] && [ "$(stat -c '%u:%g' configuration.php)" != "$user:$group" ]; then
# Set configuration to correct owner

View File

@ -208,6 +208,26 @@ if [[ "$1" == apache2* ]] || [ "$1" == php-fpm ]; then
echo >&2
echo >&2 "This server is now configured to run Joomla!"
# Check if smtp host exist
if [[ -n "${JOOMLA_SMTP_HOST}" && "${#JOOMLA_SMTP_HOST}" -gt 2 ]]; then
chmod +w configuration.php
sed -i "s/public \$mailer = 'mail';/public \$mailer = 'smtp';/g" configuration.php
sed -i "s/public \$smtphost = 'localhost';/public \$smtphost = '${JOOMLA_SMTP_HOST}';/g" configuration.php
sed -i "s/public \$smtpport = 25;/public \$smtpport = 1025;/g" configuration.php
chmod -w configuration.php
echo >&2
echo >&2 "This server has SMTP host set."
fi
# we install the patch tester
php cli/joomla.php extension:install --url "https://github.com/joomla-extensions/patchtester/releases/download/4.3.1/com_patchtester_4.3.1.zip"
# Check the exit status of the PHP command
if [ $? -eq 0 ]; then
# The PHP command succeeded
echo >&2
echo >&2 "The patch tester has been installed"
fi
# fix the configuration.php ownership
if [ "$uid" = '0' ] && [ "$(stat -c '%u:%g' configuration.php)" != "$user:$group" ]; then
# Set configuration to correct owner

View File

@ -208,6 +208,26 @@ if [[ "$1" == apache2* ]] || [ "$1" == php-fpm ]; then
echo >&2
echo >&2 "This server is now configured to run Joomla!"
# Check if smtp host exist
if [[ -n "${JOOMLA_SMTP_HOST}" && "${#JOOMLA_SMTP_HOST}" -gt 2 ]]; then
chmod +w configuration.php
sed -i "s/public \$mailer = 'mail';/public \$mailer = 'smtp';/g" configuration.php
sed -i "s/public \$smtphost = 'localhost';/public \$smtphost = '${JOOMLA_SMTP_HOST}';/g" configuration.php
sed -i "s/public \$smtpport = 25;/public \$smtpport = 1025;/g" configuration.php
chmod -w configuration.php
echo >&2
echo >&2 "This server has SMTP host set."
fi
# we install the patch tester
php cli/joomla.php extension:install --url "https://github.com/joomla-extensions/patchtester/releases/download/4.3.1/com_patchtester_4.3.1.zip"
# Check the exit status of the PHP command
if [ $? -eq 0 ]; then
# The PHP command succeeded
echo >&2
echo >&2 "The patch tester has been installed"
fi
# fix the configuration.php ownership
if [ "$uid" = '0' ] && [ "$(stat -c '%u:%g' configuration.php)" != "$user:$group" ]; then
# Set configuration to correct owner

View File

@ -208,6 +208,26 @@ if [[ "$1" == apache2* ]] || [ "$1" == php-fpm ]; then
echo >&2
echo >&2 "This server is now configured to run Joomla!"
# Check if smtp host exist
if [[ -n "${JOOMLA_SMTP_HOST}" && "${#JOOMLA_SMTP_HOST}" -gt 2 ]]; then
chmod +w configuration.php
sed -i "s/public \$mailer = 'mail';/public \$mailer = 'smtp';/g" configuration.php
sed -i "s/public \$smtphost = 'localhost';/public \$smtphost = '${JOOMLA_SMTP_HOST}';/g" configuration.php
sed -i "s/public \$smtpport = 25;/public \$smtpport = 1025;/g" configuration.php
chmod -w configuration.php
echo >&2
echo >&2 "This server has SMTP host set."
fi
# we install the patch tester
php cli/joomla.php extension:install --url "https://github.com/joomla-extensions/patchtester/releases/download/4.3.1/com_patchtester_4.3.1.zip"
# Check the exit status of the PHP command
if [ $? -eq 0 ]; then
# The PHP command succeeded
echo >&2
echo >&2 "The patch tester has been installed"
fi
# fix the configuration.php ownership
if [ "$uid" = '0' ] && [ "$(stat -c '%u:%g' configuration.php)" != "$user:$group" ]; then
# Set configuration to correct owner

View File

@ -208,6 +208,26 @@ if [[ "$1" == apache2* ]] || [ "$1" == php-fpm ]; then
echo >&2
echo >&2 "This server is now configured to run Joomla!"
# Check if smtp host exist
if [[ -n "${JOOMLA_SMTP_HOST}" && "${#JOOMLA_SMTP_HOST}" -gt 2 ]]; then
chmod +w configuration.php
sed -i "s/public \$mailer = 'mail';/public \$mailer = 'smtp';/g" configuration.php
sed -i "s/public \$smtphost = 'localhost';/public \$smtphost = '${JOOMLA_SMTP_HOST}';/g" configuration.php
sed -i "s/public \$smtpport = 25;/public \$smtpport = 1025;/g" configuration.php
chmod -w configuration.php
echo >&2
echo >&2 "This server has SMTP host set."
fi
# we install the patch tester
php cli/joomla.php extension:install --url "https://github.com/joomla-extensions/patchtester/releases/download/4.3.1/com_patchtester_4.3.1.zip"
# Check the exit status of the PHP command
if [ $? -eq 0 ]; then
# The PHP command succeeded
echo >&2
echo >&2 "The patch tester has been installed"
fi
# fix the configuration.php ownership
if [ "$uid" = '0' ] && [ "$(stat -c '%u:%g' configuration.php)" != "$user:$group" ]; then
# Set configuration to correct owner

View File

@ -208,6 +208,26 @@ if [[ "$1" == apache2* ]] || [ "$1" == php-fpm ]; then
echo >&2
echo >&2 "This server is now configured to run Joomla!"
# Check if smtp host exist
if [[ -n "${JOOMLA_SMTP_HOST}" && "${#JOOMLA_SMTP_HOST}" -gt 2 ]]; then
chmod +w configuration.php
sed -i "s/public \$mailer = 'mail';/public \$mailer = 'smtp';/g" configuration.php
sed -i "s/public \$smtphost = 'localhost';/public \$smtphost = '${JOOMLA_SMTP_HOST}';/g" configuration.php
sed -i "s/public \$smtpport = 25;/public \$smtpport = 1025;/g" configuration.php
chmod -w configuration.php
echo >&2
echo >&2 "This server has SMTP host set."
fi
# we install the patch tester
php cli/joomla.php extension:install --url "https://github.com/joomla-extensions/patchtester/releases/download/4.3.1/com_patchtester_4.3.1.zip"
# Check the exit status of the PHP command
if [ $? -eq 0 ]; then
# The PHP command succeeded
echo >&2
echo >&2 "The patch tester has been installed"
fi
# fix the configuration.php ownership
if [ "$uid" = '0' ] && [ "$(stat -c '%u:%g' configuration.php)" != "$user:$group" ]; then
# Set configuration to correct owner

View File

@ -208,6 +208,26 @@ if [[ "$1" == apache2* ]] || [ "$1" == php-fpm ]; then
echo >&2
echo >&2 "This server is now configured to run Joomla!"
# Check if smtp host exist
if [[ -n "${JOOMLA_SMTP_HOST}" && "${#JOOMLA_SMTP_HOST}" -gt 2 ]]; then
chmod +w configuration.php
sed -i "s/public \$mailer = 'mail';/public \$mailer = 'smtp';/g" configuration.php
sed -i "s/public \$smtphost = 'localhost';/public \$smtphost = '${JOOMLA_SMTP_HOST}';/g" configuration.php
sed -i "s/public \$smtpport = 25;/public \$smtpport = 1025;/g" configuration.php
chmod -w configuration.php
echo >&2
echo >&2 "This server has SMTP host set."
fi
# we install the patch tester
php cli/joomla.php extension:install --url "https://github.com/joomla-extensions/patchtester/releases/download/4.3.1/com_patchtester_4.3.1.zip"
# Check the exit status of the PHP command
if [ $? -eq 0 ]; then
# The PHP command succeeded
echo >&2
echo >&2 "The patch tester has been installed"
fi
# fix the configuration.php ownership
if [ "$uid" = '0' ] && [ "$(stat -c '%u:%g' configuration.php)" != "$user:$group" ]; then
# Set configuration to correct owner

View File

@ -208,6 +208,26 @@ if [[ "$1" == apache2* ]] || [ "$1" == php-fpm ]; then
echo >&2
echo >&2 "This server is now configured to run Joomla!"
# Check if smtp host exist
if [[ -n "${JOOMLA_SMTP_HOST}" && "${#JOOMLA_SMTP_HOST}" -gt 2 ]]; then
chmod +w configuration.php
sed -i "s/public \$mailer = 'mail';/public \$mailer = 'smtp';/g" configuration.php
sed -i "s/public \$smtphost = 'localhost';/public \$smtphost = '${JOOMLA_SMTP_HOST}';/g" configuration.php
sed -i "s/public \$smtpport = 25;/public \$smtpport = 1025;/g" configuration.php
chmod -w configuration.php
echo >&2
echo >&2 "This server has SMTP host set."
fi
# we install the patch tester
php cli/joomla.php extension:install --url "https://github.com/joomla-extensions/patchtester/releases/download/4.3.1/com_patchtester_4.3.1.zip"
# Check the exit status of the PHP command
if [ $? -eq 0 ]; then
# The PHP command succeeded
echo >&2
echo >&2 "The patch tester has been installed"
fi
# fix the configuration.php ownership
if [ "$uid" = '0' ] && [ "$(stat -c '%u:%g' configuration.php)" != "$user:$group" ]; then
# Set configuration to correct owner

View File

@ -208,6 +208,26 @@ if [[ "$1" == apache2* ]] || [ "$1" == php-fpm ]; then
echo >&2
echo >&2 "This server is now configured to run Joomla!"
# Check if smtp host exist
if [[ -n "${JOOMLA_SMTP_HOST}" && "${#JOOMLA_SMTP_HOST}" -gt 2 ]]; then
chmod +w configuration.php
sed -i "s/public \$mailer = 'mail';/public \$mailer = 'smtp';/g" configuration.php
sed -i "s/public \$smtphost = 'localhost';/public \$smtphost = '${JOOMLA_SMTP_HOST}';/g" configuration.php
sed -i "s/public \$smtpport = 25;/public \$smtpport = 1025;/g" configuration.php
chmod -w configuration.php
echo >&2
echo >&2 "This server has SMTP host set."
fi
# we install the patch tester
php cli/joomla.php extension:install --url "https://github.com/joomla-extensions/patchtester/releases/download/4.3.1/com_patchtester_4.3.1.zip"
# Check the exit status of the PHP command
if [ $? -eq 0 ]; then
# The PHP command succeeded
echo >&2
echo >&2 "The patch tester has been installed"
fi
# fix the configuration.php ownership
if [ "$uid" = '0' ] && [ "$(stat -c '%u:%g' configuration.php)" != "$user:$group" ]; then
# Set configuration to correct owner

View File

@ -208,6 +208,26 @@ if [[ "$1" == apache2* ]] || [ "$1" == php-fpm ]; then
echo >&2
echo >&2 "This server is now configured to run Joomla!"
# Check if smtp host exist
if [[ -n "${JOOMLA_SMTP_HOST}" && "${#JOOMLA_SMTP_HOST}" -gt 2 ]]; then
chmod +w configuration.php
sed -i "s/public \$mailer = 'mail';/public \$mailer = 'smtp';/g" configuration.php
sed -i "s/public \$smtphost = 'localhost';/public \$smtphost = '${JOOMLA_SMTP_HOST}';/g" configuration.php
sed -i "s/public \$smtpport = 25;/public \$smtpport = 1025;/g" configuration.php
chmod -w configuration.php
echo >&2
echo >&2 "This server has SMTP host set."
fi
# we install the patch tester
php cli/joomla.php extension:install --url "https://github.com/joomla-extensions/patchtester/releases/download/4.3.1/com_patchtester_4.3.1.zip"
# Check the exit status of the PHP command
if [ $? -eq 0 ]; then
# The PHP command succeeded
echo >&2
echo >&2 "The patch tester has been installed"
fi
# fix the configuration.php ownership
if [ "$uid" = '0' ] && [ "$(stat -c '%u:%g' configuration.php)" != "$user:$group" ]; then
# Set configuration to correct owner

View File

@ -208,6 +208,26 @@ if [[ "$1" == apache2* ]] || [ "$1" == php-fpm ]; then
echo >&2
echo >&2 "This server is now configured to run Joomla!"
# Check if smtp host exist
if [[ -n "${JOOMLA_SMTP_HOST}" && "${#JOOMLA_SMTP_HOST}" -gt 2 ]]; then
chmod +w configuration.php
sed -i "s/public \$mailer = 'mail';/public \$mailer = 'smtp';/g" configuration.php
sed -i "s/public \$smtphost = 'localhost';/public \$smtphost = '${JOOMLA_SMTP_HOST}';/g" configuration.php
sed -i "s/public \$smtpport = 25;/public \$smtpport = 1025;/g" configuration.php
chmod -w configuration.php
echo >&2
echo >&2 "This server has SMTP host set."
fi
# we install the patch tester
php cli/joomla.php extension:install --url "https://github.com/joomla-extensions/patchtester/releases/download/4.3.1/com_patchtester_4.3.1.zip"
# Check the exit status of the PHP command
if [ $? -eq 0 ]; then
# The PHP command succeeded
echo >&2
echo >&2 "The patch tester has been installed"
fi
# fix the configuration.php ownership
if [ "$uid" = '0' ] && [ "$(stat -c '%u:%g' configuration.php)" != "$user:$group" ]; then
# Set configuration to correct owner

View File

@ -208,6 +208,26 @@ if [[ "$1" == apache2* ]] || [ "$1" == php-fpm ]; then
echo >&2
echo >&2 "This server is now configured to run Joomla!"
# Check if smtp host exist
if [[ -n "${JOOMLA_SMTP_HOST}" && "${#JOOMLA_SMTP_HOST}" -gt 2 ]]; then
chmod +w configuration.php
sed -i "s/public \$mailer = 'mail';/public \$mailer = 'smtp';/g" configuration.php
sed -i "s/public \$smtphost = 'localhost';/public \$smtphost = '${JOOMLA_SMTP_HOST}';/g" configuration.php
sed -i "s/public \$smtpport = 25;/public \$smtpport = 1025;/g" configuration.php
chmod -w configuration.php
echo >&2
echo >&2 "This server has SMTP host set."
fi
# we install the patch tester
php cli/joomla.php extension:install --url "https://github.com/joomla-extensions/patchtester/releases/download/4.3.1/com_patchtester_4.3.1.zip"
# Check the exit status of the PHP command
if [ $? -eq 0 ]; then
# The PHP command succeeded
echo >&2
echo >&2 "The patch tester has been installed"
fi
# fix the configuration.php ownership
if [ "$uid" = '0' ] && [ "$(stat -c '%u:%g' configuration.php)" != "$user:$group" ]; then
# Set configuration to correct owner

View File

@ -208,6 +208,26 @@ if [[ "$1" == apache2* ]] || [ "$1" == php-fpm ]; then
echo >&2
echo >&2 "This server is now configured to run Joomla!"
# Check if smtp host exist
if [[ -n "${JOOMLA_SMTP_HOST}" && "${#JOOMLA_SMTP_HOST}" -gt 2 ]]; then
chmod +w configuration.php
sed -i "s/public \$mailer = 'mail';/public \$mailer = 'smtp';/g" configuration.php
sed -i "s/public \$smtphost = 'localhost';/public \$smtphost = '${JOOMLA_SMTP_HOST}';/g" configuration.php
sed -i "s/public \$smtpport = 25;/public \$smtpport = 1025;/g" configuration.php
chmod -w configuration.php
echo >&2
echo >&2 "This server has SMTP host set."
fi
# we install the patch tester
php cli/joomla.php extension:install --url "https://github.com/joomla-extensions/patchtester/releases/download/4.3.1/com_patchtester_4.3.1.zip"
# Check the exit status of the PHP command
if [ $? -eq 0 ]; then
# The PHP command succeeded
echo >&2
echo >&2 "The patch tester has been installed"
fi
# fix the configuration.php ownership
if [ "$uid" = '0' ] && [ "$(stat -c '%u:%g' configuration.php)" != "$user:$group" ]; then
# Set configuration to correct owner

View File

@ -208,6 +208,26 @@ if [[ "$1" == apache2* ]] || [ "$1" == php-fpm ]; then
echo >&2
echo >&2 "This server is now configured to run Joomla!"
# Check if smtp host exist
if [[ -n "${JOOMLA_SMTP_HOST}" && "${#JOOMLA_SMTP_HOST}" -gt 2 ]]; then
chmod +w configuration.php
sed -i "s/public \$mailer = 'mail';/public \$mailer = 'smtp';/g" configuration.php
sed -i "s/public \$smtphost = 'localhost';/public \$smtphost = '${JOOMLA_SMTP_HOST}';/g" configuration.php
sed -i "s/public \$smtpport = 25;/public \$smtpport = 1025;/g" configuration.php
chmod -w configuration.php
echo >&2
echo >&2 "This server has SMTP host set."
fi
# we install the patch tester
php cli/joomla.php extension:install --url "https://github.com/joomla-extensions/patchtester/releases/download/4.3.1/com_patchtester_4.3.1.zip"
# Check the exit status of the PHP command
if [ $? -eq 0 ]; then
# The PHP command succeeded
echo >&2
echo >&2 "The patch tester has been installed"
fi
# fix the configuration.php ownership
if [ "$uid" = '0' ] && [ "$(stat -c '%u:%g' configuration.php)" != "$user:$group" ]; then
# Set configuration to correct owner

View File

@ -208,6 +208,26 @@ if [[ "$1" == apache2* ]] || [ "$1" == php-fpm ]; then
echo >&2
echo >&2 "This server is now configured to run Joomla!"
# Check if smtp host exist
if [[ -n "${JOOMLA_SMTP_HOST}" && "${#JOOMLA_SMTP_HOST}" -gt 2 ]]; then
chmod +w configuration.php
sed -i "s/public \$mailer = 'mail';/public \$mailer = 'smtp';/g" configuration.php
sed -i "s/public \$smtphost = 'localhost';/public \$smtphost = '${JOOMLA_SMTP_HOST}';/g" configuration.php
sed -i "s/public \$smtpport = 25;/public \$smtpport = 1025;/g" configuration.php
chmod -w configuration.php
echo >&2
echo >&2 "This server has SMTP host set."
fi
# we install the patch tester
php cli/joomla.php extension:install --url "https://github.com/joomla-extensions/patchtester/releases/download/4.3.1/com_patchtester_4.3.1.zip"
# Check the exit status of the PHP command
if [ $? -eq 0 ]; then
# The PHP command succeeded
echo >&2
echo >&2 "The patch tester has been installed"
fi
# fix the configuration.php ownership
if [ "$uid" = '0' ] && [ "$(stat -c '%u:%g' configuration.php)" != "$user:$group" ]; then
# Set configuration to correct owner

View File

@ -208,6 +208,26 @@ if [[ "$1" == apache2* ]] || [ "$1" == php-fpm ]; then
echo >&2
echo >&2 "This server is now configured to run Joomla!"
# Check if smtp host exist
if [[ -n "${JOOMLA_SMTP_HOST}" && "${#JOOMLA_SMTP_HOST}" -gt 2 ]]; then
chmod +w configuration.php
sed -i "s/public \$mailer = 'mail';/public \$mailer = 'smtp';/g" configuration.php
sed -i "s/public \$smtphost = 'localhost';/public \$smtphost = '${JOOMLA_SMTP_HOST}';/g" configuration.php
sed -i "s/public \$smtpport = 25;/public \$smtpport = 1025;/g" configuration.php
chmod -w configuration.php
echo >&2
echo >&2 "This server has SMTP host set."
fi
# we install the patch tester
php cli/joomla.php extension:install --url "https://github.com/joomla-extensions/patchtester/releases/download/4.3.1/com_patchtester_4.3.1.zip"
# Check the exit status of the PHP command
if [ $? -eq 0 ]; then
# The PHP command succeeded
echo >&2
echo >&2 "The patch tester has been installed"
fi
# fix the configuration.php ownership
if [ "$uid" = '0' ] && [ "$(stat -c '%u:%g' configuration.php)" != "$user:$group" ]; then
# Set configuration to correct owner

View File

@ -208,6 +208,26 @@ if [[ "$1" == apache2* ]] || [ "$1" == php-fpm ]; then
echo >&2
echo >&2 "This server is now configured to run Joomla!"
# Check if smtp host exist
if [[ -n "${JOOMLA_SMTP_HOST}" && "${#JOOMLA_SMTP_HOST}" -gt 2 ]]; then
chmod +w configuration.php
sed -i "s/public \$mailer = 'mail';/public \$mailer = 'smtp';/g" configuration.php
sed -i "s/public \$smtphost = 'localhost';/public \$smtphost = '${JOOMLA_SMTP_HOST}';/g" configuration.php
sed -i "s/public \$smtpport = 25;/public \$smtpport = 1025;/g" configuration.php
chmod -w configuration.php
echo >&2
echo >&2 "This server has SMTP host set."
fi
# we install the patch tester
php cli/joomla.php extension:install --url "https://github.com/joomla-extensions/patchtester/releases/download/4.3.1/com_patchtester_4.3.1.zip"
# Check the exit status of the PHP command
if [ $? -eq 0 ]; then
# The PHP command succeeded
echo >&2
echo >&2 "The patch tester has been installed"
fi
# fix the configuration.php ownership
if [ "$uid" = '0' ] && [ "$(stat -c '%u:%g' configuration.php)" != "$user:$group" ]; then
# Set configuration to correct owner

View File

@ -208,6 +208,26 @@ if [[ "$1" == apache2* ]] || [ "$1" == php-fpm ]; then
echo >&2
echo >&2 "This server is now configured to run Joomla!"
# Check if smtp host exist
if [[ -n "${JOOMLA_SMTP_HOST}" && "${#JOOMLA_SMTP_HOST}" -gt 2 ]]; then
chmod +w configuration.php
sed -i "s/public \$mailer = 'mail';/public \$mailer = 'smtp';/g" configuration.php
sed -i "s/public \$smtphost = 'localhost';/public \$smtphost = '${JOOMLA_SMTP_HOST}';/g" configuration.php
sed -i "s/public \$smtpport = 25;/public \$smtpport = 1025;/g" configuration.php
chmod -w configuration.php
echo >&2
echo >&2 "This server has SMTP host set."
fi
# we install the patch tester
php cli/joomla.php extension:install --url "https://github.com/joomla-extensions/patchtester/releases/download/4.3.1/com_patchtester_4.3.1.zip"
# Check the exit status of the PHP command
if [ $? -eq 0 ]; then
# The PHP command succeeded
echo >&2
echo >&2 "The patch tester has been installed"
fi
# fix the configuration.php ownership
if [ "$uid" = '0' ] && [ "$(stat -c '%u:%g' configuration.php)" != "$user:$group" ]; then
# Set configuration to correct owner

266
README.md
View File

@ -1,118 +1,176 @@
# About this Repo
# Joomla! Octoleo Docker Image
This is the Git repo of the Docker [official image](https://docs.docker.com/docker-hub/official_repos/) for [joomla](https://registry.hub.docker.com/_/joomla/). See [the Docker Hub page](https://registry.hub.docker.com/_/joomla/) for the full readme on how to use this Docker image and for information regarding contributing and issues.
Welcome to the Joomla! Octoleo project, where we provide Docker images tailored for Joomla! enthusiasts and developers. These images are curated by @llewellynvdm and function as a playground for innovating and testing ideas that could eventually enhance the [official Joomla-Docker](https://github.com/joomla-docker/docker-joomla) images. While these images are experimental and not intended for production use, your feedback and contributions are highly valued.
The full readme is generated over in [docker-library/docs](https://github.com/docker-library/docs), specifically in [docker-library/docs/joomla](https://github.com/docker-library/docs/tree/master/joomla).
[![Docker Pulls](https://img.shields.io/docker/pulls/llewellyn/joomla.svg)](https://hub.docker.com/r/llewellyn/joomla)
See a change merged here that doesn't show up on the Docker Hub yet? Check [the "library/joomla" manifest file in the docker-library/official-images repo](https://github.com/docker-library/official-images/blob/master/library/joomla), especially [PRs with the "library/joomla" label on that repo](https://github.com/docker-library/official-images/labels/library%2Fjoomla). For more information about the official images process, see the [docker-library/official-images readme](https://github.com/docker-library/official-images/blob/master/README.md).
[![Joomla Logo](https://avatars.githubusercontent.com/u/69416061?s=200&v=4)](https://hub.docker.com/r/llewellyn/joomla)
---
### Build Status Badges Per Arch
## Quick Start
| [![GitHub CI build status badge](https://github.com/joomla-docker/docker-joomla/workflows/GitHub%20CI/badge.svg)](https://github.com/joomla-docker/docker-joomla/actions?query=workflow%3A%22GitHub+CI%22) | [![amd64 build status badge](https://img.shields.io/jenkins/s/https/doi-janky.infosiftr.net/job/multiarch/job/amd64/job/joomla.svg?label=amd64)](https://doi-janky.infosiftr.net/job/multiarch/job/amd64/job/joomla) | [![arm32v5 build status badge](https://img.shields.io/jenkins/s/https/doi-janky.infosiftr.net/job/multiarch/job/arm32v5/job/joomla.svg?label=arm32v5)](https://doi-janky.infosiftr.net/job/multiarch/job/arm32v5/job/joomla) | [![i386 build status badge](https://img.shields.io/jenkins/s/https/doi-janky.infosiftr.net/job/multiarch/job/i386/job/joomla.svg?label=i386)](https://doi-janky.infosiftr.net/job/multiarch/job/i386/job/joomla) |
| --- | --- | --- | --- |
| [![arm32v6 build status badge](https://img.shields.io/jenkins/s/https/doi-janky.infosiftr.net/job/multiarch/job/arm32v6/job/joomla.svg?label=arm32v6)](https://doi-janky.infosiftr.net/job/multiarch/job/arm32v6/job/joomla) | [![arm32v7 build status badge](https://img.shields.io/jenkins/s/https/doi-janky.infosiftr.net/job/multiarch/job/arm32v7/job/joomla.svg?label=arm32v7)](https://doi-janky.infosiftr.net/job/multiarch/job/arm32v7/job/joomla) | [![arm64v8 build status badge](https://img.shields.io/jenkins/s/https/doi-janky.infosiftr.net/job/multiarch/job/arm64v8/job/joomla.svg?label=arm64v8)](https://doi-janky.infosiftr.net/job/multiarch/job/arm64v8/job/joomla) | [![mips64le build status badge](https://img.shields.io/jenkins/s/https/doi-janky.infosiftr.net/job/multiarch/job/mips64le/job/joomla.svg?label=mips64le)](https://doi-janky.infosiftr.net/job/multiarch/job/mips64le/job/joomla) |
| [![ppc64le build status badge](https://img.shields.io/jenkins/s/https/doi-janky.infosiftr.net/job/multiarch/job/ppc64le/job/joomla.svg?label=ppc64le)](https://doi-janky.infosiftr.net/job/multiarch/job/ppc64le/job/joomla) | [![s390x build status badge](https://img.shields.io/jenkins/s/https/doi-janky.infosiftr.net/job/multiarch/job/s390x/job/joomla.svg?label=s390x)](https://doi-janky.infosiftr.net/job/multiarch/job/s390x/job/joomla) | |
To get started, ensure you have [Docker Compose](https://docs.docker.com/compose/install/) installed.
[See OS/ARCH](https://registry.hub.docker.com/_/joomla/?tab=tags) on official images.
### Setting Up Traefik as a Reverse Proxy
---
## How to update the official docker-library/official-images repo
We recommend using [Traefik](https://doc.traefik.io/traefik/) for reverse proxying. Create a `docker-compose.yml` file for Traefik in a directory like `/home/username/Docker/traefik`.
### First update the git repository (basic steps)
- Fork [this repository](https://github.com/joomla-docker/docker-joomla).
- Clone your forked repository to your local PC and change to the staging branch.
```shell
$ git clone git@github.com:your-name/docker-joomla.git
$ cd docker-joomla
$ git checkout staging
```
- Open the [versions-helper.json](https://github.com/joomla-docker/docker-joomla/blob/staging/versions-helper.json) file **if this is a version update**.
- Update the full version number on line [3](https://github.com/joomla-docker/docker-joomla/blob/0dd714aae69dd103e72ae519d4638b71da7c5e4f/versions-helper.json#L3) and [32](https://github.com/joomla-docker/docker-joomla/blob/0dd714aae69dd103e72ae519d4638b71da7c5e4f/versions-helper.json#L32) _(example)_.
- Run the [update.sh](https://github.com/joomla-docker/docker-joomla/blob/staging/update.sh) script once.
```shell
$ sudo chmod +x update.sh
$ ./update.sh
```
- **OR** make what ever changes you think will improve the images
- Make a commit message with **every change**.
```shell
$ git commit -am"Update images of Joomla! x.x.x to x.x.x"
```
- Push the changes to your repository.
```shell
$ git push origin staging
```
- Make a pull request against the staging branch.
- **Done!**
Here's a basic Traefik configuration:
### Maintainers must then do the following
- Continue only if all checks are passed with [du-diligence](https://en.wikipedia.org/wiki/Due_diligence)
- Merge the pull request into staging
- Merge the staging branch into the master branch
- Again continue only if all checks are passed with [du-diligence](https://en.wikipedia.org/wiki/Due_diligence)
- Clone the master branch of [this repository](https://github.com/joomla-docker/docker-joomla/tree/master) to your PC and change to the master branch.
```shell
$ git clone git@github.com:joomla-docker/docker-joomla.git
$ cd docker-joomla
$ git checkout master
```
- Run the [generate-stackbrew-library.sh](https://github.com/joomla-docker/docker-joomla/blob/staging/generate-stackbrew-library.sh).
```shell
$ sudo chmod +x generate-stackbrew-library.sh
$ ./generate-stackbrew-library.sh
```
- This will give an output of all the new values needed in the official images (validate the output)
- _The easy way to move this output of this file to the official images can be done in the following way._
- Open the [forked official-images](https://github.com/joomla-docker/official-images) and click on the **Fetch Upstream** button.
- Then click on **Fetch and Merge** while being in the master branch.
- Clone the master branch of [this repository](https://github.com/joomla-docker/official-images/tree/master) to your PC.
```shell
$ git clone git@github.com:joomla-docker/official-images.git
$ cd official-images
$ git checkout master
```
- Create a new branch called **joomla**
```shell
$ git checkout -b joomla
```
- At this point you should have two directories **docker-joomla** and **official-images**
- **Preferably** in the _same directory_ so you can do the following.
- Change back to the **docker-joomla** repository.
```shell
$ cd ../docker-joomla
```
- Run the following command, targeting the Joomla library file in the **official-images** directory with the output:
```shell
$ ./generate-stackbrew-library.sh > ../official-images/library/joomla
```
- Change again to the **official-images** repository.
```shell
$ cd ../official-images
```
- Make a commit that will best reflect a summary of the changes.
```shell
$ git commit -am"Update Joomla!"
```
- Push the changes to up our _**forked official-images**_
```shell
$ git push -u origin joomla
```yml
version: "3.3"
services:
traefik:
container_name: traefik
image: "traefik:latest"
command:
- --entrypoints.web.address=:80
- --entrypoints.websecure.address=:443
- --providers.docker
- --log.level=ERROR
- --certificatesresolvers.octoleoresolver.acme.httpchallenge=true
- --certificatesresolvers.octoleoresolver.acme.email=joomla@yourdomain.com
- --certificatesresolvers.octoleoresolver.acme.storage=/acme.json
- --certificatesresolvers.octoleoresolver.acme.httpchallenge.entrypoint=web
- --providers.file.directory=/conf
- --providers.file.watch=true
ports:
- "80:80"
- "443:443"
volumes:
- "/var/run/docker.sock:/var/run/docker.sock:ro"
- "/home/username/Docker/traefik/conf:/conf"
- "/home/username/Docker/traefik/acme.json:/acme.json"
labels:
- "traefik.http.routers.http-catchall.rule=hostregexp(`{host:.+}`)"
- "traefik.http.routers.http-catchall.entrypoints=web"
- "traefik.http.routers.http-catchall.middlewares=redirect-to-https"
- "traefik.http.middlewares.redirect-to-https.redirectscheme.scheme=https"
networks:
- traefik
networks:
traefik:
external:
name: traefik_webgateway
```
### Official Images About to Update
- Open a pull request from our _**forked official-images**_ to [official-images](https://github.com/docker-library/official-images).
- Use the following convention in the message, [check past](https://github.com/docker-library/official-images/pull/10902) to see convention.
```txt
Changes:
Deploy Traefik using:
- joomla-docker/docker-joomla@54a82e4: Update images of Joomla! 4.0.2 to 4.0.3
- joomla-docker/docker-joomla@f87bc00: Update version of Joomla! 4.0.2 to 4.0.3
- joomla-docker/docker-joomla@f36a82a: Update images of Joomla! 3.10.1 to 3.10.2
- joomla-docker/docker-joomla@4bc3c7b: Update version of Joomla! 3.10.1 to 3.10.2
```shell
cd /home/username/Docker/traefik
docker network create traefik_webgateway
docker-compose up -d
```
- Basically denoting each commit to [our master branch](https://github.com/joomla-docker/docker-joomla/tree/master) since the last update to the official images.
- Once this is done, the maintainers of the [official Docker images](https://github.com/docker-library/official-images) takes over.
- Should there be any issue which you can't resolve, reach out to the [other maintainers](https://github.com/joomla-docker/docker-joomla/graphs/contributors).
- Done!
> The [current maintainers](https://github.com/joomla-docker/docker-joomla/blob/master/maintainers.json) of the official images. Let us know if you have any questions.
### Deploying Joomla
Choose the Joomla! Docker image version you need. Available tags include:
- `llewellyn/joomla:latest`
- `llewellyn/joomla:x.x`
- `llewellyn/joomla:x.x-phpx.x`
- `llewellyn/joomla:x.x-phpx.x-variant`
Find all tags here: [Docker Hub Tags](https://hub.docker.com/r/llewellyn/joomla/tags)
For Joomla setup, create a `docker-compose.yml` file in `/home/username/Docker/websitename`.
Example Joomla setup:
```yml
version: '3.3'
services:
mariadb_websitename:
image: mariadb:latest
container_name: mariadb_websitename
restart: unless-stopped
environment:
MARIADB_USER: octoleo
MARIADB_DATABASE: octoleo
MARIADB_PASSWORD: your_password_here
MARIADB_ROOT_PASSWORD: your_root_password_here
volumes:
- '/home/username/Projects/websitename/db:/var/lib/mysql'
networks:
- traefik
joomla_websitename:
image: llewellyn/joomla:latest
container_name: joomla_websitename
restart: unless-stopped
environment:
JOOMLA_SITE_NAME: Octoleo
JOOMLA_ADMIN_USER: Octoleo
JOOMLA_ADMIN_USERNAME: octoleo
JOOMLA_ADMIN_PASSWORD: your_password_here
JOOMLA_ADMIN_EMAIL: docker@octoleo.org
JOOMLA_DB_HOST: mariadb_websitename:3306
JOOMLA_DB_USER: octoleo
JOOMLA_DB_NAME: octoleo
JOOMLA_DB_PASSWORD: your_password_here
depends_on:
- mariadb_websitename
volumes:
- '/home/username/Projects/websitename/website:/var/www/html'
networks:
- traefik
labels:
- "traefik.enable=true"
- "traefik.http.routers.joomla_websitename.rule=Host(`octoleo.yourdomain.com`)"
- "traefik.http.routers.joomla_websitename.entrypoints=websecure"
- "traefik.http.services.joomla_websitename.loadbalancer.server.port=80"
- "traefik.http.routers.joomla_websitename.service=joomla_websitename"
- "traefik.http.routers.joomla_websitename.tls.certresolver=octoleoresolver"
phpmyadmin_websitename:
image: phpmyadmin/phpmyadmin
container_name: phpmyadmin_websitename
restart: unless-stopped
environment:
PMA_HOST: mariadb_websitename
PMA_PORT: 3306
UPLOAD_LIMIT: 300M
depends_on:
- mariadb_websitename
networks:
- traefik
labels:
- "traefik.enable=true"
- "traefik.http.routers.phpmyadmin_websitename.rule=Host(`octoleo-db.yourdomain.com`)"
- "traefik.http.routers.phpmyadmin_websitename.entrypoints=websecure"
- "traefik.http.services.phpmyadmin_websitename.loadbalancer.server.port=80"
- "traefik.http.routers.phpmyadmin_websitename.service=phpmyadmin_websitename"
- "traefik.http.routers.phpmyadmin_websitename.tls.certresolver=octoleoresolver"
networks:
traefik:
external:
name: traefik_webgateway
```
Deploy Joomla using:
```shell
cd /home/username/Docker/websitename
docker-compose up -d
```
## Usage Scenarios
This setup is ideal for running multiple Joomla instances on the same server. It simplifies access and configuration, especially when paired with a domain service like [Cloudflare](https://cloudflare.com/).
- Use Cloudflare to point your domain to your server.
- Organize your server with two main directories: **Docker** for Docker Compose files and **Projects** for project-related files.
Configure Traefik once, and then add as many Joomla containers as needed. Access your Joomla site through your domain, secured with SSL.
Enjoy experimenting with Joomla on Docker!
### License
```
Copyright (C) 2021 Llewellyn van der Merwe. All rights reserved.
Licensed under the GNU General Public License version 2 or later; see LICENSE.txt
```

View File

@ -208,6 +208,26 @@ if [[ "$1" == apache2* ]] || [ "$1" == php-fpm ]; then
echo >&2
echo >&2 "This server is now configured to run Joomla!"
# Check if smtp host exist
if [[ -n "${JOOMLA_SMTP_HOST}" && "${#JOOMLA_SMTP_HOST}" -gt 2 ]]; then
chmod +w configuration.php
sed -i "s/public \$mailer = 'mail';/public \$mailer = 'smtp';/g" configuration.php
sed -i "s/public \$smtphost = 'localhost';/public \$smtphost = '${JOOMLA_SMTP_HOST}';/g" configuration.php
sed -i "s/public \$smtpport = 25;/public \$smtpport = 1025;/g" configuration.php
chmod -w configuration.php
echo >&2
echo >&2 "This server has SMTP host set."
fi
# we install the patch tester
php cli/joomla.php extension:install --url "https://github.com/joomla-extensions/patchtester/releases/download/4.3.1/com_patchtester_4.3.1.zip"
# Check the exit status of the PHP command
if [ $? -eq 0 ]; then
# The PHP command succeeded
echo >&2
echo >&2 "The patch tester has been installed"
fi
# fix the configuration.php ownership
if [ "$uid" = '0' ] && [ "$(stat -c '%u:%g' configuration.php)" != "$user:$group" ]; then
# Set configuration to correct owner