Skip to content

Commit 5396654

Browse files
author
arpechenin
committed
- add metadata field to executor plugin
- fix comments Signed-off-by: arpechenin <arpechenin@avito.ru>
1 parent 3cad765 commit 5396654

22 files changed

+1410
-869
lines changed

.features/pending/15234-argo-workflow-level-executor-plugin-configuration.md

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ Component: General
44
Issues: 15234
55

66
This PR allows configuring the Argo Workflow Executor Plugin for a specific Argo Workflow directly within the Workflow spec.
7-
This feature enable via `ARGO_WORKFLOW_LEVEL_EXECUTOR_PLUGINS=true` controller env variable
7+
This feature is enabled via the `ARGO_WORKFLOW_LEVEL_EXECUTOR_PLUGINS=true` controller env variable
88

99

1010
apiVersion: apps/v1
@@ -30,7 +30,9 @@ Sample executor plugin definition in the Argo workflow spec:
3030
spec:
3131
entrypoint: hello-hello-hello
3232
executorPlugins:
33-
- spec:
33+
- metadata:
34+
name: print-message-plugin
35+
spec:
3436
sidecar:
3537
container:
3638
name: print-message-plugin

Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -664,7 +664,7 @@ ifneq ($(PLUGINS),true)
664664
@echo "⚠️ not starting plugins. If you want to test plugins, run 'make start PROFILE=plugins' to start it"
665665
endif
666666
ifneq ($(WORKFLOW_LEVEL_PLUGINS),true)
667-
@echo "⚠️ not starting worklow-level plugins. If you want to test plugins, run 'make start WORKFLOW_LEVEL_PLUGINS=true' to start it"
667+
@echo "⚠️ not starting workflow-level plugins. If you want to test workflow-level plugins, run 'make start WORKFLOW_LEVEL_PLUGINS=true' to start it"
668668
endif
669669
# Check dex, minio, postgres and mysql are in hosts file
670670
ifeq ($(AUTH_MODE),sso)

api/jsonschema/schema.json

Lines changed: 8 additions & 3 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

api/openapi-spec/swagger.json

Lines changed: 7 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

docs/executor_plugins.md

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,9 @@
55
Executor Plugins are disabled by default.
66
They can be enabled either globally via the Workflow Controller ConfigMap or per workflow.
77
Use the corresponding flags to enable them:
8-
`ARGO_EXECUTOR_PLUGINS=true` - enable plugins globally
9-
`ARGO_WORKFLOW_LEVEL_EXECUTOR_PLUGINS=true` - enable plugins at the workflow spec level
8+
`ARGO_EXECUTOR_PLUGINS=true` - enables the use of Executor Plugins defined globally in the controller’s ConfigMap.
9+
`ARGO_WORKFLOW_LEVEL_EXECUTOR_PLUGINS=true` - allows using Executor Plugin settings specified directly in the workflow spec. These settings take precedence over the global ones.
10+
These two options are independent of each other: you can enable only the global plugins, only the workflow-level plugins, or both at the same time.
1011

1112
For example, to enable both modes in the Workflow Controller deployment:
1213

docs/fields.md

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -889,7 +889,7 @@ WorkflowSpec is the specification of a Workflow.
889889
|`dnsPolicy`|`string`|Set DNS policy for workflow pods. Defaults to "ClusterFirst". Valid values are 'ClusterFirstWithHostNet', 'ClusterFirst', 'Default' or 'None'. DNS parameters given in DNSConfig will be merged with the policy selected with DNSPolicy. To have DNS options set along with hostNetwork, you have to specify DNS policy explicitly to 'ClusterFirstWithHostNet'.|
890890
|`entrypoint`|`string`|Entrypoint is a template reference to the starting point of the io.argoproj.workflow.v1alpha1.|
891891
|`executor`|[`ExecutorConfig`](#executorconfig)|Executor holds configurations of executor containers of the io.argoproj.workflow.v1alpha1.|
892-
|`executorPlugins`|`Array<`[`ExecutorPlugin`](#executorplugin)`>`|ExecutorPlugins specifies a list of executor plugins at the workflow level. If any plugin is defined here, the corresponding settings from the ConfigMap are ignored.|
892+
|`executorPlugins`|`Array<`[`ExecutorPlugin`](#executorplugin)`>`|Specifies executor plugins at the workflow level. This field is effective only when the ARGO_WORKFLOW_LEVEL_EXECUTOR_PLUGINS feature gate is enabled. If this field is present (even if empty), executor plugin settings from the controller ConfigMap are ignored. If this field is not set, the controller falls back to the ConfigMap configuration.|
893893
|`hooks`|[`LifecycleHook`](#lifecyclehook)|Hooks holds the lifecycle hook which is invoked at lifecycle of step, irrespective of the success, failure, or error status of the primary step|
894894
|`hostAliases`|`Array<`[`HostAlias`](#hostalias)`>`|_No description available_|
895895
|`hostNetwork`|`boolean`|Host networking requested for this workflow pod. Default to false.|
@@ -1660,11 +1660,12 @@ ExecutorConfig holds configurations of an executor container.
16601660

16611661
## ExecutorPlugin
16621662

1663-
ExecutorPlugin describe workflow level executor plugin settings
1663+
ExecutorPlugin describes workflow-level executor plugin
16641664

16651665
### Fields
16661666
| Field Name | Field Type | Description |
16671667
|:----------:|:----------:|---------------|
1668+
|`metadata`|[`ObjectMeta`](#objectmeta)|_No description available_|
16681669
|`spec`|[`ExecutorPluginSpec`](#executorpluginspec)|_No description available_|
16691670

16701671
## LifecycleHook
@@ -3947,7 +3948,7 @@ _No description available_
39473948
| Field Name | Field Type | Description |
39483949
|:----------:|:----------:|---------------|
39493950
|`automountServiceAccountToken`|`boolean`|AutomountServiceAccount mounts the service account's token. The service account must have the same name as the plugin.|
3950-
|`container`|[`Container`](#container)|_No description available_|
3951+
|`container`|[`Container`](#container)|Container defines the Kubernetes container specification for the sidecar.|
39513952

39523953
## Counter
39533954

manifests/base/crds/full/argoproj.io_clusterworkflowtemplates.yaml

Lines changed: 33 additions & 6 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

manifests/base/crds/full/argoproj.io_cronworkflows.yaml

Lines changed: 34 additions & 6 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

manifests/base/crds/full/argoproj.io_workflows.yaml

Lines changed: 33 additions & 6 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

manifests/base/crds/full/argoproj.io_workflowtemplates.yaml

Lines changed: 33 additions & 6 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)