Skip to content

Make it clear that docker ps filter name accepts regular expressions #11767

Open
@watery

Description

@watery

Problem description

Docker ps command filtering option allows using regular expressions in its name parameter, while by the docs by it seems only strings are allowed and that it:

matches on all or part of a container’s name

Problem location

Project version(s) affected

I already checked this on 19.03.11, where I have two identically prefixed containers:

  • app
  • app_stage

Here

docker ps -a --filter name=app

returns both, while:

docker ps -a --filter name=^app$ 

only returns the first one.

Suggestions for a fix

Clarify that, at least for the name filter option, a regular expression may be specified.
I learned that from this comment.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions