util

package
v1.1.6 Latest Latest
Warning

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

Go to latest
Published: Feb 17, 2021 License: Apache-2.0 Imports: 20 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func BindFlags

func BindFlags(o *zap.Options, fs *flag.FlagSet)

BindFlags custom flags

func Condition

func Condition(c v1beta1.Conditions) (status ci.State)

Condition returns a Play State

func GetCILabels

func GetCILabels(p *ci.Play) map[string]string

GetCILabels return CI label

func GetCINamespacedName

func GetCINamespacedName(prefix string, play *ci.Play) types.NamespacedName

GetCINamespacedName return CI namespacedName

func GetDeployNamespacedName

func GetDeployNamespacedName(prefix string, play *ci.Play) types.NamespacedName

GetCINamespacedName return CI namespacedName

func GetDockerImageTag

func GetDockerImageTag(play *ci.Play) (*url.URL, error)

GetDockerImageTag return the URL of the Docker repository

func GetDockerImageTagRaw

func GetDockerImageTagRaw(play *ci.Play) (address string, tag string, err error)

GetDockerImageTagRaw return the Docker repository

func GetObjectContain

func GetObjectContain(obj runtime.Object) string

GetObjectContain ...

func IgnoreNotExists

func IgnoreNotExists(err error) error

IgnoreNotFound returns nil on NotFound errors. All other values that are not NotFound errors or nil are returned unmodified.

func InNamespace

func InNamespace(play *ci.Play) client.InNamespace

func IsBuildStage

func IsBuildStage(play *ci.Play) bool

GetStage build the tasks

func IsPipelineRunning

func IsPipelineRunning(pr tkn.PipelineRun) bool

IsPipelineRunning return whether or not the pipeline is running

func JsonEncoderConfig

func JsonEncoderConfig() zapcore.EncoderConfig

JsonEncoderConfig returns an opinionated EncoderConfig

func ParseHostURL

func ParseHostURL(host string) (*url.URL, error)

ParseHostURL parses a url string, validates the string is a host url, and returns the parsed URL

func TextEncoderConfig

func TextEncoderConfig() zapcore.EncoderConfig

TextEncoderConfig returns an opinionated EncoderConfig

Types

This section is empty.

Jump to

Keyboard shortcuts

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