Skip to content

Commit e8bb748

Browse files
committed
chore: further platform fixes
1 parent f7ffa9a commit e8bb748

File tree

3 files changed

+5
-10
lines changed

3 files changed

+5
-10
lines changed

.github/actions/docker/action.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -182,7 +182,7 @@ runs:
182182
SCCACHE_BUCKET=${{ inputs.cache_bucket }}
183183
SCCACHE_REGION=${{ inputs.cache_region }}
184184
SCCACHE_ENDPOINT=${{ inputs.cache_endpoint }}
185-
SCCACHE_S3_KEY_PREFIX=${{ runner.os }}/sccache/${{ runner.arch }}/linux-gnu
185+
SCCACHE_S3_KEY_PREFIX=${{ env.SCCACHE_S3_KEY_PREFIX }}
186186
SCCACHE_VERSION=${{ env.SCCACHE_VERSION }}
187187
AWS_PROFILE=sccache
188188
cache-from: ${{ steps.layer_cache_settings.outputs.cache_from }}

.github/actions/rust/action.yaml

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -82,12 +82,6 @@ runs:
8282
echo "PROTOC=${HOME}/.local/bin/protoc" >> $GITHUB_ENV
8383
export PATH="${PATH}:${HOME}/.local/bin"
8484
85-
- name: Install sccache-cache
86-
uses: mozilla-actions/[email protected]
87-
with:
88-
version: "v0.8.2" # Must be the same as in Dockerfile
89-
if: inputs.cache == 'true'
90-
9185
- name: Set HOME variable to github context
9286
shell: bash
9387
run: echo "HOME=$HOME" >> $GITHUB_ENV

.github/actions/sccache/action.yaml

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -18,8 +18,9 @@ inputs:
1818
description: S3 endpoint secret access key
1919
required: true
2020
platform:
21-
description: "Platform and architecture to use when caching; helps to avoid invalid cache on different arch"
22-
required: true
21+
description: "Platform and architecture to use when caching; defaults to linux/amd64"
22+
required: false
23+
default: "linux/amd64"
2324
install:
2425
description: "Install sccache"
2526
default: "true"
@@ -53,6 +54,6 @@ runs:
5354
echo "SCCACHE_BUCKET=${{ inputs.bucket }}" >> $GITHUB_ENV
5455
echo "SCCACHE_REGION=${{ inputs.region }}" >> $GITHUB_ENV
5556
echo "SCCACHE_ENDPOINT=${{ inputs.endpoint }}" >> $GITHUB_ENV
56-
echo "SCCACHE_S3_KEY_PREFIX=${{ runner.os }}/sccache/${{ inputs.platform }}/" >> $GITHUB_ENV
57+
echo "SCCACHE_S3_KEY_PREFIX=sccache/${{ inputs.platform }}/" >> $GITHUB_ENV
5758
# "SCCACHE_VERSION" is used inside Docker to install the same version of sccache
5859
echo "SCCACHE_VERSION=${{ inputs.version }}" >> $GITHUB_ENV

0 commit comments

Comments
 (0)