Documentation
¶
Index ¶
- func Scrubers() map[internal.R]ScrubFn
- type Cache
- type Cluster
- type ClusterRole
- type ClusterRoleBinding
- type Collector
- type ConfigMap
- type CronJob
- type DaemonSet
- type Deployment
- type Gateway
- type GatewayClass
- type HTTPRoute
- type HorizontalPodAutoscaler
- type Ingress
- type Job
- type Linter
- func NewCluster(ctx context.Context, c *Cache, codes *issues.Codes) Linter
- func NewClusterRole(_ context.Context, c *Cache, codes *issues.Codes) Linter
- func NewClusterRoleBinding(_ context.Context, c *Cache, codes *issues.Codes) Linter
- func NewConfigMap(_ context.Context, c *Cache, codes *issues.Codes) Linter
- func NewCronJob(_ context.Context, c *Cache, codes *issues.Codes) Linter
- func NewDaemonSet(_ context.Context, c *Cache, codes *issues.Codes) Linter
- func NewDeployment(_ context.Context, c *Cache, codes *issues.Codes) Linter
- func NewGateway(_ context.Context, c *Cache, codes *issues.Codes) Linter
- func NewGatewayClass(_ context.Context, c *Cache, codes *issues.Codes) Linter
- func NewHTTPRoute(_ context.Context, c *Cache, codes *issues.Codes) Linter
- func NewHorizontalPodAutoscaler(_ context.Context, c *Cache, codes *issues.Codes) Linter
- func NewIngress(_ context.Context, c *Cache, codes *issues.Codes) Linter
- func NewJob(_ context.Context, c *Cache, codes *issues.Codes) Linter
- func NewNamespace(_ context.Context, c *Cache, codes *issues.Codes) Linter
- func NewNetworkPolicy(_ context.Context, c *Cache, codes *issues.Codes) Linter
- func NewNode(_ context.Context, c *Cache, codes *issues.Codes) Linter
- func NewPersistentVolume(_ context.Context, c *Cache, codes *issues.Codes) Linter
- func NewPersistentVolumeClaim(_ context.Context, c *Cache, codes *issues.Codes) Linter
- func NewPod(_ context.Context, c *Cache, codes *issues.Codes) Linter
- func NewPodDisruptionBudget(_ context.Context, c *Cache, codes *issues.Codes) Linter
- func NewReplicaSet(_ context.Context, c *Cache, codes *issues.Codes) Linter
- func NewRole(_ context.Context, c *Cache, codes *issues.Codes) Linter
- func NewRoleBinding(_ context.Context, c *Cache, codes *issues.Codes) Linter
- func NewSecret(_ context.Context, c *Cache, codes *issues.Codes) Linter
- func NewService(_ context.Context, c *Cache, codes *issues.Codes) Linter
- func NewServiceAccount(_ context.Context, c *Cache, codes *issues.Codes) Linter
- func NewStatefulSet(_ context.Context, c *Cache, codes *issues.Codes) Linter
- type LoaderFn
- type Namespace
- type NetworkPolicy
- type Node
- type PersistentVolume
- type PersistentVolumeClaim
- type Pod
- type PodDisruptionBudget
- type Preloads
- type ReplicaSet
- type Role
- type RoleBinding
- type ScrubFn
- type Scrubs
- type Secret
- type Service
- type ServiceAccount
- type StatefulSet
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Cache ¶ added in v0.3.5
type Cache struct {
Config *config.Config
DB *db.DB
Loader *db.Loader
// contains filtered or unexported fields
}
Cache tracks commonly used resources.
type Cluster ¶ added in v0.4.0
type Cluster struct {
*issues.Collector
*cache.Cluster
*config.Config
// contains filtered or unexported fields
}
Cluster represents a Cluster scruber.
func (*Cluster) HasMetrics ¶ added in v0.11.2
func (d *Cluster) HasMetrics() bool
type ClusterRole ¶ added in v0.6.0
type ClusterRole struct {
*issues.Collector
*Cache
}
ClusterRole represents a ClusterRole scruber.
type ClusterRoleBinding ¶ added in v0.6.0
type ClusterRoleBinding struct {
*issues.Collector
*Cache
}
ClusterRoleBinding represents a ClusterRoleBinding scruber.
type Collector ¶
type Collector interface {
MaxSeverity(res string) rules.Level
Outcome() issues.Outcome
}
Collector collects sanitization issues.
type ConfigMap ¶
type ConfigMap struct {
*issues.Collector
*Cache
}
ConfigMap represents a configMap scruber.
type CronJob ¶ added in v0.20.0
type CronJob struct {
*issues.Collector
*Cache
}
CronJob represents a CronJob scruber.
type DaemonSet ¶ added in v0.4.0
type DaemonSet struct {
*issues.Collector
*Cache
}
DaemonSet represents a DaemonSet scruber.
type Deployment ¶
type Deployment struct {
*issues.Collector
*Cache
}
Deployment represents a Deployment scruber.
type Gateway ¶ added in v0.20.0
type Gateway struct {
*issues.Collector
*Cache
}
Gateway represents a Gateway scruber.
type GatewayClass ¶ added in v0.20.0
type GatewayClass struct {
*issues.Collector
*Cache
}
GatewayClass represents a GatewayClass scruber.
type HTTPRoute ¶ added in v0.20.0
type HTTPRoute struct {
*issues.Collector
*Cache
}
HTTPRoute represents a HTTPRoute scruber.
type HorizontalPodAutoscaler ¶
type HorizontalPodAutoscaler struct {
*issues.Collector
*Cache
}
HorizontalPodAutoscaler represents a HorizontalPodAutoscaler scruber.
type Ingress ¶ added in v0.4.0
type Ingress struct {
*issues.Collector
*Cache
}
Ingress represents a Ingress scruber.
type Job ¶ added in v0.20.0
type Job struct {
*issues.Collector
*Cache
}
Job represents a Job scruber.
type Linter ¶ added in v0.20.0
type Linter interface {
// Collector tracks issues.
Collector
// Lint runs checks on a resource.
Lint(context.Context) error
// Preloads Preloads resource requirements.
Preloads() Preloads
}
Linter represents a resource linter.
func NewCluster ¶ added in v0.4.0
func NewCluster(ctx context.Context, c *Cache, codes *issues.Codes) Linter
NewCluster returns a new instance.
func NewClusterRole ¶ added in v0.6.0
func NewClusterRole(_ context.Context, c *Cache, codes *issues.Codes) Linter
NewClusterRole returns a new instance.
func NewClusterRoleBinding ¶ added in v0.6.0
func NewClusterRoleBinding(_ context.Context, c *Cache, codes *issues.Codes) Linter
NewClusterRoleBinding returns a new instance.
func NewConfigMap ¶
func NewConfigMap(_ context.Context, c *Cache, codes *issues.Codes) Linter
NewConfigMap returns a new instance.
func NewCronJob ¶ added in v0.20.0
func NewCronJob(_ context.Context, c *Cache, codes *issues.Codes) Linter
NewCronJob return a new instance.
func NewDaemonSet ¶ added in v0.4.0
func NewDaemonSet(_ context.Context, c *Cache, codes *issues.Codes) Linter
NewDaemonSet return a new instance.
func NewDeployment ¶
func NewDeployment(_ context.Context, c *Cache, codes *issues.Codes) Linter
NewDeployment returns a new instance.
func NewGateway ¶ added in v0.20.0
func NewGateway(_ context.Context, c *Cache, codes *issues.Codes) Linter
NewGateway return a new instance.
func NewGatewayClass ¶ added in v0.20.0
func NewGatewayClass(_ context.Context, c *Cache, codes *issues.Codes) Linter
NewGatewayClass return a new instance.
func NewHTTPRoute ¶ added in v0.20.0
func NewHTTPRoute(_ context.Context, c *Cache, codes *issues.Codes) Linter
NewHTTPRoute return a new instance.
func NewHorizontalPodAutoscaler ¶
func NewHorizontalPodAutoscaler(_ context.Context, c *Cache, codes *issues.Codes) Linter
NewHorizontalPodAutoscaler returns a new instance.
func NewIngress ¶ added in v0.4.0
func NewIngress(_ context.Context, c *Cache, codes *issues.Codes) Linter
NewIngress return a new instance.
func NewJob ¶ added in v0.20.0
func NewJob(_ context.Context, c *Cache, codes *issues.Codes) Linter
NewJob return a new instance.
func NewNamespace ¶
func NewNamespace(_ context.Context, c *Cache, codes *issues.Codes) Linter
NewNamespace returns a new instance.
func NewNetworkPolicy ¶ added in v0.4.0
func NewNetworkPolicy(_ context.Context, c *Cache, codes *issues.Codes) Linter
NewNetworkPolicy return a new instance.
func NewNode ¶
func NewNode(_ context.Context, c *Cache, codes *issues.Codes) Linter
NewNode return a new instance.
func NewPersistentVolume ¶
func NewPersistentVolume(_ context.Context, c *Cache, codes *issues.Codes) Linter
NewPersistentVolume return a new instance.
func NewPersistentVolumeClaim ¶
func NewPersistentVolumeClaim(_ context.Context, c *Cache, codes *issues.Codes) Linter
NewPersistentVolumeClaim returns a new instance.
func NewPod ¶
func NewPod(_ context.Context, c *Cache, codes *issues.Codes) Linter
NewPod return a new instance.
func NewPodDisruptionBudget ¶ added in v0.3.10
func NewPodDisruptionBudget(_ context.Context, c *Cache, codes *issues.Codes) Linter
NewPodDisruptionBudget return a new PodDisruptionBudget scruber.
func NewReplicaSet ¶ added in v0.4.0
func NewReplicaSet(_ context.Context, c *Cache, codes *issues.Codes) Linter
NewReplicaSet returns a new instance.
func NewRole ¶ added in v0.6.0
func NewRole(_ context.Context, c *Cache, codes *issues.Codes) Linter
NewRole returns a new instance.
func NewRoleBinding ¶ added in v0.6.0
func NewRoleBinding(_ context.Context, c *Cache, codes *issues.Codes) Linter
NewRoleBinding returns a new instance.
func NewSecret ¶
func NewSecret(_ context.Context, c *Cache, codes *issues.Codes) Linter
NewSecret return a new Secret scruber.
func NewService ¶
func NewService(_ context.Context, c *Cache, codes *issues.Codes) Linter
NewService return a new instance.
func NewServiceAccount ¶
func NewServiceAccount(_ context.Context, c *Cache, codes *issues.Codes) Linter
NewServiceAccount returns a new instance.
func NewStatefulSet ¶
func NewStatefulSet(_ context.Context, c *Cache, codes *issues.Codes) Linter
NewStatefulSet return a new StatefulSet scruber.
type LoaderFn ¶ added in v0.20.0
type LoaderFn func(context.Context, *db.Loader, types.GVR) error
LoaderFn represents a resource loader.
type Namespace ¶
type Namespace struct {
*issues.Collector
*Cache
}
Namespace represents a Namespace scruber.
type NetworkPolicy ¶ added in v0.4.0
type NetworkPolicy struct {
*issues.Collector
*Cache
}
NetworkPolicy represents a NetworkPolicy scruber.
type Node ¶
type Node struct {
*issues.Collector
*Cache
}
Node represents a Node scruber.
type PersistentVolume ¶
type PersistentVolume struct {
*issues.Collector
*Cache
}
PersistentVolume represents a PersistentVolume scruber.
type PersistentVolumeClaim ¶
type PersistentVolumeClaim struct {
*issues.Collector
*Cache
}
PersistentVolumeClaim represents a PersistentVolumeClaim scruber.
type Pod ¶
type Pod struct {
*issues.Collector
*Cache
}
Pod represents a Pod scruber.
type PodDisruptionBudget ¶ added in v0.3.10
type PodDisruptionBudget struct {
*issues.Collector
*Cache
}
PodDisruptionBudget represents a pdb scruber.
type ReplicaSet ¶ added in v0.4.0
type ReplicaSet struct {
*issues.Collector
*Cache
}
ReplicaSet represents a ReplicaSet scruber.
type Role ¶ added in v0.6.0
type Role struct {
*issues.Collector
*Cache
}
Role represents a Role scruber.
type RoleBinding ¶ added in v0.6.0
type RoleBinding struct {
*issues.Collector
*Cache
}
RoleBinding represents a RoleBinding scruber.
type ScrubFn ¶ added in v0.20.0
type ScrubFn func(context.Context, *Cache, *issues.Codes) Linter
ScrubFn represents a resource scruber.
type Secret ¶
type Secret struct {
*issues.Collector
*Cache
}
Secret represents a Secret scruber.
type Service ¶
type Service struct {
*issues.Collector
*Cache
}
Service represents a Service scruber.
type ServiceAccount ¶ added in v0.4.0
type ServiceAccount struct {
*issues.Collector
*Cache
}
ServiceAccount represents a ServiceAccount scruber.
type StatefulSet ¶
type StatefulSet struct {
*issues.Collector
*Cache
}
StatefulSet represents a StatefulSet scruber.