Provide initial set of node labels during swarm join
Nobody has claimed this yet.
- Dominant language
- Go
- Stars
- 3.7k
- Forks
- 676
- Avg merge
- 4d 9h
- Merged PRs (30d)
- 6
Description
As of now, setting a node's labels is a task that can be performed by a manager through docker node update after a node has already joined the cluster. However, the following scenarios would benefit from the ability to specify an initial set of labels through something similar to docker swarm join --label key=value:
- A
globalorreplicatedservice with a constraint ofnode.label.key!=valuemight deploy a task in the new node before the operator labels the node withkey=value - The formation of a multi-node cluster where a labelling scheme is known a priori requires an open connection to a manager node just for labelling, assuming secrets or autoaccept are used.
- A
globalservice with anode.role==managerconstraint which creates containers that bind-mount the docker socket could utilize an initial set of node labels for node-related metadata.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by tracing the docker swarm join path and comparing it with docker node update, focusing on when node labels become available to scheduling. Define the behavior for an initial key=value label set and verify that constrained services cannot schedule before those labels are applied; the issue does not name specific files or tests.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- docker, go
- Domain
- cli, distributed-systems
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 28/100