Setting up server and database