From d53089f6fabe073d9027d6d90c9e4cd90582d77d Mon Sep 17 00:00:00 2001 From: Charlie Moog Date: Wed, 11 Nov 2020 13:57:54 -0600 Subject: [PATCH] Add default tag and registry to image response --- coder-sdk/image.go | 23 ++++++++++++++--------- 1 file changed, 14 insertions(+), 9 deletions(-) diff --git a/coder-sdk/image.go b/coder-sdk/image.go index f87e9384..78fad426 100644 --- a/coder-sdk/image.go +++ b/coder-sdk/image.go @@ -3,19 +3,24 @@ package coder import ( "context" "net/http" + "time" ) // Image describes a Coder Image. type Image struct { - ID string `json:"id"` - OrganizationID string `json:"organization_id"` - Repository string `json:"repository"` - Description string `json:"description"` - URL string `json:"url"` // User-supplied URL for image. - DefaultCPUCores float32 `json:"default_cpu_cores"` - DefaultMemoryGB float32 `json:"default_memory_gb"` - DefaultDiskGB int `json:"default_disk_gb"` - Deprecated bool `json:"deprecated"` + ID string `json:"id"` + OrganizationID string `json:"organization_id"` + Repository string `json:"repository"` + Description string `json:"description"` + URL string `json:"url"` // User-supplied URL for image. + Registry *Registry `json:"registry"` + DefaultTag *ImageTag `json:"default_tag"` + DefaultCPUCores float32 `json:"default_cpu_cores"` + DefaultMemoryGB float32 `json:"default_memory_gb"` + DefaultDiskGB int `json:"default_disk_gb"` + Deprecated bool `json:"deprecated"` + CreatedAt time.Time `json:"created_at"` + UpdatedAt time.Time `json:"updated_at"` } // NewRegistryRequest describes a docker registry used in importing an image.