Before you can install your own Booktype server, you will need a database to be available. PostgreSQL (https://www.postgresql.org) is the recommended database management system for production servers. If you are setting up a development machine, you can skip this step and use the built-in sqlite database for testing purposes.
The following instructions for setting up PostgreSQL were tested on Debian GNU/Linux 9 (stretch) and Ubuntu 18.04 LTS (bionic), using sudo for root access to the server.
1. Open a terminal, then enter the following command to install PostgreSQL:
sudo apt install postgresql
2. Change to the home directory of the postgres user on the system, then create the PostgreSQL user booktype-user with the command:
sudo -u postgres createuser -SDRP booktype-user
Enter the password you wish to set in the database, as prompted. You will need to re-enter it for confirmation.
3. Create a database named booktype-db, setting booktype-user as the owner with the -O option. The encoding should be the international UTF-8 character set, as indicated with the -E option.
sudo -u postgres createdb -E utf8 -T template0 -O booktype-user booktype-db
4. By default, a new install of PostgreSQL on Debian or Ubuntu GNU/Linux allows local connections from applications. If you already had PostgreSQL installed on the server, confirm connections to the database booktype-db by booktype-user are allowed, by checking the PostgreSQL configuration file. The exact file name depends on the PostgreSQL version that you are using. For example, if the version was 9.6, the command to edit the file on Debian or Ubuntu GNU/Linux would be:
sudo nano /etc/postgresql/9.6/main/pg_hba.conf
At the end of this file is a section with client authentication rules, like this:
# TYPE DATABASE USER CIDR-ADDRESS METHOD
# "local" is for Unix domain socket connections only
local all all peer
# IPv4 local connections:
host all all 127.0.0.1/32 md5
# IPv6 local connections:
host all all ::1/128 md5
If a suitable rule allowing Booktype connections is not enabled, you can add an extra line for a local IPv6 connection at the end of the section, separated by spaces, like so:
host booktype-db booktype-user ::1/128 md5
Save any changes to this file with the keyboard shortcut Ctrl+O, and then quit nano with Ctrl+X.
5. Finally, if you have changed the configuration, restart PostgreSQL with the command:
sudo service postgresql restart
You are now ready to install Booktype. Please see the following chapters for details.
There has been error in communication with Booktype server. Not sure right now where is the problem.
You should refresh this page.