Skip to content

Commit 03a7fb5

Browse files
[ci] salvage build-cache before 6 hour limit
1 parent 48c7339 commit 03a7fb5

File tree

1 file changed

+7
-1
lines changed

1 file changed

+7
-1
lines changed

.github/workflows/build-toolchain.yml

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -151,6 +151,7 @@ jobs:
151151
if: ${{ steps.build-cache.outputs.cache-hit == 'true' }}
152152
- name: Build ${{ matrix.target }} installable archive on Docker container
153153
if: ${{ matrix.container != null }}
154+
timeout-minutes: 300 # Exit before 6 hours limit to allow cache upload
154155
run: |
155156
docker volume create oss-swift-package
156157
docker run --name swiftwasm-ci-buildbot \
@@ -163,12 +164,17 @@ jobs:
163164
-v oss-swift-package:/home/build-user \
164165
${{ matrix.container }}
165166
docker exec swiftwasm-ci-buildbot /bin/bash -lc 'env; cp -r /source/* /home/build-user/; ./swift/utils/webassembly/ci.sh'
167+
docker cp swiftwasm-ci-buildbot:/home/build-user/swift-wasm-${{ env.TOOLCHAIN_CHANNEL }}-SNAPSHOT-${{ matrix.target }}.tar.gz .
168+
169+
- name: Extract build-cache from Docker container
170+
if: ${{ matrix.container != null && always() }}
171+
run: |
166172
rm -rf ${{ github.workspace }}/build-cache
167173
docker cp swiftwasm-ci-buildbot:/home/build-user/build-cache ${{ github.workspace }}/build-cache
168-
docker cp swiftwasm-ci-buildbot:/home/build-user/swift-wasm-${{ env.TOOLCHAIN_CHANNEL }}-SNAPSHOT-${{ matrix.target }}.tar.gz .
169174
170175
- name: Build ${{ matrix.target }} installable archive
171176
if: ${{ matrix.container == null }}
177+
timeout-minutes: 300 # Exit before 6 hours limit to allow cache upload
172178
env:
173179
SKIP_XCODE_VERSION_CHECK: 1
174180
run: |

0 commit comments

Comments
 (0)