Skip to content

Commit

Permalink
Update Alerts and Providers to v1beta3 API
Browse files Browse the repository at this point in the history
Notification-controller is introducing v1beta3 APIs for Alerts and
Providers. Update all the references to those APIs to use the new
version.

Signed-off-by: Sunny <[email protected]>
  • Loading branch information
darkowlzz committed Nov 14, 2023
1 parent a3f08a9 commit 8b1250d
Show file tree
Hide file tree
Showing 5 changed files with 13 additions and 13 deletions.
2 changes: 1 addition & 1 deletion content/en/flux/cheatsheets/oci-artifacts.md
Original file line number Diff line number Diff line change
Expand Up @@ -479,7 +479,7 @@ please see the [HelmChart documentation](/flux/components/source/helmcharts/#ver
Configure alerting for when new artifacts are pulled and reconciled:

```yaml
apiVersion: notification.toolkit.fluxcd.io/v1beta2
apiVersion: notification.toolkit.fluxcd.io/v1beta3
kind: Alert
metadata:
name: podinfo
Expand Down
6 changes: 3 additions & 3 deletions content/en/flux/gitops-toolkit/packages.md
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,7 @@ go get github.com/fluxcd/notification-controller/api
Import package

```go
import notificationv1b2 "github.com/fluxcd/notification-controller/api/v1beta2"
import notificationv1b3 "github.com/fluxcd/notification-controller/api/v1beta3"
```

and for `Receiver` objects:
Expand All @@ -115,8 +115,8 @@ API Types
| Name | Version |
|----------------------------------------------------|---------|
| [Receiver](../components/notification/receiver.md) | v1 |
| [Provider](../components/notification/provider.md) | v1beta2 |
| [Alert](../components/notification/alert.md) | v1beta2 |
| [Provider](../components/notification/provider.md) | v1beta3 |
| [Alert](../components/notification/alert.md) | v1beta3 |

### image.toolkit.fluxcd.io

Expand Down
2 changes: 1 addition & 1 deletion content/en/flux/guides/helmreleases.md
Original file line number Diff line number Diff line change
Expand Up @@ -552,7 +552,7 @@ the `flux-system` to start receiving notifications about the Helm
release:

```yaml
apiVersion: notification.toolkit.fluxcd.io/v1beta2
apiVersion: notification.toolkit.fluxcd.io/v1beta3
kind: Alert
metadata:
name: helm-podinfo
Expand Down
12 changes: 6 additions & 6 deletions content/en/flux/monitoring/alerts.md
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ kubectl -n flagger-system create secret generic slack-bot-token \
Create a notification provider for Slack by referencing the above secret:

```yaml
apiVersion: notification.toolkit.fluxcd.io/v1beta2
apiVersion: notification.toolkit.fluxcd.io/v1beta3
kind: Provider
metadata:
name: slack-bot
Expand All @@ -57,7 +57,7 @@ For a complete list please see the [Provider `.spec.type` documentation](/flux/c
Create an alert definition for all repositories and kustomizations:

```yaml
apiVersion: notification.toolkit.fluxcd.io/v1beta2
apiVersion: notification.toolkit.fluxcd.io/v1beta3
kind: Alert
metadata:
name: on-call-webapp
Expand Down Expand Up @@ -199,7 +199,7 @@ The only caveat being that the provider address needs to point to the same
git repository as the event source originates from.

```yaml
apiVersion: notification.toolkit.fluxcd.io/v1beta2
apiVersion: notification.toolkit.fluxcd.io/v1beta3
kind: Provider
metadata:
name: flux-system
Expand All @@ -210,7 +210,7 @@ spec:
secretRef:
name: github
---
apiVersion: notification.toolkit.fluxcd.io/v1beta2
apiVersion: notification.toolkit.fluxcd.io/v1beta3
kind: Alert
metadata:
name: podinfo
Expand Down Expand Up @@ -306,7 +306,7 @@ To display the Flux notifications on Grafana dashboards
you can configure Flux to push events to Grafana annotations API:

```yaml
apiVersion: notification.toolkit.fluxcd.io/v1beta2
apiVersion: notification.toolkit.fluxcd.io/v1beta3
kind: Alert
metadata:
name: grafana
Expand All @@ -320,7 +320,7 @@ spec:
name: '*'
namespace: flux-system
---
apiVersion: notification.toolkit.fluxcd.io/v1beta2
apiVersion: notification.toolkit.fluxcd.io/v1beta3
kind: Provider
metadata:
name: grafana
Expand Down
4 changes: 2 additions & 2 deletions content/en/flux/use-cases/gh-actions-helm-promotion.md
Original file line number Diff line number Diff line change
Expand Up @@ -163,7 +163,7 @@ it performs a Helm release upgrade.
Example of `clusters/staging/apps/demo-github.yaml`:

```yaml
apiVersion: notification.toolkit.fluxcd.io/v1beta2
apiVersion: notification.toolkit.fluxcd.io/v1beta3
kind: Provider
metadata:
name: github
Expand All @@ -174,7 +174,7 @@ spec:
secretRef:
name: github-token
---
apiVersion: notification.toolkit.fluxcd.io/v1beta2
apiVersion: notification.toolkit.fluxcd.io/v1beta3
kind: Alert
metadata:
name: demo-dispatch
Expand Down

0 comments on commit 8b1250d

Please sign in to comment.