
Joplin Server is a free, self-hosted open-source note-taking and to-do application that captures ideas as notes, organizes them and synchronizes them to devices. This article explains how to host a Joplin Server with Docker on a Vultr Ubuntu server and synchronize it with a Joplin client application.
Before you begin, you'll need to do the following steps:
joplin.example.com.Create a new directory to store Joplin docker files in the /opt directory.
Switch to the directory.
Use a text editor to create a new Joplin Docker Compose file.
Add the following contents to the file.
The values 5434 and 8080 are examples. You can change these if required.
Replace https://joplin.example.com with your fully-qualified domain name.
Replace the values for POSTGRES_PASSWORD, POSTGRES_DATABASE, and POSTGRES_USER with your preferred values.
This Docker Compose configuration creates a new Postgres database container and a Joplin Server listening on port 8080.
Save and close the file.
Start the Joplin Server.
Verify that Joplin Server is up and running.
You should see an output similar to the example below.
Create a new Nginx configuration file.
Add the following contents to the file.
Save and close the file.
Verify the syntax and test Nginx for configuration errors.
Restart Nginx to load changes.
By default, UFW is active on Ubuntu. Here's how to configure the firewall to allow HTTP and HTTPS access on the server.
Allow HTTP access on port 80.
Allow HTTPS access on port 443.
Reload the Firewall rules to apply the changes.
Install the Certbot Let's Encrypt client.
Request a free SSL certificate. Replace joplin.example.com with your fully-qualified domain name, and admin@example.com with your email address.
Certbot will request a new certificate, install it for your Nginx server, and set up an automatic renewal event. See our Certbot guide to learn more.
Restart Nginx to apply the changes.
Using a web browser, visit your subdomain to test the Joplin server.
Log in to the Joplin server with the following default email and password.
admin@localhostadminClick your username, Admin, in the top right corner.
Edit your Administrator profile by filling in the Full name, Email, and Password fields. To ensure Joplin server security, enter a strong, hard-to-guess password and click Update Profile.
Click Admin on the main top bar navigation menu.
Navigate to Users, then click Add user to set up a new non-administrative account to sync with your Joplin Client.
Complete the user form and click Create user to save the new account.
Joplin has clients available for desktop and mobile devices.
Install the Joplin client application from the official website.
Launch the Joplin client.
Navigate to the Synchronisation section.
Click the Synchronisation target dropdown.
Select Joplin Server from the list.
Enter your fully-qualified domain name in the Joplin Server URL field.
Enter your account email address in the Joplin Server email field.
Enter your password in the Joplin Server password field.
Set your preferred timing in the Synchronisation interval field.
Save your changes.
You can test the Joplin Server host port from the command line with curl.
Here are some common issues you may encounter, and how to handle them.
You may see this error:
Confirm that the Joplin Server container is running and listening on the port assigned in your Docker Compose file. As an example, this article uses port 8080. Make sure Joplin Server is running on Docker and listening on the host port.
You may see an error message such as:
Check the Docker logs for issues if you see this error.
Another error you may see from the Joplin client is:
To fix this error, add https:// at the beginning of the URL, and verify you've used the correct username and password.
Another error you may see is:
Check the - APP_BASE_URL= environment variable in the Joplin Docker Compose file and verify the correct domain name is used to access the application. The correct variable should look like the one below. Replace joplin.example.com with your fully-qualified domain name.
You have successfully hosted Joplin Server with Docker on Ubuntu and synchronized it with a Joplin Client application. You can set up several user accounts and keep them in sync with the server.
0 Comments
Be the first to comment and share your perspective with the community.