On beneluxlaan.com I used to have a nice website, but is down for quite some while.
Now that I have an extra server at home, lets host the website there, repair it, and use cloudflare to tunnel the traffic to the site itself.
In order to setup cloudflare, I added the beneluxlaan.com domain:


In order to start fresh, I deleted all the DNS records. Later one CNAME will be added by creating a pulic hostname in Zero Trust configuration
Next, an update of my beneluxlaan.com nameservers is required

And now, we wait…

In the mean while, we can download (from my old server) the backup of beneluxlaan.com and transfer it to the new ubuntu machine







30 minutes later

Add it in zero trust

Then the site resolved…. an error

Manually update the site:
- Deleting wp-admin and wp-includes directory
- Upload the new files via scp

This is getting innoing. Now it redirects (301) to the www subdomain

Lets modify some database settings

After chaning the sitename from http://www.beneluxlaan.com to https://beneluxlaan.com, the admin page worked

Okay, but it still doesnt work. The debug.log states

Making some quick changes to the header.php file, it now displays a webpage… but…. it looks crap

But that is a fix for later….
New installation with default https enabled
So the first installation, from a backup, didn’t go that well
The new installation didn’t get any easier, during installation there was a http/https mixed content error

By adding some lines to the wp-config.php file, at least the installation was going well.
define('FORCE_SSL_ADMIN', true);
if ($_SERVER['HTTP_X_FORWARDED_PROTO'] == 'https') {
$_SERVER['HTTPS'] = 'on';
}


Okay, okay, new option, restore backup and use php version with php-fpm
After a default restore of the environment, we get this error

To solve this, there is an option to have multiple php version on the same server
By editing the options.conf file in /usr/local/directadmin

After a rebuild of php, via the command ./build php, the DirectAdmin interface gives an option per domain to supply the php version

And yups, it works (locally)
