Skip to content

Self-hosting

Installation and the first journal

What install.sh checks, the settings files it writes, the first operator account and opening the first journal.

Last updated:

The install script

Installation runs with install.sh:

sudo ./install.sh --config install.conf --pubkey release.pub --check-only
sudo ./install.sh --config install.conf --pubkey release.pub

--check-only runs the checks only. Every run leaves a record named install-VERSION-TIME.md. An example install.conf is in the package; the institution's name, the portal address, the language, the entrance type, the backup directory, the mail settings and the first operator's e-mail go into it.

The settings written

The script writes prod.env (the application) and postgres.env (the database and backups) under /etc/journalos with mode 0600. Secret values (the authentication secret, the encryption key, the health token, the backup keys, the database passwords) are generated on the server and never shown. An existing prod.env is not rewritten. The database administrator's password and the backup encryption key are only in postgres.env; the application never sees them.

The first operator

The script creates the organization and the first operator account, makes the account platform operator and organization administrator, and sends an e-mail to set a password, valid for one hour. Finally it checks the components' health, the redirect from HTTP to HTTPS, and the SPF and DMARC records of the mail domain.

The first journal

The operator sets a password and turns on two-step verification, then registers and approves the release in the operator console. Journals are then created from the portal's /new page. An institution's installation creates no new organization; journals are added to the existing one by its organization administrators. One account can create at most three journals in 24 hours.

A question this page does not answer? Write to us.