ci: add CodeQL, Semgrep, Gitleaks, Trivy security scanning

This commit is contained in:
Mortalus
2026-02-21 05:24:54 +01:00
parent a1deee92cc
commit 38d1ca339a
4 changed files with 163 additions and 0 deletions

42
.github/workflows/codeql.yml vendored Normal file
View File

@@ -0,0 +1,42 @@
name: "CodeQL Security Analysis"
on:
push:
branches: [main]
pull_request:
branches: [main]
schedule:
# Run weekly on Monday at 6 AM UTC
- cron: '0 6 * * 1'
jobs:
analyze:
name: Analyze Code
runs-on: ubuntu-latest
permissions:
actions: read
contents: read
security-events: write
strategy:
fail-fast: false
matrix:
language: ['javascript']
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Initialize CodeQL
uses: github/codeql-action/init@v3
with:
languages: ${{ matrix.language }}
queries: security-extended # More thorough than default
- name: Autobuild
uses: github/codeql-action/autobuild@v3
- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@v3
with:
category: "/language:${{matrix.language}}"