/
.travis.yml
30 lines (25 loc) · 1.29 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
sudo: required
language: bash
services:
- docker
before_install:
- sudo apt-get update -qq
- sudo apt-get install -qq default-jdk
- docker login --username "$DOCKER_USERNAME" --password "$DOCKER_PASSWORD"
- docker build -t inaetics/buildroot_minimum_celix buildroot_minimum_celix
- docker build -t inaetics/cagent_builder cagent_builder
- docker run inaetics/cagent_builder build_script > cagent_builder.sh && chmod +x cagent_builder.sh
install:
- ./cagent_builder.sh make_celix_agent
- ./cagent_builder.sh make_node_agent_bundles
after_success:
- test $TRAVIS_PULL_REQUEST == "false" && test $TRAVIS_BRANCH == "master" &&
docker push inaetics/buildroot_minimum_celix &&
docker push inaetics/cagent_builder &&
docker push inaetics/celix-agent &&
git config --global user.name "Travis CI" && git config --global user.email bpetri@gmx.net &&
git clone https://github.com/INAETICS/bundles.git $TRAVIS_BUILD_DIR/bundles && cd $TRAVIS_BUILD_DIR/bundles &&
git config credential.helper "store --file=.git/credentials" &&
echo "https://$GITHUB_TOKEN:@github.com" > .git/credentials &&
cp $TRAVIS_BUILD_DIR/deploy/*.jar $TRAVIS_BUILD_DIR/bundles/default-resources &&
git add default-resources/*.jar && git commit -m "build $TRAVIS_REPO_SLUG $TRAVIS_COMMIT" && git push -f