How to install Wiki.js + Node.js + CPanel

Created: July 2, 2020, 1:09 p.m.
Update: Sept. 26, 2021, 9:58 a.m.
How to install Wiki.js + Node.js in WebFaction


Webfaction Hosting or a hosting plan.
ssh access Node.js  10.12
Wiki-js  2.4.107
Let's Encrypt PostgreSQL

Paths, files and folders

Domain /home/user/public_html/wikijs
Application /home/user/webapps/wikijs
leave configuration files OUT of public access
Domain propagation ready!


PostgreSQL Server, new data base.

db 		wiki
user wikiu
pass wikipass host localhost

Download, setup and install

$ cd /home/USER/webapps/wiki
$ wget
tar xzf wiki-js.tar.gz
$ cp config.sample.yml config.yml
# Database
# ---------------------------------------------------------------------
# Supported Database Engines:
# - postgres = PostgreSQL 9.5 or later
  type: postgres
  # PostgreSQL / MySQL / MariaDB / MS SQL Server only:
  host: localhost
  port: 5432
  user: wikiu
  pass: wikipass
  db: wiki
  ssl: false
WebFaction create scripts to start, stop and restart process Node.
node (bin)
start (script)
stop (script)

Run web configuration

$ ./bin/node wiki.js configure
OpenBrowser at and follow steps to finish installation.

Start Process Node to run server

$ ./bin/node server/index.js start
Loading configuration from /home/USER/webapps/wiki/config.yml... OK
2020-07-02T16:39:01.199Z [MASTER] info: =======================================
2020-07-02T16:39:01.201Z [MASTER] info: = Wiki.js 2.4.107 =====================
2020-07-02T16:39:01.201Z [MASTER] info: =======================================
2020-07-02T16:39:01.201Z [MASTER] info: Initializing...
2020-07-02T16:39:01.573Z [MASTER] info: Using database driver pg for postgres [ OK ]


webfaction port?

Alter Script path o JS file server

vim bin/start
nohup /home/gpsi/webapps/gpsi_doc/bin/node /home/gpsi/webapps/gpsi_doc/hello-world.js > /dev/null 2>&1 &
nohup /home/gpsi/webapps/gpsi_doc/bin/node /home/gpsi/webapps/gpsi_doc/server/index.js > /dev/null 2>&1 &
Well done!

Erros Found in migration
App 3160740 output: Loading configuration from /home/USERNAME/public_html/wikijsfinal/config.yml... 
App 3160740 output: OK
App 3160740 output: 2021-01-27T19:32:46.123Z [MASTER] info: =======================================
App 3160740 output: 2021-01-27T19:32:46.126Z [MASTER] info: = Wiki.js 2.4.107 =====================
App 3160740 output: 2021-01-27T19:32:46.126Z [MASTER] info: =======================================
App 3160740 output: 2021-01-27T19:32:46.126Z [MASTER] info: Initializing...
App 3160740 output: 2021-01-27T19:32:46.595Z [MASTER] info: Using database driver pg for postgres [ OK ]
App 3160740 output: 2021-01-27T19:32:46.601Z [MASTER] info: Connecting to database...
App 3160740 output: (node:3160740) UnhandledPromiseRejectionWarning: error: unrecognized configuration parameter "application_name"
App 3160740 output:     at Parser.parseErrorMessage (/home/USERNAME/public_html/wikijsfinal/node_modules/pg-protocol/dist/parser.js:241:15)
App 3160740 output:     at Parser.handlePacket (/home/USERNAME/public_html/wikijsfinal/node_modules/pg-protocol/dist/parser.js:89:29)
App 3160740 output:     at Parser.parse (/home/USERNAME/public_html/wikijsfinal/node_modules/pg-protocol/dist/parser.js:41:38)
App 3160740 output:     at (/home/USERNAME/public_html/wikijsfinal/node_modules/pg-protocol/dist/index.js:8:42)
App 3160740 output:     at Socket.emit (events.js:198:13)
App 3160740 output:     at addChunk (_stream_readable.js:288:12)
App 3160740 output:     at readableAddChunk (_stream_readable.js:269:11)
App 3160740 output:     at Socket.Readable.push (_stream_readable.js:224:10)

Tiago de Souza Moraes - - 2021 // CSS by UIKIT CSS