forked from BlueBlock/MoonMail
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.travis.yml
49 lines (44 loc) · 1.33 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
language: node_js
sudo: required
node_js:
- '8.10'
before_install: # if "install" is overridden
# Repo for Yarn
- sudo apt-key adv --fetch-keys http://dl.yarnpkg.com/debian/pubkey.gpg
- echo "deb http://dl.yarnpkg.com/debian/ stable main" | sudo tee /etc/apt/sources.list.d/yarn.list
- sudo apt-get update -qq
- sudo apt-get install -y -qq yarn
- yarn install
- source .ci/detect-changed-services.sh && detect_changed_services && echo $changed_services
env:
global:
- ES_VERSION=6.0.0
- ES_DOWNLOAD_URL=https://artifacts.elastic.co/downloads/elasticsearch/elasticsearch-${ES_VERSION}.tar.gz
stages:
- test
- name: staging-deploy
if: branch = master AND type = push
- name: prod-deploy
if: branch = release AND type = push
jobs:
include:
- stage: test
script: ./.ci/test.sh
- stage: staging-deploy
script: ./.ci/staging-deploy.sh
- stage: prod-deploy
script: ./.ci/prod-deploy.sh
cache:
yarn: true
directories:
- "$(npm config get prefix)/lib/node_modules"
- node_modules
- events/node_modules
- api/node_modules
- private/node_modules
- extensions/node_modules
- template-marketplace/node_modules
- lists-microservice/node_modules
- emails-microservice/node_modules
- campaigns-microservice/node_modules
- events-router/node_modules