From aac1e1679412b3e84d6cde1d32295bf22a31e28f Mon Sep 17 00:00:00 2001 From: Moritz Kiefer Date: Tue, 9 Jun 2020 10:08:06 +0200 Subject: [PATCH] Fix caching on Linux and MacOS (#6270) When bumping the cache url on Windows, I accidentally also changed the URL we push to on Linux and MacOS. This is obviously a bad idea so this PR fixes it. changelog_begin changelog_end --- ci/configure-bazel.sh | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/ci/configure-bazel.sh b/ci/configure-bazel.sh index ac1c542427..4b1bcb40ca 100755 --- a/ci/configure-bazel.sh +++ b/ci/configure-bazel.sh @@ -48,7 +48,10 @@ if [ ! -z "${BAZEL_CONFIG_DIR:-}" ]; then cd "$BAZEL_CONFIG_DIR" fi +CACHE_URL="https://storage.googleapis.com/daml-bazel-cache" + if is_windows; then + CACHE_URL="$CACHE_URL/v1" echo "build --config windows" > .bazelrc.local echo "build --config windows-ci" >> .bazelrc.local @@ -81,5 +84,5 @@ if [[ "${IS_FORK}" = False ]]; then echo "$GOOGLE_APPLICATION_CREDENTIALS_CONTENT" > "$GOOGLE_APPLICATION_CREDENTIALS" unset GOOGLE_APPLICATION_CREDENTIALS_CONTENT export GOOGLE_APPLICATION_CREDENTIALS - echo "build --remote_http_cache=https://storage.googleapis.com/daml-bazel-cache/v1 --remote_upload_local_results=true --google_credentials=${GOOGLE_APPLICATION_CREDENTIALS}" >> .bazelrc.local + echo "build --remote_http_cache=$CACHE_URL --remote_upload_local_results=true --google_credentials=${GOOGLE_APPLICATION_CREDENTIALS}" >> .bazelrc.local fi