Added threaded create_vm endpoint

This commit is contained in:
Qubasa
2023-09-25 16:28:32 +02:00
committed by Mic92
parent da02c7f4ae
commit b58b274118
8 changed files with 120 additions and 89 deletions

View File

@@ -1,5 +1,4 @@
import argparse
import logging
import subprocess
import time
import urllib.request
@@ -7,13 +6,12 @@ import webbrowser
from contextlib import ExitStack, contextmanager
from pathlib import Path
from threading import Thread
from typing import (Iterator, Dict, Any)
from typing import Iterator
# XXX: can we dynamically load this using nix develop?
from uvicorn import run
def defer_open_browser(base_url: str) -> None:
for i in range(5):
try: