How to Install ClassicPress on Your Synology NAS

How to Install ClassicPress on Your Synology NAS

ClassicPress is a community-led and funded open-source content management system and a fork of WordPress that preserves the TinyMCE classic editor as the default option instead of Gutenberg. In this step by step guide I will show you how to install ClassicPress on your Synology NAS using Docker & Portainer.

💡Note: This guide works perfectly with the latest ClassicPress v2.2.0 release.

  • STEP 1

Please Support My work by Making a Donation.

  • STEP 2

Install Portainer using my step by step guide. If you already have Portainer installed on your Synology NAS, skip this STEP. Attention: Make sure you have installed the latest Portainer version.

  • STEP 3

Make sure you have a synology.me Wildcard Certificate. Follow my guide to get a Wildcard Certificate. If you already have a synology.me Wildcard certificate, skip this STEP.

  • STEP 4

Go to Control Panel / Login Portal / Advanced Tab / click Reverse Proxy. Follow the instructions in the image below.

ClassicPress Synology NAS Set up 1

  • STEP 5

Now click the “Create” button. Follow the instructions in the image below.

ClassicPress Synology NAS Set up 2

  • STEP 6

After you click the Create button, the window below will open. Follow the instructions in the image below.

On the General area, set the Reverse Proxy Name description: type in ClassicPress. After that, add the following instructions:

Source:
Protocol: HTTPS
Hostname: classicpress.yourname.synology.me
Port: 443

Check Enable HSTS

Destination:
Protocol: HTTP
Hostname: localhost
Port: 8188

ClassicPress Synology NAS Set up 3

  • STEP 7

On the Reverse Proxy Rules click the Custom Header tab. Click Create and then, from the drop-down menu, click WebSocket. After you click on WebSocket, two Header Names and two Values will be automatically added. Click Save. Follow the instructions in the image below.

Synology Proxy WebSocket

  • STEP 8

Go to Control Panel / Network / Connectivity tab/ Check Enable HTTP/2 then click Apply. Follow the instructions in the image below.

ClassicPress Synology NAS Set up 4

  • STEP 9

Go to Control Panel / Security / Advanced tab/ Check Enable HTTP Compression then click Apply. Follow the instructions in the image below.

ClassicPress Synology NAS Set up 5

  • STEP 10

Go to File Station and open the docker folder. Inside the docker folder, create one new folder and name it classicpress. Follow the instructions in the image below.
Note: Be careful to enter only lowercase, not uppercase letters.

ClassicPress Synology NAS Set up 6

  • STEP 11

Now create two new folders inside the classicpress folder that you created at STEP 10 and name them data and db. Follow the instructions in the image below.
Note: Be careful to enter only lowercase, not uppercase letters.

ClassicPress Synology NAS Set up 7

  • STEP 12

Log into Portainer using your username and password. On the left sidebar in Portainer, click on Stacks then + Add stack. Follow the instructions in the image below.

1 Synology Portainer Add Stack

  • STEP 13

In the Name field type in classicpress. Follow the instructions in the image below.

Note: Copy Paste the code below in the Portainer Stacks Web editor.

services:
  classicpress:
    image: marverix/classicpress:latest
    container_name: ClassicPress
    hostname: classicpress
    healthcheck:
     test: curl -f http://localhost:80/ || exit 1
    restart: on-failure:5
    volumes:
      - /volume1/docker/classicpress/data:/var/www/html:rw
    ports:
      - 8188:80
    environment:
      CP_DB_HOST: db
      CP_DB_USER: marius
      CP_DB_PASSWORD: mariuspassword
      CP_DB_NAME: mariushosting_db
      APACHE_RUN_USER_ID: 1026
      APACHE_RUN_GROUP_ID: 100
      
  db:
    image: mariadb:11.4-noble #LTS Long Time Support Until May 29, 2029.
    container_name: ClassicPress-DB
    hostname: classicpress-db
    restart: on-failure:5
    security_opt:
      - no-new-privileges:false
    environment:
      MYSQL_DATABASE: mariushosting_db
      MYSQL_USER: marius
      MYSQL_PASSWORD: mariuspassword
      MYSQL_ROOT_PASSWORD: rootpass
      TZ: Europe/Bucharest
    volumes:
      - /volume1/docker/classicpress/db:/var/lib/mysql:rw
      
  phpmyadmin:
    image: phpmyadmin
    hostname: classicpress-phpmyadmin
    healthcheck:
     test: curl -f http://localhost:80/ || exit 1
    container_name: ClassicPress-phpMyAdmin
    ports:
      - 2580:80
    environment:
     PMA_HOST: classicpress-db
     PMA_PORT: 3306
    restart: on-failure:5

Note: Before you paste the code above in the Web editor area below, change the values for CP_DB_USER and MYSQL_USER. Type in your own username for both values; they have to be identical. marius is an example for a user.
Note: Before you paste the code above in the Web editor area below, change the value for CP_DB_PASSWORD and MYSQL_PASSWORD. Type in your own password for both values; they have to be identical. mariuspassword is an example for a password.
Note: Before you paste the code above in the Web editor area below, change the value for CP_DB_NAME and MYSQL_DATABASE. Type in your own database name for both values; they have to be identical. mariushosting_db is an example for a database name.
Note: Before you paste the code above in the Web editor area below, change the value for TZ. (Select your current Time Zone from this list.)
Note: Before you paste the code above in the Web editor area below, change the value numbers for APACHE_RUN_USER_ID and APACHE_RUN_GROUP_ID with your own UID and GID values. (Follow my step by step guide on how to do this.) 1026 is my personal USER_ID value and 100 is my personal GROUP_ID value. You have to type in your own values.

ClassicPress Synology NAS Set up 8 new 2027

  • STEP 14

Scroll down on the page until you see a button named Deploy the stack. Click on it. Follow the instructions in the image below. The installation process can take up to a few minutes. It will depend on your Internet speed connection.

ClassicPress Synology NAS Set up 9 new 2027

  • STEP 15

If everything goes right, you will see the following message at the top right of your screen: “Success Stack successfully deployed“.

ClassicPress Synology NAS Set up 10

  • STEP 16

Go back to STEP 1 or you will deal with karma 🙂.

  • STEP 17

Please wait approximately 2 minutes for the installation to be completed or you will get a blank page. Now open your browser and type in your HTTPS/SSL certificate like this https://classicpress.yourname.synology.me In my case it’s https://classic.mariushosting.synology.me If everything goes right, you will see the ClassicPress Installation Page. Choose your language then click Continue. Follow the instructions in the image below.

ClassicPress Synology NAS Set up 11

  • STEP 18

Type in your Site title, your own Admin Username, your own Admin Password and your own Admin Email then click Install ClassicPress. Follow the instructions on the image below. Warning: Username and Password in this area should be created now. Do not confuse this Username and Password with the ones created at STEP 13.

ClassicPress Synology NAS Set up 12

  • STEP 19

Wait approximately 1 minute for the installation to be completed. Click Log in. Follow the instructions in the image below.

ClassicPress Synology NAS Set up 13

  • STEP 20

Type in your own Username and Password that you have previously created at STEP 18 then click Log in. Follow the instructions in the image below.

ClassicPress Synology NAS Set up 14

  • STEP 21

Your ClassicPress instance should look like this.

ClassicPress Synology NAS Set up 15

  • STEP 22

phpMyAdmin is the graphical interface for the MariaDB database. It will help you connect to your database. Open your browser and type in http://Synology-ip-address:2580 Connect to your MariaDB using root as Username and rootpass as Password. Click Log in. Follow the instructions in the image below.

ClassicPress Synology NAS Set up 16

  • STEP 23

You can now download and back up your ClassicPress database without needing to install any backup plugin on your ClassicPress website. Warning: Do not expose the phpMyadmin instance to the Internet via Reverse Proxy. You can do it by using a strong password, but it’s not recommended to expose it. Keep it local.
Note: Find out how to backup your WordPress database using phpMyAdmin.
Note: Fix the error message: The phpMyAdmin configuration storage is not completely configured.

ClassicPress Synology NAS Set up 17

  • STEP 24

Find out how to add Email SMTP to your ClassicPress website so you can receive notifications via email. The Email Notifications setup is the same on both WordPress and ClassicPress.

Enjoy ClassicPress!

Note: Can I run Docker on my Synology NAS? See the supported models.
Note: How to Back Up Docker Containers on your Synology NAS.
Note: Find out how to update the ClassicPress container with the latest image.
Note: How to Free Disk Space on Your NAS if You Run Docker.
Note: How to Schedule Start & Stop For Docker Containers.
Note: How to Activate Email Notifications.
Note: How to Add Access Control Profile on Your NAS.
Note: How to Change Docker Containers Restart Policy.
Note: How to Use Docker Containers With VPN.
Note: Convert Docker Run Into Docker Compose.
Note: How to Clean Docker.
Note: How to Clean Docker Automatically.
Note: Best Practices When Using Docker and DDNS.
Note: Some Docker Containers Need WebSocket.
Note: Find out the Best NAS Models For Docker.
Note: Activate Gmail SMTP For Docker Containers.

This post was updated on Thursday / October 24th, 2024 at 6:26 AM