diff --git a/tools/ci_build/build.py b/tools/ci_build/build.py index cce59dd771..bfa3275759 100644 --- a/tools/ci_build/build.py +++ b/tools/ci_build/build.py @@ -1051,6 +1051,10 @@ def generate_vcpkg_install_options(source_dir, args): if "AGENT_TEMPDIRECTORY" in os.environ: temp_dir = os.environ["AGENT_TEMPDIRECTORY"] vcpkg_install_options.append(f"--x-buildtrees-root={temp_dir}") + + SYSTEM_COLLECTIONURI = os.getenv("SYSTEM_COLLECTIONURI") # noqa: N806 + + # Config asset cache terrapin_cmd_path = shutil.which("TerrapinRetrievalTool") if terrapin_cmd_path is None: terrapin_cmd_path = "C:\\local\\Terrapin\\TerrapinRetrievalTool.exe" @@ -1063,7 +1067,6 @@ def generate_vcpkg_install_options(source_dir, args): + " -b https://vcpkg.storage.devpackages.microsoft.io/artifacts/ -a true -u Environment -p {url} -s {sha512} -d {dst}\\;x-block-origin" ) else: - SYSTEM_COLLECTIONURI = os.getenv("SYSTEM_COLLECTIONURI") # noqa: N806 if ( SYSTEM_COLLECTIONURI == "https://dev.azure.com/onnxruntime/" or SYSTEM_COLLECTIONURI == "https://dev.azure.com/aiinfra/" @@ -1072,6 +1075,12 @@ def generate_vcpkg_install_options(source_dir, args): vcpkg_install_options.append( "--x-asset-sources=x-azurl,https://vcpkg.storage.devpackages.microsoft.io/artifacts/\\;x-block-origin" ) + if SYSTEM_COLLECTIONURI == "https://dev.azure.com/onnxruntime/": + vcpkg_install_options.append(" --binarysource=x-az-universal,onnxruntime,onnxruntime,onnxruntime,rw") + elif SYSTEM_COLLECTIONURI == "https://dev.azure.com/aiinfra/" + or SYSTEM_COLLECTIONURI == "https://aiinfra.visualstudio.com/": + vcpkg_install_options.append(" --binarysource=x-az-universal,aiinfra,Lotus,Lotus,rw") + # Config binary cache return vcpkg_install_options diff --git a/tools/ci_build/github/linux/run_dockerbuild.sh b/tools/ci_build/github/linux/run_dockerbuild.sh index df94a48c58..ada7c623ac 100755 --- a/tools/ci_build/github/linux/run_dockerbuild.sh +++ b/tools/ci_build/github/linux/run_dockerbuild.sh @@ -110,7 +110,6 @@ DOCKER_RUN_PARAMETER="--volume $SOURCE_ROOT:/onnxruntime_src \ --volume $BUILD_DIR:/build \ --volume /data/models:/build/models:ro \ --volume /data/onnx:/data/onnx:ro \ - --volume $HOME/.cache/onnxruntime:/home/onnxruntimedev/.cache/onnxruntime \ --volume $HOME/.onnx:/home/onnxruntimedev/.onnx" if [ $BUILD_DEVICE = "openvino" ] && [[ $BUILD_EXTR_PAR == *"--use_openvino GPU_FP"* ]]; then DOCKER_RUN_PARAMETER="$DOCKER_RUN_PARAMETER --device /dev/dri:/dev/dri"