Commit Graph

126 Commits

Author SHA1 Message Date
Max Jonas Werner 454790cee4
feat: add sourceRef.name column to Kustomization print columns
closes #556

Signed-off-by: Max Jonas Werner <mail@makk.es>
2022-02-01 16:35:13 +01:00
Stefan Prodan 518c8a021b
Allow disabling cross-namespace references
Introduce the flag `--no-cross-namespace-refs` (defaults to false) for allowing cluster admins to disable cross-namespace references to sources.

Signed-off-by: Stefan Prodan <stefan.prodan@gmail.com>
2022-01-26 22:50:10 +02:00
Aurel Canciu ec9fdb1550
Update flux pkg components
Signed-off-by: Aurel Canciu <aurelcanciu@gmail.com>
2021-12-20 14:50:41 +01:00
Aurel Canciu 57220f8c70
Update Go to v1.17
Signed-off-by: Aurel Canciu <aurelcanciu@gmail.com>
2021-12-16 14:23:15 +01:00
Stefan Prodan 24bdda0c1c
Update dependencies
- fluxcd/pkg/ssa v0.6.0
- fluxcd/source-controller/api v0.19.1
- github.com/opencontainers/runc to v1.0.3 (fix CVE-2021-43784)

Signed-off-by: Stefan Prodan <stefan.prodan@gmail.com>
2021-12-09 11:47:50 +02:00
Stefan Prodan 8eac59574f
Release v0.17.0
Signed-off-by: Stefan Prodan <stefan.prodan@gmail.com>
2021-11-09 14:18:49 +02:00
Stefan Prodan 51a7189087
Restore `spec.validation` and mark it as deprecated
Signed-off-by: Stefan Prodan <stefan.prodan@gmail.com>
2021-10-07 14:17:02 +03:00
Stefan Prodan dba56a569e
Add example for `.spec.wait` usage
Signed-off-by: Stefan Prodan <stefan.prodan@gmail.com>
2021-10-07 11:37:39 +03:00
Stefan Prodan 6346591f02
Use ssa package from fluxcd/pkg
Signed-off-by: Stefan Prodan <stefan.prodan@gmail.com>
2021-10-01 10:21:15 +03:00
Stefan Prodan 9c8f284b7f
Add `spec.wait` usage to the API docs
Signed-off-by: Stefan Prodan <stefan.prodan@gmail.com>
2021-09-30 18:35:40 +03:00
Stefan Prodan 468f00e416
Implement health checking for all resources
- Add `.spec.wait` optional boolean field to API
- Wait for all applied resources to become ready when `.spec.wait` is set to `true`

Signed-off-by: Stefan Prodan <stefan.prodan@gmail.com>
2021-09-30 18:35:39 +03:00
Stefan Prodan 69069c3ab3
Refactor reconciliation into actions
Signed-off-by: Stefan Prodan <stefan.prodan@gmail.com>
2021-09-30 18:35:39 +03:00
Stefan Prodan b33e3b3449
Update the status when health checking starts
Set the healthiness status to progressing and specify the health check timeout in the condition message.

Signed-off-by: Stefan Prodan <stefan.prodan@gmail.com>
2021-09-30 18:35:39 +03:00
Stefan Prodan 7ffe62b8e7
Introduce v1beta2 API
Changes from v1beta1:
- `spec.validation` removed (server-side validation is implicit)
- `spec.status.snapshot` replaced by `spec.status.inventory`
- `spec.patchesStrategicMerge` deprecated in favour of `spec.patches`
- `spec.patchesJson6902` deprecated in favour of `spec.patches`

Signed-off-by: Stefan Prodan <stefan.prodan@gmail.com>
2021-09-30 18:33:26 +03:00
Stefan Prodan 14329c6fa0
Refactor tests
Signed-off-by: Stefan Prodan <stefan.prodan@gmail.com>
2021-09-10 16:51:22 +03:00
Max Jonas Werner d7690d8564
feat: set default observedGeneration to -1 on Kustomizations
This is a follow-up to
https://github.com/fluxcd/helm-controller/pull/294, porting the same
code to the kustomize-controller so that all Flux 2 controllers work
the same way in this regard.

Signed-off-by: Max Jonas Werner <mail@makk.es>
2021-08-27 17:15:24 +02:00
James Alseth 6f32e53970
Improve trimString function
Previously, the function iterated until the length limit was hit, which
is relatively slow and increases with the length of the limit. The new
implementation is easier to reason about and operates in constant time,
leading to better performance.

Signed-off-by: James Alseth <james@jalseth.me>
2021-08-24 19:18:41 -07:00
Stefan Prodan fe0f946840
Update dependencies
- k8s.io/* v0.21.3
- controller-runtime v0.9.5
- kubectl 1.21.3

Signed-off-by: Stefan Prodan <stefan.prodan@gmail.com>
2021-08-05 10:45:32 +03:00
Stefan Prodan 2370360c10
Add the generic patch field to the API spec docs
Signed-off-by: Stefan Prodan <stefan.prodan@gmail.com>
2021-06-18 10:42:34 +03:00
Guillaume Le Biller 14bce3c666
Update pkg/apis/kustomize to v0.2.0
Signed-off-by: Guillaume Le Biller <glebiller@Traveldoo.com>
2021-06-11 16:45:50 +02:00
Guillaume Le Biller b797eac907
Implement generic patches in Kustomization
Allow patching multiple resources instead of a single existing one as
StrategicMerge & JSON6902 are forced to target existing named resources.

Signed-off-by: Guillaume Le Biller <glebiller@Traveldoo.com>
2021-06-11 09:04:37 +02:00
Stefan Prodan ce4445f714
Update fluxcd/pkg/runtime to v0.12.0
Signed-off-by: Stefan Prodan <stefan.prodan@gmail.com>
2021-06-08 20:34:33 +03:00
Stefan Prodan dce166f7a6
Update controller-runtime and controller-gen
- Bump controller-runtime to v0.9.0
- Bump controller-gen to v0.5.0
- Use Environment.AddUser to generate the envtest cluster admin kubeconfig

Signed-off-by: Stefan Prodan <stefan.prodan@gmail.com>
2021-06-08 20:34:16 +03:00
Stefan Prodan 3bb5bece0c
Update source-controller/api to v0.13.0
Signed-off-by: Stefan Prodan <stefan.prodan@gmail.com>
2021-05-26 16:46:11 +03:00
Stefan Prodan 036e3cf42b
Update fluxcd/source-controller/api to v0.12.0
Signed-off-by: Stefan Prodan <stefan.prodan@gmail.com>
2021-04-22 10:40:17 +03:00
Stefan Prodan 56a1fab4c2
Update fluxcd/pkg/apis/meta to v0.9.0
Signed-off-by: Stefan Prodan <stefan.prodan@gmail.com>
2021-04-21 13:41:34 +03:00
Stefan Prodan aa66416734
Update fluxcd/pkg/runtime to v0.10.2
Signed-off-by: Stefan Prodan <stefan.prodan@gmail.com>
2021-04-19 15:03:00 +03:00
Stefan Prodan 43c05a7a20
Set leader election deadline to 30s
Signed-off-by: Stefan Prodan <stefan.prodan@gmail.com>
2021-03-25 13:33:15 +02:00
Stefan Prodan 446545c71f
Expose suspended status as Prometheus metric
Signed-off-by: Stefan Prodan <stefan.prodan@gmail.com>
2021-03-17 11:27:21 +02:00
Stefan Prodan 95c2f1d04c
Update dependencies
- github.com/fluxcd/source-controller/api v0.9.1
- github.com/fluxcd/pkg/runtime v0.8.4
- sigs.k8s.io/controller-runtime v0.8.3

Signed-off-by: Stefan Prodan <stefan.prodan@gmail.com>
2021-03-15 16:29:52 +02:00
Stefan Prodan 750cbdfbb2
Update dependencies
- fluxcd/pkg/apis/meta v0.8.0
- fluxcd/source-controller/api v0.9.0

Signed-off-by: Stefan Prodan <stefan.prodan@gmail.com>
2021-02-23 16:45:38 +02:00
Stefan Prodan 65cfce2978
Add spec.force to API docs
Signed-off-by: Stefan Prodan <stefan.prodan@gmail.com>
2021-02-22 17:36:37 +02:00
Stefan Prodan 30c793ed60
Update fluxcd/pkg/runtime to v0.8.3
Signed-off-by: Stefan Prodan <stefan.prodan@gmail.com>
2021-02-22 17:04:19 +02:00
Aurel Canciu 729dc9770e
Support recreating objects on immutable field updates
Allow passing --force to kubectl apply. Useful when dealing with
immutable field changes in resources.

Signed-off-by: Aurel Canciu <aurelcanciu@gmail.com>
2021-02-22 16:59:01 +02:00
Stefan Prodan 401fec6c8d
Allow disabling var substitution for certain resources
Signed-off-by: Stefan Prodan <stefan.prodan@gmail.com>
2021-02-16 10:40:01 +02:00
Stefan Prodan 0ac1f9e631
Implement var substitution from ConfigMaps and Secrets
Signed-off-by: Stefan Prodan <stefan.prodan@gmail.com>
2021-02-16 09:20:00 +02:00
Stefan Prodan f3d9c36691
Add support for variable substitutions
Signed-off-by: Stefan Prodan <stefan.prodan@gmail.com>
2021-02-11 18:17:53 +02:00
Stefan Prodan e99f328200
Add source kind and name to not found error
Signed-off-by: Stefan Prodan <stefan.prodan@gmail.com>
2021-02-08 15:20:13 +02:00
Hidde Beydals 17a6bff52e Add Patches{StrategicMerge,JSON6902} fields to API
Signed-off-by: Hidde Beydals <hello@hidde.co>
2021-02-03 20:31:11 +01:00
Hidde Beydals 02de763ad8 Depend on the Kustomize API from `fluxcd/pkg`
Signed-off-by: Hidde Beydals <hello@hidde.co>
2021-02-03 20:12:58 +01:00
Stefan Prodan 5e17dd48f4
Add Healthy status condition
- record the last health assessment result in a dedicated status condition
- use the condition status when issuing events to prevent notifications spam

Signed-off-by: Stefan Prodan <stefan.prodan@gmail.com>
2021-02-02 14:59:06 +02:00
Stefan Prodan 0e0277aaef
Update RetryInterval description
Signed-off-by: Stefan Prodan <stefan.prodan@gmail.com>
2021-01-22 16:22:37 +02:00
Stefan Prodan 4df56cb7ab
Add RetryInterval as optional field to API
The spec.retryInterval is the interval at which to retry a previously failed reconciliation.
When not specified, it defaults to the spec.interval value.

Signed-off-by: Stefan Prodan <stefan.prodan@gmail.com>
2021-01-22 15:48:28 +02:00
Stefan Prodan 95cf7ddba4
Update source-controller/api to v0.7.0
Signed-off-by: Stefan Prodan <stefan.prodan@gmail.com>
2021-01-21 18:37:40 +02:00
Stefan Prodan 62a764a28e
Use the object reference type from fluxcd/pkg/meta
Signed-off-by: Stefan Prodan <stefan.prodan@gmail.com>
2021-01-21 13:24:32 +02:00
Stefan Prodan 9a7185e3c3
Update fluxcd/pkg/runtime to v0.8.0
Signed-off-by: Stefan Prodan <stefan.prodan@gmail.com>
2021-01-21 13:08:41 +02:00
Stefan Prodan d58bff0fe6
Update Kubernetes packages to v1.20.2
Signed-off-by: Stefan Prodan <stefan.prodan@gmail.com>
2021-01-16 15:53:45 +02:00
Hidde Beydals c6353b4afd Upgrade runtime package to v0.6.2
To include a bug fix to the `ReconcilateAtChangedPredicate`
and renaming to `ReconcileRequestedPredicate`.

Signed-off-by: Hidde Beydals <hello@hidde.co>
2021-01-14 12:34:10 +01:00
Stefan Prodan 6b9db36a49
Update fluxcd/pkg/runtime to v0.6.0
Signed-off-by: Stefan Prodan <stefan.prodan@gmail.com>
2021-01-04 11:50:59 +02:00
Stefan Prodan 696f91d380
Refactor impersonation
Signed-off-by: Stefan Prodan <stefan.prodan@gmail.com>
2021-01-04 11:50:59 +02:00