From 10e3a2d19591713cd98a5e25eacf4541f897c31f Mon Sep 17 00:00:00 2001 From: Christian Hoffmann Date: Wed, 19 Oct 2022 23:02:25 +0200 Subject: [PATCH] Build: Mac: Keep the signing-related keychain unlocked This fixes hanging Mac build runs in CI which got stuck as they required interactive unlocking of the keychain. This issue only became appareant after the switch to universal builds as that made the build take longer than the re-lock interval. Fixes: #2925 --- .github/autobuild/mac.sh | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.github/autobuild/mac.sh b/.github/autobuild/mac.sh index 5a83f86530..4d446f0add 100755 --- a/.github/autobuild/mac.sh +++ b/.github/autobuild/mac.sh @@ -52,6 +52,8 @@ prepare_signing() { # Set up a keychain for the build: security create-keychain -p "${KEYCHAIN_PASSWORD}" build.keychain security default-keychain -s build.keychain + # Remove default re-lock timeout to avoid codesign hangs: + security set-keychain-settings build.keychain security unlock-keychain -p "${KEYCHAIN_PASSWORD}" build.keychain security import certificate.p12 -k build.keychain -P "${MACOS_CERTIFICATE_PWD}" -T /usr/bin/codesign security set-key-partition-list -S apple-tool:,apple:,codesign: -s -k "${KEYCHAIN_PASSWORD}" build.keychain