install: added task using a subset of the previous auto install to support auto setup and building of core packages

This commit is contained in:
Blake Harnden 2022-07-29 14:12:17 -07:00
parent a201fd2903
commit c91d8df790

View file

@ -314,6 +314,36 @@ def install_core_files(c, local=False, verbose=False, prefix=DEFAULT_PREFIX):
c.run(f"sudo cp -r package/examples {examples_dir}", hide=hide) c.run(f"sudo cp -r package/examples {examples_dir}", hide=hide)
@task(
help={
"dev": "install development mode",
"verbose": "enable verbose",
"install-type": "used to force an install type, "
"can be one of the following (redhat, debian)",
"no-python": "avoid installing python system dependencies",
},
)
def build(
c,
verbose=False,
install_type=None,
no_python=False,
):
print("setting up to build core packages")
c.run("sudo -v", hide=True)
p = Progress(verbose)
hide = not verbose
os_info = get_os(install_type)
with p.start("installing system dependencies"):
install_system(c, os_info, hide, no_python)
with p.start("installing system grpcio-tools"):
install_grpcio(c, hide)
with p.start("building core"):
build_core(c, hide)
with p.start(f"building rpm/deb packages"):
c.run("make fpm", hide=hide)
@task( @task(
help={ help={
"dev": "install development mode", "dev": "install development mode",