Skip to content

Commit 95e9603

Browse files
sluongngiain-macdonald
authored andcommitted
github/workflows: fix cache dir for mac releases (#8696)
1 parent 7c07c92 commit 95e9603

File tree

2 files changed

+16
-2
lines changed

2 files changed

+16
-2
lines changed

.github/workflows/build-mac-intel-github-release-artifacts.yaml

+8-1
Original file line numberDiff line numberDiff line change
@@ -38,13 +38,17 @@ jobs:
3838
- name: Restore caches
3939
id: restore-caches
4040
uses: ./.github/actions/cache-restore
41+
with:
42+
repo-cache-dir: /Users/runner/repo-cache
43+
go-mod-cache-dir: /Users/runner/go-mod-cache
44+
yarn-cache-dir: /Users/runner/.cache/yarn/v6
4145

4246
- name: Build and Upload Artifacts
4347
env:
4448
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
4549
DEVELOPER_DIR: /Library/Developer/CommandLineTools
4650
GO_REPOSITORY_USE_HOST_CACHE: 1
47-
GOMODCACHE: $HOME/go-mod-cache
51+
GOMODCACHE: /Users/runner/go-mod-cache
4852
run: |
4953
bazelisk build \
5054
--config=release-mac \
@@ -61,6 +65,9 @@ jobs:
6165
uses: ./.github/actions/cache-save
6266
if: always()
6367
with:
68+
repo-cache-dir: /Users/runner/repo-cache
69+
go-mod-cache-dir: /Users/runner/go-mod-cache
70+
yarn-cache-dir: /Users/runner/.cache/yarn/v6
6471
repo-cache-hit: ${{ steps.restore-caches.outputs.repo-cache-hit }}
6572
go-mod-cache-hit: ${{ steps.restore-caches.outputs.go-mod-cache-hit }}
6673
yarn-cache-hit: ${{ steps.restore-caches.outputs.yarn-cache-hit }}

.github/workflows/build-mac-m1-github-release-artifacts.yaml

+8-1
Original file line numberDiff line numberDiff line change
@@ -49,13 +49,17 @@ jobs:
4949
- name: Restore caches
5050
id: restore-caches
5151
uses: ./.github/actions/cache-restore
52+
with:
53+
repo-cache-dir: /Users/runner/repo-cache
54+
go-mod-cache-dir: /Users/runner/go-mod-cache
55+
yarn-cache-dir: /Users/runner/.cache/yarn/v6
5256

5357
- name: Build and Upload Artifacts
5458
env:
5559
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
5660
DEVELOPER_DIR: /Library/Developer/CommandLineTools
5761
GO_REPOSITORY_USE_HOST_CACHE: 1
58-
GOMODCACHE: $HOME/go-mod-cache
62+
GOMODCACHE: /Users/runner/go-mod-cache
5963
run: |
6064
bazelisk build --config=release-m1 --remote_header=x-buildbuddy-api-key=${{ secrets.BUILDBUDDY_ORG_API_KEY }} //enterprise/server/cmd/executor:executor
6165
cp bazel-bin/enterprise/server/cmd/**/**/executor executor-enterprise-darwin-arm64
@@ -65,6 +69,9 @@ jobs:
6569
uses: ./.github/actions/cache-save
6670
if: always()
6771
with:
72+
repo-cache-dir: /Users/runner/repo-cache
73+
go-mod-cache-dir: /Users/runner/go-mod-cache
74+
yarn-cache-dir: /Users/runner/.cache/yarn/v6
6875
repo-cache-hit: ${{ steps.restore-caches.outputs.repo-cache-hit }}
6976
go-mod-cache-hit: ${{ steps.restore-caches.outputs.go-mod-cache-hit }}
7077
yarn-cache-hit: ${{ steps.restore-caches.outputs.yarn-cache-hit }}

0 commit comments

Comments
 (0)