You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
<palign="center">An <ahref="https://github.com/argoproj/argo-workflows/blob/master/docs/executor_plugins.md">Executor Plugin</a> for <ahref="https://argoproj.github.io/argo-workflows/">Argo Workflows</a> that lets you interact with Argo CD servers.</p>
4
4
</div>
5
5
6
-
## Example Usage
6
+
## Example
7
7
8
8
```yaml
9
9
apiVersion: argoproj.io/v1alpha1
@@ -17,40 +17,128 @@ spec:
17
17
plugin:
18
18
argocd:
19
19
actions:
20
-
- - sync:
21
-
apps:
22
-
- name: guestbook
23
-
- name: guestbook-backend
20
+
- - app:
21
+
sync:
22
+
apps:
23
+
- name: guestbook
24
+
- name: guestbook-backend
24
25
```
25
26
26
27
## Getting Started
27
28
28
-
### Prerequisites
29
+
### Step 1: Get an Argo CD token
29
30
30
-
You will need to have a working [Argo Workflows](https://argoproj.github.io/argo-workflows/) and [Argo CD](https://argo-cd.readthedocs.io/en/stable/) instances to be able to deploy the plugin and use it.
31
+
The plugin requires a secret named `argocd-sync-token` with a key called `jwt.txt` containing the Argo CD token. See the [Argo CD documentation](https://argo-cd.readthedocs.io/en/stable/user-guide/projects/#project-roles) for information about generating tokens.
32
+
33
+
```yaml
34
+
apiVersion: v1
35
+
kind: Secret
36
+
metadata:
37
+
name: argocd-sync-token
38
+
stringData:
39
+
jwt.txt: <token>
40
+
```
41
+
42
+
After defining the secret, apply it to your cluster:
You will have to run the workflow using a service account with appropriate permissions. See [examples/rbac.yaml](examples/rbac.yaml) for an example.
54
+
**Note:** You will have to run the workflow using a service account with appropriate permissions. See [examples/rbac.yaml](examples/rbac.yaml) for an example.
39
55
40
-
The plugin requires a secret named `argocd-sync-token` with a key called `jwt.txt` containing the Argo CD token. See the [Argo CD documentation](https://argo-cd.readthedocs.io/en/stable/user-guide/projects/#project-roles) for information about generating tokens.
56
+
### Step 3: Set your `ARGOCD_SERVER` environment variable
57
+
58
+
By default, the plugin uses `argocd-server.argocd.svc.cluster.local` for `ARGOCD_SERVER`. If you're using a different
59
+
server, you can set the `ARGOCD_SERVER` environment variable in the plugin's configmap.
0 commit comments