This code allows to use cosign with validating admission controllers for verifying the integrity of images.
cosign generate-key-pair && cat cosign.pub | base64 -w0
- Copy this text to kubernetes secret,public
in_manifest_.yaml
- Build the docker image from scratch
docker build . -t $IMAGENAME && docker push $IMAGENAME
or userewanthtammana/build:cosign
- Generate certificates & perform deployments with,
./deploy.sh
- Check the status
- I have already signed an image & pushed it to my dockerhub. For validation run,
- Deploy Singed Image -
kubectl run --rm -it rewanthtammana/python:alpine
- Deploy Unsigned Image -
kubectl run --rm -it nginx
- Deploy Singed Image -