Run on your cluster
Dagweave runs your workflows on the Argo Workflows in your own cluster. Each run goes out through the connector, and Dagweave shows you its status, logs, metrics and artifacts. There’s no hosted runtime.
A cluster operator installs the connector once and picks the namespaces and features it serves. After that, authors run workflows without touching Kubernetes.
Connecting a cluster needs a Production or Business plan. On any plan you can copy a workflow’s YAML with Get YAML and apply it yourself, or run it on your laptop with Dagweave Local, which is free.
More than one cluster
Section titled “More than one cluster”Connect as many clusters as you like, one connector each. In Where this runs, rank the clusters and namespaces a workflow may use. A run goes to the highest-ranked one that can take it. Each trigger names its own cluster and namespace, so one workflow can run on staging from one trigger and on production from another.
The connector only runs workflows in namespaces its ArgoConnection lists. The
chart creates one for argo; change the list with a Helm value. Running more
than one Argo Workflows instance? Add an ArgoConnection for each extra one.
Runs aimed anywhere else are refused.
Know who started a run
Section titled “Know who started a run”Every Workflow Dagweave sends carries annotations saying who or what started it. Nobody using Dagweave can set or change them, so an admission policy can trust them.
| Annotation | Value |
|---|---|
dagweave.com/triggered-by |
<kind>:<name>, such as user:ana@dagweave.com, api-token:deploy-bot or trigger:3f2a9c. |
dagweave.com/triggered-by-kind |
user, api-token, trigger or system. New kinds of caller may add values. |
dagweave.com/triggered-by-id |
The user, token or trigger id. |
dagweave.com/triggered-by-email |
The person behind the user or token, if any. |
dagweave.com/impersonated-by |
The Dagweave admin who started the run while signed in as the user, if any. |
dagweave.com/trigger-type |
manual, api, cron, webhook, github, sns, s3 or test. API token runs are api. |
dagweave.com/trigger-id |
The trigger that fired the run, if any. |
dagweave.com/run-id |
The Dagweave run id. |
dagweave.com/team |
The owning team’s id. |
run-id, team, trigger-type and triggered-by-kind are also written as
labels, so you can select on them. A value that isn’t a legal label value goes
in the annotations only.
Dagweave strips dagweave.com/ keys from every workflow it compiles, the run API
refuses them from callers, and the connector refuses any Workflow, WorkflowTemplate
or CronWorkflow carrying one that Dagweave didn’t send. That doesn’t stop
someone who can create Workflows in your cluster directly. For that, add an
admission policy that lets only the connector’s service account set them.
The policy below does that, then lets only the prod-deployer token start runs
in prod-* namespaces. It assumes the connector’s service account is connector
in connector-system, as in Install the connector. Change both
names to match your install.
apiVersion: admissionregistration.k8s.io/v1kind: ValidatingAdmissionPolicymetadata: name: dagweave-triggered-byspec: failurePolicy: Fail matchConstraints: resourceRules: - apiGroups: ["argoproj.io"] apiVersions: ["*"] operations: ["CREATE", "UPDATE"] resources: ["workflows"] variables: - name: fromConnector expression: "request.userInfo.username == 'system:serviceaccount:connector-system:connector'" - name: now expression: "object.metadata.?annotations.orValue({})" - name: before expression: "request.operation == 'UPDATE' ? oldObject.metadata.?annotations.orValue({}) : {}" validations: # Only the connector may add, change or remove a dagweave.com/ annotation. - expression: >- variables.fromConnector || (variables.now.all(k, !k.startsWith('dagweave.com/') || (k in variables.before && variables.before[k] == variables.now[k])) && variables.before.all(k, !k.startsWith('dagweave.com/') || k in variables.now)) message: "dagweave.com/ annotations can only be set by the Dagweave connector" # Only the deploy token may start runs in prod-* namespaces. - expression: >- request.operation != 'CREATE' || !request.namespace.startsWith('prod-') || variables.now.?['dagweave.com/triggered-by'].orValue('') == 'api-token:prod-deployer' message: "only the prod-deployer token may start runs in production"---apiVersion: admissionregistration.k8s.io/v1kind: ValidatingAdmissionPolicyBindingmetadata: name: dagweave-triggered-byspec: policyName: dagweave-triggered-by validationActions: ["Deny"]Runs Argo starts on its own, such as children of a CronWorkflow you applied or
anything from argo submit, have no Dagweave annotations. This policy treats
them as not started by the deploy token.
Add your own annotations
Section titled “Add your own annotations”Pass annotations when you start a run through the
API or MCP,
for example {"ci.dagweave.com/env": "pr-123"}. They go on the Workflow beside
Dagweave’s. You can send up to 20, each value up to 1024 bytes. Keys under
dagweave.com/, dagweave.io/, kubernetes.io/, k8s.io/ and argoproj.io/
are refused. A rerun keeps the original run’s annotations.