gitops

package
v0.1.22 Latest Latest
Warning

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

Go to latest
Published: Jul 26, 2021 License: Apache-2.0 Imports: 12 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// HelmexUpdateTaskName is the name of the task this file implements
	HelmexUpdateTaskName string = "helmex-update"

	// LocalDir is the directory where the git repo is cloned
	LocalDir string = "/tmp/gitdir"

	// CandidateID is the experiment annotations that uniquely identifies the candidate version.
	CandidateID string = "iter8.candidate.id"

	// DefaultSecretName is the default name of the secret containing the GitHub access token.
	DefaultSecretName string = "ghtoken"

	// DefaultBranch is the default branch to which this task pushes.
	DefaultBranch string = "main"
)
View Source
const (
	// LibraryName is the name of this task library
	LibraryName string = "gitops"
)

Variables

This section is empty.

Functions

func MakeHelmexUpdate

func MakeHelmexUpdate(t *v2alpha2.TaskSpec) (tasks.Task, error)

MakeHelmexUpdate constructs a HelmexUpdateTask out of a task spec

func MakeTask

func MakeTask(t *v2alpha2.TaskSpec) (tasks.Task, error)

MakeTask constructs a Task from a TaskMeta or returns an error if any.

Types

type HelmexUpdateInputs

type HelmexUpdateInputs struct {
	// GitRepo is the git repo
	GitRepo string `json:"gitRepo" yaml:"gitRepo"`
	// FilePath is the path to values.yaml file within the repo
	FilePath string `json:"filePath" yaml:"filePath"`
	// Username is the name of the GitHub user
	Username string `json:"username" yaml:"username"`
	// Branch is the name of the branch within this repo; default value is master
	Branch *string `json:"branch,omitempty" yaml:"branch,omitempty"`
	// SecretName is the name of the secret containing the GitHub access token
	SecretName *string `json:"secretName,omitempty" yaml:"secretName,omitempty"`
	// SecretName is the namespace of the secret containing the GitHub access token
	SecretNamespace *string `json:"secretNamespace,omitempty" yaml:"secretNamespace,omitempty"`
}

HelmexUpdateInputs contain the inputs to the helmex-update task to be executed.

type HelmexUpdateTask

type HelmexUpdateTask struct {
	tasks.TaskMeta
	With HelmexUpdateInputs `json:"with" yaml:"with"`
}

HelmexUpdateTask enables updates to the values.yaml file within a Helmex git repo.

func (*HelmexUpdateTask) Run

func (t *HelmexUpdateTask) Run(ctx context.Context) error

Run executes the gitops/helmex-update task

Jump to

Keyboard shortcuts

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