Documentation
¶
Overview ¶
Package models defines domain models for the database layer.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Config ¶
type Config struct {
ID string
Name string
Content string
ASTJSON json.RawMessage
ValidationErrors json.RawMessage
CreatedAt time.Time
}
Config represents a DSL configuration.
type Deployment ¶
type Deployment struct {
ID string
Name string
ConfigID sql.NullString
Status string
CreatedAt time.Time
UpdatedAt time.Time
}
Deployment represents a deployment configuration.
func NewDeployment ¶
func NewDeployment(name string) *Deployment
NewDeployment creates a new Deployment with sensible defaults.
type DeploymentStatus ¶
type DeploymentStatus string
DeploymentStatus represents valid deployment statuses.
const ( DeploymentStatusPending DeploymentStatus = "pending" DeploymentStatusRunning DeploymentStatus = "running" DeploymentStatusStopped DeploymentStatus = "stopped" DeploymentStatusFailed DeploymentStatus = "failed" DeploymentStatusComplete DeploymentStatus = "complete" )
type Execution ¶
type Execution struct {
ID string
DeploymentID string
Command string
Output sql.NullString
ExitCode sql.NullInt32
StartedAt time.Time
CompletedAt sql.NullTime
}
Execution represents a command execution history entry.
func NewExecution ¶
NewExecution creates a new Execution with sensible defaults.
func (*Execution) IsCompleted ¶
IsCompleted returns true if the execution has completed.
func (*Execution) SetCompleted ¶
SetCompleted marks the execution as completed with output and exit code.
Click to show internal directories.
Click to hide internal directories.