[server] Add PostgreSQL support.
[server] Handle database config error gracefully.

ccnet-server crashes if an unknown database engine is given.