Skip to content

Commit c467ed7

Browse files
authored
Update flux-operator to 0.22.0, Flux to 2.6.x (#1035)
Flux 2.6.1 is the latest Flux release now <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit - **New Features** - Enhanced validation for custom resources to ensure consistent naming and conditional field requirements. - Added support for referencing input providers using label selectors, and expanded input provider types. - Extended reporting with new cluster information fields. - **Bug Fixes** - Improved schema constraints to prevent invalid or inconsistent resource configurations. - **Documentation** - Updated version information in documentation and Helm chart metadata to reflect the latest release. <!-- end of auto-generated comment: release notes by coderabbit.ai -->
2 parents ed881f0 + d2bb66d commit c467ed7

6 files changed

Lines changed: 94 additions & 11 deletions

File tree

‎packages/system/fluxcd-operator/charts/flux-operator/Chart.yaml‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ annotations:
88
- name: Upstream Project
99
url: https://github.com/controlplaneio-fluxcd/flux-operator
1010
apiVersion: v2
11-
appVersion: v0.20.0
11+
appVersion: v0.22.0
1212
description: 'A Helm chart for deploying the Flux Operator. '
1313
home: https://github.com/controlplaneio-fluxcd
1414
icon: https://raw.githubusercontent.com/cncf/artwork/main/projects/flux/icon/color/flux-icon-color.png
@@ -25,4 +25,4 @@ sources:
2525
- https://github.com/controlplaneio-fluxcd/flux-operator
2626
- https://github.com/controlplaneio-fluxcd/charts
2727
type: application
28-
version: 0.20.0
28+
version: 0.22.0

‎packages/system/fluxcd-operator/charts/flux-operator/README.md‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# flux-operator
22

3-
![Version: 0.20.0](https://img.shields.io/badge/Version-0.20.0-informational?style=flat-square) ![Type: application](https://img.shields.io/badge/Type-application-informational?style=flat-square) ![AppVersion: v0.20.0](https://img.shields.io/badge/AppVersion-v0.20.0-informational?style=flat-square)
3+
![Version: 0.22.0](https://img.shields.io/badge/Version-0.22.0-informational?style=flat-square) ![Type: application](https://img.shields.io/badge/Type-application-informational?style=flat-square) ![AppVersion: v0.22.0](https://img.shields.io/badge/AppVersion-v0.22.0-informational?style=flat-square)
44

55
The [Flux Operator](https://github.com/controlplaneio-fluxcd/flux-operator) provides a
66
declarative API for the installation and upgrade of CNCF [Flux](https://fluxcd.io) and the

‎packages/system/fluxcd-operator/charts/flux-operator/templates/crds.yaml‎

Lines changed: 87 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -484,6 +484,9 @@ spec:
484484
type: string
485485
type: object
486486
type: object
487+
x-kubernetes-validations:
488+
- message: the only accepted name for a FluxInstance is 'flux'
489+
rule: self.metadata.name == 'flux'
487490
served: true
488491
storage: true
489492
subresources:
@@ -553,6 +556,22 @@ spec:
553556
spec:
554557
description: FluxReportSpec defines the observed state of a Flux installation.
555558
properties:
559+
cluster:
560+
description: Cluster is the version information of the Kubernetes
561+
cluster.
562+
properties:
563+
nodes:
564+
description: Nodes is the number of nodes in the Kubernetes cluster.
565+
type: integer
566+
platform:
567+
description: Platform is the os/arch of the Kubernetes control
568+
plane.
569+
type: string
570+
serverVersion:
571+
description: ServerVersion is the version of the Kubernetes API
572+
server.
573+
type: string
574+
type: object
556575
components:
557576
description: ComponentsStatus is the status of the Flux controller
558577
deployments.
@@ -748,6 +767,9 @@ spec:
748767
type: string
749768
type: object
750769
type: object
770+
x-kubernetes-validations:
771+
- message: the only accepted name for a FluxReport is 'flux'
772+
rule: self.metadata.name == 'flux'
751773
served: true
752774
storage: true
753775
subresources:
@@ -893,6 +915,7 @@ spec:
893915
type:
894916
description: Type specifies the type of the input provider.
895917
enum:
918+
- Static
896919
- GitHubBranch
897920
- GitHubPullRequest
898921
- GitLabBranch
@@ -902,12 +925,16 @@ spec:
902925
description: |-
903926
URL specifies the HTTP/S address of the input provider API.
904927
When connecting to a Git provider, the URL should point to the repository address.
905-
pattern: ^(http|https)://.*$
928+
pattern: ^((http|https)://.*){0,1}$
906929
type: string
907930
required:
908931
- type
909-
- url
910932
type: object
933+
x-kubernetes-validations:
934+
- message: spec.url must be empty when spec.type is 'Static'
935+
rule: self.type != 'Static' || !has(self.url)
936+
- message: spec.url must not be empty when spec.type is not 'Static'
937+
rule: self.type == 'Static' || has(self.url)
911938
status:
912939
description: ResourceSetInputProviderStatus defines the observed state
913940
of ResourceSetInputProvider.
@@ -1136,12 +1163,68 @@ spec:
11361163
- ResourceSetInputProvider
11371164
type: string
11381165
name:
1139-
description: Name of the input provider resource.
1166+
description: |-
1167+
Name of the input provider resource. Cannot be set
1168+
when the Selector field is set.
11401169
type: string
1170+
selector:
1171+
description: |-
1172+
Selector is a label selector to filter the input provider resources
1173+
as an alternative to the Name field.
1174+
properties:
1175+
matchExpressions:
1176+
description: matchExpressions is a list of label selector
1177+
requirements. The requirements are ANDed.
1178+
items:
1179+
description: |-
1180+
A label selector requirement is a selector that contains values, a key, and an operator that
1181+
relates the key and values.
1182+
properties:
1183+
key:
1184+
description: key is the label key that the selector
1185+
applies to.
1186+
type: string
1187+
operator:
1188+
description: |-
1189+
operator represents a key's relationship to a set of values.
1190+
Valid operators are In, NotIn, Exists and DoesNotExist.
1191+
type: string
1192+
values:
1193+
description: |-
1194+
values is an array of string values. If the operator is In or NotIn,
1195+
the values array must be non-empty. If the operator is Exists or DoesNotExist,
1196+
the values array must be empty. This array is replaced during a strategic
1197+
merge patch.
1198+
items:
1199+
type: string
1200+
type: array
1201+
x-kubernetes-list-type: atomic
1202+
required:
1203+
- key
1204+
- operator
1205+
type: object
1206+
type: array
1207+
x-kubernetes-list-type: atomic
1208+
matchLabels:
1209+
additionalProperties:
1210+
type: string
1211+
description: |-
1212+
matchLabels is a map of {key,value} pairs. A single {key,value} in the matchLabels
1213+
map is equivalent to an element of matchExpressions, whose key field is "key", the
1214+
operator is "In", and the values array contains only "value". The requirements are ANDed.
1215+
type: object
1216+
type: object
1217+
x-kubernetes-map-type: atomic
11411218
required:
11421219
- kind
1143-
- name
11441220
type: object
1221+
x-kubernetes-validations:
1222+
- message: at least one of name or selector must be set for input
1223+
provider references
1224+
rule: has(self.name) || has(self.selector)
1225+
- message: cannot set both name and selector for input provider
1226+
references
1227+
rule: '!has(self.name) || !has(self.selector)'
11451228
type: array
11461229
resources:
11471230
description: Resources contains the list of Kubernetes resources to

‎packages/system/fluxcd/charts/flux-instance/Chart.yaml‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ annotations:
88
- name: Upstream Project
99
url: https://github.com/controlplaneio-fluxcd/flux-operator
1010
apiVersion: v2
11-
appVersion: v0.20.0
11+
appVersion: v0.22.0
1212
description: 'A Helm chart for deploying a Flux instance managed by Flux Operator. '
1313
home: https://github.com/controlplaneio-fluxcd
1414
icon: https://raw.githubusercontent.com/cncf/artwork/main/projects/flux/icon/color/flux-icon-color.png
@@ -25,4 +25,4 @@ sources:
2525
- https://github.com/controlplaneio-fluxcd/flux-operator
2626
- https://github.com/controlplaneio-fluxcd/charts
2727
type: application
28-
version: 0.20.0
28+
version: 0.22.0

‎packages/system/fluxcd/charts/flux-instance/README.md‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# flux-instance
22

3-
![Version: 0.20.0](https://img.shields.io/badge/Version-0.20.0-informational?style=flat-square) ![Type: application](https://img.shields.io/badge/Type-application-informational?style=flat-square) ![AppVersion: v0.20.0](https://img.shields.io/badge/AppVersion-v0.20.0-informational?style=flat-square)
3+
![Version: 0.22.0](https://img.shields.io/badge/Version-0.22.0-informational?style=flat-square) ![Type: application](https://img.shields.io/badge/Type-application-informational?style=flat-square) ![AppVersion: v0.22.0](https://img.shields.io/badge/AppVersion-v0.22.0-informational?style=flat-square)
44

55
This chart is a thin wrapper around the `FluxInstance` custom resource, which is
66
used by the [Flux Operator](https://github.com/controlplaneio-fluxcd/flux-operator)

‎packages/system/fluxcd/values.yaml‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ flux-instance:
55
domain: cozy.local # -- default value is overriden in patches
66
distribution:
77
artifact: ""
8-
version: 2.5.x
8+
version: 2.6.x
99
registry: ghcr.io/fluxcd
1010
components:
1111
- source-controller

0 commit comments

Comments
 (0)