webhook

package
v0.0.487 Latest Latest
Warning

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

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

Documentation

Index

Constants

View Source
const (
	// HealthPath is the URL path for the HTTP endpoint that returns health status.
	HealthPath = "/health"
	// ReadyPath URL path for the HTTP endpoint that returns ready status.
	ReadyPath = "/ready"

	// ProwConfigMapName name of the ConfgMap holding the config
	ProwConfigMapName = "config"
	// ProwPluginsConfigMapName name of the ConfigMap holding the plugins config
	ProwPluginsConfigMapName = "plugins"
	// ProwConfigFilename config file name
	ProwConfigFilename = "config.yaml"
	// ProwPluginsFilename plugins file name
	ProwPluginsFilename = "plugins.yaml"
)

Variables

This section is empty.

Functions

func NewCmdWebhook

func NewCmdWebhook() *cobra.Command

NewCmdWebhook creates the command

Types

type Options

type Options struct {
	BindAddress string
	Path        string
	Port        int
	JSONLog     bool
	// contains filtered or unexported fields
}

Options holds the command line arguments

func NewWebhook

func NewWebhook(factory jxfactory.Factory, server *hook.Server) *Options

NewWebhook creates a new webhook handler

func (*Options) GetBotName

func (o *Options) GetBotName() string

GetBotName returns the bot name

func (*Options) GetFactory

func (o *Options) GetFactory() jxfactory.Factory

GetFactory lazily creates a Factory if its not already created

func (*Options) ProcessWebHook

func (o *Options) ProcessWebHook(l *logrus.Entry, webhook scm.Webhook) (*logrus.Entry, string, error)

ProcessWebHook process a webhook

func (*Options) Run

func (o *Options) Run() error

Run will implement this command

Jump to

Keyboard shortcuts

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