Skip to content

Commit

Permalink
chore: bump notification engine lib (#3327)
Browse files Browse the repository at this point in the history
* chore: bump notification engine lib

Signed-off-by: Zach Aller <[email protected]>

* chore: bump notification engine lib

Signed-off-by: Zach Aller <[email protected]>

---------

Signed-off-by: Zach Aller <[email protected]>
  • Loading branch information
zachaller authored Jan 25, 2024
1 parent 1a332e3 commit a07417a
Show file tree
Hide file tree
Showing 11 changed files with 39 additions and 26 deletions.
6 changes: 3 additions & 3 deletions docs/generated/notification-services/awssqs.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,10 @@

This notification service is capable of sending simple messages to AWS SQS queue.

* `queue` - name of the queue you are intending to send messages to. Can be overwriten with target destination annotation.
* `queue` - name of the queue you are intending to send messages to. Can be overridden with target destination annotation.
* `region` - region of the sqs queue can be provided via env variable AWS_DEFAULT_REGION
* `key` - optional, aws access key must be either referenced from a secret via variable or via env variable AWS_ACCESS_KEY_ID
* `secret` - optional, aws access secret must be either referenced from a secret via variableor via env variable AWS_SECRET_ACCESS_KEY
* `secret` - optional, aws access secret must be either referenced from a secret via variable or via env variable AWS_SECRET_ACCESS_KEY
* `account` optional, external accountId of the queue
* `endpointUrl` optional, useful for development with localstack

Expand Down Expand Up @@ -63,7 +63,7 @@ stringData:
### Minimal configuration using AWS Env variables
Ensure following list of enviromental variable is injected via OIDC, or other method. And assuming SQS is local to the account.
Ensure following list of environment variables are injected via OIDC, or other method. And assuming SQS is local to the account.
You may skip usage of secret for sensitive data and omit other parameters. (Setting parameters via ConfigMap takes precedent.)
Variables:
Expand Down
2 changes: 1 addition & 1 deletion docs/generated/notification-services/github.md
Original file line number Diff line number Diff line change
Expand Up @@ -87,5 +87,5 @@ template.app-deployed: |
- If `github.repoURLPath` and `github.revisionPath` are same as above, they can be omitted.
- Automerge is optional and `true` by default for github deployments to ensure the requested ref is up to date with the default branch.
Setting this option to `false` is required if you would like to deploy older refs in your default branch.
For more information see the [Github Deployment API Docs](https://docs.github.com/en/rest/deployments/deployments?apiVersion=2022-11-28#create-a-deployment).
For more information see the [GitHub Deployment API Docs](https://docs.github.com/en/rest/deployments/deployments?apiVersion=2022-11-28#create-a-deployment).
- If `github.pullRequestComment.content` is set to 65536 characters or more, it will be truncated.
2 changes: 1 addition & 1 deletion docs/generated/notification-services/googlechat.md
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ It is possible send both simple text and card messages in a chat thread by speci

```yaml
template.app-sync-succeeded: |
message: The app {{ .app.metadata.name }} has succesfully synced!
message: The app {{ .app.metadata.name }} has successfully synced!
googlechat:
threadKey: {{ .app.metadata.name }}
```
4 changes: 2 additions & 2 deletions docs/generated/notification-services/opsgenie.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,8 @@ To be able to send notifications with argocd-notifications you have to create an
8. Give your integration a name, copy the "API key" and safe it somewhere for later
9. Make sure the checkboxes for "Create and Update Access" and "enable" are selected, disable the other checkboxes to remove unnecessary permissions
10. Click "Safe Integration" at the bottom
11. Check your browser for the correct server apiURL. If it is "app.opsgenie.com" then use the us/international api url `api.opsgenie.com` in the next step, otherwise use `api.eu.opsgenie.com` (european api).
12. You are finished with configuring opsgenie. Now you need to configure argocd-notifications. Use the apiUrl, the team name and the apiKey to configure the opsgenie integration in the `argocd-notifications-secret` secret.
11. Check your browser for the correct server apiURL. If it is "app.opsgenie.com" then use the US/international api url `api.opsgenie.com` in the next step, otherwise use `api.eu.opsgenie.com` (European API).
12. You are finished with configuring opsgenie. Now you need to configure argocd-notifications. Use the apiUrl, the team name and the apiKey to configure the Opsgenie integration in the `argocd-notifications-secret` secret.

```yaml
apiVersion: v1
Expand Down
12 changes: 6 additions & 6 deletions docs/generated/notification-services/pagerduty.md
Original file line number Diff line number Diff line change
@@ -1,17 +1,17 @@
# Pagerduty
# PagerDuty

## Parameters

The Pagerduty notification service is used to create pagerduty incidents and requires specifying the following settings:
The PagerDuty notification service is used to create PagerDuty incidents and requires specifying the following settings:

* `pagerdutyToken` - the pagerduty auth token
* `pagerdutyToken` - the PagerDuty auth token
* `from` - email address of a valid user associated with the account making the request.
* `serviceID` - The ID of the resource.


## Example

The following snippet contains sample Pagerduty service configuration:
The following snippet contains sample PagerDuty service configuration:

```yaml
apiVersion: v1
Expand All @@ -35,7 +35,7 @@ data:
## Template
[Notification templates](../templates.md) support specifying subject for pagerduty notifications:
[Notification templates](../templates.md) support specifying subject for PagerDuty notifications:
```yaml
apiVersion: v1
Expand All @@ -62,5 +62,5 @@ apiVersion: argoproj.io/v1alpha1
kind: Rollout
metadata:
annotations:
notifications.argoproj.io/subscribe.on-rollout-aborted.pagerduty: "<serviceID for Pagerduty>"
notifications.argoproj.io/subscribe.on-rollout-aborted.pagerduty: "<serviceID for PagerDuty>"
```
2 changes: 1 addition & 1 deletion docs/generated/notification-services/pagerduty_v2.md
Original file line number Diff line number Diff line change
Expand Up @@ -74,5 +74,5 @@ apiVersion: argoproj.io/v1alpha1
kind: Rollout
metadata:
annotations:
notifications.argoproj.io/subscribe.on-rollout-aborted.pagerdutyv2: "<serviceID for Pagerduty>"
notifications.argoproj.io/subscribe.on-rollout-aborted.pagerdutyv2: "<serviceID for PagerDuty>"
```
14 changes: 9 additions & 5 deletions docs/generated/notification-services/slack.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,11 +6,15 @@ If you want to send message using incoming webhook, you can use [webhook](./webh

The Slack notification service configuration includes following settings:

* `token` - the app token
* `apiURL` - optional, the server url, e.g. https://example.com/api
* `username` - optional, the app username
* `icon` - optional, the app icon, e.g. :robot_face: or https://example.com/image.png
* `insecureSkipVerify` - optional bool, true or false
| **Option** | **Required** | **Type** | **Description** | **Example** |
| -------------------- | ------------ | -------------- | --------------- | ----------- |
| `apiURL` | False | `string` | The server URL. | `https://example.com/api` |
| `channels` | False | `list[string]` | | `["my-channel-1", "my-channel-2"]` |
| `icon` | False | `string` | The app icon. | `:robot_face:` or `https://example.com/image.png` |
| `insecureSkipVerify` | False | `bool` | | `true` |
| `signingSecret` | False | `string` | | `8f742231b10e8888abcd99yyyzzz85a5` |
| `token` | **True** | `string` | The app's OAuth access token. | `xoxb-1234567890-1234567890123-5n38u5ed63fgzqlvuyxvxcx6` |
| `username` | False | `string` | The app username. | `argocd` |

## Configuration

Expand Down
2 changes: 1 addition & 1 deletion docs/generated/notification-services/teams.md
Original file line number Diff line number Diff line change
Expand Up @@ -113,7 +113,7 @@ template.app-sync-succeeded: |

### summary field

You can set a summary of the message that will be shown on Notifcation & Activity Feed
You can set a summary of the message that will be shown on Notification & Activity Feed

![](https://user-images.githubusercontent.com/6957724/116587921-84c4d480-a94d-11eb-9da4-f365151a12e7.jpg)

Expand Down
15 changes: 12 additions & 3 deletions docs/generated/notification-services/webhook.md
Original file line number Diff line number Diff line change
@@ -1,16 +1,25 @@
# Webhook

The webhook notification service allows sending a generic HTTP request using the templatized request body and URL.
Using Webhook you might trigger a Jenkins job, update Github commit status.
Using Webhook you might trigger a Jenkins job, update GitHub commit status.

## Parameters

The Webhook notification service configuration includes following settings:

- `url` - the url to send the webhook to
- `headers` - optional, the headers to pass along with the webhook
- `basicAuth` - optional, the basic authentication to pass along with the webook
- `basicAuth` - optional, the basic authentication to pass along with the webhook
- `insecureSkipVerify` - optional bool, true or false
- `retryWaitMin` - Optional, the minimum wait time between retries. Default value: 1s.
- `retryWaitMax` - Optional, the maximum wait time between retries. Default value: 5s.
- `retryMax` - Optional, the maximum number of retries. Default value: 3.

## Retry Behavior

The webhook service will automatically retry the request if it fails due to network errors or if the server returns a 5xx status code. The number of retries and the wait time between retries can be configured using the `retryMax`, `retryWaitMin`, and `retryWaitMax` parameters.

The wait time between retries is between `retryWaitMin` and `retryWaitMax`. If all retries fail, the `Send` method will return an error.

## Configuration

Expand Down Expand Up @@ -67,7 +76,7 @@ metadata:
## Examples
### Set Github commit status
### Set GitHub commit status
```yaml
apiVersion: v1
Expand Down
2 changes: 1 addition & 1 deletion go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ go 1.20

require (
github.com/antonmedv/expr v1.15.5
github.com/argoproj/notifications-engine v0.4.1-0.20231011160156-2d2d1a75dbee
github.com/argoproj/notifications-engine v0.4.1-0.20231213155711-c02dc5fdb5e1
github.com/argoproj/pkg v0.13.6
github.com/aws/aws-sdk-go-v2 v1.24.1
github.com/aws/aws-sdk-go-v2/config v1.26.5
Expand Down
4 changes: 2 additions & 2 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -81,8 +81,8 @@ github.com/antonmedv/expr v1.15.5/go.mod h1:0E/6TxnOlRNp81GMzX9QfDPAmHo2Phg00y4J
github.com/apapsch/go-jsonmerge/v2 v2.0.0 h1:axGnT1gRIfimI7gJifB699GoE/oq+F2MU7Dml6nw9rQ=
github.com/apapsch/go-jsonmerge/v2 v2.0.0/go.mod h1:lvDnEdqiQrp0O42VQGgmlKpxL1AP2+08jFMw88y4klk=
github.com/appscode/go v0.0.0-20191119085241-0887d8ec2ecc/go.mod h1:OawnOmAL4ZX3YaPdN+8HTNwBveT1jMsqP74moa9XUbE=
github.com/argoproj/notifications-engine v0.4.1-0.20231011160156-2d2d1a75dbee h1:ZYILioq4v6OIsr7uh0Pcx7JY4KpJ9qs8qbjRqM6HWMY=
github.com/argoproj/notifications-engine v0.4.1-0.20231011160156-2d2d1a75dbee/go.mod h1:VG9FXG0ddIVGc7NcSTRapaUjCPCYqOji//z6mmBYwCE=
github.com/argoproj/notifications-engine v0.4.1-0.20231213155711-c02dc5fdb5e1 h1:MYlXNoATpyNCYXlh0iMs1xd2Q+VWzNbl8Zg6G/lQjKQ=
github.com/argoproj/notifications-engine v0.4.1-0.20231213155711-c02dc5fdb5e1/go.mod h1:E/vv4+by868m0mmflaRfGBmKBtAupoF+mmyfekP8QCk=
github.com/argoproj/pkg v0.13.6 h1:36WPD9MNYECHcO1/R1pj6teYspiK7uMQLCgLGft2abM=
github.com/argoproj/pkg v0.13.6/go.mod h1:I698DoJBKuvNFaixh4vFl2C88cNIT1WS7KCbz5ewyF8=
github.com/armon/go-socks5 v0.0.0-20160902184237-e75332964ef5 h1:0CwZNZbxp69SHPdPJAN/hZIm0C4OItdklCFmMRWYpio=
Expand Down

0 comments on commit a07417a

Please sign in to comment.