From: Zack Cerza Date: Sat, 8 Feb 2025 00:16:20 +0000 (-0700) Subject: build-with-container.py: Add --env-file X-Git-Tag: v20.3.0~437^2~4 X-Git-Url: http://git.apps.os.sepia.ceph.com/?a=commitdiff_plain;h=8e9544fed3dc70ac91f995aacb3aed2edbd45554;p=ceph.git build-with-container.py: Add --env-file Signed-off-by: Zack Cerza --- diff --git a/src/script/build-with-container.py b/src/script/build-with-container.py index 82f892924cb52..5f8fcd489466e 100755 --- a/src/script/build-with-container.py +++ b/src/script/build-with-container.py @@ -179,6 +179,8 @@ def _container_cmd(ctx, args, *, workdir=None, interactive=False): cmd.append("--pids-limit=-1") if ctx.map_user: cmd.append("--user=0") + if ctx.cli.env_file: + cmd.append(f"--env-file={ctx.cli.env_file.absolute()}") if workdir: cmd.append(f"--workdir={workdir}") cwd = pathlib.Path(".").absolute() @@ -844,6 +846,11 @@ def parse_cli(build_step_names): choices=build_step_names, help="Execute the target build step(s)", ) + parser.add_argument( + "--env-file", + type=pathlib.Path, + help="Use this environment file when building", + ) parser.add_argument( "--dry-run", action="store_true",