forked from Shopify/ghostferry
-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy path.travis.yml
65 lines (57 loc) · 1.61 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
---
sudo: required
language: go
go:
- "1.14"
go_import_path: github.com/Shopify/ghostferry
services:
- docker
env:
- DOCKER_COMPOSE_VERSION=1.21.2 RELEASE_BRANCH=master
install:
# Installing Docker Compose
- sudo rm /usr/local/bin/docker-compose
- curl -L https://github.com/docker/compose/releases/download/${DOCKER_COMPOSE_VERSION}/docker-compose-`uname -s`-`uname -m` > docker-compose
- chmod +x docker-compose
- sudo mv docker-compose /usr/local/bin
# Installing and Starting MySQL
- .travisci/start-mysql.sh
script:
- make test
before_deploy:
# before_deploy runs once per provider on travis. We only need it to run
# once.
# https://github.com/travis-ci/travis-ci/issues/2570
- "[ \"$BEFORE_DEPLOY_RUN\" = '1' ] || .travisci/build-docs.sh"
- "[ \"$BEFORE_DEPLOY_RUN\" = '1' ] || .travisci/build-debs.sh"
- export BEFORE_DEPLOY_RUN=1
deploy:
# Need two providers for pages:
# https://github.com/travis-ci/travis-ci/issues/7780
- provider: pages
skip-cleanup: true
github-token: "$GITHUB_TOKEN"
keep-history: true
local-dir: docs/build/ghostferry-pages
on:
tags: true
- provider: pages
skip-cleanup: true
github-token: "$GITHUB_TOKEN"
keep-history: true
local-dir: docs/build/ghostferry-pages
on:
branch: master
- provider: releases
skip-cleanup: true
api_key: "$GITHUB_TOKEN"
file_glob: true
file: build/ghostferry-*.deb
on:
tags: true
- provider: script
skip-cleanup: true
script: .travisci/deploy-packagecloud.sh
on:
all_branches: true
condition: $TRAVIS_BRANCH =~ ^(staging-.*)|(master)$