Installation - Use postgresql database

Note

This chapter is for information. For a basic installation, you don’t need to apply the content of this chapter.

This documentation assume you will follow the basic installation steps and replace the mysql related actions by some postgresql actions which are described below.

Postgresql server

Install packages for postgresql server:

$ sudo apt-get install postgresql postgresql-client

Log on the postgressql server as root user:

$ su - postgres
$ pgsql

Create the user “domogik” to use the new database:

postgres=# CREATE USER domogik WITH PASSWORD 'domopass';

Create a database called “domogik”:

postgres=# CREATE DATABASE domogik OWNER domogik;

Exit the postgress shell:

postgres=# \q
$ exit

Domogik configuration

Edit your /etc/domogik/domogik.cfg file and edit the [database] section:

type = postgresql