cosign-sign/entrypoint.sh
Vojtěch Mareš 2d495f7c05
All checks were successful
ci/woodpecker/push/release Pipeline was successful
chore: add debug log to entrypoint.sh
Signed-off-by: Vojtěch Mareš <vojtech@mares.cz>
2025-09-08 15:32:51 +02:00

21 lines
441 B
Bash
Executable file

#! /bin/sh
if [ -z ${PLUGIN_IMAGES+x} ]; then
echo "ERROR: images setting is required."
exit 1
fi
echo "==== DEBUG ===="
echo "${PLUGIN_IMAGES}"
echo
echo "jq '.'"
echo "${PLUGIN_IMAGES}" | jq '.'
echo
echo "jq '.[]'"
echo "${PLUGIN_IMAGES}" | jq '.[]'
echo
echo "==== DEBUG ===="
echo "${PLUGIN_IMAGES}" | jq --raw-output '.[]' | while read -r image; do
cosign sign --key "${PLUGIN_KEY_PATH:-"./cosign.key"}" "${image}"
done