api

package
v0.7.2 Latest Latest
Warning

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

Go to latest
Published: Oct 14, 2025 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func MatchTypedObjects added in v0.2.0

func MatchTypedObjects[T client.Object](
	ctx context.Context,
	cl client.Client,
	selector *NamespacedSelector,
	list []T,
) ([]T, error)

Types

type Agekey added in v0.5.0

type Agekey struct {
	Recipient        string `json:"recipient"`
	EncryptedDataKey string `json:"enc"`
}

+kubebuilder:object:generate=true

func (*Agekey) DeepCopy added in v0.5.0

func (in *Agekey) DeepCopy() *Agekey

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Agekey.

func (*Agekey) DeepCopyInto added in v0.5.0

func (in *Agekey) DeepCopyInto(out *Agekey)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type Azkvkey added in v0.5.0

type Azkvkey struct {
	VaultURL         string `json:"vault_url"`
	Name             string `json:"name"`
	Version          string `json:"version"`
	CreatedAt        string `json:"created_at"`
	EncryptedDataKey string `json:"enc"`
}

+kubebuilder:object:generate=true

func (*Azkvkey) DeepCopy added in v0.5.0

func (in *Azkvkey) DeepCopy() *Azkvkey

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Azkvkey.

func (*Azkvkey) DeepCopyInto added in v0.5.0

func (in *Azkvkey) DeepCopyInto(out *Azkvkey)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type GcpKmskey added in v0.5.0

type GcpKmskey struct {
	ResourceID       string `json:"resource_id"`
	CreatedAt        string `json:"created_at"`
	EncryptedDataKey string `json:"enc"`
}

+kubebuilder:object:generate=true

func (*GcpKmskey) DeepCopy added in v0.5.0

func (in *GcpKmskey) DeepCopy() *GcpKmskey

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new GcpKmskey.

func (*GcpKmskey) DeepCopyInto added in v0.5.0

func (in *GcpKmskey) DeepCopyInto(out *GcpKmskey)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type Keygroup added in v0.5.0

type Keygroup struct {
	Pgpkeys           []Pgpkey    `json:"pgp,omitempty"`
	Kmskeys           []Kmskey    `json:"kms,omitempty"`
	GcpKmskeys        []GcpKmskey `json:"gcp_kms,omitempty"`
	AzureKeyVaultkeys []Azkvkey   `json:"azure_kv,omitempty"`
	Vaultkeys         []Vaultkey  `json:"hc_vault,omitempty"`
	Agekeys           []Agekey    `json:"age,omitempty"`
}

+kubebuilder:object:generate=true

func (*Keygroup) DeepCopy added in v0.5.0

func (in *Keygroup) DeepCopy() *Keygroup

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Keygroup.

func (*Keygroup) DeepCopyInto added in v0.5.0

func (in *Keygroup) DeepCopyInto(out *Keygroup)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type Kmskey added in v0.5.0

type Kmskey struct {
	Arn              string             `json:"arn"`
	Role             string             `json:"role,omitempty"`
	Context          map[string]*string `json:"context,omitempty"`
	CreatedAt        string             `json:"created_at"`
	EncryptedDataKey string             `json:"enc"`
	AwsProfile       string             `json:"aws_profile"`
}

+kubebuilder:object:generate=true

func (*Kmskey) DeepCopy added in v0.5.0

func (in *Kmskey) DeepCopy() *Kmskey

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Kmskey.

func (*Kmskey) DeepCopyInto added in v0.5.0

func (in *Kmskey) DeepCopyInto(out *Kmskey)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type Metadata added in v0.5.0

type Metadata struct {
	ShamirThreshold           int         `json:"shamir_threshold,omitempty"`
	KeyGroups                 []Keygroup  `json:"key_groups,omitempty"`
	Kmskeys                   []Kmskey    `json:"kms,omitempty"`
	GcpKmskeys                []GcpKmskey `json:"gcp_kms,omitempty"`
	AzureKeyVaultkeys         []Azkvkey   `json:"azure_kv,omitempty"`
	Vaultkeys                 []Vaultkey  `json:"hc_vault,omitempty"`
	Agekeys                   []Agekey    `json:"age,omitempty"`
	LastModified              string      `json:"lastmodified"`
	MessageAuthenticationCode string      `json:"mac"`
	Pgpkeys                   []Pgpkey    `json:"pgp,omitempty"`
	UnencryptedSuffix         string      `json:"unencrypted_suffix,omitempty"`
	EncryptedSuffix           string      `json:"encrypted_suffix,omitempty"`
	UnencryptedRegex          string      `json:"unencrypted_regex,omitempty"`
	EncryptedRegex            string      `json:"encrypted_regex,omitempty"`
	UnencryptedCommentRegex   string      `json:"unencrypted_comment_regex,omitempty"`
	EncryptedCommentRegex     string      `json:"encrypted_comment_regex,omitempty"`
	MACOnlyEncrypted          bool        `json:"mac_only_encrypted,omitempty"`
	Version                   string      `json:"version,omitempty"`
}

Metadata is stored in SOPS encrypted files, and it contains the information necessary to decrypt the file. This struct is just used for serialization, and SOPS uses another struct internally, sops.Metadata. It exists in order to allow the binary format to stay backwards compatible over time, but at the same time allow the internal representation SOPS uses to change over time. +kubebuilder:object:generate=true

func (*Metadata) DeepCopy added in v0.5.0

func (in *Metadata) DeepCopy() *Metadata

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Metadata.

func (*Metadata) DeepCopyInto added in v0.5.0

func (in *Metadata) DeepCopyInto(out *Metadata)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type NamespacedSelector

type NamespacedSelector struct {
	// Select Items based on their labels. If the namespaceSelector is also set, the selector is applied
	// to items within the selected namespaces. Otherwise for all the items.
	*metav1.LabelSelector `json:",inline"`
	// NamespaceSelector for filtering namespaces by labels where items can be located in
	NamespaceSelector *metav1.LabelSelector `json:"namespaceSelector,omitempty"`
}

Selector for resources and their labels or selecting origin namespaces +kubebuilder:object:generate=true

func (*NamespacedSelector) DeepCopy

func (in *NamespacedSelector) DeepCopy() *NamespacedSelector

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new NamespacedSelector.

func (*NamespacedSelector) DeepCopyInto

func (in *NamespacedSelector) DeepCopyInto(out *NamespacedSelector)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*NamespacedSelector) GetMatchingNamespaces

func (s *NamespacedSelector) GetMatchingNamespaces(
	ctx context.Context,
	client client.Client,
) ([]corev1.Namespace, error)

GetMatchingNamespaces retrieves the list of namespaces that match the NamespaceSelector.

func (*NamespacedSelector) MatchObjects

func (s *NamespacedSelector) MatchObjects(
	ctx context.Context,
	client client.Client,
	objects []metav1.Object,
) ([]metav1.Object, error)

func (*NamespacedSelector) MatchSecrets

func (s *NamespacedSelector) MatchSecrets(
	ctx context.Context,
	cl client.Client,
	secrets []corev1.Secret,
) ([]corev1.Secret, error)

func (*NamespacedSelector) SingleMatch

func (s *NamespacedSelector) SingleMatch(
	ctx context.Context,
	client client.Client,
	obj metav1.Object,
) (state bool, err error)

Pass A Kubernetes Object to verify it matches.

type Origin

type Origin struct {
	// Name of Object
	Name string `json:"name"`
	// namespace of Object
	Namespace string `json:"namespace,omitempty"`
	// namespace of Object
	UID k8stypes.UID `json:"uid,omitempty"`
}

func NewOrigin

func NewOrigin(obj metav1.Object) *Origin

type Pgpkey added in v0.5.0

type Pgpkey struct {
	CreatedAt        string `json:"created_at,omitempty"`
	EncryptedDataKey string `json:"enc,omitempty"`
	Fingerprint      string `json:"fp,omitempty"`
}

+kubebuilder:object:generate=true

func (*Pgpkey) DeepCopy added in v0.5.0

func (in *Pgpkey) DeepCopy() *Pgpkey

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Pgpkey.

func (*Pgpkey) DeepCopyInto added in v0.5.0

func (in *Pgpkey) DeepCopyInto(out *Pgpkey)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type SopsImplementation added in v0.6.0

type SopsImplementation interface {
	client.Object
	GetSopsMetadata() *Metadata
}

type Vaultkey added in v0.5.0

type Vaultkey struct {
	VaultAddress     string `json:"vault_address"`
	EnginePath       string `json:"engine_path"`
	KeyName          string `json:"key_name"`
	CreatedAt        string `json:"created_at"`
	EncryptedDataKey string `json:"enc"`
}

+kubebuilder:object:generate=true

func (*Vaultkey) DeepCopy added in v0.5.0

func (in *Vaultkey) DeepCopy() *Vaultkey

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Vaultkey.

func (*Vaultkey) DeepCopyInto added in v0.5.0

func (in *Vaultkey) DeepCopyInto(out *Vaultkey)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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