radix-vulnerability-scanner-api

command module
v0.0.0-...-acb99ff Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 16, 2024 License: MIT Imports: 17 Imported by: 0

README

prod prod
qa qa

radix-vulnerability-scanner-api

The for Radix Vulnerability Scanner API provides access to vulnerability scan results for applications hosted in Radix. See Radix Vulnerability Scanner for details on installation and DB Credentials (we use managed identities).

Developing

You need Go installed. Make sure GOPATH and GOROOT are properly set up.

Also needed:

  • go-swagger (on a Mac, you can install it with Homebrew: brew install go-swagger)
  • statik (install with go get github.com/rakyll/statik)
  • gomock (GO111MODULE=on go get github.com/golang/mock/mockgen@v1.4.4)

Clone the repo into your GOPATH and run go mod download.

Contribution

Want to contribute? Read our contributing guidelines

Generating mocks

We use gomock to generate mocks used in unit test. You need to regenerate mocks if you make changes to any of the interface types used by the application

make mocks

Running locally

Run once after cloning of the GitHub repository:

  1. go mod download
  2. make swagger
  3. make generate-radix-api-client

The following env var is needed. Useful default values in brackets.

  • SQL_SERVER - SQL server name
  • SQL_DATABASE - SQL database name
  • RADIX_ENVIRONMENT - Radix environment (ex. qa)
  • RADIX_CLUSTERNAME - Radix cluster name (ex. weekly-33)
  • RADIX_DNS_ZONE - Radix DNS zone (ex. dev.radix.equinor.com)
  • USE_LOCAL_RADIX_API
    • false, 0 or not set- connecting to in-clusterradix-api`
    • true or 1 - connecting to radix-api, running on http://localhost:3002
  • USE_PROFILER
    • false, 0 or not set - do not use profiler

    • true or 1 - use pprof profiler, running on http://localhost:7070/debug/pprof. Use web-UI to profile, when started service:

        go tool pprof -http=:6070 http://localhost:7070/debug/pprof/heap
      

Deployment

Radix Vulnerability Scanner API follows the standard procedure defined in how we work.

Radix Vulnerability Scanner API is installed as a Radix application in script when setting up a cluster.

Security

This is how we handle security issues

Documentation

The Go Gopher

There is no documentation for this package.

Directories

Path Synopsis
api
vulnerability/mock
Package mock is a generated GoMock package.
Package mock is a generated GoMock package.
Package docs classification Radix API.
Package docs classification Radix API.
radix_api
mock_client/client/environment
Package environmentmock is a generated GoMock package.
Package environmentmock is a generated GoMock package.
mock
Package mock is a generated GoMock package.
Package mock is a generated GoMock package.
mock
Package mock is a generated GoMock package.
Package mock is a generated GoMock package.
utils
auth/mock
Package mock is a generated GoMock package.
Package mock is a generated GoMock package.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL