Merge pull request #5844 from baude/apiv2filteridfix

allow filters to work when listing containers
This commit is contained in:
OpenShift Merge Robot 2020-04-16 08:50:11 -07:00 committed by GitHub
commit c1bafb8b5a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 5 deletions

View File

@ -32,10 +32,6 @@ func ContainerExists(w http.ResponseWriter, r *http.Request) {
}
func ListContainers(w http.ResponseWriter, r *http.Request) {
var (
//filterFuncs []libpod.ContainerFilter
//pss []entities.ListContainer
)
decoder := r.Context().Value("decoder").(*schema.Decoder)
query := struct {
All bool `schema:"all"`
@ -54,10 +50,10 @@ func ListContainers(w http.ResponseWriter, r *http.Request) {
errors.Wrapf(err, "Failed to parse parameters for %s", r.URL.String()))
return
}
runtime := r.Context().Value("runtime").(*libpod.Runtime)
opts := entities.ContainerListOptions{
All: query.All,
Filters: query.Filters,
Last: query.Last,
Size: query.Size,
Sort: "",