From 75c8f77b06ea5c7e3fc5a6afebe3b2906c50cfc6 Mon Sep 17 00:00:00 2001 From: amdfaa <107946068+amdfaa@users.noreply.github.com> Date: Thu, 5 Dec 2024 12:15:36 -0600 Subject: [PATCH] Update run_with_env_secrets.py --- .github/scripts/run_with_env_secrets.py | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/.github/scripts/run_with_env_secrets.py b/.github/scripts/run_with_env_secrets.py index af0382c80f..f19c7ca017 100644 --- a/.github/scripts/run_with_env_secrets.py +++ b/.github/scripts/run_with_env_secrets.py @@ -55,7 +55,9 @@ def main(): os.environ[senv] = str(all_secrets.get(sname, "")) except KeyError as e: print(f"Could not set {senv} from secret {sname}: {e}") - + env_file = f"{ os.environ.get('RUNNER_TEMP', '') }/github_env_{ os.environ.get('GITHUB_RUN_ID', '') }" + if os.environ.get('ROCM'. '') == "true": + env_file = f"/tmp/github_env_{ os.environ.get('GITHUB_RUN_ID', '') }" docker_path = shutil.which("docker") if not docker_path: run_cmd_or_die(f"bash { os.environ.get('RUNNER_TEMP', '') }/exec_script") @@ -69,7 +71,7 @@ def main(): -e RUNNER_ARTIFACT_DIR=/artifacts \ -e RUNNER_DOCS_DIR=/docs \ -e RUNNER_TEST_RESULTS_DIR=/test-results \ - --env-file="/tmp/github_env_{ os.environ.get('GITHUB_RUN_ID', '') }" \ + --env-file="" \ `# It is unknown why the container sees a different value for this.` \ -e GITHUB_STEP_SUMMARY \ { ' '.join([ f'-e {v}' for v in secrets_u_names ]) } \