Don't attempt to sign without GPG_PASSPHRASE

This ensures PRs can build even though GPG_PASSPHRASE is missing.
This commit is contained in:
Thomas Orozco 2016-08-10 08:47:23 +02:00
parent 24969266fc
commit 2eeac4cd60
2 changed files with 4 additions and 3 deletions

View File

@ -107,8 +107,9 @@ pip install psutil python-prctl bitmap
# Run tests
python "${SOURCE_DIR}/test/run_inner_tests.py"
# If a signing key is made available, then use it to sign the binaries
if [[ -f "${SOURCE_DIR}/sign.key" ]]; then
# If a signing key and passphrase are made available, then use it to sign the
# binaries
if [[ -n "$GPG_PASSPHRASE" ]] && [[ -f "${SOURCE_DIR}/sign.key" ]]; then
echo "Signing binaries"
GPG_SIGN_HOMEDIR="${BUILD_DIR}/gpg-sign"
GPG_VERIFY_HOMEDIR="${BUILD_DIR}/gpg-verify"

View File

@ -22,5 +22,5 @@ docker run -it --rm \
-e BUILD_DIR=/tmp/tini-build \
-e SOURCE_DIR="${SRC}" \
-e FORCE_SUBREAPER="${FORCE_SUBREAPER}" \
-e GPG_PASSPHRASE="${GPG_PASSPHRASE}" \
-e GPG_PASSPHRASE="${GPG_PASSPHRASE:=}" \
"${IMG}" "${SRC}/ci/run_build.sh"