Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/siddharthkp/now-cd
continuous deployment with now
https://github.com/siddharthkp/now-cd
Last synced: 18 days ago
JSON representation
continuous deployment with now
- Host: GitHub
- URL: https://github.com/siddharthkp/now-cd
- Owner: siddharthkp
- Created: 2018-01-09T09:41:49.000Z (almost 7 years ago)
- Default Branch: master
- Last Pushed: 2019-04-25T06:36:30.000Z (over 5 years ago)
- Last Synced: 2024-10-12T05:51:21.779Z (about 1 month ago)
- Language: JavaScript
- Homepage:
- Size: 77.1 KB
- Stars: 90
- Watchers: 4
- Forks: 5
- Open Issues: 7
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
Staging instances with now + travis
Each pull request gets it's own deployment instance `https://{author}-{repo}-{branch-name}.now.sh`
This is updated on every commit to the matching pull request.
The master branch is deployed on `https://{author}-{repo}.now.sh`
#### install
You need 2 tokens for `now-cd` to work
1. now API token
You can generate a token from [account/tokens](https://zeit.co/account/tokens). Call it `NOW_CD_TOKEN`
2. Github API token
You can generate a token from [settings/tokens/new](https://github.com/settings/tokens/new), call it `NOW_CD_GITHUB_TOKEN`
Now set these in travis repository settings [This is how](https://docs.travis-ci.com/user/environment-variables/#Defining-Variables-in-Repository-Settings).
#### usage
add this to `.travis.yml`:
```yml
after_success:
- npx now-cd
```
#### custom per-branch aliases
use the `--alias` option to set custom aliases per-branch:
```
npx now-cd --alias "master=myapp.com" --alias "staging=staging.myapp.com"
```all commits to master will now be aliased to `myapp.com`, and all commits to the staging branch will now be aliased to `staging.myapp.com`!
#### team account
use the `--team` option to mention your team name
```
npx now-cd --team auth0-design
```
#### like it?
:star: this repo
#### license
MIT © [siddharthkp](https://github.com/siddharthkp)