status

package
v2.8.0 Latest Latest
Warning

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

Go to latest
Published: Dec 15, 2020 License: Apache-2.0 Imports: 11 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// Method is the HTTP method this endpoint is register for.
	Method = "PATCH"
	// Name identifies the endpoint. It is aligned to the package path.
	Name = "status/updater"
	// Path is the HTTP request path this endpoint is registered for.
	Path = "/status/{app_namespace}/{app_name}"
)

Variables

This section is empty.

Functions

func IsDecodeFailed

func IsDecodeFailed(err error) bool

IsDecodeFailed asserts deleteFailedError.

func IsInvalidConfig

func IsInvalidConfig(err error) bool

IsInvalidConfig asserts invalidConfigError.

func IsWrongTokenError added in v2.7.0

func IsWrongTokenError(err error) bool

IsWrongTokenError asserts wrongTokenError.

Types

type Config

type Config struct {
	K8sClient k8sclient.Interface
	Logger    micrologger.Logger

	WebhookAuthToken string
}

type Endpoint

type Endpoint struct {
	// contains filtered or unexported fields
}

func New

func New(config Config) (*Endpoint, error)

func (Endpoint) Decoder

func (e Endpoint) Decoder() kithttp.DecodeRequestFunc

func (Endpoint) Encoder

func (e Endpoint) Encoder() kithttp.EncodeResponseFunc

func (Endpoint) Endpoint

func (e Endpoint) Endpoint() kitendpoint.Endpoint

func (Endpoint) Method

func (e Endpoint) Method() string

func (Endpoint) Middlewares

func (e Endpoint) Middlewares() []kitendpoint.Middleware

func (Endpoint) Name

func (e Endpoint) Name() string

func (Endpoint) Path

func (e Endpoint) Path() string

type Request

type Request struct {
	AppName      string  `json:"app_name"`
	AppNamespace string  `json:"app_namespace"`
	AppVersion   string  `json:"app_version"`
	AuthToken    string  `json:"auth_token"`
	LastDeployed v1.Time `json:"last_deployed"`
	Reason       string  `json:"reason"`
	Status       string  `json:"status"`
	Version      string  `json:"version"`
}

Jump to

Keyboard shortcuts

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