webhook

package
v1.0.1 Latest Latest
Warning

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

Go to latest
Published: Jun 28, 2024 License: AGPL-3.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Webhook

type Webhook struct {
	UUID        string                 `json:"uuid" yaml:"-"`
	ContainerId string                 `json:"containerId" yaml:"containerId"`
	Host        string                 `json:"host,omitempty" yaml:"host"`
	Action      docker.ContainerAction `json:"action" yaml:"action"`
	Created     time.Time              `json:"created" yaml:"created"`
}

func CreateWebhook

func CreateWebhook(path string, webhookItem Webhook) (Webhook, error)

type WebhooksDatabase

type WebhooksDatabase struct {
	Webhooks map[string]*Webhook `yaml:"webhooks"`
	LastRead time.Time           `yaml:"-"`
	LastSave time.Time           `yaml:"-"`
	Path     string              `yaml:"-"`
}

func ReadWebhooksFromFile

func ReadWebhooksFromFile(path string) (WebhooksDatabase, error)

func (*WebhooksDatabase) Find

func (d *WebhooksDatabase) Find(Uuid string) *Webhook

Jump to

Keyboard shortcuts

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