forked from dita-ot/dita-ot
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.travis.yml
115 lines (115 loc) · 4.82 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
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
sudo: false
language: java
jdk:
- openjdk8
env:
global:
- JAVA_OPTS="-Xmx2048M"
- GRADLE_OPTS="-Xmx2048M"
stages:
# - name: test
- name: snapshot
if: repo = dita-ot/dita-ot AND branch = develop AND type != pull_request
- name: release
if: repo = dita-ot/dita-ot AND tag IS present AND type != pull_request
# - name: deploy
# if: repo = dita-ot/dita-ot AND tag IS present AND type != pull_request
jobs:
include:
# # Test
# - stage: test
# name: "Unit and E2E tests"
# install: "./gradlew"
# script: "./gradlew check e2eTest --info --stacktrace --no-daemon"
# - install: "./gradlew"
# name: "Integration tests"
# script: "./gradlew integrationTest --info --stacktrace --no-daemon"
# Snapshot
- stage: snapshot
# name: "Snapshot distribution package deployment"
# install:
# - git submodule update --init --recursive
# - "./gradlew"
# script: "./gradlew dist -Pcommit=${TRAVIS_COMMIT} -Ptag=${TRAVIS_TAG} -PskipGenerateDocs=${SKIP_GENERATE_DOCS} --stacktrace --no-daemon"
# deploy:
# - provider: s3
# access_key_id: AKIAJUF6ATK6SJEUR4XA
# secret_access_key:
# secure: H1+xHIRiO67xYudQmcvqD58w9ux79fLwKrOh0nCCi2N8fKyeT43L1/r4/F6oVSKoeT9MVgu0bj3XsmErqOw03h47wYvPKGcGDjY4KHj/Ptr9MRTkVkJ43yvVzWvnZWpsl4KlBsUHJGm5Tkb38aQOH9DbOgUiRSwcOused0GoBhQ=
# region: eu-west-1
# bucket: dita-ot
# skip_cleanup: true
# local-dir: build/distributions
# acl: public_read
# on:
# repo: dita-ot/dita-ot
# branch: develop
name: "Maven snapshot deployment"
install:
- "openssl aes-256-cbc -K $encrypted_1b8d0aeee504_key -iv $encrypted_1b8d0aeee504_iv -in .travis/24AC15F2.gpg.enc -out .travis/24AC15F2.gpg -d"
- "./gradlew"
script: "./gradlew --no-daemon --info publish -PossrhUsername=$OSSRH_USERNAME -PossrhPassword=$OSSRH_PASSWORD -Psigning.password=$SIGNING_PASSWORD -Psigning.keyId=24AC15F2 -Psigning.secretKeyRingFile=.travis/24AC15F2.gpg"
deploy:
- provider: script
skip_cleanup: true
script: "./gradlew --no-daemon --info publish -PossrhUsername=$OSSRH_USERNAME -PossrhPassword=$OSSRH_PASSWORD -Psigning.password=$SIGNING_PASSWORD -Psigning.keyId=24AC15F2 -Psigning.secretKeyRingFile=.travis/24AC15F2.gpg"
on:
repo: dita-ot/dita-ot
branch: develop
# Release
- stage: release
name: "Release distribution package deployment"
install:
- git submodule update --init --recursive
- "./gradlew"
script: "./gradlew dist -Pcommit=${TRAVIS_COMMIT} -Ptag=${TRAVIS_TAG} -PskipGenerateDocs=${SKIP_GENERATE_DOCS} --stacktrace --no-daemon"
deploy:
- provider: releases
api_key:
secure: d2vveLfRh+KvjkuJtahHB4buR7qpUXZ7ccrmgwALVboh7BhMgZgdX/puHiEzsiS4CX0xNcV2PpdF6VBGsbMg8TAFn5ap5he7y5MnC5Rt9iaJQtMKuoV3GQ1IoZZOUCRswgpjyLOSxuP3HDgyNn44i9eYT5I9N0wkxQzaleho8Og=
skip_cleanup: true
file_glob: true
file: build/distributions/*.zip
on:
tags: true
repo: dita-ot/dita-ot
- name: "Maven release deployment"
install:
- "openssl aes-256-cbc -K $encrypted_1b8d0aeee504_key -iv $encrypted_1b8d0aeee504_iv -in .travis/24AC15F2.gpg.enc -out .travis/24AC15F2.gpg -d"
- "./gradlew"
script: skip
deploy:
- provider: script
skip_cleanup: true
script: "./gradlew --no-daemon --info publish -PossrhUsername=$OSSRH_USERNAME -PossrhPassword=$OSSRH_PASSWORD -Psigning.password=$SIGNING_PASSWORD -Psigning.keyId=24AC15F2 -Psigning.secretKeyRingFile=.travis/24AC15F2.gpg"
on:
tags: true
repo: dita-ot/dita-ot
- name: "Plug-in registry pull-request"
install: "./gradlew"
script: skip
deploy:
- provider: script
script: bash .travis/registry.sh
skip_cleanup: true
on:
tags: true
repo: dita-ot/dita-ot
# Deployment
# - state: deploy
# name: "Deploy Docker"
# install: skip
# script: skip
# deploy:
# - provider: script
# skip_cleanup: true
# script: |-
# docker login docker.pkg.github.com --username $GITHUB_USER --password $GITHUB_PACKAGE_REGISTRY
# TAG=${TRAVIS_TAG} docker build --tag docker.pkg.github.com/dita-ot/dita-ot/dita-ot:${TRAVIS_TAG} --build-arg VERSION=${TRAVIS_TAG} .
# TAG=${TRAVIS_TAG} docker push docker.pkg.github.com/dita-ot/dita-ot/dita-ot:${TRAVIS_TAG}
# on:
# tags: true
# repo: dita-ot/dita-ot
notifications:
slack:
secure: IAA4d9O2Dw1hkpY9cwxJz++VMjkgbV3EuaS09DGFujvHl2eQtpKTloE0/CDF+NZA4tcbH1dNqsGw3ETLmrqA581CLpmiiq3LG02cDMoSXZeOKB/9vo6tvLFg0UMawzo+FomJS/hvCmS5KirrFqZQKE5g6SCC05UBM5nwI5d0vOw=