chore(deps): update contributor-assistant/github-action action to v2.6.0 #2872
Workflow file for this run
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
name: PR build | |
concurrency: | |
group: pr-${{ github.event.pull_request.number }} | |
cancel-in-progress: true | |
on: | |
pull_request: | |
jobs: | |
# TODO: lycheeverse/lychee:latest on which this job depends is broken, temporarily turning it off | |
#check-links: | |
# runs-on: ubuntu-20.04 | |
# steps: | |
# - uses: actions/checkout@v2 | |
# - name: Check all links in *.md files | |
# id: lychee | |
# uses: lycheeverse/lychee-action@v1.0.8 | |
# with: | |
# args: >- | |
# -v -n "*.md" "**/*.md" | |
# --exclude "https://developers.redhat.com/download-manager/file/jboss-eap-.*.zip" | |
# --exclude "http://yourendpoint.*" | |
# --exclude "https://ingest.us0.signalfx.com.*" | |
# --exclude "http://localhost*" | |
# - name: Fail if there were link errors | |
# run: exit ${{ steps.lychee.outputs.exit_code }} | |
build: | |
runs-on: ubuntu-22.04 | |
steps: | |
- uses: actions/checkout@v4.1.7 | |
- name: Set up JDK 17 for running Gradle | |
uses: actions/setup-java@v4.3.0 | |
with: | |
distribution: temurin | |
java-version: 17 | |
- name: Cache Gradle Wrapper | |
uses: actions/cache@v4.0.2 | |
with: | |
path: ~/.gradle/wrapper | |
key: ${{ runner.os }}-gradle-wrapper-cache-${{ hashFiles('gradle/wrapper/gradle-wrapper.properties') }} | |
- name: Build and test | |
run: ./gradlew build -x :smoke-tests:test --scan --no-daemon | |
setup-muzzle-matrix: | |
runs-on: ubuntu-22.04 | |
outputs: | |
matrix: ${{ steps.set-matrix.outputs.matrix }} | |
steps: | |
- name: Check out repository | |
uses: actions/checkout@v4.1.7 | |
- name: Set up JDK 17 for running Gradle | |
uses: actions/setup-java@v4.3.0 | |
with: | |
distribution: temurin | |
java-version: 17 | |
- name: Cache Gradle Wrapper | |
uses: actions/cache@v4.0.2 | |
with: | |
path: ~/.gradle/wrapper | |
key: ${{ runner.os }}-gradle-wrapper-cache-${{ hashFiles('gradle/wrapper/gradle-wrapper.properties') }} | |
- id: set-matrix | |
run: echo "matrix={\"module\":[\"$(./gradlew -q instrumentation:listMuzzleInstrumentations | xargs echo | sed 's/ /","/g')\"]}" >> $GITHUB_OUTPUT | |
muzzle: | |
needs: setup-muzzle-matrix | |
runs-on: ubuntu-22.04 | |
strategy: | |
matrix: ${{fromJson(needs.setup-muzzle-matrix.outputs.matrix)}} | |
fail-fast: false | |
steps: | |
- name: Check out repository | |
uses: actions/checkout@v4.1.7 | |
- name: Set up JDK 17 for running Gradle | |
uses: actions/setup-java@v4.3.0 | |
with: | |
distribution: temurin | |
java-version: 17 | |
- name: Cache Gradle Wrapper | |
uses: actions/cache@v4.0.2 | |
with: | |
path: ~/.gradle/wrapper | |
key: ${{ runner.os }}-gradle-wrapper-cache-${{ hashFiles('gradle/wrapper/gradle-wrapper.properties') }} | |
- name: Run muzzle | |
# using retry because of sporadic gradle download failures | |
uses: nick-invision/retry@v3.0.0 | |
with: | |
# timing out has not been a problem, these jobs typically finish in 2-3 minutes | |
timeout_minutes: 15 | |
max_attempts: 3 | |
command: ./gradlew ${{ matrix.module }}:muzzle --stacktrace --no-daemon | |
smoke-test: | |
runs-on: ${{ matrix.os }} | |
permissions: | |
packages: read | |
strategy: | |
matrix: | |
os: [ windows-2019, ubuntu-22.04 ] | |
suite: [ "glassfish", "jboss", "jetty", "liberty", "profiler", "tomcat", "tomee", "weblogic", "websphere", "wildfly", "other" ] | |
exclude: | |
- os: ${{ !contains(github.event.pull_request.labels.*.name, 'test windows') && 'windows-2019' || '' }} | |
- os: windows-2019 | |
suite: websphere | |
- os: windows-2019 | |
suite: profiler | |
fail-fast: false | |
steps: | |
- uses: actions/checkout@v4.1.7 | |
- name: Set up JDK 17 for running Gradle | |
uses: actions/setup-java@v4.3.0 | |
with: | |
distribution: temurin | |
java-version: 17 | |
- name: Cache Gradle Wrapper | |
uses: actions/cache@v4.0.2 | |
with: | |
path: ~/.gradle/wrapper | |
key: ${{ runner.os }}-gradle-wrapper-cache-${{ hashFiles('gradle/wrapper/gradle-wrapper.properties') }} | |
- name: Login to GitHub Container Registry | |
uses: docker/login-action@v3.3.0 | |
with: | |
registry: ghcr.io | |
username: ${{ github.repository_owner }} | |
password: ${{ secrets.GITHUB_TOKEN }} | |
# only run this step if 'test proprietary app servers' is present on the PR | |
if: ${{ startsWith(matrix.os, 'ubuntu') && contains(github.event.pull_request.labels.*.name, 'test proprietary app servers') }} | |
- name: Pull proprietary images | |
run: ./gradlew pullProprietaryTestImages --scan --no-daemon | |
# only run this step if 'test proprietary app servers' is present on the PR | |
if: ${{ startsWith(matrix.os, 'ubuntu') && contains(github.event.pull_request.labels.*.name, 'test proprietary app servers') }} | |
- name: Test | |
run: ./gradlew :smoke-tests:test -PsmokeTestSuite=${{ matrix.suite }} --scan --no-daemon | |
shellcheck: | |
runs-on: ubuntu-22.04 | |
steps: | |
- uses: actions/checkout@v4.1.7 | |
- name: Install shell check | |
run: wget -qO- "https://github.com/koalaman/shellcheck/releases/download/v0.8.0/shellcheck-v0.8.0.linux.x86_64.tar.xz" | tar -xJv | |
- name: Run shellcheck | |
run: shellcheck-v0.8.0/shellcheck --format=gcc $(find scripts -name '*.sh') | |
license-check: | |
runs-on: ubuntu-22.04 | |
steps: | |
- uses: actions/checkout@v4.1.7 | |
- name: Set up JDK 17 for running Gradle | |
uses: actions/setup-java@v4.3.0 | |
with: | |
distribution: temurin | |
java-version: 17 | |
- name: Cache Gradle Wrapper | |
uses: actions/cache@v4.0.2 | |
with: | |
path: ~/.gradle/wrapper | |
key: ${{ runner.os }}-gradle-wrapper-cache-${{ hashFiles('gradle/wrapper/gradle-wrapper.properties') }} | |
- name: Generate license report | |
run: ./gradlew generateLicenseReport --no-daemon | |
- name: Check licenses | |
run: | | |
# add any untracked folders that may have been added by generateLicenseReport | |
git add licenses | |
# there's always going to one line difference due to the timestamp included in the report | |
if [[ $(git diff --cached --shortstat licenses) == " 1 file changed, 1 insertion(+), 1 deletion(-)" ]] | |
then | |
echo "Licenses are up-to-date." | |
else | |
echo "Licenses are not up-to-date, please run './gradlew generateLicenseReport' locally and commit." | |
echo | |
echo "$(git diff --cached --stat licenses)" | |
echo | |
echo "$(git diff --cached licenses)" | |
exit 1 | |
fi | |
generate-metadata: | |
runs-on: ubuntu-22.04 | |
steps: | |
- uses: actions/checkout@v4.1.7 | |
- name: Set up JDK 17 for running Gradle | |
uses: actions/setup-java@v4.3.0 | |
with: | |
distribution: temurin | |
java-version: 17 | |
- name: Cache Gradle Wrapper | |
uses: actions/cache@v4.0.2 | |
with: | |
path: ~/.gradle/wrapper | |
key: ${{ runner.os }}-gradle-wrapper-cache-${{ hashFiles('gradle/wrapper/gradle-wrapper.properties') }} | |
# verify that metadata generation succeeds | |
- name: Generate metadata | |
run: ./gradlew :metadata-generator:generateMetadata --no-daemon | |
- name: Upload metadata yaml | |
uses: actions/upload-artifact@v4.4.0 | |
with: | |
name: splunk-otel-java-metadata.yaml | |
path: metadata-generator/build/splunk-otel-java-metadata.yaml |