Manage shared ARNavi VPS contours and application keys from infrastructure

This commit is contained in:
DCCONSTRUCTIONS
2026-09-30 15:34:39 +03:00
parent 6ca6738bab
commit 1828a05332
22 changed files with 1099 additions and 2 deletions
@@ -13,6 +13,8 @@ import {
WindowFooterActions,
} from "@nodedc/ui-react";
import { B2HostSettings } from "./b2/B2HostSettings";
import {
createConfigurationRevision,
closeAssetBinding,
@@ -496,7 +498,9 @@ function HostsView({
onPoll: () => Promise<void>;
onError: (reason: unknown) => void;
}) {
const [settingsHost, setSettingsHost] = useState<InfrastructureHostView | null>(null);
const [selectedHostRef, setSelectedHostRef] = useState<string | null>(null);
useEffect(() => setSettingsHost(null), [workspace.project.projectRef]);
const [expandedHostRefs, setExpandedHostRefs] = useState<Set<string>>(() => new Set());
const inventoryRef = useRef<HTMLDivElement>(null);
const topology = workspace.ontology;
@@ -528,6 +532,7 @@ function HostsView({
}
return (
<div className="infrastructure-system-workspace" ref={inventoryRef}>
{settingsHost ? <B2HostSettings key={workspace.project.projectRef + settingsHost.hostRef} host={settingsHost} workspace={workspace} onClose={() => setSettingsHost(null)} onChanged={onPoll} onError={onError} /> : null}
<section className="infrastructure-overview-block">
<div className="infrastructure-workspace-lead">
<div>
@@ -579,6 +584,7 @@ function HostsView({
<code>{host.externalRef || host.hostKey}</code>
</div>
<div className="infrastructure-host-card__actions">
{canManageInfrastructure ? <IconButton label={`Настройки ${host.displayName}`} onClick={() => setSettingsHost(host)}><Icon name="settings" /></IconButton> : null}
<Button size="compact" variant="primary" onClick={() => setSelectedHostRef(host.hostRef)}>Мониторинг</Button>
<span
className="infrastructure-host-card__freshness"