Skip to content

Commit 72eb253

Browse files
committed
Fix document intelligence launch: port fallback and page reload after start
- services.html: Start button now reloads the page after starting a service (was missing reloadAfter=true), so the updated status and Launch button appear immediately without a manual refresh. - services.html / service_detail.html: Launch button now appears for any service that has a port configured, even when local_url is not explicitly set. Previously, services with only a port had no Launch button at all. - sample_data/import_existing_bundle.json: Added Document Intelligence (DocumentPresentationResearch_Assistant) service entry so it can be imported and launched from the Nexus Control Center. https://claude.ai/code/session_01BX7BsftaQ3WdmdGGqKjf7n
1 parent 695720d commit 72eb253

File tree

3 files changed

+36
-1
lines changed

3 files changed

+36
-1
lines changed

local_nexus_controller/templates/service_detail.html

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,10 @@ <h1 class="text-2xl font-semibold">{{ service.name }}</h1>
1313
<a href="{{ service.local_url }}" target="_blank" class="btn bg-blue-600 hover:bg-blue-700 border-blue-600">
1414
🚀 Launch Application
1515
</a>
16+
{% elif service.port %}
17+
<a href="http://127.0.0.1:{{ service.port }}" target="_blank" class="btn bg-blue-600 hover:bg-blue-700 border-blue-600">
18+
🚀 Launch Application
19+
</a>
1620
{% endif %}
1721
<button class="btn" onclick="lncServiceAction('{{ service.id }}','start', true)">Start</button>
1822
<button class="btn" onclick="lncServiceAction('{{ service.id }}','stop', true)">Stop</button>

local_nexus_controller/templates/services.html

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -57,6 +57,8 @@ <h1 class="text-2xl font-semibold">Service Explorer</h1>
5757
<td class="px-4 py-3">
5858
{% if s.local_url %}
5959
<a class="underline text-blue-400 hover:text-blue-300" href="{{ s.local_url }}" target="_blank">Open →</a>
60+
{% elif s.port %}
61+
<a class="underline text-blue-400 hover:text-blue-300" href="http://127.0.0.1:{{ s.port }}" target="_blank">Open →</a>
6062
{% else %}
6163
<span class="text-slate-500"></span>
6264
{% endif %}
@@ -65,8 +67,10 @@ <h1 class="text-2xl font-semibold">Service Explorer</h1>
6567
<div class="flex flex-wrap gap-2">
6668
{% if s.local_url %}
6769
<a href="{{ s.local_url }}" target="_blank" class="btn bg-blue-600 hover:bg-blue-700 border-blue-600 text-xs px-2 py-1">Launch</a>
70+
{% elif s.port %}
71+
<a href="http://127.0.0.1:{{ s.port }}" target="_blank" class="btn bg-blue-600 hover:bg-blue-700 border-blue-600 text-xs px-2 py-1">Launch</a>
6872
{% endif %}
69-
<button class="btn text-xs px-2 py-1" onclick="lncServiceAction('{{ s.id }}','start')">Start</button>
73+
<button class="btn text-xs px-2 py-1" onclick="lncServiceAction('{{ s.id }}','start', true)">Start</button>
7074
<button class="btn text-xs px-2 py-1" onclick="lncServiceAction('{{ s.id }}','stop')">Stop</button>
7175
<button class="btn text-xs px-2 py-1" onclick="lncServiceAction('{{ s.id }}','restart')">Restart</button>
7276
<button class="btn bg-rose-900 hover:bg-rose-800 border-rose-800 text-xs px-2 py-1" style="display: inline-block !important; visibility: visible !important;" onclick="lncDeleteService('{{ s.id }}')">Delete</button>

sample_data/import_existing_bundle.json

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -170,6 +170,33 @@
170170
"auto_assign_port": false,
171171
"auto_create_db": false,
172172
"meta": { "source": "C:/Users/nedpe/Documents/PearsonNexusAI/prototype" }
173+
},
174+
{
175+
"service": {
176+
"name": "Document Intelligence",
177+
"description": "Document Presentation Research Assistant for AI-powered document analysis, presentation generation, and research summarization.",
178+
"category": "apps",
179+
"tags": ["document", "ai", "research", "assistant"],
180+
"tech_stack": ["python"],
181+
"dependencies": [],
182+
"config_paths": ["C:/Users/nedpe/DocumentPresentationResearch_Assistant/.env"],
183+
"port": 8501,
184+
"local_url": "http://127.0.0.1:8501",
185+
"healthcheck_url": "http://127.0.0.1:8501",
186+
"working_directory": "C:/Users/nedpe/DocumentPresentationResearch_Assistant",
187+
"start_command": "streamlit run app.py --server.port {PORT} --server.address {HOST}",
188+
"stop_command": "",
189+
"restart_command": "",
190+
"database_id": null,
191+
"database_connection_string": null,
192+
"database_schema_overview": null
193+
},
194+
"database": null,
195+
"keys": [],
196+
"requested_port": 8501,
197+
"auto_assign_port": false,
198+
"auto_create_db": false,
199+
"meta": { "source": "C:/Users/nedpe/DocumentPresentationResearch_Assistant" }
173200
}
174201
]
175202

0 commit comments

Comments
 (0)