Documentation ¶
Overview ¶
Package v1beta2 contains API Schema definitions for the apps v1beta2 API group +kubebuilder:object:generate=true +groupName=apps.gitlab.com
Index ¶
- Constants
- Variables
- type CacheAzureConfig
- type CacheGCSConfig
- type CacheS3Config
- type KubernetesPodSpec
- type KubernetesPodSpecPatchType
- type Runner
- func (in *Runner) DeepCopy() *Runner
- func (in *Runner) DeepCopyInto(out *Runner)
- func (in *Runner) DeepCopyObject() runtime.Object
- func (r *Runner) Default()
- func (r *Runner) SetupWebhookWithManager(mgr ctrl.Manager) error
- func (r *Runner) ValidateCreate() error
- func (r *Runner) ValidateDelete() error
- func (r *Runner) ValidateUpdate(old runtime.Object) error
- type RunnerList
- type RunnerSpec
- type RunnerStatus
Constants ¶
const ( // PatchTypeJSONPatchType patch strategy uses the JSON Patch specification // to give control over the PodSpec objects and arrays to update // More info: https://datatracker.ietf.org/doc/html/rfc6902 PatchTypeJSONPatchType = KubernetesPodSpecPatchType("json") // PatchTypeMergePatchType patch strategy applies a key-value replacement on the existing PodSpec // More info: https://datatracker.ietf.org/doc/html/rfc7386 PatchTypeMergePatchType = KubernetesPodSpecPatchType("merge") // PatchTypeStrategicMergePatchType patch strategy uses the existing patchStrategy // applied to each field of the PodSpec object PatchTypeStrategicMergePatchType = KubernetesPodSpecPatchType("strategic") )
Variables ¶
var ( // GroupVersion is group version used to register these objects GroupVersion = schema.GroupVersion{Group: "apps.gitlab.com", Version: "v1beta2"} // 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 CacheAzureConfig ¶
type CacheAzureConfig struct { // Credentials secret contains 'accountName' and 'privateKey' // used to authenticate against Azure blob storage Credentials string `json:"credentials,omitempty"` // Name of the Azure container in which the cache will be stored ContainerName string `json:"container,omitempty"` // The domain name of the Azure blob storage // e.g. blob.core.windows.net StorageDomain string `json:"storageDomain,omitempty"` }
CacheAzureConfig defines options for Azure object store
func (*CacheAzureConfig) DeepCopy ¶
func (in *CacheAzureConfig) DeepCopy() *CacheAzureConfig
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new CacheAzureConfig.
func (*CacheAzureConfig) DeepCopyInto ¶
func (in *CacheAzureConfig) DeepCopyInto(out *CacheAzureConfig)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type CacheGCSConfig ¶
type CacheGCSConfig struct { // contains the GCS 'access-id' and 'private-key' Credentials string `json:"credentials,omitempty"` // Takes GCS credentials file, 'keys.json' CredentialsFile string `json:"credentialsFile,omitempty"` // Name of the bucket in which the cache will be stored BucketName string `json:"bucket,omitempty"` }
CacheGCSConfig defines options for GCS object store
func (*CacheGCSConfig) DeepCopy ¶
func (in *CacheGCSConfig) DeepCopy() *CacheGCSConfig
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new CacheGCSConfig.
func (*CacheGCSConfig) DeepCopyInto ¶
func (in *CacheGCSConfig) DeepCopyInto(out *CacheGCSConfig)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type CacheS3Config ¶
type CacheS3Config struct { Server string `json:"server,omitempty"` // Name of the secret containing the // 'accesskey' and 'secretkey' used to access the object storage Credentials string `json:"credentials,omitempty"` // Name of the bucket in which the cache will be stored BucketName string `json:"bucket,omitempty"` // Name of the S3 region in use BucketLocation string `json:"location,omitempty"` // Use insecure connections or HTTP Insecure bool `json:"insecure,omitempty"` }
CacheS3Config defines options for an S3 compatible cache
func (*CacheS3Config) DeepCopy ¶
func (in *CacheS3Config) DeepCopy() *CacheS3Config
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new CacheS3Config.
func (*CacheS3Config) DeepCopyInto ¶
func (in *CacheS3Config) DeepCopyInto(out *CacheS3Config)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type KubernetesPodSpec ¶ added in v1.17.0
type KubernetesPodSpec struct { // Name is the name given to the custom Pod Spec Name string `json:"name"` // Path to the file that defines the changes to apply to the final PodSpec object before it is generated. // The file must be a JSON or YAML file. // You cannot set the patch_path and patch in the same pod_spec configuration, otherwise an error occurs. PatchFile string `json:"patchFile,omitempty"` // A JSON or YAML format string that describes the changes which must be applied // to the final PodSpec object before it is generated. // You cannot set the patch_path and patch in the same pod_spec configuration, otherwise an error occurs. Patch string `json:"patch,omitempty"` // The strategy the runner uses to apply the specified changes to the PodSpec object generated by GitLab Runner. // The accepted values are merge, json, and strategic (default value). PatchType KubernetesPodSpecPatchType `json:"patchType"` }
KubernetesPodSpec represents the structure expected when adding a custom PodSpec to configure the Pod running the GitLab Runner Manager
func (*KubernetesPodSpec) DeepCopy ¶ added in v1.23.2
func (in *KubernetesPodSpec) DeepCopy() *KubernetesPodSpec
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new KubernetesPodSpec.
func (*KubernetesPodSpec) DeepCopyInto ¶ added in v1.23.2
func (in *KubernetesPodSpec) DeepCopyInto(out *KubernetesPodSpec)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*KubernetesPodSpec) JSONMarshal ¶ added in v1.17.0
func (s *KubernetesPodSpec) JSONMarshal(patchType KubernetesPodSpecPatchType) ([]byte, error)
JSONMarshal returns the patch data (JSON encoded) and type
type KubernetesPodSpecPatchType ¶ added in v1.17.0
type KubernetesPodSpecPatchType string
KubernetesPodSpecPatchType defines the type of patch allowed to update the Deployment template PodSpec
type Runner ¶
type Runner struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` // Specification of the desired behavior of a GitLab Runner instance Spec RunnerSpec `json:"spec,omitempty"` // Most recently observed status of the GitLab Runner. // It is read-only to the user Status RunnerStatus `json:"status,omitempty"` }
Runner is the open source project used to run your jobs and send the results back to GitLab
func (*Runner) DeepCopy ¶
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Runner.
func (*Runner) DeepCopyInto ¶
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*Runner) DeepCopyObject ¶
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
func (*Runner) Default ¶ added in v1.7.0
func (r *Runner) Default()
Default implements webhook.Defaulter so a webhook will be registered for the type
func (*Runner) SetupWebhookWithManager ¶
SetupWebhookWithManager adds the runner webhook to the controller runtime manager
func (*Runner) ValidateCreate ¶
ValidateCreate implements webhook.Validator so a webhook will be registered for the type
func (*Runner) ValidateDelete ¶
ValidateDelete implements webhook.Validator so a webhook will be registered for the type
type RunnerList ¶
type RunnerList struct { metav1.TypeMeta `json:",inline"` metav1.ListMeta `json:"metadata,omitempty"` Items []Runner `json:"items"` }
RunnerList contains a list of Runner
func (*RunnerList) DeepCopy ¶
func (in *RunnerList) DeepCopy() *RunnerList
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new RunnerList.
func (*RunnerList) DeepCopyInto ¶
func (in *RunnerList) DeepCopyInto(out *RunnerList)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
func (*RunnerList) DeepCopyObject ¶
func (in *RunnerList) DeepCopyObject() runtime.Object
DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.
type RunnerSpec ¶
type RunnerSpec struct { // The fully qualified domain name for the GitLab instance. // For example, https://gitlab.example.com // +operator-sdk:csv:customresourcedefinitions:type=spec,displayName="GitLab URL",xDescriptors="urn:alm:descriptor:com.tectonic.ui:text" GitLab string `json:"gitlabUrl"` //Name of secret containing the 'runner-registration-token' key used to register the runner // +operator-sdk:csv:customresourcedefinitions:type=spec,displayName="Registration Token",xDescriptors="urn:alm:descriptor:com.tectonic.ui:selector:core:v1:Secret" RegistrationToken string `json:"token"` // List of comma separated tags to be applied to the runner // More info: https://docs.gitlab.com/ee/ci/runners/#use-tags-to-limit-the-number-of-jobs-using-the-runner // +operator-sdk:csv:customresourcedefinitions:type=spec,displayName="Tags",xDescriptors="urn:alm:descriptor:com.tectonic.ui:text" Tags string `json:"tags,omitempty"` // Option to limit the number of jobs globally that can run concurrently. // The operator sets this to 10, if not specified // +operator-sdk:csv:customresourcedefinitions:type=spec,displayName="Concurrent",xDescriptors="urn:alm:descriptor:com.tectonic.ui:text" Concurrent *int32 `json:"concurrent,omitempty"` // Option to define the number of seconds between checks for new jobs. // This is set to a default of 30s by operator if not set // +operator-sdk:csv:customresourcedefinitions:type=spec,displayName="Check Interval",xDescriptors="urn:alm:descriptor:com.tectonic.ui:text" CheckInterval *int32 `json:"interval,omitempty"` // Specify whether the runner should be locked to a specific project. Defaults to false. Locked bool `json:"locked,omitempty"` // Specify if jobs without tags should be run. // If not specified, runner will default to true if no tags were specified. // In other case it will default to false. RunUntagged *bool `json:"runUntagged,omitempty"` // Specify whether the runner should only run protected branches. Defaults to false. Protected bool `json:"protected,omitempty"` // If specified, overrides the default URL used to clone or fetch the Git ref CloneURL string `json:"cloneURL,omitempty"` // Accepts configmap name. Provides user mechanism to inject environment // variables in the GitLab Runner pod via the key value pairs in the ConfigMap Environment string `json:"env,omitempty"` // If specified, overrides the default GitLab Runner image. Default is the Runner image the operator was bundled with. RunnerImage string `json:"runnerImage,omitempty"` // If specified, overrides the default GitLab Runner helper image HelperImage string `json:"helperImage,omitempty"` // If specified, overrides the namespace where job pods are created Namespace string `json:"namespace,omitempty"` // The name of the default image to use to run // build jobs, when none is specified BuildImage string `json:"buildImage,omitempty"` // Type of cache used for Runner artifacts // Options are: gcs, s3, azure // +kubebuilder:validations:Enum=s3;gcs;azure CacheType string `json:"cacheType,omitempty"` // Path defines the Runner Cache path CachePath string `json:"cachePath,omitempty"` // Name of tls secret containing the custom certificate // authority (CA) certificates CertificateAuthority string `json:"ca,omitempty"` CacheShared bool `json:"cacheShared,omitempty"` // options used to setup S3 // object store as GitLab Runner Cache S3 *CacheS3Config `json:"s3,omitempty"` // options used to setup GCS (Google // Container Storage) as GitLab Runner Cache GCS *CacheGCSConfig `json:"gcs,omitempty"` // options used to setup Azure blob // storage as GitLab Runner Cache Azure *CacheAzureConfig `json:"azure,omitempty"` // allow user to override service account // used by GitLab Runner ServiceAccount string `json:"serviceaccount,omitempty"` // allow user to provide configmap name // containing the user provided config.toml Configuration string `json:"config,omitempty"` // ImagePullPolicy sets the Image pull policy. // One of Always, Never, IfNotPresent. // Defaults to Always if :latest tag is specified, or IfNotPresent otherwise. // More info: https://kubernetes.io/docs/concepts/containers/images#updating-images ImagePullPolicy corev1.PullPolicy `json:"imagePullPolicy,omitempty"` PodSpec []KubernetesPodSpec `json:"podSpec,omitempty"` }
RunnerSpec defines the desired state of Runner +k8s:deepcopy-gen=true
func (*RunnerSpec) DeepCopy ¶
func (in *RunnerSpec) DeepCopy() *RunnerSpec
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new RunnerSpec.
func (*RunnerSpec) DeepCopyInto ¶
func (in *RunnerSpec) DeepCopyInto(out *RunnerSpec)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.
type RunnerStatus ¶
type RunnerStatus struct { // Reports status of the GitLab Runner instance // +operator-sdk:csv:customresourcedefinitions:type=status,displayName="Phase",xDescriptors="urn:alm:descriptor:com.tectonic.ui:text" Phase string `json:"phase,omitempty"` // Reports status of GitLab Runner registration // +operator-sdk:csv:customresourcedefinitions:type=status,displayName="Registration",xDescriptors="urn:alm:descriptor:com.tectonic.ui:text" Registration string `json:"registration,omitempty"` // Additional information of GitLab Runner registration // +operator-sdk:csv:customresourcedefinitions:type=status,displayName="Message",xDescriptors="urn:alm:descriptor:com.tectonic.ui:text" Message string `json:"message,omitempty"` }
RunnerStatus defines the observed state of Runner
func (*RunnerStatus) DeepCopy ¶
func (in *RunnerStatus) DeepCopy() *RunnerStatus
DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new RunnerStatus.
func (*RunnerStatus) DeepCopyInto ¶
func (in *RunnerStatus) DeepCopyInto(out *RunnerStatus)
DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.