[Docker] Joplin Server on Synology NAS

[Docker] Joplin Server on Synology NAS

Joplin is a note-taking app that can serve as a solid alternative to Evernote. It doesn’t have all the flashy features Evernote offers, but it excels at one thing: clean, reliable synchronization across all devices—Windows, macOS, Android, and more.

For people who frequently switch between multiple devices, this simple feature alone is invaluable. Joplin Server is the backend cloud component that enables this synchronization. You can host it yourself, and in this post, I’ll walk you through setting it up on a Synology NAS using Docker.


Prerequisites

Before we begin, there are a few requirements:

  • You should be familiar with Docker (Container Manager).
  • You need the ability to SSH into your Synology NAS and access the database.
  • You should know how to set up a reverse proxy.

I won’t go into detail on adding a project in Container Manager or configuring a reverse proxy. Instead, this post focuses on the essential docker-compose.yml configuration and how to manually confirm email verification when Joplin fails to send emails.


Email Verification Issue

After installation, Joplin Server will prompt you to change the default admin email and send a confirmation email to the new address. Unfortunately, when running inside Docker, the server often fails to deliver this email.

The workaround is to directly inspect the database and retrieve the confirmation URL manually. I’ll show you how to do this later.


PostgreSQL Version Note

Many recommend using PostgreSQL 15 due to stricter authentication in newer versions. However, I’ve had no issues running PostgreSQL 17.6-alpine, so that’s the version I’ll use here.


Folder Structure

Before starting, create a directory structure like this on your NAS:

/volume1/docker/joplin/
  ├─ docker-compose.yml
  └─ postgres/         # Database storage

Docker Compose Configuration

Here’s the docker-compose.yml I use.

services:
    db:
        image: postgres:17.6-alpine3.22
        container_name: joplin-db
        volumes:
            - /volume1/docker/joplin/postgres:/var/lib/postgresql/data
#        ports:
#            - "5432:5432"
        restart: unless-stopped
        environment:
            - POSTGRES_PASSWORD=YOUROWNPASSWORD
            - POSTGRES_USER=joplin
            - POSTGRES_DB=joplin
            - TZ=Asia/Seoul
    app:
        image: joplin/server:latest
        container_name: joplin-app
        depends_on:
            - db
        ports:
            - "22300:22300"
        restart: unless-stopped
        environment:
            - APP_PORT=22300
            - APP_BASE_URL=https://joplin.yourowndomain.com
            - DB_CLIENT=pg
            - POSTGRES_PASSWORD=YOUROWNPASSWORD  
            - POSTGRES_DATABASE=joplin
            - POSTGRES_USER=joplin
            - POSTGRES_PORT=5432
            - POSTGRES_HOST=db
            - TZ=Asia/Seoul

Running the Project

  1. Place the file (docker-compose.yml) inside your joplin folder.
  2. Create a project in Container Manager.
  3. Once the containers are up, set up a reverse proxy so that
    • https://joplin.yourowndomain.comlocalhost:22300

At this point, you should be able to access Joplin Server from your domain.


First Login & Email Confirmation

  • The default credentials are:
    • Email: admin@localhost
    • Password: admin

After logging in, change your email and password. Joplin will tell you a confirmation email has been sent—but it won’t arrive.

Instead, connect directly to PostgreSQL:

sudo -i     #  Get into root on Synology NAS
docker exec -it joplin-db psql -U joplin -d joplin

\dt          # List tables
select * from email;   # Inspect email table
\q           # Quit

You’ll see a record in the email table that clearly contains the confirmation link. Copy that URL into your browser to complete email verification.


Final Step

Once verified, you can install the Joplin app on Android, iOS, or desktop. The Windows client is available here:

👉 https://joplinapp.org/download


✅ With this setup, you now have your own self-hosted Joplin Server running on Synology NAS, ready to synchronize notes securely across all your devices.