This commit is contained in:
2026-02-14 14:44:42 +01:00
parent 0239438b94
commit aabb55b43c
3 changed files with 30 additions and 9 deletions
+6 -2
View File
@@ -24,17 +24,21 @@ import { Plus } from "lucide-react";
export default function DeployAppDialog({
defaultApp,
children,
ports: initialPorts,
nodeId: defaultNode,
}: {
defaultApp?: string;
nodeId?: string;
ports?: Port[];
children: ReactNode;
}) {
const { value: nodes } = useAsync("liveNodes", [], getLiveNodes);
const { value: apps } = useAsync<Application[]>("apps", [], getApps);
const [name, setName] = useState("");
const [app, setApp] = useState(defaultApp || "");
const [node, setNode] = useState("");
const [node, setNode] = useState(defaultNode || "");
const [ports, setPorts] = useState<Port[]>([]);
const [ports, setPorts] = useState<Port[]>(initialPorts || []);
const [newPort, setNewPort] = useState<Port>({
containerPort: "",
hostPort: "",