Skip to content

Commit 3c91d00

Browse files
committed
docs(workflow): add install node
1 parent 1a1b3e2 commit 3c91d00

2 files changed

Lines changed: 41 additions & 3 deletions

File tree

_scripts/install.sh

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -66,8 +66,6 @@ EOF
6666
fi
6767
if [[ -z "${K3S_URL}" ]] ; then
6868
INSTALL_K3S_EXEC="${INSTALL_K3S_EXEC} --flannel-backend=none --disable=traefik --disable=servicelb --cluster-cidr=10.233.0.0/16 --cluster-init"
69-
else
70-
INSTALL_K3S_EXEC="${INSTALL_K3S_EXEC}"
7169
fi
7270
}
7371

src/quickstart/install-workflow.md

Lines changed: 41 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -126,12 +126,52 @@ $ curl -sfL https://www.drycc.cc/install.sh | bash -
126126
```
127127

128128
!!! important
129-
Users in Chinese mainland can use the following methods to speed up installation:
129+
If you are in China, you need to use mirror acceleration:
130130

131131
```
132132
$ curl -sfL https://www.drycc.cc/install.sh | INSTALL_DRYCC_MIRROR=cn bash -
133133
```
134134

135+
### Install Node
136+
137+
Node can be a simple agent or a server; Server has the function of agent. Multiple servers have high availability, but the number of servers should not
138+
exceed 7 at most. There is no limit to the number of agents.
139+
140+
* First, check the cluster token of the master.
141+
142+
```
143+
$ cat /var/lib/rancher/k3s/server/node-token
144+
K1078e7213ca32bdaabb44536f14b9ce7926bb201f41c3f3edd39975c16ff4901ea::server:33bde27f-ac49-4483-b6ac-f4eec2c6dbfa
145+
```
146+
147+
We assume that the IP address of the cluster master is `192.168.6.240`, in that way.
148+
149+
* Then, Set the environment variable:
150+
151+
```
152+
$ export K3S_URL=https://192.168.6.240:6443
153+
$ export K3S_TOKEN="K1078e7213ca32bdaabb44536f14b9ce7926bb201f41c3f3edd39975c16ff4901ea::server:33bde27f-ac49-4483-b6ac-f4eec2c6dbfa"
154+
```
155+
156+
!!! important
157+
If you are in China, you need to use mirror acceleration:
158+
159+
```
160+
$ export INSTALL_DRYCC_MIRROR=cn
161+
```
162+
163+
* Join the cluster as server:
164+
165+
```
166+
$ curl -sfL https://www.drycc.cc/install.sh | INSTALL_K3S_EXEC=server INSTALL_DRYCC_EXEC=install_k3s bash -
167+
```
168+
169+
* Join the cluster as agent:
170+
171+
```
172+
$ curl -sfL https://www.drycc.cc/install.sh | INSTALL_K3S_EXEC=agent INSTALL_DRYCC_EXEC=install_k3s bash -
173+
```
174+
135175
### Install Options
136176

137177
When using this method to install drycc, the following environment variables can be used to configure the installation:

0 commit comments

Comments
 (0)