Files
firezone/.github/workflows/_codeql.yml
Thomas Eizinger 4e95dd1cb6 ci: fail fast inside the merge queue (#10746)
Setting `fail-fast: false` unsurprisingly makes our CI fail pretty
slowly. This is especially noticable in the merge queue where a
long-running job could still hold up the entire queue even though a
different job has failed already and the PR is never going to make it in
anyway.

To avoid this scenario, we set `fail-fast: true` whenever we are in the
merge queue.
2025-10-28 10:42:02 -07:00

45 lines
1.5 KiB
YAML

name: "CodeQL"
on:
workflow_call:
push:
branches:
- main
jobs:
analyze:
name: analyze-${{ matrix.working-directory }}
runs-on: ${{ (matrix.language == 'swift' && 'macos-14') || 'ubuntu-24.04' }}
timeout-minutes: ${{ (matrix.language == 'swift' && 120) || 360 }}
permissions:
actions: read
contents: read
security-events: write
strategy:
fail-fast: ${{ github.event_name == 'merge_group' }}
matrix:
include:
- language: "javascript-typescript"
working-directory: "website/"
- language: "javascript-typescript"
working-directory: "elixir/apps/web/assets/"
# TODO
# - language: 'java-kotlin'
# working-directory: 'kotlin/android'
# - language: 'swift'
# working-directory: 'swift/apple'
steps:
- name: Checkout repository
uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
- name: Initialize CodeQL
uses: github/codeql-action/init@v3
with:
languages: ${{ matrix.language }}
- name: Autobuild
uses: github/codeql-action/autobuild@48ab28a6f5dbc2a99bf1e0131198dd8f1df78169 # v3.28.0
with:
working-directory: ${{ matrix.working-directory }}
- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@48ab28a6f5dbc2a99bf1e0131198dd8f1df78169 # v3.28.0
with:
category: "/language:${{matrix.language}}"