TLDR: The Answer is at the bottom.
Well, this has been interesting.
So, The original plan was to Migrate everything over a new Server. I attempted to use MySQL8 as the Main Database, but trying to convert MariaDB over to MySQL8, it was nothing but headaches.
Migrating was causing the server to crash and I couldn't figure out why? Well, it turns out, when I was transferring the Database, that would cause the whole server to crash... Well, trying to figure out, why? I couldn't.
The only thing that was really demanding MySQL was Ghost..... So... I continued with MariaDB which migrating from Maria to Maria was so less Painless.
Well, after starting the server move, I got everything but the email server working so. All Websites have been moved successfully, but, email is still handled on the old server.
I've cut it back, stopped Nginx, PHP, Ghost and they all live on this new home now.
Just have to figure out the Configs to get it up and running.
So, Let's talk about running MariaDB and MySQL8 Together.
I compiled it from scratch this time, I needed to move away from MySQL defaults as, I still had MariaDB as my main Database.
There is plenty of help available online to compile MySQL, I found this page very useful...
Right, so, you've gone and got MariaDB and MySQL8 running side by side.
3306 = MariaDB
3307 = MySQL8
So, why did I do all of this?!
This annoying little red text....
I mean, I ignore the other warning..
System checks failed with message: 'Linux version is not Ubuntu 16, 18, 20, or 22'
Some features of Ghost-CLI may not work without additional configuration.
For local installs we recommend using ghost install local
instead.
? Continue anyway? (y/N)
I love the fact is they just allow you to Continue Anyway. I mean, I've been running Debian on my servers for so long, it's just, what I turn too. Plus, Ubuntu is built off of Debian so, who can't say they didn't pick a Winner?!
I digress, so.. The real answer?
How do you get your ghost install to use a MySQL server on another port.
I searched and the only answer someone provided was, MariaDB is a drop in replacement for MySQL so, just ignore the warning and use MariaDB..
I didn't find that answer to my liking and I'd spent a good few hours tinkering with MySQL to get it to install and work side by side.
"database": {
"client": "mysql",
"connection": {
"host": "127.0.0.1",
"port": "3307",
"user": "ghost_l0p",
"password": "***",
"database": "ghost_l0p"
Just underneath your "host", shove the "port" and which ever port you installed MySQL8 on, enjoy!
Be Warned, if you leave the client at "mysql2", Ghost will moan that the database isn't supported, just change the client to "mysql", oh, this works with MariaDB, it won't warn you on the command line, but the "About Ghost" will!
Might be useful to people hosting their database on other machines as well, just incase that firewall gets a bit.... Protective!
If you skipped to the bottom, that's fine. I won't curse or blame you. The answer you seek, ^^ Just a little up.