-
Notifications
You must be signed in to change notification settings - Fork 3
CI CD
Harry Turnbull edited this page May 27, 2020
·
1 revision
- Activate the repo on Travis.
- Add
.travis.ymlto root, which specifies deployment with surge and surge domain name.
language: node_js
node_js:
- "stable"
cache:
directories:
- node_modules
script:
- npm test
- npm run build
deploy:
provider: surge
skip_cleanup: true
domain: <whatever_name_here>.surge.sh
project: ./build/
on:
branch: master
- Add
SURGE_LOGINkey to travis environment variables, with value of your surge email. - Get your surge token by running
surge tokenin your terminal. - Add
SURGE_TOKENkey to travis environment variables, with value of your surge token.
- Commit and push.
- Travis will start a build.
- All tests must pass for Travis to deploy.