Skip to content

Commit

Permalink
feat: Adding simple CI build (#1)
Browse files Browse the repository at this point in the history
* feat: Adding simple CI build

* fix: Ignore gosec warning as it is intended to be able to set the InsecureSkipVerify flag
  • Loading branch information
langecode authored Feb 8, 2024
1 parent 7d331f5 commit 0f2de77
Show file tree
Hide file tree
Showing 2 changed files with 40 additions and 0 deletions.
39 changes: 39 additions & 0 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
name: CI

on:
push:
branches: ["main"]
pull_request:
branches: ["**"]

jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3

- name: Mount bazel cache
uses: actions/cache@v3
with:
path: "~/.cache/bazel"
key: bazel

- name: Run tests
run: bazel test //...

- name: Run Gosec Security Scanner
uses: securego/gosec@master
env:
# https://github.com/securego/gosec/issues/776
GOROOT: ""
with:
args: ./...

- name: Run Trivy vulnerability scanner
uses: aquasecurity/trivy-action@master
with:
scan-type: "fs"
format: "table"
exit-code: "1"
ignore-unfixed: true
vuln-type: "library"
1 change: 1 addition & 0 deletions zenoss/zenoss.go
Original file line number Diff line number Diff line change
Expand Up @@ -87,6 +87,7 @@ func NewClient(baseURI, username, password, monitor string, insecureSkipTLSVerif
return &client{
client: &http.Client{
Transport: &http.Transport{
//#nosec G402
TLSClientConfig: &tls.Config{InsecureSkipVerify: insecureSkipTLSVerify},
},
},
Expand Down

0 comments on commit 0f2de77

Please sign in to comment.