Skip to content
This repository has been archived by the owner on Jan 12, 2024. It is now read-only.

Commit

Permalink
Initial Commit of Migration to GH Actions (#60)
Browse files Browse the repository at this point in the history
* Migration to GH Actions and upgrade of Jetty
  • Loading branch information
tunderwood authored Nov 17, 2020
1 parent c84df10 commit b6bc1bc
Show file tree
Hide file tree
Showing 7 changed files with 98 additions and 37 deletions.
12 changes: 0 additions & 12 deletions .github/dependabot.yml

This file was deleted.

47 changes: 47 additions & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
@@ -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/[email protected]
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
47 changes: 47 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -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/[email protected]
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
21 changes: 0 additions & 21 deletions .travis.yml

This file was deleted.

2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

[ ![Download](https://api.bintray.com/packages/nike/maven/cerberus-client/images/download.svg) ](https://bintray.com/nike/maven/cerberus-client/_latestVersion)
[![][travis img]][travis]
[![Coverage Status](https://coveralls.io/repos/github/Nike-Inc/cerberus-java-client/badge.svg?branch=master)](https://coveralls.io/github/Nike-Inc/cerberus-java-client)
[![codecov](https://codecov.io/gh/Nike-Inc/cerberus-java-client/branch/master/graph/badge.svg)](https://codecov.io/gh/Nike-Inc/cerberus-java-client)
[![][license img]][license]

This is a Java based client library for Cerberus that is built on top of Nike's Cerberus client.
Expand Down
2 changes: 1 addition & 1 deletion gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,6 @@
# See the License for the specific language governing permissions and
# limitations under the License.
#
version=7.3.2
version=7.3.3
groupId=com.nike
artifactId=cerberus-client
4 changes: 2 additions & 2 deletions gradle/dependencies.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -30,8 +30,8 @@ configurations.all {
force "net.sourceforge.pmd:pmd-java:6.21.0"

dependencySubstitution {
substitute module("org.mortbay.jetty:jetty") with module("org.eclipse.jetty:jetty-server:9.4.31.v20200723")
substitute module("org.mortbay.jetty:jetty-util") with module("org.eclipse.jetty:jetty-util:9.4.31.v20200723")
substitute module("org.mortbay.jetty:jetty") with module("org.eclipse.jetty:jetty-server:9.4.34.v20201102")
substitute module("org.mortbay.jetty:jetty-util") with module("org.eclipse.jetty:jetty-util:9.4.34.v20201102")
substitute module("dom4j:dom4j:1.6.1") with module("org.dom4j:dom4j:2.1.3")
}
}
Expand Down

0 comments on commit b6bc1bc

Please sign in to comment.