fixed to pull images when version mismatch
This commit is contained in:
parent
b41209dc04
commit
559f1e319b
2 changed files with 21 additions and 0 deletions
|
|
@ -367,6 +367,16 @@ class MonitorScreen(Screen):
|
||||||
if not should_continue:
|
if not should_continue:
|
||||||
self.notify("Start cancelled", severity="information")
|
self.notify("Start cancelled", severity="information")
|
||||||
return
|
return
|
||||||
|
# Ensure OPENRAG_VERSION is set in .env BEFORE starting services
|
||||||
|
# This ensures docker compose reads the correct version
|
||||||
|
try:
|
||||||
|
from ..managers.env_manager import EnvManager
|
||||||
|
env_manager = EnvManager()
|
||||||
|
env_manager.ensure_openrag_version()
|
||||||
|
# Small delay to ensure .env file is written and flushed
|
||||||
|
await asyncio.sleep(0.5)
|
||||||
|
except Exception:
|
||||||
|
pass # Continue even if version setting fails
|
||||||
|
|
||||||
# Show command output in modal dialog
|
# Show command output in modal dialog
|
||||||
command_generator = self.container_manager.start_services(cpu_mode)
|
command_generator = self.container_manager.start_services(cpu_mode)
|
||||||
|
|
|
||||||
|
|
@ -461,6 +461,17 @@ class WelcomeScreen(Screen):
|
||||||
if not should_continue:
|
if not should_continue:
|
||||||
self.notify("Start cancelled", severity="information")
|
self.notify("Start cancelled", severity="information")
|
||||||
return
|
return
|
||||||
|
# Ensure OPENRAG_VERSION is set in .env BEFORE starting services
|
||||||
|
# This ensures docker compose reads the correct version
|
||||||
|
try:
|
||||||
|
from ..managers.env_manager import EnvManager
|
||||||
|
env_manager = EnvManager()
|
||||||
|
env_manager.ensure_openrag_version()
|
||||||
|
# Small delay to ensure .env file is written and flushed
|
||||||
|
import asyncio
|
||||||
|
await asyncio.sleep(0.5)
|
||||||
|
except Exception:
|
||||||
|
pass # Continue even if version setting fails
|
||||||
|
|
||||||
command_generator = self.container_manager.start_services()
|
command_generator = self.container_manager.start_services()
|
||||||
modal = CommandOutputModal(
|
modal = CommandOutputModal(
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue