Repository navigation
71 lines (71 loc) 路 2.04 KB
/
Copy pathcodeql.yaml
File metadata and controls
71 lines (71 loc) 路 2.04 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
---
name: CodeQL
concurrency:
cancel-in-progress: true
group: ${{ github.workflow }}-${{ github.ref }}
on:
pull_request:
branches:
- main
paths-ignore:
- "docs/**"
push:
branches:
- main
paths-ignore:
- "docs/**"
schedule:
- cron: "17 4 * * 1"
permissions:
contents: read
env:
GOTOOLCHAIN: local
GOFLAGS: "-tags=nowatcher,nobadger,nomysql,nopgx"
jobs:
analyze:
name: Analyze (${{ matrix.language }})
runs-on: ubuntu-latest
permissions:
contents: read
security-events: write
strategy:
fail-fast: false
matrix:
include:
- language: actions
build-mode: none
- language: c-cpp
build-mode: manual
- language: go
build-mode: manual
steps:
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
with:
persist-credentials: false
- if: matrix.build-mode == 'manual'
uses: ./.github/actions/setup-go
with:
# A warm build cache skips the compiler calls the extractors trace
cache: "false"
- if: matrix.build-mode == 'manual'
uses: ./.github/actions/setup-php
- name: Install libbrotli-dev
if: matrix.build-mode == 'manual'
run: sudo apt-get install -y libbrotli-dev
- name: Set CGO flags
if: matrix.build-mode == 'manual'
run: echo "CGO_CFLAGS=$(php-config --includes)" >> "${GITHUB_ENV}"
- uses: github/codeql-action/init@6f2ac81f5cd81fe351a197ba0b00d91d03cd2aee # v4.39.0
with:
languages: ${{ matrix.language }}
build-mode: ${{ matrix.build-mode }}
- name: Build
if: matrix.build-mode == 'manual'
run: go build ./...
- name: Build Caddy module
if: matrix.build-mode == 'manual'
working-directory: caddy/
run: go build ./...
- uses: github/codeql-action/analyze@6f2ac81f5cd81fe351a197ba0b00d91d03cd2aee # v4.39.0
with:
category: /language:${{ matrix.language }}