GitOps Toolkit controller that patches container image tags in Git
Go to file
Michael Bridgen 5affa3a34b
Correct directory diffing test and algorithm
Two steps:

1. TestDiffDirectories did not check if the expected only return value
was correct; the intention was there to do so (judging by the
comment "change in order"), but my eye for detail failed me.

2. Reversing the directory comparison in the test revealed bugs in the
comparison code -- in general, it should skip any directory that is
not a directory in the comparator.

To make this easier, the code now keeps track of the expected files it
saw. That means the check for whether an actual file has an expected
counterpart only has two cases, yes or no (rather that trying to
account for whether it's a directory and so on). If a directory was
skipped while scanning the expected files, it won't be in the actual
files anyway.

Signed-off-by: Michael Bridgen <michael@weave.works>
2022-04-26 01:22:12 +05:30
.github/workflows Add support for fuzzing tests using oss-fuzz-build. 2022-02-11 19:59:48 +05:30
api Update source-controller/api to v0.24.0 2022-04-19 13:01:11 +01:00
config Release v0.22.0 2022-04-19 15:58:09 +01:00
controllers Move ginkgo suite to legacy & add testenv 2022-04-21 18:59:05 +05:30
docs update toolkit.f.i docs links 2022-04-01 10:29:36 +02:00
hack Use new standardized runtime and meta package 2022-03-21 12:45:55 +01:00
pkg Correct directory diffing test and algorithm 2022-04-26 01:22:12 +05:30
tests/fuzz Update dependencies 2022-04-19 15:21:11 +01:00
.dockerignore Add support for fuzzing tests using oss-fuzz-build. 2022-02-11 19:59:48 +05:30
.gitignore Upgrade libgit2 and fix static builds 2022-02-10 16:28:41 +05:30
.goreleaser.yaml Publish SBOM and sign release artifacts 2022-01-25 15:24:18 +02:00
ATTRIBUTIONS.md Update source-controller to v0.22.4 2022-03-28 15:22:19 +01:00
CHANGELOG.md Release v0.22.0 2022-04-19 15:58:09 +01:00
CODE_OF_CONDUCT.md Add license, DCO and COC 2020-08-11 10:26:03 +03:00
DCO Add license, DCO and COC 2020-08-11 10:26:03 +03:00
DEVELOPMENT.md Update dev docs 2022-01-24 13:33:25 +00:00
Dockerfile Update libgit2 to 1.3.1 2022-04-13 15:56:56 +01:00
LICENSE Add license, DCO and COC 2020-08-11 10:26:03 +03:00
MAINTAINERS Add pjbgf to Maintainers 2022-02-17 11:23:12 +00:00
Makefile Update source-controller/api to v0.24.0 2022-04-19 13:01:11 +01:00
PROJECT Graduate v1alpha2 API to v1beta1 2021-06-28 11:26:59 +01:00
README.md update toolkit.f.i docs links 2022-04-01 10:29:36 +02:00
go.mod Release v0.22.0 2022-04-19 15:58:09 +01:00
go.sum Update dependencies 2022-04-19 15:21:11 +01:00
main.go add flag to allow configuration of ssh kex algos 2022-04-14 04:05:18 +05:30

README.md

Image automation controller

CII Best Practices report license release

This controller automates updates to YAML when new container images are available.

Its sibling, image-reflector-controller, scans container image repositories and reflects the metadata in Kubernetes resources. This controller reacts to that image metadata by updating YAML files in a git repository, and committing the changes.

How to install it

Please see the installation and use guide.

How to work on it

The shared library libgit2 needs to be installed to test or build locally. The version required corresponds to the version of git2go (which are Go bindings for libgit2), according to this table.

See https://github.com/fluxcd/source-controller/blob/main/DEVELOPMENT.md#installing-required-dependencies for instructions on how to install libgit2.