Help us shape the future of Go! Take the 2026 Go Developer Survey

hooks

package
v1.1.0 Latest Latest
Warning

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

Go to latest
Published: May 27, 2024 License: MIT Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ConfigHooks

type ConfigHooks struct {
	WebhookSecret string
}

type Hooks

type Hooks struct {
	*ConfigHooks
	// contains filtered or unexported fields
}

func NewHooks

func NewHooks(c *ConfigHooks, i Interactor) *Hooks

func (*Hooks) HandleHook

func (h *Hooks) HandleHook(c *gin.Context)

HandleHook handles deployment status event, basically, it creates a new deployment status for the deployment.

type Interactor

type Interactor interface {
	FindRepoByID(ctx context.Context, id int64) (*ent.Repo, error)
	FindDeploymentByUID(ctx context.Context, uid int64) (*ent.Deployment, error)
	Deploy(ctx context.Context, u *ent.User, r *ent.Repo, d *ent.Deployment, env *extent.Env) (*ent.Deployment, error)
	UpdateDeployment(ctx context.Context, d *ent.Deployment) (*ent.Deployment, error)
	CreateDeploymentStatus(ctx context.Context, ds *ent.DeploymentStatus) (*ent.DeploymentStatus, error)
	ProduceDeploymentStatisticsOfRepo(ctx context.Context, r *ent.Repo, d *ent.Deployment) (*ent.DeploymentStatistics, error)
	GetEvaluatedConfig(ctx context.Context, u *ent.User, r *ent.Repo, v *extent.EvalValues) (*extent.Config, error)
}

Directories

Path Synopsis
Package mock is a generated GoMock package.
Package mock is a generated GoMock package.

Jump to

Keyboard shortcuts

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