mirror of
https://github.com/yunionio/cloudpods.git
synced 2026-09-21 06:09:39 +08:00
image bugfix
This commit is contained in:
@@ -204,17 +204,12 @@ func (self *SRegion) GetImages(status ImageStatusType, owner ImageOwnerType, ima
|
||||
|
||||
if len(owner) > 0 {
|
||||
own := string(owner)
|
||||
if own == "self" {
|
||||
filters = AppendSingleValueFilter(filters, "owner-id", own)
|
||||
} else {
|
||||
params.SetOwners([]*string{&own})
|
||||
}
|
||||
params.SetOwners([]*string{&own})
|
||||
}
|
||||
|
||||
if len(imageId) > 0 {
|
||||
params.SetImageIds(ConvertedList(imageId))
|
||||
}
|
||||
|
||||
ret, err := self.ec2Client.DescribeImages(params)
|
||||
if err != nil {
|
||||
return nil, 0, err
|
||||
|
||||
@@ -8,7 +8,7 @@ import (
|
||||
func init() {
|
||||
type ImageListOptions struct {
|
||||
Status string `help:"image status type" choices:"Creating|Available|UnAvailable|CreateFailed"`
|
||||
Owner string `help:"Owner type" choices:"system|self|others|marketplace"`
|
||||
Owner string `help:"Owner type" choices:"amazon|self|microsoft|aws-marketplace"`
|
||||
Id []string `help:"Image ID"`
|
||||
Name string `help:"image name"`
|
||||
Limit int `help:"page size"`
|
||||
|
||||
Reference in New Issue
Block a user