docs/docs/getting-started/updating.mdx
Silentoplayz 9cdd0c0284 Squashed commit of the following:
commit af900c8803
Author: Silentoplayz <50341825+Silentoplayz@users.noreply.github.com>
Date:   Thu Dec 26 14:56:03 2024 -0500

    Update env-configuration.md

    update for v0.4.8 list of env vars

commit 622cd3d6cb
Merge: ce3429a 41f918c
Author: Timothy Jaeryang Baek <tim@openwebui.com>
Date:   Wed Dec 25 13:31:27 2024 -0800

    Merge pull request #339 from jtslear/main

    Details model default for ComfyUI

commit ce3429a907
Author: Timothy Jaeryang Baek <tim@openwebui.com>
Date:   Tue Dec 24 20:37:54 2024 -0700

    refac

commit 7c221579ad
Author: Timothy Jaeryang Baek <tim@openwebui.com>
Date:   Mon Dec 23 13:06:36 2024 -0700

    refac

commit 41f918c408
Author: John T Skarbek <jtslear@users.noreply.github.com>
Date:   Mon Dec 23 08:45:24 2024 -0500

    Details model default for ComfyUI

    Adds concise detail for the Set Default Model option in the Image configuration pane for ComfyUI

commit 6b2523cf35
Author: Timothy Jaeryang Baek <tim@openwebui.com>
Date:   Mon Dec 23 01:59:26 2024 -0700

    Update roadmap.mdx

commit 15df6c51c1
Author: Timothy Jaeryang Baek <tim@openwebui.com>
Date:   Sun Dec 22 16:58:14 2024 -0700

    refac

commit dbe6a7261d
Merge: 13aec58 142e75b
Author: silentoplayz <50341825+silentoplayz@users.noreply.github.com>
Date:   Sat Dec 21 20:43:20 2024 -0500

    Merge pull request #337 from silentoplayz/main

    Updated DockerUpdating.md page

commit 13aec580d3
Author: Timothy Jaeryang Baek <tim@openwebui.com>
Date:   Sat Dec 21 18:21:30 2024 -0700

    Update roadmap.mdx

commit b286d6cb42
Merge: 6d8b6d9 0bdca8c
Author: silentoplayz <50341825+silentoplayz@users.noreply.github.com>
Date:   Sat Dec 21 12:53:14 2024 -0500

    Merge pull request #336 from silentoplayz/main

    New Apache Tika & Artifacts Docs Pages

commit 6d8b6d97ca
Merge: a2bc93d 1c83f95
Author: silentoplayz <50341825+silentoplayz@users.noreply.github.com>
Date:   Sat Dec 21 10:45:40 2024 -0500

    Merge pull request #335 from silentoplayz/main

    New "Redis Websockets" Docs Page

commit a2bc93d074
Merge: 283df1a 62c4ca3
Author: silentoplayz <50341825+silentoplayz@users.noreply.github.com>
Date:   Fri Dec 20 17:49:40 2024 -0500

    Merge pull request #330 from xiaowuap/patch-1

    Add BingAPI in web_search.md

commit 62c4ca375f
Author: Enzo Wu <xiaowuap@outlook.com>
Date:   Sat Dec 21 01:09:45 2024 +0800

    Add BingAPI in web_search.md

    First time to contribute~
2024-12-26 14:57:54 -05:00

112 lines
4.0 KiB
Plaintext

---
sidebar_position: 300
title: "🔄 Updating Open WebUI"
---
## Why isn't my Open WebUI updating?
To update your local Docker installation of Open WebUI to the latest version available, you can either use **Watchtower** or manually update the container. Follow either of the steps provided below to be guided through updating your existing Open WebUI image.
### Manual Update
1. **Stop and remove the current container**:
This will stop the running container and remove it, but it won't delete the data stored in the Docker volume. (Replace `open-webui` with your container's name throughout the updating process if it's different for you.)
```bash
docker rm -f open-webui
```
2. **Pull the latest Docker image**:
This will update the Docker image, but it won't update the running container or its data.
```bash
docker pull ghcr.io/open-webui/open-webui:main
```
:::info
**Remove any existing data in the Docker volume (NOT RECOMMENDED UNLESS ABSOLUTELY NECCESSARY!)**. Skip this step entirely if not needed and move on to the last step:
If you want to start with a clean slate, you can remove the existing data in the Docker volume. Be careful, as this will delete all your chat histories and other data.
The data is stored in a Docker volume named `open-webui`. You can remove it with the following command:
```bash
docker volume rm open-webui
```
:::
3. **Start the container again with the updated image and existing volume attached**:
If you didn't remove the existing data, this will start the container with the updated image and the existing data. If you removed the existing data, this will start the container with the updated image and a new, empty volume. **For Nvidia GPU support, add `--gpus all` to the docker run command**
```bash
docker run -d -p 3000:8080 -v open-webui:/app/backend/data --name open-webui ghcr.io/open-webui/open-webui:main
```
## Automatically Updating Open WebUI with Watchtower
You can use [Watchtower](https://containrrr.dev/watchtower/) to automate the update process for Open WebUI. Here are three options:
### Option 1: One-time Update
You can run Watchtower as a one-time update to stop the current container, pull the latest image, and start a new container with the updated image and existing volume attached (**For Nvidia GPU support, add `--gpus all` to the docker run command**):
```bash
docker run --rm --volume /var/run/docker.sock:/var/run/docker.sock containrrr/watchtower --run-once open-webui
```
### Option 2: Running Watchtower as a Separate Container
You can run Watchtower as a separate container that watches and updates your Open WebUI container:
```bash
docker run -d --name watchtower \
--volume /var/run/docker.sock:/var/run/docker.sock \
containrrr/watchtower -i 300 open-webui
```
This will start Watchtower in detached mode, watching your Open WebUI container for updates every 5 minutes.
### Option 3: Integrating Watchtower with a `docker-compose.yml` File
You can also integrate Watchtower with your `docker-compose.yml` file to automate updates for Open WebUI (**For Nvidia GPU support, add `--gpus all` to the docker run command**):
```yml
version: '3'
services:
open-webui:
image: ghcr.io/open-webui/open-webui:main
ports:
- "3000:8080"
volumes:
- open-webui:/app/backend/data
watchtower:
image: containrrr/watchtower
volumes:
- /var/run/docker.sock:/var/run/docker.sock
command: --interval 300 open-webui
depends_on:
- open-webui
volumes:
open-webui:
```
In this example, Watchtower is integrated with the `docker-compose.yml` file and watches the Open WebUI container for updates every 5 minutes.
## Persistent Data in Docker Volumes
The data is stored in a Docker volume named `open-webui`. The path to the volume is not directly accessible, but you can inspect the volume with the following command:
```bash
docker volume inspect open-webui
```
This will show you the details of the volume, including the mountpoint, which is usually located in `/var/lib/docker/volumes/open-webui/_data`.