Updated server config, started app.js refactoring.