v1alpha1

package
v0.6.4 Latest Latest
Warning

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

Go to latest
Published: Sep 9, 2024 License: EUPL-1.2 Imports: 11 Imported by: 0

Documentation

Overview

Package v1alpha1 contains API Schema definitions for the v1alpha1 API group +kubebuilder:object:generate=true +groupName=cpet.belastingdienst.nl

Index

Constants

View Source
const (
	PaasStatusInfo      PaasStatusLevel  = "INFO"
	PaasStatusWarning   PaasStatusLevel  = "WARNING"
	PaasStatusError     PaasStatusLevel  = "ERROR"
	PaasStatusParse     PaasStatusAction = "parse"
	PaasStatusCreate    PaasStatusAction = "create"
	PaasStatusDelete    PaasStatusAction = "delete"
	PaasStatusFind      PaasStatusAction = "find"
	PaasStatusUpdate    PaasStatusAction = "update"
	PaasStatusReconcile PaasStatusAction = "reconcile"
)

Variables

View Source
var (
	// GroupVersion is group version used to register these objects
	GroupVersion = schema.GroupVersion{Group: "cpet.belastingdienst.nl", Version: "v1alpha1"}

	// SchemeBuilder is used to add go types to the GroupVersionKind scheme
	SchemeBuilder = &scheme.Builder{GroupVersion: GroupVersion}

	// AddToScheme adds the types in this group-version to the given scheme.
	AddToScheme = SchemeBuilder.AddToScheme
)

Functions

This section is empty.

Types

type Paas

type Paas struct {
	metav1.TypeMeta   `json:",inline"`
	metav1.ObjectMeta `json:"metadata,omitempty"`

	Spec   PaasSpec   `json:"spec,omitempty"`
	Status PaasStatus `json:"status,omitempty"`
}

Paas is the Schema for the paas API

func (Paas) AllCapNamespaces

func (p Paas) AllCapNamespaces() (ns map[string]bool)

func (Paas) AllEnabledNamespaces

func (p Paas) AllEnabledNamespaces() (ns map[string]bool)

func (Paas) AmIOwner

func (p Paas) AmIOwner(references []metav1.OwnerReference) bool

func (Paas) ClonedAnnotations

func (p Paas) ClonedAnnotations() map[string]string

func (Paas) ClonedLabels

func (p Paas) ClonedLabels() map[string]string

func (*Paas) DeepCopy

func (in *Paas) DeepCopy() *Paas

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

func (*Paas) DeepCopyInto

func (in *Paas) DeepCopyInto(out *Paas)

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

func (*Paas) DeepCopyObject

func (in *Paas) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

func (Paas) GetNsSshSecrets

func (p Paas) GetNsSshSecrets(ns string) (secrets map[string]string)

func (Paas) IsItMe

func (p Paas) IsItMe(reference metav1.OwnerReference) bool

func (Paas) PrefixedAllCapNamespaces

func (p Paas) PrefixedAllCapNamespaces() (ns map[string]bool)

func (Paas) PrefixedAllEnabledNamespaces

func (p Paas) PrefixedAllEnabledNamespaces() (ns map[string]bool)

func (Paas) PrefixedBoolMap

func (p Paas) PrefixedBoolMap(m map[string]bool) map[string]bool

func (Paas) WithoutMe

func (p Paas) WithoutMe(references []metav1.OwnerReference) (withoutMe []metav1.OwnerReference)

type PaasArgoCD

type PaasArgoCD struct {
	// Do we want an ArgoCD namespace, default false
	Enabled bool `json:"enabled,omitempty"`
	// The URL that contains the Applications / Application Sets to be used by this ArgoCD
	GitUrl string `json:"gitUrl,omitempty"`
	// The revision of the git repo that contains the Applications / Application Sets to be used by this ArgoCD
	GitRevision string `json:"gitRevision,omitempty"`
	// the path in the git repo that contains the Applications / Application Sets to be used by this ArgoCD
	GitPath string `json:"gitPath,omitempty"`
	// This project has it's own ClusterResourceQuota settings
	Quota PaasQuotas `json:"quota,omitempty"`
	// You can add ssh keys (which is a type of secret) for ArgoCD to use for access to bitBucket
	// They must be encrypted with the public key corresponding to the private key deployed together with the PaaS operator
	SshSecrets map[string]string `json:"sshSecrets,omitempty"`
	// You can enable extra permissions for the service accounts beloning to this capability
	// Exact definitions is configured in Paas Configmap
	// Note that we want to remove (some of) these permissions in future releases (like self-provisioner)
	ExtraPermissions bool `json:"extra_permissions,omitempty"`
}

func (*PaasArgoCD) CapabilityName

func (pa *PaasArgoCD) CapabilityName() string

func (*PaasArgoCD) DeepCopy

func (in *PaasArgoCD) DeepCopy() *PaasArgoCD

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

func (*PaasArgoCD) DeepCopyInto

func (in *PaasArgoCD) DeepCopyInto(out *PaasArgoCD)

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

func (PaasArgoCD) GetSshSecrets

func (pa PaasArgoCD) GetSshSecrets() map[string]string

func (*PaasArgoCD) IsEnabled

func (pa *PaasArgoCD) IsEnabled() bool

func (PaasArgoCD) Quotas

func (pa PaasArgoCD) Quotas() (pq PaasQuotas)

func (*PaasArgoCD) SetDefaults

func (pa *PaasArgoCD) SetDefaults()

func (*PaasArgoCD) SetSshSecret added in v0.6.1

func (pa *PaasArgoCD) SetSshSecret(key string, value string)

func (*PaasArgoCD) WithExtraPermissions

func (pa *PaasArgoCD) WithExtraPermissions() bool

type PaasCI

type PaasCI struct {
	// Do we want a CI (Tekton) namespace, default false
	Enabled bool `json:"enabled,omitempty"`
	// This project has it's own ClusterResourceQuota settings
	Quota PaasQuotas `json:"quota,omitempty"`
	// You can add ssh keys (which is a type of secret) for ArgoCD to use for access to bitBucket
	// They must be encrypted with the public key corresponding to the private key deployed together with the PaaS operator
	SshSecrets map[string]string `json:"sshSecrets,omitempty"`
	// You can enable extra permissions for the service accounts beloning to this capability
	// Exact definitions is configured in Paas Configmap
	// Note that we want to remove (some of) these permissions in future releases (like self-provisioner)
	ExtraPermissions bool `json:"extra_permissions,omitempty"`
}

func (*PaasCI) CapabilityName

func (pc *PaasCI) CapabilityName() string

func (*PaasCI) DeepCopy

func (in *PaasCI) DeepCopy() *PaasCI

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

func (*PaasCI) DeepCopyInto

func (in *PaasCI) DeepCopyInto(out *PaasCI)

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

func (PaasCI) GetSshSecrets

func (pc PaasCI) GetSshSecrets() map[string]string

func (*PaasCI) IsEnabled

func (pc *PaasCI) IsEnabled() bool

func (PaasCI) Quotas

func (pc PaasCI) Quotas() (pq PaasQuotas)

func (*PaasCI) SetSshSecret added in v0.6.1

func (pc *PaasCI) SetSshSecret(key string, value string)

func (*PaasCI) WithExtraPermissions

func (pc *PaasCI) WithExtraPermissions() bool

type PaasCapabilities

type PaasCapabilities struct {
	// ArgoCD defines the ArgoCD deployment that should be available.
	ArgoCD PaasArgoCD `json:"argocd,omitempty"`
	// CI defines the settings for a CI namespace (tekton) for this PAAS
	CI PaasCI `json:"tekton,omitempty"`
	// SSO defines the settings for a SSO (KeyCloak) namwespace for this PAAS
	SSO PaasSSO `json:"sso,omitempty"`
	// Grafana defines the settings for a Grafana monitoring namespace for this PAAS
	Grafana PaasGrafana `json:"grafana,omitempty"`
}

func (PaasCapabilities) AsMap

func (pc PaasCapabilities) AsMap() map[string]paasCapability

func (PaasCapabilities) AsPrefixedMap

func (pc PaasCapabilities) AsPrefixedMap(prefix string) map[string]paasCapability

AsMap geeft de namen van de capabilties, terwijl bijvoorbeeld de namespace namen en quota namen geprefixt zijn met de paas naam. Daarom een AsPrefixedMap, zodat we ook makkelijk kunnen zoeken als je de namespace naam hebt.

func (*PaasCapabilities) DeepCopy

func (in *PaasCapabilities) DeepCopy() *PaasCapabilities

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

func (*PaasCapabilities) DeepCopyInto

func (in *PaasCapabilities) DeepCopyInto(out *PaasCapabilities)

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

func (PaasCapabilities) IsCap

func (pc PaasCapabilities) IsCap(name string) bool

type PaasGrafana

type PaasGrafana struct {
	// Do we want a Grafana namespace, default false
	Enabled bool `json:"enabled,omitempty"`
	// This project has it's own ClusterResourceQuota settings
	Quota PaasQuotas `json:"quota,omitempty"`
	// You can add ssh keys (which is a type of secret) for ArgoCD to use for access to bitBucket
	// They must be encrypted with the public key corresponding to the private key deployed together with the PaaS operator
	SshSecrets map[string]string `json:"sshSecrets,omitempty"`
	// You can enable extra permissions for the service accounts beloning to this capability
	// Exact definitions is configured in Paas Configmap
	// Note that we want to remove (some of) these permissions in future releases (like self-provisioner)
	ExtraPermissions bool `json:"extra_permissions,omitempty"`
}

func (*PaasGrafana) CapabilityName

func (pg *PaasGrafana) CapabilityName() string

func (*PaasGrafana) DeepCopy

func (in *PaasGrafana) DeepCopy() *PaasGrafana

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

func (*PaasGrafana) DeepCopyInto

func (in *PaasGrafana) DeepCopyInto(out *PaasGrafana)

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

func (PaasGrafana) GetSshSecrets

func (pg PaasGrafana) GetSshSecrets() map[string]string

func (*PaasGrafana) IsEnabled

func (pg *PaasGrafana) IsEnabled() bool

func (PaasGrafana) Quotas

func (pg PaasGrafana) Quotas() (pq PaasQuotas)

func (*PaasGrafana) SetSshSecret added in v0.6.1

func (pg *PaasGrafana) SetSshSecret(key string, value string)

func (*PaasGrafana) WithExtraPermissions

func (pg *PaasGrafana) WithExtraPermissions() bool

type PaasGroup

type PaasGroup struct {
	Query string   `json:"query,omitempty"`
	Users []string `json:"users,omitempty"`
	Roles []string `json:"roles,omitempty"`
}

func (*PaasGroup) DeepCopy

func (in *PaasGroup) DeepCopy() *PaasGroup

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

func (*PaasGroup) DeepCopyInto

func (in *PaasGroup) DeepCopyInto(out *PaasGroup)

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

func (PaasGroup) Name

func (g PaasGroup) Name(defName string) string

type PaasGroups

type PaasGroups map[string]PaasGroup

func (PaasGroups) AsGroups

func (pgs PaasGroups) AsGroups() groups.Groups

func (PaasGroups) DeepCopy

func (in PaasGroups) DeepCopy() PaasGroups

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

func (PaasGroups) DeepCopyInto

func (in PaasGroups) DeepCopyInto(out *PaasGroups)

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

func (PaasGroups) Filtered added in v0.6.0

func (gs PaasGroups) Filtered(groups []string) PaasGroups

func (PaasGroups) Key2Name

func (g PaasGroups) Key2Name(key string) string

NameFromQuery finds a group by its key, and retrieves a name - from query if possible - from key is needed - emptystring if not in map

func (PaasGroups) Keys

func (pgs PaasGroups) Keys() (groups []string)

func (PaasGroups) LdapQueries

func (gs PaasGroups) LdapQueries() []string

func (PaasGroups) Names

func (gs PaasGroups) Names() (groups []string)

func (PaasGroups) Roles added in v0.6.0

func (gs PaasGroups) Roles() map[string][]string

type PaasList

type PaasList struct {
	metav1.TypeMeta `json:",inline"`
	metav1.ListMeta `json:"metadata,omitempty"`
	Items           []Paas `json:"items,omitempty"`
}

PaasList contains a list of Paas

func (*PaasList) DeepCopy

func (in *PaasList) DeepCopy() *PaasList

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

func (*PaasList) DeepCopyInto

func (in *PaasList) DeepCopyInto(out *PaasList)

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

func (*PaasList) DeepCopyObject

func (in *PaasList) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

type PaasNS

type PaasNS struct {
	metav1.TypeMeta   `json:",inline"`
	metav1.ObjectMeta `json:"metadata,omitempty"`

	Spec   PaasNSSpec   `json:"spec,omitempty"`
	Status PaasNsStatus `json:"status,omitempty"`
}

PaasNS is the Schema for the paasns API

func (PaasNS) AmIOwner added in v0.6.0

func (p PaasNS) AmIOwner(references []metav1.OwnerReference) bool

func (PaasNS) ClonedLabels

func (p PaasNS) ClonedLabels() map[string]string

func (*PaasNS) DeepCopy

func (in *PaasNS) DeepCopy() *PaasNS

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

func (*PaasNS) DeepCopyInto

func (in *PaasNS) DeepCopyInto(out *PaasNS)

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

func (*PaasNS) DeepCopyObject

func (in *PaasNS) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

func (PaasNS) IsItMe added in v0.6.0

func (p PaasNS) IsItMe(reference metav1.OwnerReference) bool

func (PaasNS) NamespaceName

func (pns PaasNS) NamespaceName() string

type PaasNSList

type PaasNSList struct {
	metav1.TypeMeta `json:",inline"`
	metav1.ListMeta `json:"metadata,omitempty"`
	Items           []PaasNS `json:"items"`
}

PaasNSList contains a list of PaasNS

func (*PaasNSList) DeepCopy

func (in *PaasNSList) DeepCopy() *PaasNSList

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

func (*PaasNSList) DeepCopyInto

func (in *PaasNSList) DeepCopyInto(out *PaasNSList)

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

func (*PaasNSList) DeepCopyObject

func (in *PaasNSList) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

type PaasNSSpec

type PaasNSSpec struct {

	// Foo is an example field of PaasNS. Edit paasns_types.go to remove/update
	Paas       string            `json:"paas"`
	Groups     []string          `json:"groups,omitempty"`
	SshSecrets map[string]string `json:"sshSecrets,omitempty"`
}

PaasNSSpec defines the desired state of PaasNS

func (*PaasNSSpec) DeepCopy

func (in *PaasNSSpec) DeepCopy() *PaasNSSpec

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

func (*PaasNSSpec) DeepCopyInto

func (in *PaasNSSpec) DeepCopyInto(out *PaasNSSpec)

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

type PaasNsStatus added in v0.5.0

type PaasNsStatus struct {
	// Important: Run "make" to regenerate code after modifying this file
	Messages []string `json:"messages,omitempty"`
}

PaasStatus defines the observed state of Paas

func (*PaasNsStatus) AddMessage added in v0.5.0

func (ps *PaasNsStatus) AddMessage(level PaasStatusLevel, action PaasStatusAction, obj client.Object, message string)

func (*PaasNsStatus) AddMessages added in v0.6.0

func (ps *PaasNsStatus) AddMessages(msgs []string)

func (*PaasNsStatus) DeepCopy added in v0.6.1

func (in *PaasNsStatus) DeepCopy() *PaasNsStatus

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

func (*PaasNsStatus) DeepCopyInto added in v0.6.1

func (in *PaasNsStatus) DeepCopyInto(out *PaasNsStatus)

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

func (*PaasNsStatus) GetMessages added in v0.6.0

func (ps *PaasNsStatus) GetMessages() []string

func (*PaasNsStatus) Truncate added in v0.5.0

func (ps *PaasNsStatus) Truncate()

type PaasQuotas

type PaasQuotas map[corev1.ResourceName]resourcev1.Quantity

func (PaasQuotas) DeepCopy

func (in PaasQuotas) DeepCopy() PaasQuotas

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

func (PaasQuotas) DeepCopyInto

func (in PaasQuotas) DeepCopyInto(out *PaasQuotas)

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

func (PaasQuotas) QuotaWithDefaults

func (pq PaasQuotas) QuotaWithDefaults(defaults map[string]string) (q PaasQuotas)

type PaasSSO

type PaasSSO struct {
	// Do we want an SSO namespace, default false
	Enabled bool `json:"enabled,omitempty"`
	// This project has it's own ClusterResourceQuota settings
	Quota PaasQuotas `json:"quota,omitempty"`
	// You can add ssh keys (which is a type of secret) for ArgoCD to use for access to bitBucket
	// They must be encrypted with the public key corresponding to the private key deployed together with the PaaS operator
	SshSecrets map[string]string `json:"sshSecrets,omitempty"`
	// You can enable extra permissions for the service accounts beloning to this capability
	// Exact definitions is configured in Paas Configmap
	// Note that we want to remove (some of) these permissions in future releases (like self-provisioner)
	ExtraPermissions bool `json:"extra_permissions,omitempty"`
}

func (*PaasSSO) CapabilityName

func (ps *PaasSSO) CapabilityName() string

func (*PaasSSO) DeepCopy

func (in *PaasSSO) DeepCopy() *PaasSSO

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

func (*PaasSSO) DeepCopyInto

func (in *PaasSSO) DeepCopyInto(out *PaasSSO)

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

func (PaasSSO) GetSshSecrets

func (ps PaasSSO) GetSshSecrets() map[string]string

func (*PaasSSO) IsEnabled

func (ps *PaasSSO) IsEnabled() bool

func (PaasSSO) Quotas

func (ps PaasSSO) Quotas() (pq PaasQuotas)

func (*PaasSSO) SetSshSecret added in v0.6.1

func (ps *PaasSSO) SetSshSecret(key string, value string)

func (*PaasSSO) WithExtraPermissions

func (ps *PaasSSO) WithExtraPermissions() bool

type PaasSpec

type PaasSpec struct {

	//Cabailities is a subset of capabilities that will be available in this Pass Project
	Capabilities PaasCapabilities `json:"capabilities,omitempty"`

	//requestor is an informational field which decides on the requestor (also application responable)
	Requestor string `json:"requestor"`

	Groups PaasGroups `json:"groups,omitempty"`

	// Quota defines the quotas which should be set on the cluster resource quota as used by this PaaS project
	Quota PaasQuotas `json:"quota"`

	// Namespaces can be used to define extra namespaces to be created as part of this PaaS project
	Namespaces []string `json:"namespaces,omitempty"`
	// You can add ssh keys (which is a type of secret) for ArgoCD to use for access to bitBucket
	// They must be encrypted with the public key corresponding to the private key deployed together with the PaaS operator
	SshSecrets map[string]string `json:"sshSecrets,omitempty"`
}

PaasSpec defines the desired state of Paas

func (*PaasSpec) DeepCopy

func (in *PaasSpec) DeepCopy() *PaasSpec

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

func (*PaasSpec) DeepCopyInto

func (in *PaasSpec) DeepCopyInto(out *PaasSpec)

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

type PaasStatus

type PaasStatus struct {
	// Important: Run "make" to regenerate code after modifying this file
	Messages []string              `json:"messages,omitempty"`
	Quota    map[string]PaasQuotas `json:"quotas"`
}

PaasStatus defines the observed state of Paas

func (*PaasStatus) AddMessage

func (ps *PaasStatus) AddMessage(level PaasStatusLevel, action PaasStatusAction, obj client.Object, message string)

func (*PaasStatus) AddMessages added in v0.6.0

func (ps *PaasStatus) AddMessages(msgs []string)

func (*PaasStatus) DeepCopy

func (in *PaasStatus) DeepCopy() *PaasStatus

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

func (*PaasStatus) DeepCopyInto

func (in *PaasStatus) DeepCopyInto(out *PaasStatus)

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

func (*PaasStatus) GetMessages added in v0.6.0

func (ps *PaasStatus) GetMessages() []string

func (*PaasStatus) Truncate

func (ps *PaasStatus) Truncate()

type PaasStatusAction

type PaasStatusAction string

type PaasStatusLevel

type PaasStatusLevel string

Jump to

Keyboard shortcuts

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