freezingsaddles / freezing-compose

The Docker Compose structure for running the application suite.
4 stars 2 forks source link

add wordpress site for register.freezingsaddles.org #16

Open obscurerichard opened 4 years ago

obscurerichard commented 4 years ago

It would be valuable to have the WordPress registration site hosted on the freezingsaddles.org domain - we can secure it with SSL via LetsEncrypt easily, and it would let us do more direct integration with the database of registrants eventually.

It's possible to run WordPress via Docker and Docker Compose. The current registration site. http://s94971567.onlinehome.us , administered by Carol C., uses Updraft Plus as a backup solution. I did a proof of concept migration of this in November, 2021.

To do this I installed Wordpress via Docker (see #19 ) and then attempted to do a restoration of backups. I first tried to use the https://wordpress.org/plugins/all-in-one-wp-migration/ plugin, but I could not get it to restore, so I did a second pass of restoration using the Updraft Plus backup plugin, where I restored the backups from Dropbox from the other site. I edited the database backup file to replace http://s94971567.onlinehome.us with https://register.freezingsaddles.org and then put the backup files in place in /opt/compose/wordpress/wp-content/updraft, and I was able to do a restoration. Without editing the database files the Updraft restore complained that this was a migration not a restore and I had to get a premium license. No thanks!

The resulting installation had Ninja Forms in place and looks like it is at least partially functioning. To prevent confusion, I disabled automatic backups on the register.freezingsaddles.org site since it looks like the restore put the configuration of Updraft Plus that includes the Dropbox token into place.

There were some issues though that we would need to resolve before making a switch:

Carol investigated and expanded on the list:

In general, it seems to be working well—thanks for all your work on this! It will need a few tweaks before it is ready for use. Given that you’re dealing with a much more serious issue right now (getting the site to read the Strava data), and we won’t be using the new site this year anyway, we can defer action on these. However, just noting for later:

MailPoet requires PDO MYSQL PHP Extension

_MailPoet Error: MailPoet requires a PDO_MYSQL PHP extension. Please read our instructions on how to resolve this issue_. We should probably use a Dockerfile and docker-compose to do this.

WordFence .htaccess fixes

WordFence is complaining:

To make your site as secure as possible, take a moment to optimize the Wordfence Web Application Firewall: https://register.freezingsaddles.org/wp-admin/admin.php?page=WordfenceWAF&subpage=waf_options#configureAutoPrepend

image

Changes to .htaccess and wp-config.php

I used the advice in https://help.servmask.com/2018/10/27/how-to-increase-maximum-upload-file-size-in-wordpress/ to increase the maximum upload file size and processing times. Those changes are just in the .htaccess and wp-config.php files on the server currently though., If we need those we should save them in version control and put at least a note in the README for a runbook, or script the care and feeding of those files.

obscurerichard commented 2 years ago

This is not really fully resolved, we still need to do testing and integration.