Retrieve and configure SSH signature
This commit is contained in:
parent
8c5626fbc3
commit
9de9906f3e
@ -79,6 +79,7 @@ steps:
|
|||||||
- chmod 600 ~/.ssh/id_ed25519
|
- chmod 600 ~/.ssh/id_ed25519
|
||||||
- echo -e "Host *\n\tStrictHostKeyChecking no\n" >> ~/.ssh/config
|
- echo -e "Host *\n\tStrictHostKeyChecking no\n" >> ~/.ssh/config
|
||||||
- wget -O ~/keys.gpg "https://lessons.nemunai.re/api/users/$${LOGIN}/pgp_keys" && gpg --import ~/keys.gpg || true
|
- wget -O ~/keys.gpg "https://lessons.nemunai.re/api/users/$${LOGIN}/pgp_keys" && gpg --import ~/keys.gpg || true
|
||||||
|
- wget -O ~/.ssh/allowed_signers "https://lessons.nemunai.re/api/users/$${LOGIN}/allowed_signers" && git config --global gpg.ssh.allowedSignersFile "~/.ssh/allowed_signers" || true
|
||||||
- set -o pipefail; git ls-remote --tags "${REPO_URL}" | grep "refs/tags/${REPO_TAG}" | tail -n 1 | sed 's@/@ @;s@/@ @;s@\^{}$@@' | awk '{ print "Using tag " $$4 }' || { echo "No tag found (was looking for ${REPO_TAG})" >&2; exit 1; }
|
- set -o pipefail; git ls-remote --tags "${REPO_URL}" | grep "refs/tags/${REPO_TAG}" | tail -n 1 | sed 's@/@ @;s@/@ @;s@\^{}$@@' | awk '{ print "Using tag " $$4 }' || { echo "No tag found (was looking for ${REPO_TAG})" >&2; exit 1; }
|
||||||
- git clone --depth 1 --recurse-submodules --branch $$(git ls-remote --tags "${REPO_URL}" | grep "refs/tags/${REPO_TAG}" | tail -n 1 | sed 's@/@ @;s@/@ @;s@\^{}$@@' | awk '{ print $$4 }') ${REPO_URL} "/work/${LOGIN}"
|
- git clone --depth 1 --recurse-submodules --branch $$(git ls-remote --tags "${REPO_URL}" | grep "refs/tags/${REPO_TAG}" | tail -n 1 | sed 's@/@ @;s@/@ @;s@\^{}$@@' | awk '{ print $$4 }') ${REPO_URL} "/work/${LOGIN}"
|
||||||
- git -C "/work/${LOGIN}" verify-tag --raw $$(git ls-remote --tags "${REPO_URL}" | grep "refs/tags/${REPO_TAG}" | tail -n 1 | sed 's@/@ @;s@/@ @;s@\^{}$@@' | awk '{ print $$4 }') || { echo "Tag verification failed" >&2; [ -n "${TAG_SIG_OPTIONAL}" ] || exit 2; }
|
- git -C "/work/${LOGIN}" verify-tag --raw $$(git ls-remote --tags "${REPO_URL}" | grep "refs/tags/${REPO_TAG}" | tail -n 1 | sed 's@/@ @;s@/@ @;s@\^{}$@@' | awk '{ print $$4 }') || { echo "Tag verification failed" >&2; [ -n "${TAG_SIG_OPTIONAL}" ] || exit 2; }
|
||||||
|
Reference in New Issue
Block a user