client

package
v0.0.4 Latest Latest
Warning

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

Go to latest
Published: Feb 9, 2020 License: MIT Imports: 14 Imported by: 7

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Serve

func Serve(configType interface{}, opts ...ServeOpt)

Serve is the main entry point for plugins

Types

type IntegrationPlugin

type IntegrationPlugin interface {
	// Run runs the plugin. Once this function returns the plugin stops running.
	// Implementors must respect the context deadline as that's the signal for graceful shutdown.
	Run(ctx context.Context, config interface{}, srv v1.WerftServiceClient) error
}

IntegrationPlugin works on the public werft API

type ServeOpt

type ServeOpt struct {
	Type common.Type
	Run  func(ctx context.Context, config interface{}, socket string) error
}

ServeOpt configures a plugin serve

func WithIntegrationPlugin

func WithIntegrationPlugin(p IntegrationPlugin) ServeOpt

WithIntegrationPlugin registers integration plugin capabilities

Jump to

Keyboard shortcuts

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