s
This commit is contained in:
@@ -47,7 +47,7 @@ DOCKER_NODE_IMAGE = os.environ.get("WEB_CONSOLE_NODE_IMAGE", "node:20-bookworm-s
|
||||
sys.path.insert(0, str(ROOT))
|
||||
sys.path.insert(0, str(SCRIPTS_DIR))
|
||||
import env_check # noqa: E402
|
||||
from src.runtime_bootstrap import raise_nofile_limit # noqa: E402
|
||||
from src.runtime_bootstrap import ensure_runtime_layout, raise_nofile_limit # noqa: E402
|
||||
|
||||
|
||||
def load_runtime_env() -> None:
|
||||
@@ -495,6 +495,15 @@ def run_prod(host: str, port: str, skip_build: bool, reload: bool) -> None:
|
||||
def main() -> None:
|
||||
load_runtime_env()
|
||||
raise_nofile_limit()
|
||||
runtime_issues = ensure_runtime_layout(ROOT)
|
||||
if runtime_issues:
|
||||
print("[launch] warning: some runtime directories are not writable by the current user:", file=sys.stderr)
|
||||
for issue in runtime_issues:
|
||||
print(f"[launch] - {issue}", file=sys.stderr)
|
||||
print(
|
||||
"[launch] hint: fix deployment ownership for runtime dirs such as config/logs/backup_config/.pm2/.process_runner/downloads/backup",
|
||||
file=sys.stderr,
|
||||
)
|
||||
|
||||
default_port = os.environ.get("PORT", "8001")
|
||||
ap = argparse.ArgumentParser(description="直播控制台一键启动")
|
||||
|
||||
Reference in New Issue
Block a user