v1alpha1

package
v0.8.0 Latest Latest
Warning

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

Go to latest
Published: Jul 10, 2022 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Overview

Package v1alpha1 contains API Schema definitions for the tower v1alpha1 API group +kubebuilder:object:generate=true +groupName=tower.ansible.com

Index

Constants

This section is empty.

Variables

View Source
var (
	// GroupVersion is group version used to register these objects
	GroupVersion = schema.GroupVersion{Group: "tower.ansible.com", 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 AnsibleJob

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

	Spec   AnsibleJobSpec   `json:"spec,omitempty"`
	Status AnsibleJobStatus `json:"status,omitempty"`
}

AnsibleJob is the Schema for the ansiblejobs API

func (*AnsibleJob) DeepCopy

func (in *AnsibleJob) DeepCopy() *AnsibleJob

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

func (*AnsibleJob) DeepCopyInto

func (in *AnsibleJob) DeepCopyInto(out *AnsibleJob)

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

func (*AnsibleJob) DeepCopyObject

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

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

type AnsibleJobList

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

AnsibleJobList contains a list of AnsibleJob

func (*AnsibleJobList) DeepCopy

func (in *AnsibleJobList) DeepCopy() *AnsibleJobList

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

func (*AnsibleJobList) DeepCopyInto

func (in *AnsibleJobList) DeepCopyInto(out *AnsibleJobList)

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

func (*AnsibleJobList) DeepCopyObject

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

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

type AnsibleJobResult

type AnsibleJobResult struct {
	Changed  bool   `json:"changed,omitempty"`
	Failed   bool   `json:"failed,omitempty"`
	Elapsed  string `json:"elapsed,omitempty"`
	Finished string `json:"finished,omitempty"`
	Started  string `json:"started,omitempty"`
	Status   string `json:"status,omitempty"`
	URL      string `json:"url,omitempty"`
}

func (*AnsibleJobResult) DeepCopy

func (in *AnsibleJobResult) DeepCopy() *AnsibleJobResult

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

func (*AnsibleJobResult) DeepCopyInto

func (in *AnsibleJobResult) DeepCopyInto(out *AnsibleJobResult)

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

type AnsibleJobSpec

type AnsibleJobSpec struct {
	// INSERT ADDITIONAL SPEC FIELDS - desired state of cluster
	// Important: Run "make" to regenerate code after modifying this file
	TowerAuthSecretName string          `json:"tower_auth_secret,omitempty"`
	JobTemplateName     string          `json:"job_template_name,omitempty"`
	Inventory           string          `json:"inventory,omitempty"`
	ExtraVars           json.RawMessage `json:"extra_vars,omitempty"`
}

AnsibleJobSpec defines the desired state of AnsibleJob

func (*AnsibleJobSpec) DeepCopy

func (in *AnsibleJobSpec) DeepCopy() *AnsibleJobSpec

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

func (*AnsibleJobSpec) DeepCopyInto

func (in *AnsibleJobSpec) DeepCopyInto(out *AnsibleJobSpec)

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

type AnsibleJobStatus

type AnsibleJobStatus struct {
	// INSERT ADDITIONAL STATUS FIELD - define observed state of cluster
	// Important: Run "make" to regenerate code after modifying this file
	AnsibleJobResult `json:"ansibleJobResult,omitempty"`
	Conditions       []Condition `json:"conditions,omitempty"`
	K8sJob           `json:"k8sJob,omitempty"`
	Message          string `json:"message,omitempty"`
}

AnsibleJobStatus defines the observed state of AnsibleJob

func (*AnsibleJobStatus) DeepCopy

func (in *AnsibleJobStatus) DeepCopy() *AnsibleJobStatus

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

func (*AnsibleJobStatus) DeepCopyInto

func (in *AnsibleJobStatus) DeepCopyInto(out *AnsibleJobStatus)

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

type AnsibleResult

type AnsibleResult struct {
	Ok               int       `json:"ok"`
	Changed          int       `json:"changed"`
	Skipped          int       `json:"skipped"`
	Failures         int       `json:"failures"`
	TimeOfCompletion EventTime `json:"completion"`
}

bridging from https://github.com/operator-framework/operator-sdk/blob/master/internal/ansible/controller/status/types.go AnsibleResult - encapsulation of the ansible result.

func (*AnsibleResult) DeepCopy

func (in *AnsibleResult) DeepCopy() *AnsibleResult

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

func (*AnsibleResult) DeepCopyInto

func (in *AnsibleResult) DeepCopyInto(out *AnsibleResult)

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

type Condition

type Condition struct {
	Type               ConditionType      `json:"type,omitempty"`
	Status             v1.ConditionStatus `json:"status,omitempty"`
	LastTransitionTime metav1.Time        `json:"lastTransitionTime,omitempty"`
	AnsibleResult      *AnsibleResult     `json:"ansibleResult,omitempty"`
	Reason             string             `json:"reason,omitempty"`
	Message            string             `json:"message,omitempty"`
}

Condition - the condition for the ansible operator.

func (*Condition) DeepCopy

func (in *Condition) DeepCopy() *Condition

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

func (*Condition) DeepCopyInto

func (in *Condition) DeepCopyInto(out *Condition)

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

type ConditionType

type ConditionType string

ConditionType - type of condition

const (
	// RunningConditionType - condition type of running.
	RunningConditionType ConditionType = "Running"
	// FailureConditionType - condition type of failure.
	FailureConditionType ConditionType = "Failure"

	JobScussed = "successful"
)

type Env

type Env struct {
	Inventory            string `json:"inventory,omitempty"`
	SecretNamespacedName string `json:"secretNamespacedName,omitempty"`
	TemplateName         string `json:"templateName,omitempty"`
	VerifySSL            bool   `json:"verifySSL,omitempty"`
}

func (*Env) DeepCopy

func (in *Env) DeepCopy() *Env

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

func (*Env) DeepCopyInto

func (in *Env) DeepCopyInto(out *Env)

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

type EventTime

type EventTime struct {
	metav1.Time
}

https://github.com/operator-framework/operator-sdk/blob/master/internal/ansible/runner/eventapi/types.go#L46-L49 EventTime - time to unmarshal nano time. +kubebuilder:object:generate=true

func (*EventTime) DeepCopy

func (in *EventTime) DeepCopy() *EventTime

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

func (*EventTime) DeepCopyInto

func (in *EventTime) DeepCopyInto(out *EventTime)

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

func (EventTime) MarshalJSON

func (e EventTime) MarshalJSON() ([]byte, error)

MarshalJSON - override the marshal json.

func (*EventTime) UnmarshalJSON

func (e *EventTime) UnmarshalJSON(b []byte) (err error)

UnmarshalJSON - override unmarshal json.

type K8sJob

type K8sJob struct {
	Created        bool `json:"created,omitempty"`
	Env            `json:"env,omitempty"`
	Message        string `json:"message,omitempty"`
	NamespacedName string `json:"namespacedName,omitempty"`
}

func (*K8sJob) DeepCopy

func (in *K8sJob) DeepCopy() *K8sJob

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

func (*K8sJob) DeepCopyInto

func (in *K8sJob) DeepCopyInto(out *K8sJob)

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