-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #14 from Alvearie/release-3.1.0
Release 3.1-1.0.3
- Loading branch information
Showing
20 changed files
with
362 additions
and
70 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,57 @@ | ||
name: CI Workflow | ||
|
||
on: | ||
push: | ||
branches: [ '**' ] | ||
tags: [ '**' ] | ||
workflow_dispatch: | ||
|
||
concurrency: ci-${{ github.ref }} | ||
|
||
jobs: | ||
buildAndTest: | ||
name: Build, Test, and Package | ||
runs-on: ubuntu-latest | ||
env: | ||
RESOURCE_GROUP: hri-dev1-wdc-kube | ||
|
||
steps: | ||
- name: Set branch name environment variable | ||
uses: nelonoel/branch-name@v1.0.1 | ||
|
||
- uses: actions/checkout@v2 | ||
|
||
- name: Copyright Check | ||
run: ./copyrightCheck.sh | ||
|
||
- name: Set up adoptopenjdk8 | ||
uses: actions/setup-java@v2 | ||
with: | ||
java-version: '8' | ||
distribution: 'adopt' | ||
cache: 'gradle' | ||
|
||
- name: Set GitHub Tag environment variable | ||
if: startsWith(github.ref, 'refs/tags/v') == true | ||
run: | | ||
TAG_ID=${GITHUB_REF##*/} | ||
echo "ACTIONS_TAG=$TAG_ID" >> $GITHUB_ENV | ||
- name: Gradle build | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
run: ./gradlew clean build | ||
|
||
- name: Gradle publish | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
run: ./gradlew publish | ||
|
||
- name: Post Slack Update | ||
if: ${{ failure() && ( github.ref == 'refs/heads/main' || github.ref == 'refs/heads/develop' || startsWith(github.ref, 'refs/heads/support-') ) }} | ||
id: slack | ||
uses: slackapi/slack-github-action@v1.14.0 | ||
with: | ||
payload: "{\"Repo\":\"${{ github.repository }}\",\"Workflow\":\"${{ github.workflow }}\",\"Branch\":\"${{ env.BRANCH_NAME }}\",\"Link\":\"https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }}\"}" | ||
env: | ||
SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK_URL }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,45 @@ | ||
name: Code Scans | ||
|
||
on: | ||
push: | ||
branches: [ 'main', 'develop', 'support-*' ] | ||
pull_request: | ||
types: [opened, synchronize, reopened] | ||
|
||
concurrency: code-scans-${{ github.ref }} | ||
|
||
jobs: | ||
buildAndTest: | ||
name: Static Code Analysis | ||
runs-on: ubuntu-latest | ||
|
||
steps: | ||
- name: Set branch name environment variable | ||
uses: nelonoel/branch-name@v1.0.1 | ||
|
||
- uses: actions/checkout@v2 | ||
with: | ||
# full checkout for SonarCloud analysis | ||
fetch-depth: 0 | ||
|
||
- name: Set up Java 11 | ||
uses: actions/setup-java@v2 | ||
with: | ||
java-version: '11' | ||
distribution: 'adopt' | ||
cache: 'gradle' | ||
|
||
- name: SonarCloud Scan | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }} | ||
run: ./gradlew clean build sonarqube -Dsonar.login=$SONAR_TOKEN | ||
|
||
- name: Post Slack Update | ||
if: ${{ failure() && ( github.ref == 'refs/heads/main' || github.ref == 'refs/heads/develop' || startsWith(github.ref, 'refs/heads/support-') ) }} | ||
id: slack | ||
uses: slackapi/slack-github-action@v1.14.0 | ||
with: | ||
payload: "{\"Repo\":\"${{ github.repository }}\",\"Workflow\":\"${{ github.workflow }}\",\"Branch\":\"${{ env.BRANCH_NAME }}\",\"Link\":\"https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }}\"}" | ||
env: | ||
SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK_URL }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,61 @@ | ||
name: Pull Request Checks | ||
|
||
on: | ||
pull_request: | ||
types: [opened] | ||
pull_request_review: | ||
types: [submitted] | ||
workflow_dispatch: | ||
|
||
concurrency: pr-${{ github.ref }} | ||
|
||
jobs: | ||
dependency-checks: | ||
name: Dependency Checks | ||
# run if the PR was opened or there was a comment containing '/pr_checks' | ||
if: (github.event_name == 'pull_request') || (github.event_name == 'pull_request_review' && contains(github.event.review.body, '/pr_checks')) | ||
runs-on: ubuntu-latest | ||
env: | ||
RESOURCE_GROUP: hri-dev1-wdc-kube | ||
|
||
steps: | ||
- name: Set branch name environment variable | ||
run: echo "BRANCH_NAME=$(echo ${{github.event.pull_request.head.ref}} | tr / -)" >> $GITHUB_ENV | ||
|
||
- uses: actions/checkout@v2 | ||
|
||
- name: Set up adoptopenjdk8 | ||
uses: actions/setup-java@v2 | ||
with: | ||
java-version: '8' | ||
distribution: 'adopt-hotspot' | ||
cache: 'gradle' | ||
|
||
- name: Gradle build | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
run: ./gradlew clean build publishToMavenLocal | ||
|
||
- name: Check OpenSource Dependencies | ||
# override default -eo pipefail | ||
shell: bash --noprofile --norc {0} | ||
env: | ||
SONATYPE_OSS_PASSWORD: ${{ secrets.SONATYPE_OSS_PASSWORD }} | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
run: | | ||
./gradlew ossIndexAudit --info | ||
found=$? | ||
echo "VULNERABILITIES=$found" >> $GITHUB_ENV | ||
[[ "$found" == 1 ]] && echo "::error ::Vulnerabilities found in dependencies." | ||
exit 0 | ||
- uses: actions/github-script@v4 | ||
if: ${{ env.VULNERABILITIES != 0 }} | ||
with: | ||
script: | | ||
github.issues.createComment({ | ||
issue_number: context.issue.number, | ||
owner: context.repo.owner, | ||
repo: context.repo.repo, | ||
body: "## ⚠️ Vulnerabilities found in dependencies.\nSee the 'PR -> Vulnerability Checks' logs for more details: https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }}" | ||
}) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
/build | ||
|
||
# IntelliJ | ||
.idea | ||
.idea/ | ||
*.iml | ||
*.iws | ||
*.ipr | ||
.DS_Store | ||
|
||
# Gradle | ||
.gradle/ | ||
.gradletasknamecache | ||
gradle-app.setting | ||
|
||
# AppScan on Cloud - ASoC | ||
/dependencies | ||
appscan.irx | ||
appscan_logs.zip | ||
|
||
*.class | ||
*.log | ||
out |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.