When I moved to the final version 1.12 of the new built in Docker swarm support, it seems that I lost the ability to set the secret that would be used when workers and managers request to join the swarm. Now it seems that I have to let Docker set the secret and then I have to extract it from the first created node and share it with the other nodes.
When setting up a swarm programmatically, it is much easier to generate the secret and then pass it in as a parameter everywhere. How can I still do this?