CodeQL (daily) #857
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: CodeQL (daily) | |
on: | |
schedule: | |
# daily at 1:30 UTC | |
- cron: "30 1 * * *" | |
workflow_dispatch: | |
permissions: | |
contents: read | |
jobs: | |
analyze: | |
permissions: | |
actions: read # for github/codeql-action/init to get workflow details | |
security-events: write # for github/codeql-action/analyze to upload SARIF results | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4.1.7 | |
- name: Free disk space | |
run: .github/scripts/gha-free-disk-space.sh | |
- name: Set up Java 17 | |
uses: actions/setup-java@99b8673ff64fbf99d8d325f52d9a5bdedb8483e9 # v4.2.1 | |
with: | |
distribution: temurin | |
java-version-file: .java-version | |
- name: Initialize CodeQL | |
uses: github/codeql-action/init@4fa2a7953630fd2f3fb380f21be14ede0169dd4f # v3.25.12 | |
with: | |
languages: java | |
# using "latest" helps to keep up with the latest Kotlin support | |
# see https://github.com/github/codeql-action/issues/1555#issuecomment-1452228433 | |
tools: latest | |
- name: Setup Gradle | |
uses: gradle/actions/setup-gradle@d9c87d481d55275bb5441eef3fe0e46805f9ef70 # v3.5.0 | |
- name: Build | |
# skipping build cache is needed so that all modules will be analyzed | |
run: ./gradlew assemble -x javadoc --no-build-cache --no-daemon | |
- name: Perform CodeQL analysis | |
uses: github/codeql-action/analyze@4fa2a7953630fd2f3fb380f21be14ede0169dd4f # v3.25.12 | |
workflow-notification: | |
needs: | |
- analyze | |
if: always() | |
uses: ./.github/workflows/reusable-workflow-notification.yml | |
with: | |
success: ${{ needs.analyze.result == 'success' }} |