Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Release Stage #66

Open
wants to merge 32 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
32 commits
Select commit Hold shift + click to select a range
4adc9fc
add release workflow
carlosthe19916 Dec 12, 2019
573b706
remove test just for testing
carlosthe19916 Dec 12, 2019
977bea4
fix invalid script
carlosthe19916 Dec 12, 2019
faa63d8
Release 0.0.1
carlosthe19916 Dec 12, 2019
cc4e6c9
Prepare next release 0.0.2-SNAPSHOT
carlosthe19916 Dec 12, 2019
587880e
change release file
carlosthe19916 Dec 12, 2019
dd75790
remove useless files
carlosthe19916 Dec 12, 2019
52d5374
Release 0.0.2
carlosthe19916 Dec 12, 2019
c8ac041
Prepare next release 0.0.3-SNAPSHOT
carlosthe19916 Dec 12, 2019
83c9a8d
change script execution
carlosthe19916 Dec 12, 2019
3b4603c
change if
carlosthe19916 Dec 12, 2019
43344fb
Release 0.0.3
carlosthe19916 Dec 12, 2019
522719b
Prepare next release 0.0.4-SNAPSHOT
carlosthe19916 Dec 12, 2019
6558237
change if
carlosthe19916 Dec 12, 2019
bda1c1e
Release 0.0.4
carlosthe19916 Dec 12, 2019
66d7d8d
Prepare next release 0.0.5-SNAPSHOT
carlosthe19916 Dec 12, 2019
a555ca4
pull fuse image
carlosthe19916 Dec 12, 2019
0051fb1
Release 0.0.5
carlosthe19916 Dec 12, 2019
88402f4
Prepare next release 0.0.6-SNAPSHOT
carlosthe19916 Dec 12, 2019
3a1abeb
pull fuse image
carlosthe19916 Dec 12, 2019
6961f81
Release 0.0.6
carlosthe19916 Dec 12, 2019
d8face9
Prepare next release 0.0.7-SNAPSHOT
carlosthe19916 Dec 12, 2019
8392caa
pull fuse image
carlosthe19916 Dec 12, 2019
dcd55e3
Release 0.0.7
carlosthe19916 Dec 12, 2019
ce6d6c0
Prepare next release 0.0.8-SNAPSHOT
carlosthe19916 Dec 12, 2019
655626c
pull fuse image
carlosthe19916 Dec 12, 2019
0176e5f
Release 0.0.8
carlosthe19916 Dec 12, 2019
3e62c17
Prepare next release 0.0.9-SNAPSHOT
carlosthe19916 Dec 12, 2019
2012383
pull fuse image
carlosthe19916 Dec 12, 2019
544f057
change release organization
carlosthe19916 Dec 12, 2019
9d70ec6
remove useless files
carlosthe19916 Dec 12, 2019
92730a3
remove useless files
carlosthe19916 Dec 12, 2019
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 11 additions & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,8 @@ notifications:
email: false
jdk:
- openjdk8
services:
- docker
addons:
sonarcloud:
organization: project-xavier
Expand All @@ -18,3 +20,12 @@ jobs:
- mvn test -DtestLogRootLevel=warn -Pcoverage
- 'if [ "$TRAVIS_PULL_REQUEST" = "false" ]; then sonar-scanner; fi'
- bash <(curl -s https://codecov.io/bash)
- stage: Release
script:
- ./.travis/release.sh
deploy:
provider: releases
api_key: $GITHUB_OAUTH_TOKEN
skip_cleanup: true
on:
tags: true
22 changes: 22 additions & 0 deletions .travis/release.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
#!/bin/bash
if [ -n "$TRAVIS_TAG" ]; then
# We can choose eithe follow this block of commands to download the image without authentication in Red Hat Registry
# Or we can create a Registry Service Account and login here
docker pull registry.access.redhat.com/fuse7/fuse-java-openshift
docker tag registry.access.redhat.com/fuse7/fuse-java-openshift:latest fuse7/fuse-java-openshift:latest
docker tag registry.access.redhat.com/fuse7/fuse-java-openshift:latest fuse7/fuse-java-openshift:1.3 # fabric8 use this specific version

# Build image
mvn fabric8:build -Dfabric8.mode=kubernetes

# Tag Docker image
docker tag xavier/xavier-integration:"$TRAVIS_TAG" projectxavier/xavier-integration:latest
docker tag xavier/xavier-integration:"$TRAVIS_TAG" projectxavier/xavier-integration:"$TRAVIS_TAG"

# Docker Hub login
docker login -u "$DOCKER_USERNAME" -p "$DOCKER_PASSWORD";

# Docker push
docker push projectxavier/xavier-integration:latest
docker push projectxavier/xavier-integration:"$TRAVIS_TAG"
fi
25 changes: 25 additions & 0 deletions release.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
#!/usr/bin/env bash

echo "===================================="
read -p "Enter Release: " releaseVersion
read -p "Enter Next Release (SNAPSHOT): " nextVersion
read -p "Enter Github Username: " username
read -s -p "Enter Github Password: " password

# Update to release
mvn versions:set -DnewVersion="$releaseVersion"

git add .
git commit -m "Release $releaseVersion"
git push "https://$username:[email protected]/project-xavier/xavier-integration.git"

# Create tag and push
git tag "$releaseVersion"
git push "https://$username:[email protected]/project-xavier/xavier-integration.git" --tags

# Create next snapshot
mvn versions:set -DnewVersion="$nextVersion-SNAPSHOT"

git add .
git commit -m "Prepare next release $nextVersion-SNAPSHOT"
git push "https://$username:[email protected]/project-xavier/xavier-integration.git"