Last active
September 11, 2018 18:04
-
-
Save pckilgore/8c96e86f3ca041d59ced67a2d320f54c to your computer and use it in GitHub Desktop.
Auto deploy and alias your node_js app to production domain with travis-ci.com and now.sh, but only build/test master and PRs.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
language: node_js | |
node_js: | |
- node | |
dist: trusty | |
branches: | |
only: | |
- master | |
cache: | |
directories: | |
- $HOME/.npm | |
script: npm test | |
before_deploy: npm install now --no-save | |
deploy: | |
- provider: script | |
script: now --token $NOW_TOKEN --public && now alias --token $NOW_TOKEN | |
skip_cleanup: true | |
on: | |
master: true |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment