For this post I’m assuming you already have Tiny Core Linux up and running and persistence (Tiny Core’s ability to save changes) is working. I’m also assuming that your installation of Tiny Core Linux has an adequately sized hard drive.
Use these instructions, or whatever method you prefer, to get MariaDB (A “drop-in” MySQL replacement) working in your Tiny Core installation. Note: I may use the names MySQL and MariaDB interchangeably in these instructions.
I’m assuming you’ve followed some process and have MariaDB up and running.
Connect to MySQL as
mysql -u root
Create a database for WordPress. Feel free to use a different database name than
CREATE DATABASE wordpress_db_01;
Create a database user with the appropriate access for
GRANT ALL PRIVILEGES ON wordpress_db_01.* TO "wordpress_user_01"@"localhost" IDENTIFIED BY "password";
The important elements from that command above are that our WordPress database user name is
wordpress_user_01, and the password for that user is
password. Feel free to use different values.
Enforce the changes we just made, and then exit the
FLUSH PRIVILEGES; exit
Install the Apache extension that includes PHP.
tce-load -wi apache2-mod-php5
By default, the Apache web server files are located in
/usr/local/apache2/htdocs. Without some additional work, any changes made to that directory will be blown away when you reboot your Tiny Core Linux machine. That is the nature of Tiny Core Linux extensions.
To get around this, I do something a bit unorthodox and keep my web server files on a persistent mount point,
/opt. I then symlink to those files from
/usr/local/apache2/htdocs. I use a boot script to re-create that symlink each reboot. This is not standard practice, but it will work. Read the Tiny Core docs if you would rather implement this another way.
/opt/bootlocal.sh and add the following so that our custom Apache configuration will be re-created each reboot.
# Apache rm -rf /usr/local/apache2/htdocs ln -s /opt/apache2/htdocs /usr/local/apache2/htdocs ln -sf /opt/apache2/httpd.conf /usr/local/apache2/conf/ apachectl start
Save those changes to
htdocs directory for our web server files.
mkdir -p /opt/apache2/htdocs
Make a copy of the
sudo cp /usr/local/apache2/conf/httpd.conf /opt/apache2/
/opt/apache2/httpd.conf. Uncomment and modify the
ServerName line to look like this.
.htaccess file in
/opt/apache2/htdocs/ with the following line.
DirectoryIndex index.php index.html
/opt/apache2/httpd.conf. Find the config directive for
AllowOverride line from
<Directory "/usr/local/apache2/htdocs"> # A few lines down you'll find AllowOverride AllowOverride All
OK, now we should have our web server directory root at
/opt/apache2/htdocs. We also have a custom Apache config file at
This means we should be able to make changes to our web server directory and those changes will persist every time we reboot. Apache should be all set.
Reboot and verify Apache is running on your Tiny Core linux box.
If Apache is not running, then go back and figure out what went wrong. Make sure your config modifications and symlinks are correct.
tce-load -wi curl
Download WordPress and unzip it.
curl -o /tmp/latest.zip https://wordpress.org/latest.zip unzip /tmp/latest.zip -d /tmp/ mv /tmp/wordpress/* /opt/apache2/htdocs/
Navigate to your web server using a browser and start installing WordPress.
I’ll leave it to you to to follow the wizard and get WordPress up and running (remember the username, password, and database name we setup earlier in MySQL!).