Signed-off-by: Evan Hazlett <ejhazlett@gmail.com>
| ... | ... |
@@ -46,7 +46,6 @@ func runList(dockerCli *command.DockerCli, opts listOptions) error {
|
| 46 | 46 |
client := dockerCli.Client() |
| 47 | 47 |
|
| 48 | 48 |
serviceFilters := opts.filter.Value() |
| 49 |
- serviceFilters.Add("runtime", string(swarm.RuntimeContainer))
|
|
| 50 | 49 |
services, err := client.ServiceList(ctx, types.ServiceListOptions{Filters: serviceFilters})
|
| 51 | 50 |
if err != nil {
|
| 52 | 51 |
return err |
| ... | ... |
@@ -7,7 +7,6 @@ import ( |
| 7 | 7 |
|
| 8 | 8 |
"github.com/docker/docker/api/types" |
| 9 | 9 |
"github.com/docker/docker/api/types/filters" |
| 10 |
- swarmtypes "github.com/docker/docker/api/types/swarm" |
|
| 11 | 10 |
"github.com/docker/docker/cli" |
| 12 | 11 |
"github.com/docker/docker/cli/command" |
| 13 | 12 |
"github.com/docker/docker/cli/command/formatter" |
| ... | ... |
@@ -59,11 +58,8 @@ func runPS(dockerCli *command.DockerCli, opts psOptions) error {
|
| 59 | 59 |
serviceIDFilter := filters.NewArgs() |
| 60 | 60 |
serviceNameFilter := filters.NewArgs() |
| 61 | 61 |
for _, service := range opts.services {
|
| 62 |
- // default to container runtime |
|
| 63 | 62 |
serviceIDFilter.Add("id", service)
|
| 64 |
- serviceIDFilter.Add("runtime", string(swarmtypes.RuntimeContainer))
|
|
| 65 | 63 |
serviceNameFilter.Add("name", service)
|
| 66 |
- serviceNameFilter.Add("runtime", string(swarmtypes.RuntimeContainer))
|
|
| 67 | 64 |
} |
| 68 | 65 |
serviceByIDList, err := client.ServiceList(ctx, types.ServiceListOptions{Filters: serviceIDFilter})
|
| 69 | 66 |
if err != nil {
|
| ... | ... |
@@ -54,7 +54,10 @@ func (c *Cluster) GetServices(options apitypes.ServiceListOptions) ([]types.Serv |
| 54 | 54 |
NamePrefixes: options.Filters.Get("name"),
|
| 55 | 55 |
IDPrefixes: options.Filters.Get("id"),
|
| 56 | 56 |
Labels: runconfigopts.ConvertKVStringsToMap(options.Filters.Get("label")),
|
| 57 |
- Runtimes: options.Filters.Get("runtime"),
|
|
| 57 |
+ // (ehazlett): hardcode runtime for now. eventually we will |
|
| 58 |
+ // be able to filter for the desired runtimes once more |
|
| 59 |
+ // are supported. |
|
| 60 |
+ Runtimes: []string{string(types.RuntimeContainer)},
|
|
| 58 | 61 |
} |
| 59 | 62 |
|
| 60 | 63 |
ctx, cancel := c.getRequestContext() |