Joining Linux worker nodes to the cluster

First, we add the DTR node, which is a worker node. The UCP web interface provides a GUI to format important command-line operations, including joining nodes to the cluster and installing DTR. While we still need to run these commands from the command line, the GUI tool helps us to correctly set the parameters. To join nodes, we first select the Nodes menu item under Shared Resources and click Add Node, as shown in Figure 7. Then, on the next screen, we make sure LINUX and WORKER are selected and copy the command to the clipboard, as shown in Figure 8:

Figure 7: Universal Control Plane Nodes

The following is the Add Node dialog box in the Docker UCP Web UI. Select LINUX and WORKER, then click on the copy button:

Figure 8: Universal Control Plane Add Linux Node

To join the DTR node, we SSH to the node and execute the command we copied from the UCP Add Node screen in Figure 8. Make sure you use your UCP's token, not the following example: 

DTR-node$ docker swarm join --token SWMTKN-1-3ggoagvdn7jm27pflayqj3z7zmylz72fix6jqv0vrh4giv9785-xxxxxxxxxxxxxxxxxxxxx 172.31.0.170:2377

This node joined a swarm as a worker.