This repository has been archived by the owner on Jul 6, 2020. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 9
/
.travis.yml
83 lines (83 loc) · 2.01 KB
/
.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
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
dist: xenial
sudo: required
os:
- linux
matrix:
include:
- name: Dawn
language: node_js
env: TEST_DIR=dawn
- name: Hibike
language: python
python: 3.6
env: TEST_DIR=hibike/travis
- name: Runtime
language: python
python: 3.8
arch: arm64
env: TEST_DIR=runtime
- name: Shepherd
language: python
python: 3.7
env: TEST_DIR=shepherd
- name: Foundry
language: python
python: 3.7
env: TEST_DIR=foundry
addons:
apt:
packages:
- python3-setuptools
- python3-pip
- libasound2-dev
- socat
env:
global:
- APP_ID=15634
cache:
pip: true
directories:
- node_modules
- $HOME/.cache/yarn
before_install:
- openssl aes-256-cbc -K $encrypted_516b8f19f8a6_key -iv $encrypted_516b8f19f8a6_iv -in DevOps/pipeline/piecentral-artifacts.pem.encrypted -out DevOps/pipeline/piecentral-artifacts.pem -d
- mkdir -p artifacts
- if [[ $TEST_DIR = dawn ]] && git tag -l --points-at HEAD | grep dawn; then
export DEPLOY_ARTIFACTS=1; fi
- if [[ $TEST_DIR = runtime ]] && git tag -l --points-at HEAD | grep runtime; then
export DEPLOY_ARTIFACTS=1; fi
- if [[ $TEST_DIR = shepherd ]] && git tag -l --points-at HEAD | grep shepherd; then
export DEPLOY_ARTIFACTS=1; fi
- pushd $TEST_DIR
- mkdir -p build-deps/bin
- export PATH="${PATH}:$(pwd)/build-deps/bin"
- popd
install:
- pushd $TEST_DIR
- make install
- if [[ $DEPLOY_ARTIFACTS = 1 ]]; then make artifacts-install; fi
- popd
script:
- pushd $TEST_DIR
- make test
- make lint
- if [[ $DEPLOY_ARTIFACTS = 1 ]]; then make artifacts; fi
- popd
branches:
only:
- master
- /^shepherd\/.*$/
- /^dawn\/.*$/
- /^devops\/.*$/
- /^foundry\/.*$/
- /^hibike\/.*$/
- /^runtime\/.*$/
- /^test\/.*$/
deploy:
provider: script
script: ./DevOps/pipeline/deploy-artifacts.sh "$APP_ID" "$TRAVIS_TAG" "$(pwd)/artifacts"
skip_cleanup: true
on:
branch: master
tags: true
condition: $DEPLOY_ARTIFACTS = 1