scan_api_store

package
v1.6.0 Latest Latest
Warning

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

Go to latest
Published: Sep 22, 2022 License: MPL-2.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

View Source
const (
	AddRequest    requestType = "add"
	DeleteRequest requestType = "delete"
)

Variables

This section is empty.

Functions

func HandleAuditConfig

func HandleAuditConfig(ctx context.Context, kubeClient client.Client, scanApiStore ScanApiStore, auditConfig v1alpha2.MondooAuditConfig) error

HandleAuditConfig adds the scan API service URL, token and integration MRN to the scan API store if the provided MondooAuditConfig has k8s resources enabled.

Types

type ClientConfiguration

type ClientConfiguration struct {
	Client         mondooclient.Client
	IntegrationMrn string
}

type ScanApiStore

type ScanApiStore interface {
	Start()
	// Add adds a scan api url to the store. The operatorion is idempotent.
	Add(url, token, integrationMrn string)
	// Delete deletes a scan api url from the store. The operatorion is idempotent.
	Delete(url string)
	// GetAll returns all scan api urls.
	GetAll() []ClientConfiguration
}

func NewScanApiStore

func NewScanApiStore(ctx context.Context) ScanApiStore

Directories

Path Synopsis
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