Skip to content

Commit

Permalink
feat(ci): fix CodeQL findings
Browse files Browse the repository at this point in the history
  • Loading branch information
aellwein committed Jan 11, 2025
1 parent 4562c4e commit 5fe5a05
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 6 deletions.
17 changes: 12 additions & 5 deletions .github/workflows/go.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,16 +8,20 @@ on:

jobs:
build:
permissions:
contents: read
pull-requests: write

runs-on: ubuntu-latest
strategy:
matrix:
go: ["1.22", "1.23"]
steps:
- name: Checkout
uses: actions/checkout@v4
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2

- name: Set up Go ${{ matrix.go }}
uses: actions/setup-go@v5
uses: actions/setup-go@3041bf56c941b39c61721a86cd11f3bb1338122a # v5.2.0
with:
go-version: ${{ matrix.go }}

Expand All @@ -29,21 +33,24 @@ jobs:
codecov:
name: codecov
runs-on: ubuntu-latest
permissions:
contents: read
pull-requests: write
steps:
- name: Set up Go 1.22
uses: actions/setup-go@v5
uses: actions/setup-go@3041bf56c941b39c61721a86cd11f3bb1338122a # v5.2.0
with:
go-version: "1.22"

- name: Checkout
uses: actions/checkout@v4
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2

- name: Generate coverage report
run: |
go test ./... -coverprofile=coverage.txt -covermode=atomic
- name: Upload coverage report
uses: codecov/codecov-action@v4
uses: codecov/codecov-action@b9fd7d16f6d7d1b5d2bec1a2887e65ceed900238 # v4.6.0
env:
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
with:
Expand Down
2 changes: 1 addition & 1 deletion go.mod
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
module github.com/aellwein/netcup-dns-api

go 1.22
go 1.22.10

require github.com/stretchr/testify v1.8.4

Expand Down

0 comments on commit 5fe5a05

Please sign in to comment.