diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml new file mode 100644 index 0000000..189c845 --- /dev/null +++ b/.github/workflows/build.yml @@ -0,0 +1,47 @@ +# This workflow will build a Java project with Gradle +# For more information see: https://help.github.com/actions/language-and-framework-guides/building-and-testing-java-with-gradle + +name: Build + +on: + push: + branches: + - '*' + pull_request: + branches: + - master + schedule: + - cron: "0 22 * * 1" + +jobs: + build: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v2 + - name: Set up JDK 8 + uses: actions/setup-java@v1 + with: + java-version: 8 + - name: Grant execute permission for gradlew + run: chmod +x gradlew + - name: Build with Gradle + run: ./gradlew assemble + - name: Test with Gradle + run: ./gradlew check + - name: Upload coverage report to CodeCov + uses: codecov/codecov-action@v1 + with: + token: ${{ secrets.CODECOV_TOKEN }} # not required for public repos + file: ./build/reports/cobertura/coverage.xml # optional + fail_ci_if_error: true # optional (default = false) + verbose: true + - name: Slack notification when master build fails + if: ${{ failure() && github.ref == 'refs/heads/master'}} + uses: rtCamp/action-slack-notify@v2.1.0 + env: + SLACK_WEBHOOK: ${{ secrets.SLACK_WEBHOOK }} + SLACK_CHANNEL: cerberus-alerts + SLACK_MESSAGE: 'Cerberus main build has failed :build-failed:' + SLACK_ICON: https://github.githubassets.com/images/modules/logos_page/GitHub-Mark.png + SLACK_TITLE: Cerberus Build Failure Notification + SLACK_USERNAME: GitHub Actions \ No newline at end of file diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml new file mode 100644 index 0000000..9df0fad --- /dev/null +++ b/.github/workflows/release.yml @@ -0,0 +1,47 @@ +# This workflow will build a Java project with Gradle +# For more information see: https://help.github.com/actions/language-and-framework-guides/building-and-testing-java-with-gradle + +name: Release + +on: + push: + # Sequence of patterns matched against refs/tags + tags: + - 'v*' # Push events to matching v*, i.e. v1.0, v20.15.10 +jobs: + Build-and-Release: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v2 + - name: Set up JDK 8 + uses: actions/setup-java@v1 + with: + java-version: 8 + - name: Grant execute permission for gradlew + run: chmod +x gradlew + - name: Build with Gradle + run: ./gradlew assemble + - name: Test with Gradle + run: ./gradlew check + - name: Upload coverage report to CodeCov + uses: codecov/codecov-action@v1 + with: + token: ${{ secrets.CODECOV_TOKEN }} # not required for public repos + file: ./build/reports/cobertura/coverage.xml # optional + fail_ci_if_error: true # optional (default = false) + verbose: true + - name: Release artifact to Bintray + env: + BINTRAY_USER: ${{ secrets.BINTRAY_USER }} + BINTRAY_KEY: ${{ secrets.BINTRAY_KEY}} + run: ./gradlew bintrayUpload + - name: Slack notification when release fails + if: ${{ failure() }} + uses: rtCamp/action-slack-notify@v2.1.0 + env: + SLACK_WEBHOOK: ${{ secrets.SLACK_WEBHOOK }} + SLACK_CHANNEL: cerberus-alerts + SLACK_MESSAGE: 'Cerberus release workflow has failed :build-failed:' + SLACK_ICON: https://github.githubassets.com/images/modules/logos_page/GitHub-Mark.png + SLACK_TITLE: Cerberus Build Failure Notification + SLACK_USERNAME: GitHub Actions \ No newline at end of file diff --git a/.travis.yml b/.travis.yml deleted file mode 100644 index eaefdaa..0000000 --- a/.travis.yml +++ /dev/null @@ -1,21 +0,0 @@ -language: java -jdk: -- openjdk8 -cache: - directories: - - "$HOME/.m2" -after_success: -- "./gradlew cobertura coveralls --stacktrace" -- test "${TRAVIS_PULL_REQUEST}" == "false" && test "${TRAVIS_TAG}" != "" && ./gradlew - bintrayUpload --stacktrace -env: - global: - - secure: V+98P90JRZuUrfc753trYHkMc2Dz/U/NVkK6jlIj/QVhEec7TtnIcPk4Vkysjl+XdYlpdEQ5oDIWNcXiUlVgDZhuN5dj5QwICC79yjLWu48SIKXz+O051elYG/CciNHiGrF2lIno0qwcgCOL7l6al0JHHzfsSr5jZ/3+DOmUjgeRDSgkWO2n9rGMGNHn+DoIX/4/t5fnjCIyZrBZVN14Op/BCQXekfSHfABnd3L0ZdqKPwaU1B3XUKtx5OhWjjE5dxhHd0GPwdKJdMToWfyKnI84TWX/KE7FsIrPf1FuyE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master AND (type = push OR type=cron) - on_success: change - on_failure: always - rooms: - - secure:CBgiFoO63tCweyUappuTLFZ7q+0XzNGQzeuSK0lpsVwUuWvTz36kUxuOIplJQmNtxJ/kdYM/rvziRlLen5i5unVp3GPDGgT0Zu8xOQyA9o5aNOHOA7lJViUmoNqt1oXAO/ZtcPMtLOwwQ/l4O3VBMd2LLRzKROt23NaGS5BFKF6kzhVR4Pookufn4aBcfqSXOfmOmyaSLIT7ugtQ52+1Z4sRKNTV2T8kSDRlEJvaCvUphX5eWMrF41Z69CbN2MSPzEXqmO7RO/vEEkAwgcR5jKvCZOJ8bVK67KXOu9+lZB85iIomUJogOcHlkF0+O6840XdTh4CCuM51zru2ZX1PK8I7wVbPBoi+850xoe11/zkBLgBylS5NfyVD+xRrOnKlXGw/uuLEDC4IM4lRRQsXUlU1vP10MvCuR9IehutwCSNGI9Uej1lXnE4scA/WKalKwbzywrS7MTJi+C2vRX6a1Z7yh3svmYRUxh8NZRkvSoqH4ayBc32Luwsyu8bKtx1KyApzPh4s940X3kmLBDta18mfkxQjbdUI+6qJDvoMYcHgUD120mAO4cmtiWIieLVI+m9WkCbUivQOySxH/UedEXALkZ5RcE/9tuBa5WgwXLftAH1bzaIFjw8ZeFAdTEq5wKNzPu/l+FLhUQntqyOYypYXKWXsJ0EESm2FGl3FBD8= diff --git a/README.md b/README.md index 38a5b3d..90a2dee 100644 --- a/README.md +++ b/README.md @@ -2,7 +2,7 @@ [ ![Download](https://api.bintray.com/packages/nike/maven/cerberus-archaius-client/images/download.svg) ](https://bintray.com/nike/maven/cerberus-archaius-client/_latestVersion) [![][travis img]][travis] -[![Coverage Status](https://coveralls.io/repos/github/Nike-Inc/cerberus-archaius-client/badge.svg)](https://coveralls.io/github/Nike-Inc/cerberus-archaius-client) +[![codecov](https://codecov.io/gh/Nike-Inc/cerberus-archaius-client/branch/master/graph/badge.svg)](https://codecov.io/gh/Nike-Inc/cerberus-archaius-client) [![][license img]][license] A java based client library that surfaces Cerberus secrets via Archaius. diff --git a/gradle.properties b/gradle.properties index dbf4c3c..14995a1 100644 --- a/gradle.properties +++ b/gradle.properties @@ -14,7 +14,7 @@ # limitations under the License. # -version=7.1.1 +version=7.1.2 groupId=com.nike artifactId=cerberus-archaius-client