File tree Expand file tree Collapse file tree 6 files changed +22
-3
lines changed Expand file tree Collapse file tree 6 files changed +22
-3
lines changed Original file line number Diff line number Diff line change 7
7
run-e2e-tests :
8
8
default : ' false'
9
9
description : If we need to build to run E2E tests. If yes, we need to build also x86.
10
+ gradle-cache-encryption-key :
11
+ description : " The encryption key needed to store the Gradle Configuration cache"
10
12
runs :
11
13
using : composite
12
14
steps :
24
26
uses : ./.github/actions/setup-gradle
25
27
with :
26
28
cache-read-only : " false"
29
+ cache-encryption-key : ${{ inputs.gradle-cache-encryption-key }}
27
30
- name : Restore Android ccache
28
31
uses : actions/cache/restore@v4
29
32
with :
54
57
# release: we want to build all archs (default)
55
58
TASKS="publishAllToMavenTempLocal publishAndroidToSonatype build"
56
59
fi
57
- ./gradlew $TASKS -PenableWarningsAsErrors=true
60
+ ./gradlew $TASKS -PenableWarningsAsErrors=true --configuration-cache
58
61
- name : Save Android ccache
59
62
if : ${{ github.ref == 'refs/heads/main' || contains(github.ref, '-stable') }}
60
63
uses : actions/cache/save@v4
Original file line number Diff line number Diff line change @@ -11,6 +11,9 @@ inputs:
11
11
required : false
12
12
description : The GHA npm token, required only to publish to npm
13
13
default : ' '
14
+ gradle-cache-encryption-key :
15
+ description : The encryption key needed to store the Gradle Configuration cache
16
+
14
17
runs :
15
18
using : composite
16
19
steps :
@@ -102,6 +105,8 @@ runs:
102
105
uses : ./.github/actions/setup-node
103
106
- name : Setup gradle
104
107
uses : ./.github/actions/setup-gradle
108
+ with :
109
+ cache-encryption-key : ${{ inputs.gradle-cache-encryption-key }}
105
110
- name : Install dependencies
106
111
uses : ./.github/actions/yarn-install
107
112
- name : Build packages
Original file line number Diff line number Diff line change 4
4
cache-read-only :
5
5
description : " Whether the Gradle Cache should be in read-only mode so this job won't be allowed to write to it"
6
6
default : " true"
7
+ cache-encryption-key :
8
+ description : " The encryption key needed to store the Gradle Configuration cache"
7
9
runs :
8
10
using : " composite"
9
11
steps :
15
17
cache-read-only : ${{ (github.ref != 'refs/heads/main' && !contains(github.ref, '-stable')) || inputs.cache-read-only == 'true' }}
16
18
# Similarly, for those jobs we want to start with a clean cache so it doesn't grow without limits (this is the negation of the previous condition).
17
19
cache-write-only : ${{ (github.ref == 'refs/heads/main' || contains(github.ref, '-stable')) && inputs.cache-read-only != 'true' }}
18
- # Temporarily disabling to try resolve a cache cleanup failure
19
- # gradle-home-cache-cleanup: true
20
20
add-job-summary-as-pr-comment : on-failure
21
+ # Encryption key for the Gradle Configuration Cache.
22
+ # See https://docs.gradle.org/8.6/userguide/configuration_cache.html#config_cache:secrets:configuring_encryption_key
23
+ cache-encryption-key : ${{ inputs.cache-encryption-key }}
Original file line number Diff line number Diff line change @@ -153,6 +153,7 @@ jobs:
153
153
uses : ./.github/actions/build-android
154
154
with :
155
155
release-type : ${{ needs.set_release_type.outputs.RELEASE_TYPE }}
156
+ gradle-cache-encryption-key : ${{ secrets.GRADLE_CACHE_ENCRYPTION_KEY }}
156
157
157
158
build_npm_package :
158
159
runs-on : 8-core-ubuntu
@@ -188,3 +189,4 @@ jobs:
188
189
hermes-ws-dir : ${{ env.HERMES_WS_DIR }}
189
190
release-type : ${{ needs.set_release_type.outputs.RELEASE_TYPE }}
190
191
gha-npm-token : ${{ env.GHA_NPM_TOKEN }}
192
+ gradle-cache-encryption-key : ${{ secrets.GRADLE_CACHE_ENCRYPTION_KEY }}
Original file line number Diff line number Diff line change @@ -150,6 +150,7 @@ jobs:
150
150
uses : ./.github/actions/build-android
151
151
with :
152
152
release-type : ${{ needs.set_release_type.outputs.RELEASE_TYPE }}
153
+ gradle-cache-encryption-key : ${{ secrets.GRADLE_CACHE_ENCRYPTION_KEY }}
153
154
154
155
build_npm_package :
155
156
runs-on : 8-core-ubuntu
@@ -189,6 +190,7 @@ jobs:
189
190
hermes-ws-dir : ${{ env.HERMES_WS_DIR }}
190
191
release-type : ${{ needs.set_release_type.outputs.RELEASE_TYPE }}
191
192
gha-npm-token : ${{ env.GHA_NPM_TOKEN }}
193
+ gradle-cache-encryption-key : ${{ secrets.GRADLE_CACHE_ENCRYPTION_KEY }}
192
194
- name : Publish @react-native-community/template
193
195
id : publish-template-to-npm
194
196
uses : actions/github-script@v6
Original file line number Diff line number Diff line change @@ -444,6 +444,7 @@ jobs:
444
444
with :
445
445
release-type : ${{ needs.set_release_type.outputs.RELEASE_TYPE }}
446
446
run-e2e-tests : ${{ github.ref == 'refs/heads/main' || contains(github.ref, 'stable') || inputs.run-e2e-tests }}
447
+ gradle-cache-encryption-key : ${{ secrets.GRADLE_CACHE_ENCRYPTION_KEY }}
447
448
448
449
test_e2e_android_rntester :
449
450
if : ${{ github.ref == 'refs/heads/main' || contains(github.ref, 'stable') || inputs.run-e2e-tests }}
@@ -504,6 +505,7 @@ jobs:
504
505
with :
505
506
hermes-ws-dir : ${{ env.HERMES_WS_DIR }}
506
507
release-type : ${{ needs.set_release_type.outputs.RELEASE_TYPE }}
508
+ gradle-cache-encryption-key : ${{ secrets.GRADLE_CACHE_ENCRYPTION_KEY }}
507
509
508
510
test_android_helloworld :
509
511
runs-on : 4-core-ubuntu
@@ -542,6 +544,8 @@ jobs:
542
544
path : /tmp/maven-local
543
545
- name : Setup gradle
544
546
uses : ./.github/actions/setup-gradle
547
+ with :
548
+ cache-encryption-key : ${{ secrets.GRADLE_CACHE_ENCRYPTION_KEY }}
545
549
- name : Run yarn install
546
550
uses : ./.github/actions/yarn-install
547
551
- name : Prepare the Helloworld application
You can’t perform that action at this time.
0 commit comments