Documentation ¶
Overview ¶
Package run provides utils for running contain/container images
Index ¶
- func LayerToContainer(layer v1.Layer, target *SyncTarget) error
- type Containersync
- type MatchContainer
- type Runpod
- type RunpodContainerStatus
- type RunpodContainerStatusState
- type RunpodContainerStatusStateRunning
- type RunpodContainerStatusStateTerminated
- type RunpodContainerStatusStateWaiting
- type RunpodMetadata
- type RunpodStatus
- type SyncTarget
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func LayerToContainer ¶
func LayerToContainer(layer v1.Layer, target *SyncTarget) error
Types ¶
type Containersync ¶
type Containersync struct {
// contains filtered or unexported fields
}
func NewContainersync ¶
func NewContainersync(config *schema.ContainConfig) (*Containersync, error)
func (*Containersync) MatchPod ¶
func (c *Containersync) MatchPod(pod Runpod) *RunpodContainerStatus
MatchPod assumes that a selector was applied at get, and matches on pod status if the pod is a suitable sync target or not
func (*Containersync) PodWait ¶
func (c *Containersync) PodWait(attempt int) (*SyncTarget, error)
func (*Containersync) Run ¶
func (c *Containersync) Run(layers ...v1.Layer) (*SyncTarget, error)
type MatchContainer ¶ added in v0.3.2
type MatchContainer struct {
// contains filtered or unexported fields
}
type Runpod ¶
type Runpod struct { Metadata RunpodMetadata `json:"metadata"` Status RunpodStatus `json:"status"` }
type RunpodContainerStatus ¶
type RunpodContainerStatusState ¶ added in v0.2.3
type RunpodContainerStatusState struct { Waiting RunpodContainerStatusStateWaiting `json:"waiting"` Running RunpodContainerStatusStateRunning `json:"running"` Terminated RunpodContainerStatusStateTerminated `json:"terminated"` }
type RunpodContainerStatusStateRunning ¶ added in v0.2.3
type RunpodContainerStatusStateRunning struct {
StartedAt string `json:"startedAt"`
}
type RunpodContainerStatusStateTerminated ¶ added in v0.2.3
type RunpodContainerStatusStateWaiting ¶ added in v0.2.3
type RunpodContainerStatusStateWaiting struct {
Reason string `json:"reason"`
}
type RunpodMetadata ¶
type RunpodStatus ¶
type RunpodStatus struct { Phase string `json:"phase"` ContainerStatuses []RunpodContainerStatus `json:"containerStatuses"` }
type SyncTarget ¶
type SyncTarget struct { Pod RunpodMetadata Container RunpodContainerStatus }
Click to show internal directories.
Click to hide internal directories.