Run directly from a docker image:
docker run --rm ghcr.io/salsadigitalauorg/lagoon-csp-collector:main lagoon-csp-collector <flags>
Or add to your docker image:
COPY --from=ghcr.io/salsadigitalauorg/lagoon-csp-collector:main /usr/local/bin/lagoon-csp-collector /usr/local/bin/lagoon-csp-collector
$ lagoon-csp-collector -h
Usage of lagoon-csp-collector:
-api string
The endpoint to hydrate the CSP report
-port string
Port to run the collector on (default "3000")
-test-domain string
A domain to validate in the health check
An API endpoint to retrieve additional data from for the CSP, this is intended to return a Lagoon project name that matches the domain name for a the CSP report violation.
The port that the service runs on.
A domain that will be sent to api
during the health check to determine if the service is up and responding correctly.
git clone [email protected]:salsadigitalauorg/lagoon-csp-collector.git && cd lagoon-csp-collector
go generate ./...
go build -ldflags="-s -w" -o build/lagoon-csp-collector .
go run . -h