-
Notifications
You must be signed in to change notification settings - Fork 2
47 lines (46 loc) · 1.24 KB
/
deploy.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
name: deploy
on:
push:
branches:
- master
jobs:
npm-deploy:
name: node-deploy
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@master
- name: 'Automated Version Bump'
uses: 'phips28/gh-action-bump-version@master'
with:
tag-prefix: ''
- name: Set up Node.js
uses: actions/setup-node@master
with:
node-version: '12.x'
registry-url: 'https://registry.npmjs.org'
- run: npm run check
- run: npm run doc
- run: npm publish --access public
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_AUTH_TOKEN }}
- name: Generate docs
uses: peaceiris/actions-gh-pages@v3
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: ./docs
enable_jekyll: true
docker-deploy:
runs-on: ubuntu-latest
needs: npm-deploy
strategy:
matrix:
node-version: [12.x]
steps:
- uses: actions/checkout@v2
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v1
with:
node-version: ${{ matrix.node-version }}
- run: docker login --username ${{ secrets.DOCKER_USERNAME }} -p ${{ secrets.DOCKER_TOKEN }}
- run: npm run docker:push