routes and database set up