Fixed database creation with template config file