mirror of
https://github.com/keycloak/keycloak.git
synced 2026-01-25 16:42:34 +00:00
Failure to upload the SARIF file on pull requests (#10725)
The changes proposed here will resolve the issues we have with pull-request after the merge of #10606. It creates 3 different workflows to conditionally execute the job based on changes submitted. A detailed explanation about the issue can be found on #10717. Resolves #10717
This commit is contained in:
committed by
GitHub
parent
1b214aaed6
commit
6ebad26904
45
.github/workflows/codeql-java-analysis.yml
vendored
Normal file
45
.github/workflows/codeql-java-analysis.yml
vendored
Normal file
@@ -0,0 +1,45 @@
|
||||
# For most projects, this workflow file will not need changing; you simply need
|
||||
# to commit it to your repository.
|
||||
#
|
||||
# You may wish to alter this file to override the set of languages analyzed,
|
||||
# or to provide custom queries or build logic.
|
||||
name: "CodeQL Java"
|
||||
|
||||
on:
|
||||
push:
|
||||
branches: [main]
|
||||
pull_request:
|
||||
branches: [main]
|
||||
paths:
|
||||
- '**.java'
|
||||
schedule:
|
||||
- cron: '0 9 * * 2'
|
||||
|
||||
jobs:
|
||||
analyze:
|
||||
name: CodeQL analyze
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v2
|
||||
- uses: actions/setup-java@v1
|
||||
with:
|
||||
java-version: '11'
|
||||
|
||||
- name: Update maven settings
|
||||
run: mkdir -p ~/.m2 ; cp .github/settings.xml ~/.m2/
|
||||
|
||||
- name: Initialize CodeQL
|
||||
uses: github/codeql-action/init@v1
|
||||
env:
|
||||
CODEQL_ACTION_EXTRA_OPTIONS: '{"database":{"finalize":["--no-run-unnecessary-builds"]}}'
|
||||
with:
|
||||
languages: java
|
||||
|
||||
- name: Build Keycloak
|
||||
run: mvn install -Dmaven.test.skip -DskipQuarkus -DskipTestsuite -DskipExamples -DskipTests
|
||||
|
||||
- name: Perform CodeQL Analysis
|
||||
uses: github/codeql-action/analyze@v1
|
||||
env:
|
||||
CODEQL_ACTION_EXTRA_OPTIONS: '{"database":{"interpret-results":["--max-paths",0]}}'
|
||||
Reference in New Issue
Block a user