You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Updates will cause `cloudflared` to restart which will impact traffic currently being served. You can perform zero-downtime upgrades by using Cloudflare's [Load Balancer product](/cloudflare-one/connections/connect-networks/downloads/update-cloudflared/#update-with-cloudflare-load-balancer) or by using [multiple `cloudflared` instances](/cloudflare-one/connections/connect-networks/downloads/update-cloudflared/#update-with-multiple-cloudflared-instances).
11
11
12
-
## Remotely-managed tunnels
12
+
## Update the `cloudflared` service
13
13
14
-
To update `cloudflared` for a tunnel[created through the dashboard](/cloudflare-one/connections/connect-networks/get-started/create-remote-tunnel/):
14
+
Refer to the following commands to update `cloudflared` for a [remotely-managed tunnel](/cloudflare-one/connections/connect-networks/get-started/create-remote-tunnel/)created through the dashboard or a [locally-managed tunnel](/cloudflare-one/connections/connect-networks/do-more-with-tunnels/local-management/). Locally-managed tunnels must be set up to [run as a service](/cloudflare-one/connections/connect-networks/do-more-with-tunnels/local-management/as-a-service/) for the following commands to execute successfully.
1. In Zero Trust, go to **Networks** > **Tunnels**.
95
+
**If you created a remotely-managed tunnel using the [dashboard](/cloudflare-one/connections/connect-networks/get-started/create-remote-tunnel/):**
96
+
97
+
1. In [Zero Trust](https://one.dash.cloudflare.com/), go to **Networks** > **Tunnels**.
96
98
2. Select your tunnel and select **Configure**.
97
-
3. Select **Docker** and copy the installation command shown in the dashboard.
99
+
3. Select **Docker** and copy the installation command shown in the dashboard. The copied command will contain your token.
98
100
4. Paste this command into a terminal window.
99
101
100
-
This creates a new container from the latest `cloudflared` image. You can now delete the old container.
102
+
This command creates a new container from the latest `cloudflared` image. You can now delete the old container.
103
+
104
+
:::caution
105
+
106
+
Cloudflare recommends creating remotely-managed tunnels when working with Docker.
107
+
108
+
:::
109
+
110
+
**If you created a remotely or locally-managed tunnel using the [API](/cloudflare-one/connections/connect-networks/get-started/create-remote-tunnel-api/), run the following command:**
111
+
112
+
```sh
113
+
docker run --pull always cloudflare/cloudflared:latest tunnel --no-autoupdate run --token <TOKEN>
114
+
```
115
+
116
+
**If you created a locally-managed tunnel using the [CLI](/cloudflare-one/connections/connect-networks/do-more-with-tunnels/local-management/create-local-tunnel/#2-authenticate-cloudflared):**
117
+
118
+
1. Mount your local `.cloudflared`[directory](/cloudflare-one/connections/connect-networks/do-more-with-tunnels/local-management/local-tunnel-terms/#default-cloudflared-directory) into the Docker container using a volume.
119
+
120
+
2. Run the following command to update `cloudflared`:
121
+
122
+
```sh
123
+
docker run --pull always -v <PATH-TO-YOUR-LOCAL-CLOUDFLARED>:/home/nonroot/.cloudflared cloudflare/cloudflared:latest tunnel --no-autoupdate run <TUNNEL-ID>
0 commit comments