WikiJS

Installer Postgresql

apt install postgresql sudo sudo -u postgres psql ALTER USER postgres WITH PASSWORD 'password'; CREATE USER wikijs with CREATEDB CREATEROLE; ALTER USER wikijs with PASSWORD 'password'; CREATE DATABASE wikijs OWNER wikijs; \l

Installer nodeJs

apt install curl curl -fsSL https://deb.nodesource.com/setup_20.x | sudo -E bash - &&\ sudo apt-get install -y nodejs wget https://github.com/Requarks/wiki/releases/latest/download/wiki-js.tar.gz mkdir /srv/wiki tar xzvf wiki-js.tar.gz -C /srv/wiki cd /srv/wiki mv config.sample.yml config.yml modifier les paramètres de la db node server adduser wikijs --home /srv/wiki/ chown wikijs: /srv/wiki/ -R
nano /etc/systemd/system/wiki.service

contenu:

[Unit] Description=Wiki.js After=network.target [Service] Type=simple ExecStart=/usr/bin/node server Restart=always # Consider creating a dedicated user for Wiki.js here: User=wikijs Environment=NODE_ENV=production WorkingDirectory=/srv/wiki [Install] WantedBy=multi-user.target
systemctl daemon-reload systemctl start wiki