Whether can be set in group a stack service dynamic host name/container name?
CodePudding user response:
In the stack/write file, use the following format:Services:
Thaservice:
...
The hostname: "{{. Service. The Name}} - {{. Task. The Slot}}"
Link to the available template variables document: https://docs.docker.com/engine/swarm/services/#create-services-using-templates
CodePudding user response:
Brother solution not the problem