Added mode argument to manager, moved secret key to environment variable
for heroku