summaryrefslogtreecommitdiff
path: root/pkg/api/handlers
diff options
context:
space:
mode:
authorOpenShift Merge Robot <openshift-merge-robot@users.noreply.github.com>2020-10-12 07:01:10 -0400
committerGitHub <noreply@github.com>2020-10-12 07:01:10 -0400
commit212011f166d6f56421fcc5260def999e71156d32 (patch)
tree662725e76b8bc04a5ede4f8a3d40b375add1d334 /pkg/api/handlers
parentdce30de594c6206659104a1208f4012a32a82bdc (diff)
parent66798e993a1d3c111f15a85242cac1427c39f53e (diff)
downloadpodman-212011f166d6f56421fcc5260def999e71156d32.tar.gz
podman-212011f166d6f56421fcc5260def999e71156d32.tar.bz2
podman-212011f166d6f56421fcc5260def999e71156d32.zip
Merge pull request #7836 from QiWang19/search-tags
Search repository tags using --list-tags
Diffstat (limited to 'pkg/api/handlers')
-rw-r--r--pkg/api/handlers/libpod/images.go7
1 files changed, 5 insertions, 2 deletions
diff --git a/pkg/api/handlers/libpod/images.go b/pkg/api/handlers/libpod/images.go
index 43123c5a3..1292090fb 100644
--- a/pkg/api/handlers/libpod/images.go
+++ b/pkg/api/handlers/libpod/images.go
@@ -608,6 +608,7 @@ func SearchImages(w http.ResponseWriter, r *http.Request) {
NoTrunc bool `json:"noTrunc"`
Filters []string `json:"filters"`
TLSVerify bool `json:"tlsVerify"`
+ ListTags bool `json:"listTags"`
}{
// This is where you can override the golang default value for one of fields
}
@@ -618,8 +619,9 @@ func SearchImages(w http.ResponseWriter, r *http.Request) {
}
options := image.SearchOptions{
- Limit: query.Limit,
- NoTrunc: query.NoTrunc,
+ Limit: query.Limit,
+ NoTrunc: query.NoTrunc,
+ ListTags: query.ListTags,
}
if _, found := r.URL.Query()["tlsVerify"]; found {
options.InsecureSkipTLSVerify = types.NewOptionalBool(!query.TLSVerify)
@@ -650,6 +652,7 @@ func SearchImages(w http.ResponseWriter, r *http.Request) {
reports[i].Stars = searchResults[i].Stars
reports[i].Official = searchResults[i].Official
reports[i].Automated = searchResults[i].Automated
+ reports[i].Tag = searchResults[i].Tag
}
utils.WriteResponse(w, http.StatusOK, reports)