Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

docs: authorizing kargo stages to modify argo apps #2921

Merged
merged 4 commits into from
Dec 23, 2024
Merged
Changes from 2 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
47 changes: 47 additions & 0 deletions docs/docs/30-how-to-guides/25-argo-cd-integration.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
---
description: Learn how to integrate Kargo Stages with Argo CD Applications.
sidebar_label: Argo CD Integration
---

# Argo CD Integration

Kargo integrates seamlessly with Argo CD to facilitate a more streamlined application lifecycle
management process. While Argo CD helps with deploying Kubernetes objects and synchronizing changes
in the cluster, Kargo focuses on orchestrating the promotion of these changes through various
`Stage`s of development, such as from `development` to `testing` and then to `production`.
krancour marked this conversation as resolved.
Show resolved Hide resolved

:::note
This page is a work in progress.
During this process, you may find limited details here. Please bear with us as we work to add more information.
krancour marked this conversation as resolved.
Show resolved Hide resolved
:::

### Authorizing Kargo `Stage`s to Modify Argo CD Applications
krancour marked this conversation as resolved.
Show resolved Hide resolved

To enable Kargo `Stage`s to interact with and modify Argo CD applications, applications need
to explicitly authorize Kargo to perform these actions. This is accomplished using the
`kargo.akuity.io/authorized-stage` annotation.

Kargo requires the annotation in the following format:
krancour marked this conversation as resolved.
Show resolved Hide resolved

```yaml
kargo.akuity.io/authorized-stage: "<project-name>:<stage-name>"
```

This annotation signifies consent for Kargo to manage the application on behalf of the designated `Project` and `Stage`.
krancour marked this conversation as resolved.
Show resolved Hide resolved

In the following example, the `Application` manifest is configured to
authorize the `test` `Stage` of the `kargo-demo` `Project` to manage
the application by including the `kargo.akuity.io/authorized-stage: kargo-demo:test`
annotation:
krancour marked this conversation as resolved.
Show resolved Hide resolved

```yaml
apiVersion: argoproj.io/v1alpha1
kind: Application
metadata:
name: kargo-demo-test
namespace: argocd
annotations:
kargo.akuity.io/authorized-stage: kargo-demo:test
spec:
# Application Specifications
```
krancour marked this conversation as resolved.
Show resolved Hide resolved