mirror of
https://github.com/saltstack/salt.git
synced 2025-04-16 17:50:20 +00:00
The extras-<python-major>.<python-minor>
is a Salt thing.
Create it at the right stage. Signed-off-by: Pedro Algarvio <palgarvio@vmware.com>
This commit is contained in:
parent
5c1ac329c4
commit
310991a6d6
1 changed files with 11 additions and 2 deletions
|
@ -467,8 +467,6 @@ def onedir_dependencies(
|
|||
str(requirements_file),
|
||||
env=env,
|
||||
)
|
||||
extras_dir = dest / f"extras-{requirements_version}"
|
||||
extras_dir.mkdir()
|
||||
|
||||
|
||||
@build.command(
|
||||
|
@ -580,6 +578,17 @@ def salt_onedir(
|
|||
ctx.error("Cloud not find a site-packages path with 'site-packages' in it?!")
|
||||
ctx.exit(1)
|
||||
|
||||
ret = ctx.run(
|
||||
str(python_executable),
|
||||
"-c",
|
||||
"import sys; print('{}.{}'.format(*sys.version_info))",
|
||||
capture=True,
|
||||
)
|
||||
python_version_info = ret.stdout.strip().decode()
|
||||
extras_dir = onedir_env / f"extras-{python_version_info}"
|
||||
ctx.info(f"Creating Salt's extras path: {extras_dir}")
|
||||
extras_dir.mkdir(exist_ok=True)
|
||||
|
||||
pth_path = pathlib.Path(site_packages) / "salt-extras.pth"
|
||||
ctx.info(f"Writing '{pth_path}' ...")
|
||||
pth_path.write_text(
|
||||
|
|
Loading…
Add table
Reference in a new issue