forked from twilio/twilio-java
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.travis.yml
51 lines (51 loc) · 1.59 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
language: java
sudo: false
cache:
directories:
- "$HOME/.m2"
before_install:
- curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo apt-key add -
- sudo add-apt-repository "deb [arch=amd64] https://download.docker.com/linux/ubuntu $(lsb_release -cs) stable"
- sudo apt-get update
- sudo apt-get -y -o Dpkg::Options::="--force-confnew" install docker-ce
- docker --version
- echo $GPG_SECRET_KEYS | base64 --decode | $GPG_EXECUTABLE --import --batch || true
- echo $GPG_OWNERTRUST | base64 --decode | $GPG_EXECUTABLE --import-ownertrust --batch
|| true
jobs:
include:
- jdk: openjdk8
dist: xenial
- jdk: openjdk11
dist: xenial
services:
- docker
install:
- mvn --settings .maven.xml install -DskipTests=true -Dgpg.skip -Dmaven.javadoc.skip=true
-B -V
script:
- mvn test -B
- if [[ "$TRAVIS_BRANCH" == "main" || "$TRAVIS_BRANCH" == "travis" ]] && [ "$TRAVIS_PULL_REQUEST"
== "false" ]; then echo "${DOCKER_PASSWORD}" | docker login -u "${DOCKER_USERNAME}"
--password-stdin; fi
deploy:
- provider: script
script: make docker-build && make docker-push
skip_cleanup: true
on:
tags: true
jdk: openjdk8
- provider: script
script: mvn clean deploy --settings .maven.xml -DskipTests=true -B -U -Prelease
skip_cleanup: true
on:
tags: true
jdk: openjdk8
notifications:
slack:
if: branch = main
on_pull_requests: false
on_success: never
on_failure: change
rooms:
secure: Yd0IZ2zGmRm64fVwbPebNJ+VJxT958iT3Zz7xP1CSkpR+w6rUulQhWvsn2ka4Kqge+TaXbhNu3I55wRdPCxLrEkTNgCdTkJ9y5HYMxPHpRcQ0XFxJHBmAW6y9foUdSbk2KdM1TKwNUnCp43QmSMWfaMjnvNbh2GzadS/JS1nmBI=