The GOTK controllers all use an annotation to trigger syncing outside of the schedule (e.g., when a webhook is indicates a new revision). This commit makes the ImageRepository controller respect the annotation, by checking it when examining an image repo object. This works a little different to the other controllers, which tend to assume that any incoming event means a sync is due. The image reflector controller uses the ChangedPredicate to filter incoming evetns, as they do, but goes further to check the annotation and otherwise, the scheduled scan time. |
||
---|---|---|
.github/workflows | ||
api | ||
config | ||
controllers | ||
hack | ||
.gitignore | ||
CODE_OF_CONDUCT.md | ||
CONTRIBUTING.md | ||
DCO | ||
Dockerfile | ||
LICENSE | ||
MAINTAINERS | ||
Makefile | ||
PROJECT | ||
README.md | ||
go.mod | ||
go.sum | ||
main.go |
README.md
Image (metadata) reflector controller
This is an attempt to build controllers along the lines set out in https://squaremo.dev/posts/gitops-controllers/.
This repository implements the image metadata reflector controller, which scans container image repositories and reflects the metadata, in Kubernetes resources. The sibling repository image-automation-controller implements the automation controller, which acts on the reflected data (e.g., a new image version) by updating the image references used in files in git.