WordPress and MIAB

I was able to install WordPress on my MIAB box, even though they say don’t do this I figured there would be a very unobtrusive way that didn’t require modifying anything outside the /home/user-data/www directory. So I am sharing this so others can leverage off of it.

STEP 1. Add the following nginx config to /home/user-data/www/your-domain.com.conf changing your-domain.com to whatever yours may be.

location ~* \.php$ { include fastcgi_params; fastcgi_pass php-fpm; fastcgi_index index.php; client_max_body_size 8M; } location ~* { index index.php index.html; try_files $uri $uri/ /index.php?$args; } location ^~ /wp-content/database/ { deny all; }

STEP 2. Run web_update

cd /root/mailinabox/tools ./web_update

STEP 3. Download and install WordPress to /home/user-data/www/default (don’t run setup, use directions in step #4).
STEP 4. Download and install SQLite Integration plugin.
STEP 5. Change the user and group owner of all files.

cd /home/user-data/www/default chown -R www-data.www-data *

STEP 6. Follow the install instructions located at the link in STEP #4.

That’s all folks! It doesn’t require you to install any binaries like MySQL or Apache even though they are recommended to run WordPress. My site has been running for a few days with no problems. I even have a custom theme installed. It would be nice to see MIAB support this in the future as WordPress is a very popular website framework and you just can’t survive with static HTML websites in this day and age.

So as of June 30th 2019, that plugin was closed for download. What might we do now?

I AM NOT RECOMMENDING YOU DOWNLOAD IT, BUT:

https://plugins.trac.wordpress.org/browser/sqlite-integration?order=name#trunk

That is the source code for the plugin, since this is PHP (scripting) you can just download the code, upload to wordpress under “wp-plugins\sqlite” folder and enable in settings.

But again - I DO NOT RECOMMEND USING IT AS IT IS FOUR YEARS OLD.

Understood. Heck, I tried using mysql too, but the NGINX hacks no longer work anyway it seems. Can’t get PHP to open. The example.com.conf in the www folder isn’t parsed anymore it seems. It makes no changes to the nginx.conf or the conf.d/local where the sections for my domains are by default.
Manually tweaking teh local.conf file and just restarting nginx didn’t work either, and I started getting letsencrypt validation errors when they probed me.

Can still do flat html though…

I’d run on another box, but then the built in letsencrypt no longer works as the hostname www.mydomain.com no longer aims ay the MIAB box, so it won’t auto enroll.

I know they don’t want add-ons like this, and I get it… but I have a little tiny wordpress page for my Ham Radio domain I wanted to keep.

Well you could MIAB on one server, and wordpress on another… but do what you think is good!