fix: use PodmanClient::lan_address_for as static fallback for port mapping
Dynamic port extraction from container bindings, falling back to the static PodmanClient address map for apps without port bindings (e.g. host-network containers). Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
parent
0c5b7db4a2
commit
a6f2e6743f
@ -133,7 +133,7 @@ impl DockerPackageScanner {
|
|||||||
} else {
|
} else {
|
||||||
// Dynamic: use actual port bindings from container, fall back to static map
|
// Dynamic: use actual port bindings from container, fall back to static map
|
||||||
extract_lan_address(&container.ports)
|
extract_lan_address(&container.ports)
|
||||||
.or_else(|| self.runtime.get_ui_address(&app_id))
|
.or_else(|| PodmanClient::lan_address_for(&app_id))
|
||||||
};
|
};
|
||||||
|
|
||||||
debug!("Container {}: ports={:?}, lan_address={:?}", app_id, container.ports, lan_address);
|
debug!("Container {}: ports={:?}, lan_address={:?}", app_id, container.ports, lan_address);
|
||||||
|
|||||||
@ -66,8 +66,8 @@ impl PodmanClient {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/// Map container name to its UI launch URL
|
/// Map container name to its UI launch URL (static fallback for docker_packages scanner)
|
||||||
fn lan_address_for(name: &str) -> Option<String> {
|
pub fn lan_address_for(name: &str) -> Option<String> {
|
||||||
let url = match name {
|
let url = match name {
|
||||||
"bitcoin-knots" | "bitcoin-ui" => "http://localhost:8334",
|
"bitcoin-knots" | "bitcoin-ui" => "http://localhost:8334",
|
||||||
"lnd" | "archy-lnd-ui" => "http://localhost:8081",
|
"lnd" | "archy-lnd-ui" => "http://localhost:8081",
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user