From f89af8b5045bfdcb24ce8cc74ed676d77c9e67a6 Mon Sep 17 00:00:00 2001 From: Adin Scannell Date: Wed, 6 Jan 2021 15:36:02 -0800 Subject: Don't canonicalize cache directory. ... Otherwise it will be mounted in via some other path, and will not be available inside the container at all. PiperOrigin-RevId: 350440843 --- tools/bazel.mk | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/tools/bazel.mk b/tools/bazel.mk index a0246a560..af8e53d3f 100644 --- a/tools/bazel.mk +++ b/tools/bazel.mk @@ -47,8 +47,8 @@ HASH := $(shell readlink -m $(CURDIR) | md5sum | cut -c1-8) BUILDER_NAME := gvisor-builder-$(HASH)-$(ARCH) DOCKER_NAME := gvisor-bazel-$(HASH)-$(ARCH) DOCKER_PRIVILEGED := --privileged -BAZEL_CACHE := $(shell readlink -m ~/.cache/bazel/) -GCLOUD_CONFIG := $(shell readlink -m ~/.config/gcloud/) +BAZEL_CACHE := $(HOME)/.cache/bazel/ +GCLOUD_CONFIG := $(HOME)/.config/gcloud/ DOCKER_SOCKET := /var/run/docker.sock DOCKER_CONFIG := /etc/docker @@ -77,8 +77,8 @@ DOCKER_RUN_OPTIONS := DOCKER_RUN_OPTIONS += --user $(UID):$(GID) DOCKER_RUN_OPTIONS += --entrypoint "" DOCKER_RUN_OPTIONS += --init -DOCKER_RUN_OPTIONS += -v "$(BAZEL_CACHE):$(BAZEL_CACHE)" -DOCKER_RUN_OPTIONS += -v "$(GCLOUD_CONFIG):$(GCLOUD_CONFIG)" +DOCKER_RUN_OPTIONS += -v "$(shell readlink -m $(BAZEL_CACHE)):$(BAZEL_CACHE)" +DOCKER_RUN_OPTIONS += -v "$(shell readlink -m $(GCLOUD_CONFIG)):$(GCLOUD_CONFIG)" DOCKER_RUN_OPTIONS += -v "/tmp:/tmp" DOCKER_EXEC_OPTIONS := --user $(UID):$(GID) DOCKER_EXEC_OPTIONS += --interactive -- cgit v1.2.3