-
Notifications
You must be signed in to change notification settings - Fork 0
/
.travis.yml
40 lines (37 loc) · 938 Bytes
/
.travis.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
language: node_js
node_js:
- 11
before_script:
- cd ui
- npm ci
jobs:
include:
- stage: Build
script:
- npm run-script build
- stage: Test
script:
- npm run-script lint
- npm test -- --coverage --watchAll=false
- npm i -g codecov
- codecov
- stage: Test Docker
services:
- docker
script:
- docker build .
- stage: Deploy
script:
- docker build . -t spotypop/kitty_hash_ui:$TRAVIS_BUILD_NUMBER
- echo "$DOCKER_PASSWORD" | docker login -u "$DOCKER_USERNAME" --password-stdin
- docker push spotypop/kitty_hash_ui:$TRAVIS_BUILD_NUMBER
stages:
- name: Build
# require the type to be a PR
if: type = pull_request
- name: Test Docker
# require the type to be a PR
if: type = pull_request
- name: Deploy
# require the type to be push to master
if: type = push AND branch = master