Documentation ¶
Index ¶
- func BDPodAnnotationKeys(containerCount int) []string
- func BDPodLabelKeys(containerCount int) []string
- func CopyMap(dict map[string]string) map[string]string
- func HasAllKeys(dict map[string]string, keys []string) bool
- func HasAnyKeys(dict map[string]string, keys []string) bool
- func ParseImageIDString(imageID string) (string, string, error)
- func RemoveBDPodAnnotationKeys(containerCount int, annotations map[string]string) map[string]string
- func RemoveBDPodLabelKeys(containerCount int, labels map[string]string) map[string]string
- func RemoveKeys(dict map[string]string, keys []string) map[string]string
- type ClientInterface
- type Container
- type Dump
- type Image
- type KubeClient
- type KubeClientConfig
- type Meta
- type Pod
- type PodAnnotationKey
- type PodImageAnnotationKey
- type PodImageLabelKey
- type PodLabelKey
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func BDPodAnnotationKeys ¶
BDPodAnnotationKeys .....
func ParseImageIDString ¶
ParseImageIDString parses an ImageID pulled from kubernetes. Example image id:
docker-pullable://registry.kipp.blackducksoftware.com/blackducksoftware/hub-registration@sha256:cb4983d8399a59bb5ee6e68b6177d878966a8fe41abe18a45c3b1d8809f1d043
func RemoveBDPodAnnotationKeys ¶
RemoveBDPodAnnotationKeys .....
func RemoveBDPodLabelKeys ¶
RemoveBDPodLabelKeys .....
Types ¶
type ClientInterface ¶
ClientInterface .....
type Dump ¶
type Dump struct { Meta *Meta Pods []*Pod PodsByName map[string]*Pod DuplicatePodNames map[string]bool // Images []*Image ImagesBySha map[string]*Image DuplicateImageShas map[string]bool ImagesMissingSha []*Image }
Dump .....
type KubeClient ¶
type KubeClient struct {
// contains filtered or unexported fields
}
KubeClient is an implementation of the Client interface for kubernetes
func NewKubeClient ¶
func NewKubeClient(config *KubeClientConfig) (*KubeClient, error)
NewKubeClient .....
func NewKubeClientFromInsideCluster ¶
func NewKubeClientFromInsideCluster() (*KubeClient, error)
NewKubeClientFromInsideCluster instantiates a KubeClient using configuration pulled from the cluster.
func NewKubeClientFromOutsideCluster ¶
func NewKubeClientFromOutsideCluster(masterURL string, kubeconfigPath string) (*KubeClient, error)
NewKubeClientFromOutsideCluster instantiates a KubeClient using a master URL and a path to a kubeconfig file.
func (*KubeClient) CleanupAllPods ¶
func (client *KubeClient) CleanupAllPods() error
CleanupAllPods .....
func (*KubeClient) GetAllPods ¶
func (client *KubeClient) GetAllPods() ([]*Pod, error)
GetAllPods .....
type KubeClientConfig ¶
KubeClientConfig .....
type Meta ¶
type Meta struct { MajorVersion string MinorVersion string GitVersion string GitCommit string GitTreeState string BuildDate string GoVersion string Compiler string Platform string NodeCount int }
Meta .....
type Pod ¶
type Pod struct { Name string UID string Namespace string Containers []*Container Annotations map[string]string Labels map[string]string }
Pod .....
func (*Pod) HasAllBDAnnotations ¶
HasAllBDAnnotations .....
func (*Pod) HasAnyBDAnnotations ¶
HasAnyBDAnnotations .....
type PodAnnotationKey ¶
type PodAnnotationKey int
PodAnnotationKey .....
const ( PodAnnotationKeyVulnerabilities PodAnnotationKey = iota PodAnnotationKeyPolicyViolations PodAnnotationKey = iota PodAnnotationKeyOverallStatus PodAnnotationKey = iota PodAnnotationKeyServerVersion PodAnnotationKey = iota PodAnnotationKeyScannerVersion PodAnnotationKey = iota )
type PodImageAnnotationKey ¶
type PodImageAnnotationKey int
PodImageAnnotationKey .....
const ( PodImageAnnotationKeyVulnerabilities PodImageAnnotationKey = iota PodImageAnnotationKeyPolicyViolations PodImageAnnotationKey = iota PodImageAnnotationKeyOverallStatus PodImageAnnotationKey = iota PodImageAnnotationKeyServerVersion PodImageAnnotationKey = iota PodImageAnnotationKeyScannerVersion PodImageAnnotationKey = iota PodImageAnnotationKeyProjectEndpoint PodImageAnnotationKey = iota PodImageAnnotationKeyImage PodImageAnnotationKey = iota )
func (PodImageAnnotationKey) String ¶
func (pak PodImageAnnotationKey) String(index int) string
String .....
type PodImageLabelKey ¶
type PodImageLabelKey int
PodImageLabelKey .....
const ( PodImageLabelKeyVulnerabilities PodImageLabelKey = iota PodImageLabelKeyPolicyViolations PodImageLabelKey = iota PodImageLabelKeyOverallStatus PodImageLabelKey = iota PodImageLabelKeyImage PodImageLabelKey = iota )
type PodLabelKey ¶
type PodLabelKey int
PodLabelKey .....
const ( PodLabelKeyVulnerabilities PodLabelKey = iota PodLabelKeyPolicyViolations PodLabelKey = iota PodLabelKeyOverallStatus PodLabelKey = iota )