deployment

package
v0.0.0-...-cd1078e Latest Latest
Warning

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

Go to latest
Published: Feb 21, 2025 License: MIT Imports: 27 Imported by: 0

Documentation

Index

Constants

View Source
const (
	ApplicationOrderFieldDeploymentTime application.ApplicationOrderField = "DEPLOYMENT_TIME"
	JobOrderFieldDeploymentTime         job.JobOrderField                 = "DEPLOYMENT_TIME"
)

Variables

Functions

func NewLoaderContext

func NewLoaderContext(ctx context.Context, pool *pgxpool.Pool, client hookd.Client) context.Context

func RunCleaner

func RunCleaner(ctx context.Context, dbtx deploymentsql.DBTX, log logrus.FieldLogger)

Types

type ChangeDeploymentKeyInput

type ChangeDeploymentKeyInput struct {
	TeamSlug slug.Slug `json:"team"`
}

type ChangeDeploymentKeyPayload

type ChangeDeploymentKeyPayload struct {
	DeploymentKey *DeploymentKey `json:"deploymentKey,omitempty"`
}

type Deployment

type Deployment struct {
	CreatedAt        time.Time `json:"createdAt"`
	Repository       *string   `json:"repository,omitempty"`
	DeployerUsername *string   `json:"deployerUsername,omitempty"`
	CommitSha        *string   `json:"commitSha,omitempty"`
	TriggerUrl       *string   `json:"triggerUrl,omitempty"`
	TeamSlug         slug.Slug `json:"teamSlug"`
	EnvironmentName  string    `json:"environmentName"`
	UUID             uuid.UUID `json:"-"`
}

func (*Deployment) ID

func (d *Deployment) ID() ident.Ident

func (Deployment) IsNode

func (Deployment) IsNode()

type DeploymentConnection

type DeploymentConnection = pagination.Connection[*Deployment]

func ListForTeam

func ListForTeam(ctx context.Context, teamSlug slug.Slug, page *pagination.Pagination) (*DeploymentConnection, error)

func ListForWorkload

func ListForWorkload(ctx context.Context, teamSlug slug.Slug, environmentName, workloadName string, workloadType workload.Type, page *pagination.Pagination) (*DeploymentConnection, error)

type DeploymentEdge

type DeploymentEdge = pagination.Edge[*Deployment]

type DeploymentKey

type DeploymentKey struct {
	Key      string    `json:"key"`
	Created  time.Time `json:"created"`
	Expires  time.Time `json:"expires"`
	TeamSlug slug.Slug `json:"-"`
}

func ChangeDeploymentKey

func ChangeDeploymentKey(ctx context.Context, teamSlug slug.Slug) (*DeploymentKey, error)

func KeyForTeam

func KeyForTeam(ctx context.Context, teamSlug slug.Slug) (*DeploymentKey, error)

func (DeploymentKey) ID

func (d DeploymentKey) ID() ident.Ident

func (DeploymentKey) IsNode

func (DeploymentKey) IsNode()

type DeploymentResource

type DeploymentResource struct {
	Kind      string    `json:"kind"`
	Name      string    `json:"name"`
	CreatedAt time.Time `json:"-"`
	Group     string    `json:"-"`
	Version   string    `json:"-"`
	Namespace string    `json:"-"`
	UUID      uuid.UUID `json:"-"`
}

func (*DeploymentResource) ID

func (d *DeploymentResource) ID() ident.Ident

func (DeploymentResource) IsNode

func (DeploymentResource) IsNode()

type DeploymentResourceConnection

type DeploymentResourceConnection = pagination.Connection[*DeploymentResource]

func ListResourcesForDeployment

func ListResourcesForDeployment(ctx context.Context, deploymentID uuid.UUID, page *pagination.Pagination) (*DeploymentResourceConnection, error)

type DeploymentResourceEdge

type DeploymentResourceEdge = pagination.Edge[*DeploymentResource]

type DeploymentStatus

type DeploymentStatus struct {
	CreatedAt time.Time             `json:"createdAt"`
	State     DeploymentStatusState `json:"state"`
	Message   string                `json:"message,omitempty"`
	UUID      uuid.UUID             `json:"-"`
}

func (*DeploymentStatus) ID

func (d *DeploymentStatus) ID() ident.Ident

func (DeploymentStatus) IsNode

func (DeploymentStatus) IsNode()

type DeploymentStatusConnection

type DeploymentStatusConnection = pagination.Connection[*DeploymentStatus]

func ListStatusesForDeployment

func ListStatusesForDeployment(ctx context.Context, deploymentID uuid.UUID, page *pagination.Pagination) (*DeploymentStatusConnection, error)

type DeploymentStatusEdge

type DeploymentStatusEdge = pagination.Edge[*DeploymentStatus]

type DeploymentStatusState

type DeploymentStatusState string
const (
	DeploymentStatusStateSuccess    DeploymentStatusState = "SUCCESS"
	DeploymentStatusStateError      DeploymentStatusState = "ERROR"
	DeploymentStatusStateFailure    DeploymentStatusState = "FAILURE"
	DeploymentStatusStateInactive   DeploymentStatusState = "INACTIVE"
	DeploymentStatusStateInProgress DeploymentStatusState = "IN_PROGRESS"
	DeploymentStatusStateQueued     DeploymentStatusState = "QUEUED"
	DeploymentStatusStatePending    DeploymentStatusState = "PENDING"
)

func (DeploymentStatusState) IsValid

func (e DeploymentStatusState) IsValid() bool

func (DeploymentStatusState) MarshalGQL

func (e DeploymentStatusState) MarshalGQL(w io.Writer)

func (DeploymentStatusState) String

func (e DeploymentStatusState) String() string

func (*DeploymentStatusState) UnmarshalGQL

func (e *DeploymentStatusState) UnmarshalGQL(v interface{}) error

type TeamDeployKeyUpdatedActivityLogEntry

type TeamDeployKeyUpdatedActivityLogEntry struct {
	activitylog.GenericActivityLogEntry
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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