controllers

package
v0.4.0 Latest Latest
Warning

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

Go to latest
Published: Mar 20, 2020 License: Apache-2.0 Imports: 18 Imported by: 0

Documentation

Index

Constants

View Source
const (
	LabelKeyRunnerTemplateHash = "runner-template-hash"
)

Variables

This section is empty.

Functions

func CloneAndAddLabel added in v0.4.0

func CloneAndAddLabel(labels map[string]string, labelKey, labelValue string) map[string]string

Clones the given map and returns a new map with the given key and value added. Returns the given map, if labelKey is empty.

Proudly copied from k8s.io/kubernetes/pkg/util/labels.CloneAndAddLabel

func ComputeHash added in v0.4.0

func ComputeHash(template interface{}) string

ComputeHash returns a hash value calculated from pod template and a collisionCount to avoid hash collision. The hash will be safe encoded to avoid bad words.

Proudly modified and adopted from k8s.io/kubernetes/pkg/util/hash.DeepHashObject and k8s.io/kubernetes/pkg/controller.ComputeHash.

Types

type GitHubRegistrationToken added in v0.2.0

type GitHubRegistrationToken struct {
	Token     string `json:"token"`
	ExpiresAt string `json:"expires_at"`
}

type GitHubRunner added in v0.2.0

type GitHubRunner struct {
	ID     int    `json:"id"`
	Name   string `json:"name"`
	OS     string `json:"os"`
	Status string `json:"status"`
}

type GitHubRunnerList added in v0.4.0

type GitHubRunnerList struct {
	TotalCount int            `json:"total_count"`
	Runners    []GitHubRunner `json:"runners,omitempty"`
}

type RunnerDeploymentReconciler added in v0.4.0

type RunnerDeploymentReconciler struct {
	client.Client
	Log      logr.Logger
	Recorder record.EventRecorder
	Scheme   *runtime.Scheme
}

RunnerDeploymentReconciler reconciles a Runner object

func (*RunnerDeploymentReconciler) Reconcile added in v0.4.0

func (r *RunnerDeploymentReconciler) Reconcile(req ctrl.Request) (ctrl.Result, error)

func (*RunnerDeploymentReconciler) SetupWithManager added in v0.4.0

func (r *RunnerDeploymentReconciler) SetupWithManager(mgr ctrl.Manager) error

type RunnerReconciler

type RunnerReconciler struct {
	client.Client
	Log          logr.Logger
	Recorder     record.EventRecorder
	Scheme       *runtime.Scheme
	GitHubClient *github.Client
	RunnerImage  string
	DockerImage  string
}

RunnerReconciler reconciles a Runner object

func (*RunnerReconciler) Reconcile

func (r *RunnerReconciler) Reconcile(req ctrl.Request) (ctrl.Result, error)

func (*RunnerReconciler) SetupWithManager

func (r *RunnerReconciler) SetupWithManager(mgr ctrl.Manager) error

type RunnerReplicaSetReconciler added in v0.4.0

type RunnerReplicaSetReconciler struct {
	client.Client
	Log      logr.Logger
	Recorder record.EventRecorder
	Scheme   *runtime.Scheme
}

RunnerReplicaSetReconciler reconciles a Runner object

func (*RunnerReplicaSetReconciler) Reconcile added in v0.4.0

func (r *RunnerReplicaSetReconciler) Reconcile(req ctrl.Request) (ctrl.Result, error)

func (*RunnerReplicaSetReconciler) SetupWithManager added in v0.4.0

func (r *RunnerReplicaSetReconciler) SetupWithManager(mgr ctrl.Manager) error

Jump to

Keyboard shortcuts

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