Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
22 changes: 14 additions & 8 deletions machine_types.go
Original file line number Diff line number Diff line change
Expand Up @@ -52,14 +52,15 @@ type Machine struct {
InstanceID string `json:"instance_id,omitempty"`
Version string `json:"version,omitempty"`
// PrivateIP is the internal 6PN address of the machine.
PrivateIP string `json:"private_ip,omitempty"`
CreatedAt string `json:"created_at,omitempty"`
UpdatedAt string `json:"updated_at,omitempty"`
Config *MachineConfig `json:"config,omitempty"`
Events []*MachineEvent `json:"events,omitempty"`
Checks []*MachineCheckStatus `json:"checks,omitempty"`
LeaseNonce string `json:"nonce,omitempty"`
HostStatus HostStatus `json:"host_status,omitempty" enums:"ok,unknown,unreachable"`
PrivateIP string `json:"private_ip,omitempty"`
CreatedAt string `json:"created_at,omitempty"`
UpdatedAt string `json:"updated_at,omitempty"`
Config *MachineConfig `json:"config,omitempty"`
Events []*MachineEvent `json:"events,omitempty"`
Checks []*MachineCheckStatus `json:"checks,omitempty"`
LeaseNonce string `json:"nonce,omitempty"`
HostStatus HostStatus `json:"host_status,omitempty" enums:"ok,unknown,unreachable"`
ContainerStatuses []*ContainerStatus `json:"containers,omitempty"`

// When `host_status` isn't "ok", the config can't be fully retrieved and has to be rebuilt from multiple sources
// to form an partial configuration, not suitable to clone or recreate the original machine
Expand Down Expand Up @@ -649,6 +650,11 @@ type MachineServiceConcurrency struct {
SoftLimit int `json:"soft_limit,omitempty" toml:"soft_limit,omitempty"`
}

type ContainerStatus struct {
Name string `json:"name"`
State string `json:"state"`
}

type MachineConfig struct {
// Fields managed from fly.toml
// If you add anything here, ensure appconfig.Config.ToMachine() is updated
Expand Down
Loading