Hosting Flashcards
1
Q
create a namespace in Heroku
A
heroku create «app name»
2
Q
deploy to Heroku
A
» setup env variables in heroku » setup port variable in code: process.env.PORT » setup npm run start script »» heroku create «app name» »» git push heroku master
3
Q
set environment variable in Heroku
A
heroku config:set «key»=«value»
4
Q
delete environment variable in Heroku
A
heroku config:unset «key»
5
Q
view environment variables in Heroku
A
heroku config
6
Q
setup babel for N app in Heroku
A
// import polyfills and runtime globally » index.js: import "core-js/stable" import "regenerator-runtime/runtime"
// setup postbuild script for Heroku » package.json > scripts: "heroku-postbuild": "babel «src dir» --out-dir «dest dir» --copy-files"
7
Q
setup manifest.json for arangodb foxx service in aran
A
» manifest.json: { "engines": { "arangodb": "^«version»" }, "main": "«entry point»" }
8
Q
what are the caveats of arangodb foxx services?
A
» no async, await, and promises
» no import statement