Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ( ErrMissingGitLabEventHeader = errors.New("missing X-Gitlab-Event Header") ErrEventNotSpecifiedToParse = errors.New("event not defined to be parsed") ErrReadingRequestBody = errors.New("error reading request body") ErrGitLabTokenVerificationFailed = errors.New("token validation failed") ErrCouldNotParseWebhookEvent = errors.New("could parse the webhook event") ErrCouldNotHandleEvent = errors.New("error handling the event") )
Functions ¶
func NewAdapter ¶
func NewAdapter(ctx context.Context, processed adapter.EnvConfigAccessor, ceClient cloudevents.Client) adapter.Adapter
NewAdapter returns the instance of gitLabReceiveAdapter that implements adapter.Adapter interface
func NewEnvConfig ¶
func NewEnvConfig() adapter.EnvConfigAccessor
NewEnvConfig function reads env variables defined in envConfig structure and returns accessor interface
func NewWebhookHandler ¶ added in v0.47.0
func NewWebhookHandler(secret string, sender EventSender) webhook
NewWebhookHandler provide a webhook receiver that parses Gitlab events and emits CloudEvents.
Types ¶
type EventSender ¶ added in v0.47.0
Click to show internal directories.
Click to hide internal directories.