[GH-ISSUE #20830] issue: PersistentConfig values are cached in Redis even when persistent config is disabled #139030

Closed
opened 2026-05-25 12:09:37 -05:00 by GiteaMirror · 2 comments
Owner

Originally created by @kirill-sch on GitHub (Jan 20, 2026).
Original GitHub issue: https://github.com/open-webui/open-webui/issues/20830

Check Existing Issues

  • I have searched for any existing and/or related issues.
  • I have searched for any existing and/or related discussions.
  • I have also searched in the CLOSED issues AND CLOSED discussions and found no related items (your issue might already be addressed on the development branch!).
  • I am using the latest version of Open WebUI.

Installation Method

Docker

Open WebUI Version

v0.7.2

Ollama Version (if applicable)

No response

Operating System

Windows 10

Browser (if applicable)

No response

Confirmation

  • I have read and followed all instructions in README.md.
  • I am using the latest version of both Open WebUI and Ollama.
  • I have included the browser console logs.
  • I have included the Docker container logs.
  • I have provided every relevant configuration, setting, and environment variable used in my setup.
  • I have clearly listed every relevant configuration, custom setting, environment variable, and command-line option that influences my setup (such as Docker Compose overrides, .env values, browser settings, authentication configurations, etc).
  • I have documented step-by-step reproduction instructions that are precise, sequential, and leave nothing to interpretation. My steps:
  • Start with the initial platform/version/OS and dependencies used,
  • Specify exact install/launch/configure commands,
  • List URLs visited, user input (incl. example values/emails/passwords if needed),
  • Describe all options and toggles enabled or changed,
  • Include any files or environmental changes,
  • Identify the expected and actual result at each stage,
  • Ensure any reasonably skilled user can follow and hit the same issue.

Expected Behavior

When persistent config is turned off (ENABLE_PERSISTENT_CONFIG=False), all variables should be loaded from environment variables and should not persist between container restarts, even if changes are made in the Admin UI and saved.

Actual Behavior

Environment variables labeled as PersistentConfig will persist between container restarts when Redis is used, even with persistent config disabled. In the Admin UI, if you click Save (without even changing any values), environment variables labeled as PersistentConfig will be cached. On container restart, the application will not use the environment variables that are set, but will instead load the values from the cache. To have it pick up the environment variables again, you must manually delete the corresponding configuration keys from Redis. As a result, even with persistent config disabled, the configuration will always persist.

Steps to Reproduce

      DATABASE_URL: "database-url"
      VECTOR_DB: "pgvector"
      REDIS_URL: "redis://redis-openweb:6379/0"
      ENABLE_WEBSOCKET_SUPPORT: "True"
      WEBSOCKET_MANAGER: "redis"
      WEBSOCKET_REDIS_URL: "redis://redis-openweb:6379/1"
      OPENAI_API_KEY: "sk-1234"
      ENABLE_PERSISTENT_CONFIG: "False"
  1. Start the container with the following environment variables
  2. In the UI, go to Admin panel > Settings > Connections
  3. Verify that on the initial startup, the configured OPENAI_API_KEY is visible under Edit Connection
  4. Check Redis and confirm that there is no cached OPENAI_API_KEY key at this point (if you were to change the environment variable now, the new value would be loaded)
  5. Change the API Key to a different value and click Save in the Edit Connection settings
  6. Check Redis and verify that the key has now been cached
  7. Run docker compose down
  8. Change OPENAI_API_KEY to a different value (e.g. OPENAI_API_KEY: "sk-notnot" )
  9. Run docker compose up -d
  10. Verify in the UI under Admin panel > Settings > Connections > Edit Connection that the OPENAI_API_KEY did not change (you will see the original value instead of the updated environment variable)
  11. Delete the cached key from Redis
  12. Run docker compose down and docker compose up -d
  13. Verify that the API key has now changed to the value set in the environment variable

Logs & Screenshots

step 3.
Image

step 4.
Image

step 5.
Image

step 6.
Image

step 10.
Image

step 11.
Image

step 13.
Image

Additional Information

No response

Originally created by @kirill-sch on GitHub (Jan 20, 2026). Original GitHub issue: https://github.com/open-webui/open-webui/issues/20830 ### Check Existing Issues - [x] I have searched for any existing and/or related issues. - [x] I have searched for any existing and/or related discussions. - [x] I have also searched in the CLOSED issues AND CLOSED discussions and found no related items (your issue might already be addressed on the development branch!). - [x] I am using the latest version of Open WebUI. ### Installation Method Docker ### Open WebUI Version v0.7.2 ### Ollama Version (if applicable) _No response_ ### Operating System Windows 10 ### Browser (if applicable) _No response_ ### Confirmation - [x] I have read and followed all instructions in `README.md`. - [x] I am using the latest version of **both** Open WebUI and Ollama. - [x] I have included the browser console logs. - [x] I have included the Docker container logs. - [x] I have **provided every relevant configuration, setting, and environment variable used in my setup.** - [x] I have clearly **listed every relevant configuration, custom setting, environment variable, and command-line option that influences my setup** (such as Docker Compose overrides, .env values, browser settings, authentication configurations, etc). - [x] I have documented **step-by-step reproduction instructions that are precise, sequential, and leave nothing to interpretation**. My steps: - Start with the initial platform/version/OS and dependencies used, - Specify exact install/launch/configure commands, - List URLs visited, user input (incl. example values/emails/passwords if needed), - Describe all options and toggles enabled or changed, - Include any files or environmental changes, - Identify the expected and actual result at each stage, - Ensure any reasonably skilled user can follow and hit the same issue. ### Expected Behavior When persistent config is turned off (`ENABLE_PERSISTENT_CONFIG=False`), all variables should be loaded from environment variables and should not persist between container restarts, even if changes are made in the Admin UI and saved. ### Actual Behavior Environment variables labeled as PersistentConfig will persist between container restarts when Redis is used, even with persistent config disabled. In the Admin UI, if you click Save (without even changing any values), environment variables labeled as PersistentConfig will be cached. On container restart, the application will not use the environment variables that are set, but will instead load the values from the cache. To have it pick up the environment variables again, you must manually delete the corresponding configuration keys from Redis. As a result, even with persistent config disabled, the configuration will always persist. ### Steps to Reproduce ``` DATABASE_URL: "database-url" VECTOR_DB: "pgvector" REDIS_URL: "redis://redis-openweb:6379/0" ENABLE_WEBSOCKET_SUPPORT: "True" WEBSOCKET_MANAGER: "redis" WEBSOCKET_REDIS_URL: "redis://redis-openweb:6379/1" OPENAI_API_KEY: "sk-1234" ENABLE_PERSISTENT_CONFIG: "False" ``` 1. Start the container with the following environment variables 2. In the UI, go to Admin panel > Settings > Connections 3. Verify that on the initial startup, the configured `OPENAI_API_KEY` is visible under Edit Connection 4. Check Redis and confirm that there is no cached `OPENAI_API_KEY` key at this point (if you were to change the environment variable now, the new value would be loaded) 5. Change the API Key to a different value and click Save in the Edit Connection settings 6. Check Redis and verify that the key has now been cached 7. Run `docker compose down` 8. Change `OPENAI_API_KEY` to a different value (e.g. `OPENAI_API_KEY: "sk-notnot"` ) 9. Run `docker compose up -d` 10. Verify in the UI under Admin panel > Settings > Connections > Edit Connection that the `OPENAI_API_KEY` did not change (you will see the original value instead of the updated environment variable) 11. Delete the cached key from Redis 12. Run `docker compose down` and `docker compose up -d` 13. Verify that the API key has now changed to the value set in the environment variable ### Logs & Screenshots step 3. <img width="555" height="53" alt="Image" src="https://github.com/user-attachments/assets/8997d6a4-6a33-44ad-ad6b-ce8391d18503" /> step 4. <img width="910" height="251" alt="Image" src="https://github.com/user-attachments/assets/b6de8e4e-40cc-4822-9b72-f36bed452d9c" /> step 5. <img width="572" height="65" alt="Image" src="https://github.com/user-attachments/assets/ae9034e0-4ee7-4c3c-992f-4375e78e5b4d" /> step 6. <img width="1817" height="380" alt="Image" src="https://github.com/user-attachments/assets/8a4d8cbb-db2e-461a-a5bb-7af9ce3ef771" /> step 10. <img width="568" height="56" alt="Image" src="https://github.com/user-attachments/assets/28f5aa8d-7c7e-43ca-8b13-4a3c06156007" /> step 11. <img width="916" height="342" alt="Image" src="https://github.com/user-attachments/assets/bfc30352-cff1-4998-90c1-c4f5b6899b3c" /> step 13. <img width="571" height="66" alt="Image" src="https://github.com/user-attachments/assets/9f7f1835-bd53-428a-9d4b-6c3c7c67624a" /> ### Additional Information _No response_
GiteaMirror added the bug label 2026-05-25 12:09:37 -05:00
Author
Owner

@owui-terminator[bot] commented on GitHub (Jan 20, 2026):

🔍 Similar Issues Found

I found some existing issues that might be related to this one. Please check if any of these are duplicates or contain helpful solutions:

  1. #15984 issue: PersistentConfig appears to not be persisten
    by mymro • Jul 24, 2025 • bug

💡 Tips:

  • If this is a duplicate, please consider closing this issue and adding any additional details to the existing one
  • If you found a solution in any of these issues, please share it here to help others

This comment was generated automatically by a bot. Please react with a 👍 if this comment was helpful, or a 👎 if it was not.

<!-- gh-comment-id:3775140249 --> @owui-terminator[bot] commented on GitHub (Jan 20, 2026): 🔍 **Similar Issues Found** I found some existing issues that might be related to this one. Please check if any of these are duplicates or contain helpful solutions: 1. [#15984](https://github.com/open-webui/open-webui/issues/15984) **issue: PersistentConfig appears to not be persisten** *by mymro • Jul 24, 2025 • `bug`* --- 💡 **Tips:** - If this is a duplicate, please consider closing this issue and adding any additional details to the existing one - If you found a solution in any of these issues, please share it here to help others *This comment was generated automatically by a bot.* Please react with a 👍 if this comment was helpful, or a 👎 if it was not.
Author
Owner

@tjbck commented on GitHub (Jan 21, 2026):

Good catch, should be fixed in dev!

<!-- gh-comment-id:3781724768 --> @tjbck commented on GitHub (Jan 21, 2026): Good catch, should be fixed in dev!
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/open-webui#139030