@@ -11,28 +11,31 @@ import (
11
11
12
12
// Environment describes a Coder environment
13
13
type Environment struct {
14
- ID string `json:"id" tab:"-"`
15
- Name string `json:"name"`
16
- ImageID string `json:"image_id" tab:"-"`
17
- ImageTag string `json:"image_tag"`
18
- OrganizationID string `json:"organization_id" tab:"-"`
19
- UserID string `json:"user_id" tab:"-"`
20
- LastBuiltAt time.Time `json:"last_built_at" tab:"-"`
21
- CPUCores float32 `json:"cpu_cores"`
22
- MemoryGB int `json:"memory_gb"`
23
- DiskGB int `json:"disk_gb"`
24
- GPUs int `json:"gpus"`
25
- Updating bool `json:"updating"`
26
- LatestStat EnvironmentStat `json:"latest_stat" tab:"Status"`
27
- RebuildMessages []struct {
28
- Text string `json:"text"`
29
- Required bool `json:"required"`
30
- } `json:"rebuild_messages" tab:"-"`
31
- CreatedAt time.Time `json:"created_at" tab:"-"`
32
- UpdatedAt time.Time `json:"updated_at" tab:"-"`
33
- LastOpenedAt time.Time `json:"last_opened_at" tab:"-"`
34
- LastConnectionAt time.Time `json:"last_connection_at" tab:"-"`
35
- AutoOffThreshold xjson.Duration `json:"auto_off_threshold" tab:"-"`
14
+ ID string `json:"id" tab:"-"`
15
+ Name string `json:"name" tab:"Name"`
16
+ ImageID string `json:"image_id" tab:"-"`
17
+ ImageTag string `json:"image_tag" tab:"ImageTag"`
18
+ OrganizationID string `json:"organization_id" tab:"-"`
19
+ UserID string `json:"user_id" tab:"-"`
20
+ LastBuiltAt time.Time `json:"last_built_at" tab:"-"`
21
+ CPUCores float32 `json:"cpu_cores" tab:"CPUCores"`
22
+ MemoryGB int `json:"memory_gb" tab:"MemoryGB"`
23
+ DiskGB int `json:"disk_gb" tab:"DiskGB"`
24
+ GPUs int `json:"gpus" tab:"GPUs"`
25
+ Updating bool `json:"updating" tab:"Updating"`
26
+ LatestStat EnvironmentStat `json:"latest_stat" tab:"Status"`
27
+ RebuildMessages []RebuildMessage `json:"rebuild_messages" tab:"-"`
28
+ CreatedAt time.Time `json:"created_at" tab:"-"`
29
+ UpdatedAt time.Time `json:"updated_at" tab:"-"`
30
+ LastOpenedAt time.Time `json:"last_opened_at" tab:"-"`
31
+ LastConnectionAt time.Time `json:"last_connection_at" tab:"-"`
32
+ AutoOffThreshold xjson.Duration `json:"auto_off_threshold" tab:"-"`
33
+ }
34
+
35
+ // RebuildMessage defines the message shown when an Environment requires a rebuild for it can be accessed.
36
+ type RebuildMessage struct {
37
+ Text string `json:"text"`
38
+ Required bool `json:"required"`
36
39
}
37
40
38
41
// EnvironmentStat represents the state of an environment
0 commit comments