Skip to content

Commit

Permalink
fix build.sh
Browse files Browse the repository at this point in the history
  • Loading branch information
gerblesh committed Jul 23, 2023
1 parent e9b2ec4 commit 869cb7e
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions scripts/build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -109,17 +109,18 @@ fi
echo "Setup container signing in policy.json and cosign.yaml"
echo "Registry to write: $IMAGE_REGISTRY"

POLICY=$(jq '.transports.docker."$IMAGE_REGISTRY" += [{
POLICY=$(jq '.transports.docker."${IMAGE_REGISTRY}" |=[{
"type": "sigstoreSigned",
"keyPath": "/usr/etc/pki/containers/cosign.pub",
"signedIdentity": {
"type": "matchRepository"
}
}]' /usr/etc/containers/policy.json)
}] + .' /usr/etc/containers/policy.json)

echo "policy.json: $POLICY"
echo $POLICY > /usr/etc/containers/policy.json

cat /usr/etc/containers/policy.json

cp /usr/etc/containers/registries.d/ublue-os.yaml /usr/etc/containers/registries.d/cosign.yaml
sed -i "s ghcr.io/ublue-os $IMAGE_REGISTRY g" /usr/etc/containers/registries.d/cosign.yaml

Expand Down

0 comments on commit 869cb7e

Please sign in to comment.