Reviewing #28192, stumbled upon this https://github.com/docker/docker/pull/28192/files#diff-b2821be6b073a3446a2f5aca438ef409R84, and realized that, as of now, the filter label on docker node ls only filters on the engine labels.
This means I can't filter node based on labels I've set on my nodes (using docker node update --label-add for example).
Not sure if there is/was a discussion about that, but I feel we should support both, maybe with a syntax like :
# filter swarm/node labels
$ docker node ls --filter node.label=…
# filter engine labels
$ docker node ls --filter engine.label=…
# filter both labels
$ docker node ls --filter label=…
/cc @diogomonica @stevvooe @aaronlehmann
Reviewing #28192, stumbled upon this https://github.com/docker/docker/pull/28192/files#diff-b2821be6b073a3446a2f5aca438ef409R84, and realized that, as of now, the
filterlabel ondocker node lsonly filters on the engine labels.This means I can't filter node based on labels I've set on my nodes (using
docker node update --label-addfor example).Not sure if there is/was a discussion about that, but I feel we should support both, maybe with a syntax like :
/cc @diogomonica @stevvooe @aaronlehmann