grafeas / kritis

Deploy-time Policy Enforcer for Kubernetes applications
https://github.com/grafeas/kritis/blob/master/docs/binary-authorization.md
Apache License 2.0
694 stars 134 forks source link

Allow to use Docker images from Artifact Registry #613 #614

Closed xkobal closed 2 years ago

xkobal commented 2 years ago

This Pull Request fixes the #613 issue by allowing to use docker image from Google Artifact Registry.

Given the naming of the actual validation function, I took the choice of creating a dedicated function to validate the syntax of Google Artifact Registries. (named GAR in my changes)

I have choose to rename the isValidImageOnGCR to isValidImageOnGCP (Google Cloud Platform).

I'm not a specialist of Golang, so I'm open to any comment on my changes.

I am using this code on a forked Kritis image and it works like a charm.

ooq commented 2 years ago

LGTM. Once #612 is in, can you sync your PR with master, so that the tests can pass? Thanks @xkobal !

xkobal commented 2 years ago

Thank you for the rebase and merge @ooq. You were faster that me !