Skip to content

Commit db781af

Browse files
authored
Merge pull request #1186 from fluxcd/bump-apis-receiver
receiver: Update default API versions to GA
2 parents 4e80403 + c5e1147 commit db781af

File tree

2 files changed

+15
-17
lines changed

2 files changed

+15
-17
lines changed

docs/spec/v1/receivers.md

Lines changed: 13 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -121,7 +121,7 @@ handle the incoming webhook request.
121121
#### Supported Receiver types
122122

123123
| Receiver | Type | Supports filtering using [Events](#events) |
124-
| ------------------------------------------ | -------------- | ------------------------------------------ |
124+
|--------------------------------------------|----------------|--------------------------------------------|
125125
| [Generic webhook](#generic) | `generic` | ❌ |
126126
| [Generic webhook with HMAC](#generic-hmac) | `generic-hmac` | ❌ |
127127
| [GitHub](#github) | `github` | ✅ |
@@ -426,7 +426,7 @@ spec:
426426
secretRef:
427427
name: webhook-token
428428
resources:
429-
- apiVersion: image.toolkit.fluxcd.io/v1beta2
429+
- apiVersion: image.toolkit.fluxcd.io/v1
430430
kind: ImageRepository
431431
name: webapp
432432
```
@@ -459,7 +459,7 @@ spec:
459459
secretRef:
460460
name: webhook-token
461461
resources:
462-
- apiVersion: image.toolkit.fluxcd.io/v1beta2
462+
- apiVersion: image.toolkit.fluxcd.io/v1
463463
kind: ImageRepository
464464
name: webapp
465465
```
@@ -493,7 +493,7 @@ spec:
493493
secretRef:
494494
name: webhook-token
495495
resources:
496-
- apiVersion: image.toolkit.fluxcd.io/v1beta2
496+
- apiVersion: image.toolkit.fluxcd.io/v1
497497
kind: ImageRepository
498498
name: webapp
499499
```
@@ -537,7 +537,7 @@ spec:
537537
secretRef:
538538
name: webhook-token
539539
resources:
540-
- apiVersion: image.toolkit.fluxcd.io/v1beta2
540+
- apiVersion: image.toolkit.fluxcd.io/v1
541541
kind: ImageRepository
542542
name: webapp
543543
```
@@ -576,7 +576,7 @@ spec:
576576
secretRef:
577577
name: webhook-token
578578
resources:
579-
- apiVersion: image.toolkit.fluxcd.io/v1beta2
579+
- apiVersion: image.toolkit.fluxcd.io/v1
580580
kind: ImageRepository
581581
name: webapp
582582
namespace: default
@@ -662,11 +662,9 @@ called.
662662
A resource entry contains the following fields:
663663

664664
- `apiVersion` (Optional): The Flux Custom Resource API group and version, such as
665-
`source.toolkit.fluxcd.io/v1beta2`.
666-
- `kind`: The Flux Custom Resource kind, supported values are `Bucket`,
667-
`GitRepository`, `Kustomization`, `HelmRelease`, `HelmChart`,
668-
`HelmRepository`, `ImageRepository`, `ImagePolicy`, `ImageUpdateAutomation`
669-
and `OCIRepository`.
665+
`source.toolkit.fluxcd.io/v1`.
666+
- `kind`: The Flux Custom Resource kind, e.g. `Bucket`,
667+
`GitRepository`, `OCIRepository` or `ImageRepository`.
670668
- `name`: The Flux Custom Resource `.metadata.name` or `*` (if `matchLabels` is specified)
671669
- `namespace` (Optional): The Flux Custom Resource `.metadata.namespace`.
672670
When not specified, the Receiver's `.metadata.namespace` is used instead.
@@ -679,7 +677,7 @@ To reconcile a single object, set the `kind`, `name` and `namespace`:
679677

680678
```yaml
681679
resources:
682-
- apiVersion: image.toolkit.fluxcd.io/v1beta2
680+
- apiVersion: image.toolkit.fluxcd.io/v1
683681
kind: ImageRepository
684682
name: podinfo
685683
```
@@ -690,7 +688,7 @@ To reconcile objects of a particular kind with specific labels:
690688

691689
```yaml
692690
resources:
693-
- apiVersion: image.toolkit.fluxcd.io/v1beta2
691+
- apiVersion: image.toolkit.fluxcd.io/v1
694692
kind: ImageRepository
695693
name: "*"
696694
matchLabels:
@@ -717,7 +715,7 @@ spec:
717715
secretRef:
718716
name: flux-gar-token
719717
resources:
720-
- apiVersion: image.toolkit.fluxcd.io/v1beta2
718+
- apiVersion: image.toolkit.fluxcd.io/v1
721719
kind: ImageRepository
722720
name: "*"
723721
matchLabels:
@@ -739,7 +737,7 @@ spec:
739737
secretRef:
740738
name: flux-gar-token
741739
resources:
742-
- apiVersion: image.toolkit.fluxcd.io/v1beta2
740+
- apiVersion: image.toolkit.fluxcd.io/v1
743741
kind: ImageRepository
744742
name: "*"
745743
matchLabels:

internal/server/receiver_handlers.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -60,8 +60,8 @@ var defaultFluxAPIVersions = map[string]string{
6060
"HelmChart": "source.toolkit.fluxcd.io/v1",
6161
"HelmRepository": "source.toolkit.fluxcd.io/v1",
6262
"GitRepository": "source.toolkit.fluxcd.io/v1",
63-
"OCIRepository": "source.toolkit.fluxcd.io/v1beta2",
64-
"ImageRepository": "image.toolkit.fluxcd.io/v1beta2",
63+
"OCIRepository": "source.toolkit.fluxcd.io/v1",
64+
"ImageRepository": "image.toolkit.fluxcd.io/v1",
6565
}
6666

6767
// IndexReceiverWebhookPath is a client.IndexerFunc that returns the Receiver's

0 commit comments

Comments
 (0)