HI,

I need to run up a couple of turnkey instances of Joomla3 to help a friend in hosting a couple of sites for a while.

I need Joomla 3 and PHP 7.4 ideally so I don't have to go through any site upgrading.

Also I'm pretty new to turnkey and linux to be honest, and was trying to run the Joomla3 lxc on a proxmox host I have which went really well until I realised ver 16.1 of the template only had PHP 7.3.

After trying to upgrade it to PHP 7.4 and failing, I tried to make a 17.1 iso following the "How to build your own appliance" guide

https://www.turnkeylinux.org/docs/howto-build-isos-with-tkldev

I managed to make the core iso, but it's failing when I try to make a Joomla 3 build

https://github.com/turnkeylinux-apps/joomla3.git

This first threw an error about --disable-ssl not being an available option in bright red.

So I removed this switch from conf.d/main

Now I'm getting the error below:

+ a2dissite 000-default
Site 000-default disabled.
To activate the new configuration, you need to run:
  systemctl reload apache2
+ a2ensite joomla
ERROR: Site joomla not properly enabled: /etc/apache2/sites-enabled/joomla.conf is a real file, not touching it
make: *** [/usr/share/fab/product.mk:569: build/stamps/root.patched] Error 1

 

I'm pretty much out of my depth now... lol

Appreciate any help with this 

  

Forum: 
Jeremy Davis's picture

I just looked at Joomal3 today actually. The buildcode was updated a while ago, but when I went to build it, I got the same failure (--disable-ssl not an available option). The dev that worked on it has seen my report and will hopefully look into it tomorrow (fingers crossed).

If not, I'll try to have a quick look myself. If I have time, I might even have a quick look today.

Actually though, the second error you note is interesting! It says that "/etc/apache2/sites-enabled/joomla.conf is a real file"! It shouldn't be!? My guess is that you created that (perhaps unintentionally?). So if you wanted to persevere, I suggest first cleaning everything:

cd joomla3
make clean

Then double check that there is no overlay/etc/apache2/sites-enabled directory:

ls overlay/etc/apache2/sites-enabled

If everything is as it should be, that should give an error message. Something like "ls: cannot access 'overlay/etc/apache2/sites-enabled': No such file or directory". Then retry:

make

If that still fails, please share the output of:

git diff

And also please share the last 20-30 lines of the "make" output and I'll help out as best I can. In the meantime, I'll report back if/when I've had a look at it.

Worst case scenario, you could just install Joomla3 manually on our LAMP appliance?

I might have to continue tomorrow but here are the last 20 odd lines from the "make" output

 

7 package suggestions were added by new dependencies, use `composer suggest` to see details.
Generating autoload files
11 packages you are using are looking for funding.
Use the `composer fund` command to find out more!
No security vulnerability advisories found
+ ln -s /usr/local/lib/composer/vendor/bin/joomla /usr/local/bin/joomla
+ service mysql start
Starting MariaDB database server: mariadbd.
+ mysqladmin create sites_joomla
+ mysql --batch --execute 'grant all privileges on sites_joomla.* to joomla@localhost identified by '\''2bb4f8008d1bfc7a8c2e041340384c73'\''; flush privileges;'
+ joomla site:create joomla --release=3.10.8 --www /var/www -L joomla:2bb4f8008d1bfc7a8c2e041340384c73 --skip-create-statement
Downloading https://github.com/joomla/joomla-cms/archive/3.10.8.tar.gz - this could take a few minutes ..
Your new Joomla site has been created.
It was installed using the domain name joomla.test.
You can login using the following username and password combination: admin/admin.
+ a2dissite 000-default
Site 000-default disabled.
To activate the new configuration, you need to run:
  systemctl reload apache2
+ a2ensite joomla
ERROR: Site joomla not properly enabled: /etc/apache2/sites-enabled/joomla.conf is a real file, not touching it
make: *** [/usr/share/fab/product.mk:569: build/stamps/root.patched] Error 1

 

Thanks again for your help, much appreciated (apologies for the dump of text, not sure how to tag the code?)

<code>test<code\>

Jeremy Davis's picture

Yeah that Apache error is a weird one. I see now that it was nothing you were doing, it seems to be the Joomla CLI tool we're using?! Anyway, I'm pretty sure I've fixed it. I also bumped the Joomla3 version to latest current stable (3.10.11).

It's not yet merged into the turnkey repo on GitHub and it may be a day or so before it is. So you'll need to pull from my fork of the code. If you understand what I'm saying, then great and I'm probably about to over explain it. If you don't have a clue what I mean, don't worry, I'll spell it out! :)

So in your TKLDev terminal, make sure that you're in the joomla buildcode dir and add my GitHub account to your local repo as a "remote":

cd joomla3
git remote add jeremy https://github.com/JedMeister/joomla3.git

Then pull my latest changes and check them out. I'm guessing that you may have some uncommitted changes locally. Probably the easiest way to get them out of the way (so you don't get conflicts with my changes) is to "stash them" first:

git stash
git fetch jeremy
git checkout final-tweaks

Now you should be good to go:

make clean
make

If you want to get back your stashed changes, try this:

git checkout master
git stash pop

Thanks Jeremy,

 

I ran through your process and made an iso for Joomla3!!

Also, I really did need the git pull help so appreciate you setting that out for me :)

From here I will continue with the last parts of the build process, renaming and downloading the iso.

I'll feedback how successful the Turnkey iso of Joomlla3 is, hopefully with PHP 7.4.. lol

 

Again, thankyou so much for your speedy help. Its been much appreciated!

Jeremy Davis's picture

You're most welcome - and thanks for your help too! :)

I got the first sites files and DB copied over and have the site working now.

Had to search a bit to get info on where to load everything to. Bit of trial and error with thanks to Proxmox snapshots!!

I ended up overwriting the /var/www/joomla folder with the site files and restoring the DB using the cli commands from an earlier reply of yours Jeremy. I just couldn't get the import working through adminer, but that might have been due to the initial size of the VM I created not having enough space...

Adminer - import database unavailable | TurnKey GNU/Linux (turnkeylinux.org)

mysql -u root db_name < /path/to/file.sql

This was after creating the Database with the same name from within Adminer and the same user with privelages to that database as referenced in the sites configuration.php file.

So, the first site is working well enough now that it can be used until my friend sorts out their hosting mess.

Thanks again Jeremy for your help with all of this!

Jeremy Davis's picture

Glad to hear that you worked around the Adminer issue. I must agree that it's a missing feature that I imagine would be very useful. I'm a CLI guy myself, but I totally get that sometimes it's easier to just click stuff! :)

I wonder if there is a plugin or a config setting that we've overlooked to support that functionality? Or perhaps there is a bug in our setup and/or theme and it's just not showing?

I'll need to look into that when I get a chance...

Anyway, glad you're up and running. Happy to help.

I'm having some weird 'split brain' issues with the website I moved to the Turnkey Joomla appliance.

It's been quite a while since I've done any website stuff like this...

The website works internally when browsed to it's local private IP address (Turnkey IP address)

But when browsed externally it seems to have a lot of content stripped out.

I have it accessible behind HAproxy (OPNSense) alongside two other personal sites.

My assumption is that HAproxy is doing something weird, but I wanted to confirm I have put everything into the right place with respect to site and DB?

 

To migrate and install I:

Backed up the site files within Public_html to zip and the MYSQL database to a .sql file.

Created a new empty DB with the same name as the original (as seen within configuration.php) using Adminer

Created a new DB user with the same name and password (as seen within configuration.php)

Imported the DB using CLI

mysql -u root db_name < /path/to/file.sql

Assigned Privelages to the DB

Copied files over to the site using WINSCP  to the folder /var/www/jooomla/ overwiriting where required

Started up the site and it seems to work OK but have the experience as stated above.

 

Thanks for any advice on this

 

Sorry it was an error in the configuration.php file that existed in the original setup.

the live site was set as http:// whereas it should now be https://

 

 

 

Jeremy Davis's picture

Nice work hunting it down. I was going to suggest something like that. FWIW, looking in the browser "dev tools" will often point you in the right direction with issues like that. E.g. in this case it probably would have been showing an error about "mixed content" or similar (i.e. some stuff being served via http on a https page).

Add new comment