v1alpha1

package
v0.0.0-...-c8eb8dd Latest Latest
Warning

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

Go to latest
Published: Sep 21, 2020 License: MIT Imports: 11 Imported by: 0

Documentation

Overview

Package v1alpha1 contains API Schema definitions for the ghapp v1alpha1 API group +kubebuilder:object:generate=true +groupName=ghapp.tsuzu.dev

Index

Constants

This section is empty.

Variables

View Source
var (
	// GroupVersion is group version used to register these objects
	GroupVersion = schema.GroupVersion{Group: "ghapp.tsuzu.dev", 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 ClusterGitHubApp

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

	Spec   ClusterGitHubAppSpec   `json:"spec,omitempty"`
	Status ClusterGitHubAppStatus `json:"status,omitempty"`
}

ClusterGitHubApp is the Schema for the clustergithubapps API +kubebuilder:resource:path=clustergithubapps,scope=Cluster

func (*ClusterGitHubApp) DeepCopy

func (in *ClusterGitHubApp) DeepCopy() *ClusterGitHubApp

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

func (*ClusterGitHubApp) DeepCopyInto

func (in *ClusterGitHubApp) DeepCopyInto(out *ClusterGitHubApp)

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

func (*ClusterGitHubApp) DeepCopyObject

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

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

func (*ClusterGitHubApp) GetAppID

func (a *ClusterGitHubApp) GetAppID() int64

func (*ClusterGitHubApp) GetPrivateKey

func (a *ClusterGitHubApp) GetPrivateKey(ctx context.Context, c client.Client) ([]byte, error)

func (*ClusterGitHubApp) GetURL

func (a *ClusterGitHubApp) GetURL() string

type ClusterGitHubAppList

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

ClusterGitHubAppList contains a list of ClusterGitHubApp

func (*ClusterGitHubAppList) DeepCopy

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

func (*ClusterGitHubAppList) DeepCopyInto

func (in *ClusterGitHubAppList) DeepCopyInto(out *ClusterGitHubAppList)

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

func (*ClusterGitHubAppList) DeepCopyObject

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

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

type ClusterGitHubAppSpec

type ClusterGitHubAppSpec struct {

	// URL is the base url for GitHub
	// +kubebuilder:validation:Optional
	URL string `json:"url"`

	// AppID is the id of GitHub App
	AppID int64 `json:"appID"`

	// PrivateKeySecretRef is the reference for the secret of GitHub App's private key
	PrivateKeySecretRef PrivateKeySecretRef `json:"privateKeySecretRef"`
}

ClusterGitHubAppSpec defines the desired state of ClusterGitHubApp

func (*ClusterGitHubAppSpec) DeepCopy

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

func (*ClusterGitHubAppSpec) DeepCopyInto

func (in *ClusterGitHubAppSpec) DeepCopyInto(out *ClusterGitHubAppSpec)

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

type ClusterGitHubAppStatus

type ClusterGitHubAppStatus struct {
}

ClusterGitHubAppStatus defines the observed state of ClusterGitHubApp

func (*ClusterGitHubAppStatus) DeepCopy

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

func (*ClusterGitHubAppStatus) DeepCopyInto

func (in *ClusterGitHubAppStatus) DeepCopyInto(out *ClusterGitHubAppStatus)

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

type GitHubApp

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

	Spec   GitHubAppSpec   `json:"spec,omitempty"`
	Status GitHubAppStatus `json:"status,omitempty"`
}

GitHubApp is the Schema for the githubapps API

func (*GitHubApp) DeepCopy

func (in *GitHubApp) DeepCopy() *GitHubApp

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

func (*GitHubApp) DeepCopyInto

func (in *GitHubApp) DeepCopyInto(out *GitHubApp)

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

func (*GitHubApp) DeepCopyObject

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

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

func (*GitHubApp) GetAppID

func (a *GitHubApp) GetAppID() int64

func (*GitHubApp) GetPrivateKey

func (a *GitHubApp) GetPrivateKey(ctx context.Context, c client.Client) ([]byte, error)

func (*GitHubApp) GetURL

func (a *GitHubApp) GetURL() string

type GitHubAppList

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

GitHubAppList contains a list of GitHubApp

func (*GitHubAppList) DeepCopy

func (in *GitHubAppList) DeepCopy() *GitHubAppList

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

func (*GitHubAppList) DeepCopyInto

func (in *GitHubAppList) DeepCopyInto(out *GitHubAppList)

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

func (*GitHubAppList) DeepCopyObject

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

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

type GitHubAppSpec

type GitHubAppSpec struct {

	// URL is the base url for GitHub
	// +kubebuilder:validation:Optional
	URL string `json:"url"`

	// AppID is the id of GitHub App
	AppID int64 `json:"appID"`

	// PrivateKeySecretRef is the reference for the secret of GitHub App's private key
	PrivateKeySecretRef PrivateKeySecretRef `json:"privateKeySecretRef"`
}

GitHubAppSpec defines the desired state of GitHubApp

func (*GitHubAppSpec) DeepCopy

func (in *GitHubAppSpec) DeepCopy() *GitHubAppSpec

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

func (*GitHubAppSpec) DeepCopyInto

func (in *GitHubAppSpec) DeepCopyInto(out *GitHubAppSpec)

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

type GitHubAppStatus

type GitHubAppStatus struct {
}

GitHubAppStatus defines the observed state of GitHubApp

func (*GitHubAppStatus) DeepCopy

func (in *GitHubAppStatus) DeepCopy() *GitHubAppStatus

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

func (*GitHubAppStatus) DeepCopyInto

func (in *GitHubAppStatus) DeepCopyInto(out *GitHubAppStatus)

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

type Installation

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

	Spec   InstallationSpec   `json:"spec,omitempty"`
	Status InstallationStatus `json:"status,omitempty"`
}

Installation is the Schema for the installations API

func (*Installation) DeepCopy

func (in *Installation) DeepCopy() *Installation

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

func (*Installation) DeepCopyInto

func (in *Installation) DeepCopyInto(out *Installation)

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

func (*Installation) DeepCopyObject

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

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

type InstallationList

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

InstallationList contains a list of Installation

func (*InstallationList) DeepCopy

func (in *InstallationList) DeepCopy() *InstallationList

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

func (*InstallationList) DeepCopyInto

func (in *InstallationList) DeepCopyInto(out *InstallationList)

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

func (*InstallationList) DeepCopyObject

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

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

type InstallationPermissions

type InstallationPermissions struct {
	Administration              *string `json:"administration,omitempty"`
	Blocking                    *string `json:"blocking,omitempty"`
	Checks                      *string `json:"checks,omitempty"`
	Contents                    *string `json:"contents,omitempty"`
	ContentReferences           *string `json:"content_references,omitempty"`
	Deployments                 *string `json:"deployments,omitempty"`
	Emails                      *string `json:"emails,omitempty"`
	Followers                   *string `json:"followers,omitempty"`
	Issues                      *string `json:"issues,omitempty"`
	Metadata                    *string `json:"metadata,omitempty"`
	Members                     *string `json:"members,omitempty"`
	OrganizationAdministration  *string `json:"organization_administration,omitempty"`
	OrganizationHooks           *string `json:"organization_hooks,omitempty"`
	OrganizationPlan            *string `json:"organization_plan,omitempty"`
	OrganizationPreReceiveHooks *string `json:"organization_pre_receive_hooks,omitempty"`
	OrganizationProjects        *string `json:"organization_projects,omitempty"`
	OrganizationUserBlocking    *string `json:"organization_user_blocking,omitempty"`
	Packages                    *string `json:"packages,omitempty"`
	Pages                       *string `json:"pages,omitempty"`
	PullRequests                *string `json:"pull_requests,omitempty"`
	RepositoryHooks             *string `json:"repository_hooks,omitempty"`
	RepositoryProjects          *string `json:"repository_projects,omitempty"`
	RepositoryPreReceiveHooks   *string `json:"repository_pre_receive_hooks,omitempty"`
	SingleFile                  *string `json:"single_file,omitempty"`
	Statuses                    *string `json:"statuses,omitempty"`
	TeamDiscussions             *string `json:"team_discussions,omitempty"`
	VulnerabilityAlerts         *string `json:"vulnerability_alerts,omitempty"`
}

InstallationPermissions is the permissions to restrict permissions for tokens

func (*InstallationPermissions) DeepCopy

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

func (*InstallationPermissions) DeepCopyInto

func (in *InstallationPermissions) DeepCopyInto(out *InstallationPermissions)

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

func (*InstallationPermissions) GetGitHubPermissions

func (p *InstallationPermissions) GetGitHubPermissions() *github.InstallationPermissions

GetGitHubPermissions returns github.InstallationPermissions converted from InstallationPermissions

type InstallationSpec

type InstallationSpec struct {

	// AppRef is a reference to ClusterGitHubApp or GitHubApp
	AppRef corev1.ObjectReference `json:"appRef"`

	// InstallationID is an installation id for GitHub App
	InstallationID int64 `json:"installationID"`

	// RepositoryIDS are used to restrict permissions for tokens
	// +kubebuilder:validation:Optional
	RepositoryIDs []int64 `json:"repositoryIDs,omitempty"`

	// Permissions are used to restrict permissions for tokens
	// +kubebuilder:validation:Optional
	Permissions *InstallationPermissions `json:"permissions"`

	// Key is the key in the secret to save the token
	Key string `json:"key"`

	// Template is the template to generate secret with the installation token
	Template SecretTemplateSpec `json:"template"`
}

InstallationSpec defines the desired state of GitHub installation

func (*InstallationSpec) DeepCopy

func (in *InstallationSpec) DeepCopy() *InstallationSpec

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

func (*InstallationSpec) DeepCopyInto

func (in *InstallationSpec) DeepCopyInto(out *InstallationSpec)

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

type InstallationStatus

type InstallationStatus struct {

	// Ready is the status of the installation token
	Ready bool `json:"ready"`

	// Secret is the secret name to save the installation token
	Secret string `json:"secret"`

	// Message is the error message if something failed
	// +kubebuilder:validation:Optional
	Message string `json:"message,omitempty"`
}

InstallationStatus defines the observed state of Installation

func (*InstallationStatus) DeepCopy

func (in *InstallationStatus) DeepCopy() *InstallationStatus

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

func (*InstallationStatus) DeepCopyInto

func (in *InstallationStatus) DeepCopyInto(out *InstallationStatus)

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

type MetadataSpec

type MetadataSpec struct {
	// Map of string keys and values that can be used to organize and categorize
	// (scope and select) objects. May match selectors of replication controllers
	// and services.
	// More info: http://kubernetes.io/docs/user-guide/labels
	// +kubebuilder:validation:Optional
	Labels map[string]string `json:"labels,omitempty"`

	// Annotations is an unstructured key value map stored with a resource that may be
	// set by external tools to store and retrieve arbitrary metadata. They are not
	// queryable and should be preserved when modifying objects.
	// More info: http://kubernetes.io/docs/user-guide/annotations
	// +kubebuilder:validation:Optional
	Annotations map[string]string `json:"annotations,omitempty"`
}

func (*MetadataSpec) DeepCopy

func (in *MetadataSpec) DeepCopy() *MetadataSpec

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

func (*MetadataSpec) DeepCopyInto

func (in *MetadataSpec) DeepCopyInto(out *MetadataSpec)

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

type PrivateKeySecretRef

type PrivateKeySecretRef struct {
	Name string `json:"name"`
	Key  string `json:"key"`
}

func (*PrivateKeySecretRef) DeepCopy

func (in *PrivateKeySecretRef) DeepCopy() *PrivateKeySecretRef

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

func (*PrivateKeySecretRef) DeepCopyInto

func (in *PrivateKeySecretRef) DeepCopyInto(out *PrivateKeySecretRef)

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

type SecretTemplateSpec

type SecretTemplateSpec struct {
	// Standard object's metadata.
	// More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata
	// +kubebuilder:validation:Optional
	MetadataSpec `json:"metadata,omitempty"`

	// Immutable, if set to true, ensures that data stored in the Secret cannot
	// be updated (only object metadata can be modified).
	// If not set to true, the field can be modified at any time.
	// Defaulted to nil.
	// This is an alpha field enabled by ImmutableEphemeralVolumes feature gate.
	// +kubebuilder:validation:Optional
	Immutable *bool `json:"immutable,omitempty"`

	// Data contains the secret data. Each key must consist of alphanumeric
	// characters, '-', '_' or '.'. The serialized form of the secret data is a
	// base64 encoded string, representing the arbitrary (possibly non-string)
	// data value here. Described in https://tools.ietf.org/html/rfc4648#section-4
	// +kubebuilder:validation:Optional
	Data map[string][]byte `json:"data,omitempty"`

	// stringData allows specifying non-binary secret data in string form.
	// It is provided as a write-only convenience method.
	// All keys and values are merged into the data field on write, overwriting any existing values.
	// It is never output when reading from the API.
	// +k8s:conversion-gen=false
	// +kubebuilder:validation:Optional
	StringData map[string]string `json:"stringData,omitempty"`

	// Used to facilitate programmatic handling of secret data.
	// +kubebuilder:validation:Optional
	Type corev1.SecretType `json:"type,omitempty"`
}

SecretTemplateSpec is the template to generate secret with the installation token

func (*SecretTemplateSpec) DeepCopy

func (in *SecretTemplateSpec) DeepCopy() *SecretTemplateSpec

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

func (*SecretTemplateSpec) DeepCopyInto

func (in *SecretTemplateSpec) DeepCopyInto(out *SecretTemplateSpec)

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

Jump to

Keyboard shortcuts

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