Run the following command line by setting your parameters.
vsp_defense scan --lang=go --api-key=<YOUR_API_KEY> --path=/work/demo/apps/vulnerable-go/ --project-name=vunerable-go;
image: golang:1.14
cache:
paths:
- /apt-cache
- /go/src/github.com
- /go/src/golang.org
- /go/src/google.golang.org
- /go/src/gopkg.in
stages:
- test
runscan:
stage: test
script:
- curl https://raw.githubusercontent.com/CloudDefenseAI/cd/master/latest/cd-latest-linux-x64.tar.gz > /tmp/cd-latest-linux-x64.tar.gz && tar -C /usr/local/bin -xzf /tmp/cd-latest-linux-x64.tar.gz && chmod +x /usr/local/bin/cdefense
- vsp_defense --lang=go --go --project-name=go-sample --api-key=$API_KEY --path=$PWD/go.sum --verbose
- echo $?