Installing and Running Wiki.JS on the Raspberry Pi

In this project, we will show you how to install and run Wiki.JS on a Raspberry Pi.

Raspberry Pi Wiki.JS

Wiki.JS is a powerful, free, and self-hosted wiki that you can run on your Raspberry Pi.

Using a self-hosted wiki solution such as Wiki.JS allows you to organize and store information easily.

One of the benefits of this particular Wiki clone is that it boasts a considerable number of features and has support for a visual editor, markdown, and more. It even boasts support for 2-factor authentication, allowing you to improve the security of your setup.

To get Wiki.JS running on the Raspberry Pi, we will use Docker. Docker allows us to get this software up and running quickly without fighting dependencies.

Equipment

Below is a list of the equipment we used when setting up Wiki.JS on our Raspberry Pi.

Recommended

Optional

This tutorial was last tested on a Raspberry Pi 400 running the latest version of Raspberry Pi OS Bullseye.

Installing Wiki.JS on the Raspberry Pi

Over these following steps, we will walk you through the process of getting Docker on your Raspberry Pi and setting it up to run Wiki.JS.

One of the most significant advantages of using Docker is that we can easily install the database server Wiki.JS relies on.

Preparing your Raspberry Pi for Wiki.JS

1. Before installing Wiki.JS, we need to update our Raspberry Pi’s operating system.

Update the package list and any out-of-date packages using the following commands within the terminal.

sudo apt update
sudo apt upgrade -y

2. Once the update completes, you will now want to install Docker to your Raspberry Pi.

Please follow the guide we have linked above before returning to this tutorial. That guide will show you how to install Docker and have it configured to work properly on your device.

3. We must also create a directory to store our Docker compose file.

Create this directory in your current user’s home directory by using the command below.

mkdir ~/wikijs

4. Once the directory is created, we must change to it by using the cd command.

cd ~/wikijs

Writing the Docker Compose file for Wiki.JS

5. After following our Docker installation guide, we can now write a Docker compose file for our Wiki.JS installation.

This compose file will set up the Wiki.JS and PostgreSQL container on our Raspberry Pi.

Start writing this compose file by using the following command in the terminal.

sudo nano ~/wikijs/docker-compose.yml

6. Within this file, you will want to enter the following lines.

While typing in these lines, replace “” with a password of your choosing. Keep this password secure, as Wiki.JS will store its data on this database server.

version: "3"
services:

  db:
    image: postgres:15-alpine
    environment:
      POSTGRES_DB: wiki
      POSTGRES_PASSWORD: 
      POSTGRES_USER: wikijs
    logging:
      driver: "none"
    restart: unless-stopped
    volumes:
      - db-data:/var/lib/postgresql/data

  wiki:
    image: ghcr.io/requarks/wiki:2
    depends_on:
      - db
    environment:
      DB_TYPE: postgres
      DB_HOST: db
      DB_PORT: 5432
      DB_USER: wikijs
      DB_PASS: 
      DB_NAME: wiki
    restart: unless-stopped
    ports:
      - "80:3000"

volumes:
  db-data:

7. After entering these lines, you can save and quit by pressing CTRL + X, Y, then the ENTER key.

Starting up WikiJS on your Raspberry Pi

8. We are finally at a point where we can start up WikiJS on the Raspberry Pi.

To start this software on your Pi, run the following command within the terminal.

docker compose up -d

During its initial startup, Docker will pull the latest versions of both Wiki.JS and PostgreSQL to your Pi. This process can take a few minutes, so be patient before proceeding.

Accessing the Wiki.JS Web Interface

9. Once the container starts, you can access the Wiki.JS web interface using your favourite web browser.

All you need to do is know your Pi’s local IP address. The easiest way to get this is to use the hostname command.

hostname -I

10. After getting your IP address you will want to go straight to the following address.

Ensure you replace “” with your Pi’s IP.

http://

First Run of Wiki.JS on the Rasberry Pi

11. When you first access the Wiki.JS web interface, you will be asked to enter some information.

First, specify an email for your administrator account (1.). This is the email you will use to log in to your account.

Next, you need to set a password that you will use to access this account (2.).

Finally, you must also set a URL for your site (3.). If you are using a domain name, this is the place that you will want to enter it.

Once everything is filled out, click the “Install” button (4.) at the bottom of the dialog box.

Create admin account for Wiki.JS on the Raspberry Pi

12. Wiki.JS will now finish setting itself up on your Raspberry Pi.

This process can take a couple of minutes, so don’t worry if it appears to have stopped doing anything.

Finalizing Wiki.JS installation

13. After the installation process, you will need to log in using the information you set previously (1.).

Once you have filled out your email and password, click the “Log In” button (2.).

Login to Wiki.JS

14. You are finally at the point where you can start setting up Wiki.JS to your liking.

You can now browse its administration page or immediately begin creating a home page for your new self-hosted wiki.

Wiki.JS running on the Raspberry Pi

Conclusion

Hopefully, at this stage, you will now have Wiki.JS running on your Raspberry Pi.

This software is a powerful self-hosted wiki that allows you to store and document information easily.

Please feel free to comment below if you have questions about using this software on your Pi.

We have numerous other projects for the Raspberry Pi that are well worth checking out.

Print Friendly, PDF & Email

Leave a Comment

This site uses Akismet to reduce spam. Learn how your comment data is processed.

Server Status

Aradippou Chat 1 Chat 2 Larnaca Limassol Nicosia

Chat Links

Official Links.

1. Chat 1.
2. Chat 2.

Alternative Mirror Links.

1. KiwiIRC 1.
2. KiwiIRC 2.

Other Web Clients.

1. IrcCloud.

Recent Posts

Related Posts:

Advertisement

Archives

Super Club Radio

Mighty Deals

CyIRC

CyIRC Tweets

Scroll Up
Fatal error: Uncaught WMAC\JSMin_UnterminatedStringException: WMAC\JSMin: Unterminated String at byte 1180: "+o.accessToken}}).then(e=>{if(!e.ok)throw e;return e});return a.catch(e=>{console.error(`Failed to logout chatrix session. deviceId: ${o.deviceId}`)}),a}})(); in /home/bszucbfe/public_html/wp-content/plugins/clearfy/components/minify-and-combine/includes/classes/ext/php/jsmin.php:215 Stack trace: #0 /home/bszucbfe/public_html/wp-content/plugins/clearfy/components/minify-and-combine/includes/classes/ext/php/jsmin.php(157): WMAC\JSMin->action(2) #1 /home/bszucbfe/public_html/wp-content/plugins/clearfy/components/minify-and-combine/includes/classes/ext/php/jsmin.php(96): WMAC\JSMin->min() #2 /home/bszucbfe/public_html/wp-content/plugins/clearfy/components/minify-and-combine/includes/classes/class-main.php(375): WMAC\JSMin::minify('(function(){"us...') #3 /home/bszucbfe/public_html/wp-includes/class-wp-hook.php(310): WMAC_PluginMain->jsSnippetcacher('(function(){"us...', '/home/bszucbfe/...') #4 /home/bszucbfe/public_h in /home/bszucbfe/public_html/wp-content/plugins/clearfy/components/minify-and-combine/includes/classes/ext/php/jsmin.php on line 215