refactor: keep root install as the sole installer source
This commit is contained in:
1 parent
6491a766f4
commit
a46bd6e132
14 files changed
+95
-385
No files matched your search
@@ -3,7 +3,6 @@
|
||||
|
||||
import argparse
|
||||
import hashlib
|
||||
import importlib.util
|
||||
import json
|
||||
import os
|
||||
from pathlib import Path
|
||||
@@ -13,6 +12,9 @@ import signal
|
||||
import subprocess
|
||||
import time
|
||||
|
||||
from install_support import load_installer
|
||||
|
||||
|
||||
WORKSPACE = Path(__file__).resolve().parents[2]
|
||||
OS_LIBRARIES = (
|
||||
"libc.so.6", "libdl.so.2", "libm.so.6", "libpthread.so.0", "librt.so.1",
|
||||
@@ -195,10 +197,7 @@ def ordinary_uid_target_reuse(image):
|
||||
def install_assets(assets, image, manifest):
|
||||
# Only transport is local: signature verification, full tar extraction and
|
||||
# the final bootstrap executable are the real first-install implementation.
|
||||
script = WORKSPACE / "skills/scripts/install.py"
|
||||
specification = importlib.util.spec_from_file_location("dever_release_installer", script)
|
||||
installer = importlib.util.module_from_spec(specification)
|
||||
specification.loader.exec_module(installer)
|
||||
installer = load_installer()
|
||||
stem = f"dever-{manifest['platform']}"
|
||||
base = installer.RELEASES
|
||||
routes = {
|
||||
@@ -239,7 +238,7 @@ def accept(release, assets, image, report, init, extension_helper=None):
|
||||
install_assets(assets, image, manifest)
|
||||
else:
|
||||
execute([
|
||||
"/usr/bin/python3", WORKSPACE / "skills/scripts/install.py",
|
||||
"/bin/bash", WORKSPACE / "install",
|
||||
"--release", release, "--version", manifest["version"],
|
||||
"--system-root", image,
|
||||
])
|
||||
|
||||
Reference in new issue
Block a user