Skip to content
Merged
Show file tree
Hide file tree
Changes from 6 commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/e2e.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ jobs:
- name: Set up Go
uses: actions/setup-go@v5.0.0
with:
go-version: '1.23'
go-version: '1.24'
- uses: actions/checkout@v4
- name: Setup k3s
env:
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/gh-pages.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ jobs:
- name: Set up Go
uses: actions/setup-go@v5.0.0
with:
go-version: '1.23'
go-version: '1.24'
- name: build
run: |
pip install mkdocs mkdocs_material
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/go.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ on:
- "master"
env:
# Golang version to use across CI steps
GOLANG_VERSION: '1.23'
GOLANG_VERSION: '1.24'

concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/release.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -127,7 +127,7 @@ jobs:
- name: Setup Golang
uses: actions/setup-go@v4
with:
go-version: 1.23
go-version: 1.24

- name: Generate release artifacts
run: |
Expand Down
4 changes: 2 additions & 2 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
# Initial stage which pulls prepares build dependencies and CLI tooling we need for our final image
# Also used as the image in CI jobs so needs all dependencies
####################################################################################################
FROM --platform=$BUILDPLATFORM golang:1.23 as builder
FROM --platform=$BUILDPLATFORM golang:1.24.13 as builder

RUN apt-get update && apt-get install -y \
wget \
Expand Down Expand Up @@ -40,7 +40,7 @@ RUN NODE_ENV='production' yarn build
####################################################################################################
# Rollout Controller Build stage which performs the actual build of argo-rollouts binaries
####################################################################################################
FROM --platform=$BUILDPLATFORM golang:1.23 as argo-rollouts-build
FROM --platform=$BUILDPLATFORM golang:1.24.13 as argo-rollouts-build

WORKDIR /go/src/github.com/argoproj/argo-rollouts

Expand Down
2 changes: 1 addition & 1 deletion Dockerfile.dev
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
####################################################################################################
# argo-rollouts-dev
####################################################################################################
FROM golang:1.20 as builder
FROM golang:1.24 as builder

RUN apt-get update && apt-get install -y \
ca-certificates && \
Expand Down
1,217 changes: 1,203 additions & 14 deletions docs/features/kustomize/rollout_cr_schema.json

Large diffs are not rendered by default.

20 changes: 19 additions & 1 deletion docs/generated/notification-services/github.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,9 @@ The GitHub notification service changes commit status using [GitHub Apps](https:
- `appID` - the app id
- `installationID` - the app installation id
- `privateKey` - the app private key
- `enterpriseBaseURL` - optional URL, e.g. https://git.example.com/
- `enterpriseBaseURL` - optional URL, e.g. https://git.example.com/api/v3

> ⚠️ _NOTE:_ Specifying `/api/v3` in the `enterpriseBaseURL` is required until [argoproj/notifications-engine#205](https://github.com/argoproj/notifications-engine/issues/205) is resolved.

## Configuration

Expand Down Expand Up @@ -82,6 +84,20 @@ template.app-deployed: |
content: |
Application {{.app.metadata.name}} is now running new version of deployments manifests.
See more here: {{.context.argocdUrl}}/applications/{{.app.metadata.name}}?operation=true
commentTag: "continuous-delivery/{{.app.metadata.name}}"
checkRun:
name: "continuous-delivery/{{.app.metadata.name}}"
details_url: "{{.context.argocdUrl}}/applications/{{.app.metadata.name}}?operation=true"
status: completed
conclusion: success
started_at: "YYYY-MM-DDTHH:MM:SSZ"
completed_at: "YYYY-MM-DDTHH:MM:SSZ"
output:
title: "Deployment of {{.app.metadata.name}} on ArgoCD"
summary: "Application {{.app.metadata.name}} is now running new version of deployments manifests."
text: |
Application {{.app.metadata.name}} is now running new version of deployments manifests.
See more here: {{.context.argocdUrl}}/applications/{{.app.metadata.name}}?operation=true
```

**Notes**:
Expand All @@ -92,4 +108,6 @@ template.app-deployed: |
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).
- If `github.pullRequestComment.content` is set to 65536 characters or more, it will be truncated.
- The `github.pullRequestComment.commentTag` parameter is used to identify the comment. If a comment with the specified tag is found, it will be updated (upserted). If no comment with the tag is found, a new comment will be created.
- Reference is optional. When set, it will be used as the ref to deploy. If not set, the revision will be used as the ref to deploy.

21 changes: 18 additions & 3 deletions docs/generated/notification-services/grafana.md
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,22 @@ stringData:
grafana-api-key: api-key
```

7. Create subscription for your Grafana integration
7. Create a template in `argo-notifications-cm` Configmap
This will be used to pass the (required) text of the annocation to Grafana (or re-use an existing one)
As there is no specific template for Grafana, you must use the generic `message`:

```yaml
apiVersion: v1
kind: ConfigMap
metadata:
name: argo-rollouts-notification-configmap
data:
templates:
template.app-deployed: |
messsage: Application {{.app.metadata.name}} is now running new version of deployments manifests.
```

8. Create subscription for your Grafana integration

```yaml
apiVersion: argoproj.io/v1alpha1
Expand All @@ -47,5 +62,5 @@ metadata:
notifications.argoproj.io/subscribe.<trigger-name>.grafana: tag1|tag2 # list of tags separated with |
```

8. Change the annotations settings
![8](https://user-images.githubusercontent.com/18019529/112022083-47fb0600-8b75-11eb-849b-d25d41925909.png)
9. Change the annotations settings
![8](https://user-images.githubusercontent.com/18019529/112022083-47fb0600-8b75-11eb-849b-d25d41925909.png)
74 changes: 50 additions & 24 deletions docs/generated/notification-services/opsgenie.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,28 +2,34 @@

To be able to send notifications with argocd-notifications you have to create an [API Integration](https://docs.opsgenie.com/docs/integrations-overview) inside your [Opsgenie Team](https://docs.opsgenie.com/docs/teams).

1. Login to Opsgenie at https://app.opsgenie.com or https://app.eu.opsgenie.com (if you have an account in the european union)
2. Make sure you already have a team, if not follow this guide https://docs.opsgenie.com/docs/teams
3. Click "Teams" in the Menu on the left
4. Select the team that you want to notify
5. In the teams configuration menu select "Integrations"
6. Click "Add Integration" in the top right corner
7. Select "API" integration
8. Give your integration a name, copy the "API key" and safe it somewhere for later
9. Click "Edit" in the integration settings
10. Make sure the checkbox for "Create and Update Access" is selected, disable the other checkboxes to remove unnecessary permissions
11. Click "Save" at the bottom
12. Click "Turn on integration" in the top right corner
13. 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).
14. 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 `argo-rollouts-notification-secret` secret.
15. You can find the example `argo-rollouts-notification-configmap` configuration at the below.
1. Login to Opsgenie at https://app.opsgenie.com or https://app.eu.opsgenie.com (if you have an account in the European Union).
2. Make sure you already have a team; if not, follow this guide: https://docs.opsgenie.com/docs/teams.
3. Click "Teams" in the Menu on the left.
4. Select the team that you want to notify.
5. In the team's configuration menu, select "Integrations".
6. Click "Add Integration" in the top right corner.
7. Select "API" integration.
8. Give your integration a name, copy the "API key", and save it somewhere for later.
9. Click "Edit" in the integration settings.
10. Make sure the checkbox for "Create and Update Access" is selected; disable the other checkboxes to remove unnecessary permissions.
11. Click "Save" at the bottom.
12. Click "Turn on integration" in the top right corner.
13. Check your browser for the correct server apiURL. If it is "app.opsgenie.com", then use the US/international API URL `api.opsgenie.com`; otherwise, use `api.eu.opsgenie.com` (European API).
14. 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 `argo-rollouts-notification-secret` secret.
15. You can find the example `argo-rollouts-notification-configmap` configuration below.

| **Option** | **Required** | **Type** | **Description** | **Example** |
| ------------- | ------------ | -------- | -------------------------------------------------------------------------------------------------------- | -------------------------------- |
| `description` | True | `string` | Description field of the alert that is generally used to provide a detailed information about the alert. | `Hello from Argo CD!` |
| `priority` | False | `string` | Priority level of the alert. Possible values are P1, P2, P3, P4 and P5. Default value is P3. | `P1` |
| `description` | True | `string` | Description field of the alert that is generally used to provide detailed information about the alert. | `Hello from Argo CD!` |
| `priority` | False | `string` | Priority level of the alert. Possible values are P1, P2, P3, P4, and P5. Default value is P3. | `P1` |
| `alias` | False | `string` | Client-defined identifier of the alert, that is also the key element of Alert De-Duplication. | `Life is too short for no alias` |
| `note` | False | `string` | Additional note that will be added while creating the alert. | `Error from Argo CD!` |
| `note` | False | `string` | Additional note that will be added while creating the alert. | `Error from Argo CD!` |
| `actions` | False | `[]string` | Custom actions that will be available for the alert. | `["Resolve", "Escalate"]` |
| `tags` | False | `[]string` | Tags of the alert. | `["critical", "deployment"]` |
| `visibleTo` | False | `[]alert.Responder` | Teams and users that the alert will become visible to without sending any notification. The `type` field is mandatory for each item, where possible values are `team` and `user`. In addition to the `type` field, either `id` or `name` should be provided for teams, and either `id` or `username` should be given for users. Please note that alerts will be visible to the teams specified within the `responders` field by default, so there is no need to re-specify them in the `visibleTo` field. | `[{Type: "team", Id: "team_id"}, {Type: "user", Id: "user_id"}]` |
| `details` | False | `map[string]string` | Map of key-value pairs to use as custom properties of the alert. | `{"environment": "production", "service": "web"}` |
| `entity` | False | `string` | Entity field of the alert that is generally used to specify which domain the alert is related to. | `web-server` |
| `user` | False | `string` | Display name of the request owner. | `admin_user` |

```yaml
apiVersion: v1
Expand All @@ -47,18 +53,38 @@ data:
priority: P1
alias: {{.app.metadata.name}}
note: Error from Argo CD!
actions:
- Restart
- AnExampleAction
tags:
- OverwriteQuietHours
- Critical
visibleTo:
- Id: "{{.app.metadata.responderId}}"
Type: "team"
- Name: "rocket_team"
Type: "team"
- Id: "{{.app.metadata.responderUserId}}"
Type: "user"
- Username: "trinity@opsgenie.com"
Type: "user"
details:
environment: production
service: web
entity: Argo CD Application
user: John Doe
trigger.on-a-problem: |
- description: Application has a problem.
send:
- opsgenie
when: app.status.health.status == 'Degraded' or app.status.operationState.phase in ['Error', 'Failed'] or app.status.sync.status == 'Unknown'
```

16. Add annotation in application yaml file to enable notifications for specific Argo CD app.
16. Add annotation in the application YAML file to enable notifications for a specific Argo CD app.
```yaml
apiVersion: argoproj.io/v1alpha1
kind: Application
metadata:
annotations:
notifications.argoproj.io/subscribe.on-a-problem.opsgenie: <your-team>
apiVersion: argoproj.io/v1alpha1
kind: Application
metadata:
annotations:
notifications.argoproj.io/subscribe.on-a-problem.opsgenie: <your-team>
```
4 changes: 2 additions & 2 deletions docs/generated/notification-services/rocketchat.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@

The Rocket.Chat notification service configuration includes following settings:

* `email` - the Rocker.Chat user's email
* `email` - the Rocker.Chat user's SAMAccountName
* `password` - the Rocker.Chat user's password
* `alias` - optional alias that should be used to post message
* `icon` - optional message icon
Expand All @@ -25,7 +25,7 @@ The Rocket.Chat notification service configuration includes following settings:
4. Copy username and password that you was created for bot user
5. Create a public or private channel, or a team, for this example `my_channel`
6. Add your bot to this channel **otherwise it won't work**
7. Store email and password in argocd_notifications-secret Secret
7. Store email and password in argo-rollouts-notification-secret Secret

```yaml
apiVersion: v1
Expand Down
35 changes: 32 additions & 3 deletions docs/generated/notification-services/slack.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,11 +21,11 @@ The Slack notification service configuration includes following settings:

1. Create Slack Application using https://api.slack.com/apps?new_app=1
![1](https://user-images.githubusercontent.com/426437/73604308-4cb0c500-4543-11ea-9092-6ca6bae21cbb.png)
1. Once application is created navigate to `Enter OAuth & Permissions`
1. Once application is created navigate to `OAuth & Permissions`
![2](https://user-images.githubusercontent.com/426437/73604309-4d495b80-4543-11ea-9908-4dea403d3399.png)
1. Click `Permissions` under `Add features and functionality` section and add `chat:write` scope. To use the optional username and icon overrides in the Slack notification service also add the `chat:write.customize` scope.
1. Go to `Scopes` > `Bot Token Scopes` > `Add an OAuth Scope`. Add `chat:write` scope. To use the optional username and icon overrides in the Slack notification service also add the `chat:write.customize` scope.
![3](https://user-images.githubusercontent.com/426437/73604310-4d495b80-4543-11ea-8576-09cd91aea0e5.png)
1. Scroll back to the top, click 'Install App to Workspace' button and confirm the installation.
1. `OAuth & Permission` > `OAuth Tokens for Your Workspace` > `Install to Workspace`
![4](https://user-images.githubusercontent.com/426437/73604311-4d495b80-4543-11ea-9155-9d216b20ec86.png)
1. Once installation is completed copy the OAuth token.
![5](https://user-images.githubusercontent.com/426437/73604312-4d495b80-4543-11ea-832b-a9d9d5e4bc29.png)
Expand Down Expand Up @@ -117,6 +117,35 @@ template.app-sync-status: |
}]
```

If you want to specify an icon and username for each message, you can specify values for `username` and `icon` in the `slack` field.
For icon you can specify emoji and image URL, just like in the service definition.
If you set `username` and `icon` in template, the values set in template will be used even if values are specified in the service definition.

```yaml
template.app-sync-status: |
message: |
Application {{.app.metadata.name}} sync is {{.app.status.sync.status}}.
Application details: {{.context.argocdUrl}}/applications/{{.app.metadata.name}}.
slack:
username: "testbot"
icon: https://example.com/image.png
attachments: |
[{
"title": "{{.app.metadata.name}}",
"title_link": "{{.context.argocdUrl}}/applications/{{.app.metadata.name}}",
"color": "#18be52",
"fields": [{
"title": "Sync Status",
"value": "{{.app.status.sync.status}}",
"short": true
}, {
"title": "Repository",
"value": "{{.app.spec.source.repoURL}}",
"short": true
}]
}]
```

The messages can be aggregated to the slack threads by grouping key which can be specified in a `groupingKey` string field under `slack` field.
`groupingKey` is used across each template and works independently on each slack channel.
When multiple applications will be updated at the same time or frequently, the messages in slack channel can be easily read by aggregating with git commit hash, application name, etc.
Expand Down
Loading
Loading