Skip to content

Merge pull request #146 from ecos-umons/dependabot/github_actions/act… #308

Merge pull request #146 from ecos-umons/dependabot/github_actions/act…

Merge pull request #146 from ecos-umons/dependabot/github_actions/act… #308

Workflow file for this run

name: CodeQL security analysis for Java
on:
push:
branches: [ "main" ]
pull_request:
branches: [ "main" ]
schedule:
- cron: '42 1 * * 2'
permissions:
contents: read
jobs:
build:
name: compiling and security scanning
runs-on: ubuntu-latest
timeout-minutes: 360
permissions:
actions: read
contents: read
security-events: write
steps:
- name: Harden Runner
uses: step-security/harden-runner@cb605e52c26070c328afc4562f0b4ada7618a84e # v2.10.4
with:
egress-policy: audit
- name: Checkout repository
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
- name: Set up with Java
uses: actions/setup-java@3a4f6e1af504cf6a31855fa899c6aa5355ba6c12 # v4.7.0
with:
distribution: 'temurin'
java-version: 21
cache: 'maven'
- name: Initialize CodeQL for security scanning
uses: github/codeql-action/init@b6a472f63d85b9c78a3ac5e89422239fc15e9b3c # v3.28.1
with:
languages: 'java-kotlin'
- name: Compile Java source code with Maven
run: mvn -B compile --file pom.xml
# unit tests are not run since they are not required for the CodeQL security analysis
- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@b6a472f63d85b9c78a3ac5e89422239fc15e9b3c # v3.28.1
with:
category: "/language:java-kotlin"