# 將工作節點添加到cluster

現在已正確配置了Manager節點，是時候將Worker節點添加到Swarm集群了。首先，複製上一章節中的"swarm init"命令的輸出，然後將該輸出粘貼到工作節點上以加入Swarm集群：

到HOST 2:192.168.43.101

```
sudo docker swarm join --token SWMTKN-1-3ltemfcbr4wa71zfctzpzkzzp7wxfijrm17fv7m1u4t60c8gp4-0p5ak00mdqd6flp0d0doa88qy 192.168.43.100:2377
This node joined a swarm as a worker.

```

回歸HOST1，檢視worker節點是否加入

```
sudo docker node ls
ID                            HOSTNAME            STATUS              AVAILABILITY        MANAGER STATUS      ENGINE VERSION
x0544nvby7gt0zaxp30gjjqov *   pi-GB-BSi5A-6200    Ready               Active              Leader              18.09.9
vz8vwt7bom9s2go59wtt04lbf     ubuntu-mate         Ready               Active                                  19.03.3

```

![](/files/-M2HTqRJ71ypDZ6psm_2)

把樹梅派也加入

![](/files/-M2Hvg0GmaJoieKzv_fF)


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://kawsing.gitbook.io/opensystem/docker-swarm/jiang-gong-zuo-jie-dian-tian-jia-dao-cluster.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
