add security scan

This commit is contained in:
Ruidy 2022-03-31 11:29:26 -04:00
parent 7cdbf7717f
commit a8a485a537
4 changed files with 11 additions and 2 deletions

View file

@ -4,4 +4,5 @@
.git*
.idea/
.golangci.yml
coverage.out
coverage.out
.trivycache/

1
.gitignore vendored
View file

@ -58,3 +58,4 @@ Network Trash Folder
Temporary Items
.apdisk
docs/public
.trivycache/

View file

@ -1,4 +1,5 @@
TEST = "go test ./... -coverpkg=./... -coverprofile coverage.out -covermode=count; go tool cover -func coverage.out; rm coverage.out"
IMAGE=underscore
build:
docker build -t underscore:latest .
@ -6,6 +7,12 @@ build:
test: build
docker run --name underscore --rm -i -t underscore sh -c $(TEST)
scan:
trivy --cache-dir .trivycache/ image --exit-code 0 --no-progress --severity CRITICAL $(IMAGE)
scan-config:
trivy config .
docs:
cd docs && hugo server -D

View file

@ -1,5 +1,5 @@
---
title: underscore
title: _Underscore
---
![License](https://img.shields.io/github/license/rjNemo/underscore?style=for-the-badge)