extractor

package
v0.6.2 Latest Latest
Warning

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

Go to latest
Published: Sep 6, 2024 License: AGPL-3.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var DefaultRules = []ImageReferenceExtractionRule{
	{
		TypeMeta: metav1.TypeMeta{
			Kind:       "Pod",
			APIVersion: "v1",
		},
		Paths: []string{"$.spec.containers[*].image"},
	},
	{
		TypeMeta: metav1.TypeMeta{
			Kind:       "Deployment",
			APIVersion: "apps/v1",
		},
		Paths: []string{"$.spec.template.spec.containers[*].image"},
	},
	{
		TypeMeta: metav1.TypeMeta{
			Kind:       "StatefulSet",
			APIVersion: "apps/v1",
		},
		Paths: []string{"$.spec.template.spec.containers[*].image"},
	},
	{
		TypeMeta: metav1.TypeMeta{
			Kind:       "DaemonSet",
			APIVersion: "apps/v1",
		},
		Paths: []string{"$.spec.template.spec.containers[*].image"},
	},
	{
		TypeMeta: metav1.TypeMeta{
			Kind:       "Job",
			APIVersion: "batch/v1",
		},
		Paths: []string{"$.spec.template.spec.containers[*].image"},
	},
	{
		TypeMeta: metav1.TypeMeta{
			Kind:       "CronJob",
			APIVersion: "batch/v1",
		},
		Paths: []string{"$.spec.jobTemplate.spec.template.spec.containers[*].image"},
	},
	{
		TypeMeta: metav1.TypeMeta{
			Kind:       "Config",
			APIVersion: "airgapify.pecke.tt/v1alpha1",
		},
		Paths: []string{"$.spec.images[*]"},
	},
}

Functions

This section is empty.

Types

type ImageReferenceExtractionRule

type ImageReferenceExtractionRule struct {
	metav1.TypeMeta
	// Paths is a list of JSON paths to extract image references from.
	Paths []string
}

type ImageReferenceExtractor

type ImageReferenceExtractor struct {
	// contains filtered or unexported fields
}

func (*ImageReferenceExtractor) ExtractImageReferences

func (e *ImageReferenceExtractor) ExtractImageReferences(objects []unstructured.Unstructured) (sets.String, error)

Jump to

Keyboard shortcuts

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