Skip to content

Commit 17c0867

Browse files
authored
fix(release): do not fail if we can not attest a material (#231)
Signed-off-by: Miguel Martinez Trivino <[email protected]>
1 parent 3b5def0 commit 17c0867

File tree

2 files changed

+3
-1
lines changed

2 files changed

+3
-1
lines changed

.github/workflows/contracts/releases.cue

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@ materials: [
44
{type: "ARTIFACT", name: "cli-linux-amd64", output: true},
55
{type: "ARTIFACT", name: "control-plane-linux-amd64", output: true},
66
{type: "ARTIFACT", name: "artifact-cas-linux-amd64", output: true},
7+
{type: "ARTIFACT", name: "chainloop-plugin-discord-webhook-linux-amd64"},
78
// Container images
89
{type: "CONTAINER_IMAGE", name: "control-plane-image", output: true},
910
{type: "CONTAINER_IMAGE", name: "artifact-cas-image", output: true},

.github/workflows/release.yaml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -101,10 +101,11 @@ jobs:
101101
run: |
102102
# Binaries x86_64
103103
# TODO: add the rest of binaries
104+
# NOTE that we are not making the attestation fail if the material is not found. We will fail on "att push"
104105
echo -n '${{ steps.release.outputs.artifacts }}' | jq -r '.[] | select(.type=="Binary" and .goos=="linux" and .goarch=="amd64") | { "name": "\(.extra.ID)-\(.goos)-\(.goarch)", "path":"\(.path)"} | @base64' | while read i; do
105106
BINARY_NAME=$(echo "${i}" | base64 --decode | jq -r ${1} .name)
106107
BINARY_PATH=$(echo "${i}" | base64 --decode | jq -r ${1} .path)
107-
chainloop attestation add --name ${BINARY_NAME} --value ${BINARY_PATH}
108+
chainloop attestation add --name ${BINARY_NAME} --value ${BINARY_PATH} || true
108109
done
109110
110111
- name: Finish and Record Attestation

0 commit comments

Comments
 (0)