added environment-dependent config file (env.sample.js needs to be copied to env.js and then edited)
proper CORS-supported login redirection