Skip to content

Commit

Permalink
story(security): add codeql workflow (#12)
Browse files Browse the repository at this point in the history
* build(security): enable codeql

* chore(issue-12): improve workflow naming
  • Loading branch information
Zaba505 authored Dec 10, 2023
1 parent 46fc70d commit d136956
Show file tree
Hide file tree
Showing 2 changed files with 43 additions and 1 deletion.
3 changes: 2 additions & 1 deletion .github/workflows/build.yaml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: build
name: Go

on:
push:
Expand All @@ -8,6 +8,7 @@ on:

jobs:
build:
name: Build
runs-on: ubuntu-latest
steps:
- name: Checkout
Expand Down
41 changes: 41 additions & 0 deletions .github/workflows/codeql.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
name: "CodeQL"

on:
push:
branches: [ "main" ]
pull_request:
branches: [ "main" ]
schedule:
- cron: '34 11 * * 3'

jobs:
analyze:
name: Analyze
runs-on: ${{ (matrix.language == 'swift' && 'macos-latest') || 'ubuntu-latest' }}
timeout-minutes: ${{ (matrix.language == 'swift' && 120) || 360 }}
permissions:
actions: read
contents: read
security-events: write

strategy:
fail-fast: false
matrix:
language: [ 'go' ]

steps:
- name: Checkout repository
uses: actions/checkout@v3

- name: Initialize CodeQL
uses: github/codeql-action/init@v2
with:
languages: ${{ matrix.language }}

- name: Autobuild
uses: github/codeql-action/autobuild@v2

- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@v2
with:
category: "/language:${{matrix.language}}"

0 comments on commit d136956

Please sign in to comment.