Skip to content
This repository was archived by the owner on Oct 9, 2023. It is now read-only.

Commit 5b50d88

Browse files
authored
Added support for EnvironmentVariables on ExecutionConfig (#558)
* added environment variables to ExecutionConfig and propagated to taskExecutionMetadata Signed-off-by: Daniel Rammer <[email protected]> * fixed unit tests Signed-off-by: Daniel Rammer <[email protected]> * updated flyteplugins Signed-off-by: Daniel Rammer <[email protected]> --------- Signed-off-by: Daniel Rammer <[email protected]>
1 parent 0025cbe commit 5b50d88

File tree

48 files changed

+62
-11
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

48 files changed

+62
-11
lines changed

go.mod

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,8 @@ require (
66
github.com/DiSiqueira/GoTree v1.0.1-0.20180907134536-53a8e837f295
77
github.com/benlaurie/objecthash v0.0.0-20180202135721-d1e3d6079fc1
88
github.com/fatih/color v1.13.0
9-
github.com/flyteorg/flyteidl v1.3.14
10-
github.com/flyteorg/flyteplugins v1.0.52
9+
github.com/flyteorg/flyteidl v1.3.19
10+
github.com/flyteorg/flyteplugins v1.0.56
1111
github.com/flyteorg/flytestdlib v1.0.15
1212
github.com/ghodss/yaml v1.0.0
1313
github.com/go-redis/redis v6.15.7+incompatible

go.sum

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -260,10 +260,10 @@ github.com/fatih/color v1.7.0/go.mod h1:Zm6kSWBoL9eyXnKyktHP6abPY2pDugNf5Kwzbycv
260260
github.com/fatih/color v1.13.0 h1:8LOYc1KYPPmyKMuN8QV2DNRWNbLo6LZ0iLs8+mlH53w=
261261
github.com/fatih/color v1.13.0/go.mod h1:kLAiJbzzSOZDVNGyDpeOxJ47H46qBXwg5ILebYFFOfk=
262262
github.com/felixge/httpsnoop v1.0.1/go.mod h1:m8KPJKqk1gH5J9DgRY2ASl2lWCfGKXixSwevea8zH2U=
263-
github.com/flyteorg/flyteidl v1.3.14 h1:o5M0g/r6pXTPu5PEurbYxbQmuOu3hqqsaI2M6uvK0N8=
264-
github.com/flyteorg/flyteidl v1.3.14/go.mod h1:Pkt2skI1LiHs/2ZoekBnyPhuGOFMiuul6HHcKGZBsbM=
265-
github.com/flyteorg/flyteplugins v1.0.52 h1:AWNrRYgm0bCzOws+bIfJDfPBZqBmTdABxW78r8q3kP4=
266-
github.com/flyteorg/flyteplugins v1.0.52/go.mod h1:ztsonku5fKwyxcIg1k69PTiBVjRI6d3nK5DnC+iwx08=
263+
github.com/flyteorg/flyteidl v1.3.19 h1:i79Dh7UoP8Z4LEJ2ox6jlfZVJtFZ+r4g84CJj1gh22Y=
264+
github.com/flyteorg/flyteidl v1.3.19/go.mod h1:Pkt2skI1LiHs/2ZoekBnyPhuGOFMiuul6HHcKGZBsbM=
265+
github.com/flyteorg/flyteplugins v1.0.56 h1:kBTDgTpdSi7wcptk4cMwz5vfh1MU82VaUMMboe1InXw=
266+
github.com/flyteorg/flyteplugins v1.0.56/go.mod h1:aFCKSn8TPzxSAILIiogHtUnHlUCN9+y6Vf+r9R4KZDU=
267267
github.com/flyteorg/flytestdlib v1.0.15 h1:kv9jDQmytbE84caY+pkZN8trJU2ouSAmESzpTEhfTt0=
268268
github.com/flyteorg/flytestdlib v1.0.15/go.mod h1:ghw/cjY0sEWIIbyCtcJnL/Gt7ZS7gf9SUi0CCPhbz3s=
269269
github.com/flyteorg/stow v0.3.6 h1:jt50ciM14qhKBaIrB+ppXXY+SXB59FNREFgTJqCyqIk=

pkg/apis/flyteworkflow/v1alpha1/execution_config.go

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,8 @@ type ExecutionConfig struct {
3232
Interruptible *bool
3333
// Defines whether a workflow should skip all its cached results and re-compute its output, overwriting any already stored data.
3434
OverwriteCache bool
35+
// Defines a map of environment varable name / value pairs that are applied to all tasks.
36+
EnvironmentVariables map[string]string
3537
}
3638

3739
type TaskPluginOverride struct {

pkg/compiler/test/testdata/snacks-core/k8s/002_core.containerization.multi_images.my_workflow_2_wf.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
apiVersion: flyte.lyft.com/v1alpha1
22
executionConfig:
3+
EnvironmentVariables: null
34
Interruptible: null
45
MaxParallelism: 0
56
OverwriteCache: false

pkg/compiler/test/testdata/snacks-core/k8s/010_core.containerization.raw_container.wf_2_wf.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
apiVersion: flyte.lyft.com/v1alpha1
22
executionConfig:
3+
EnvironmentVariables: null
34
Interruptible: null
45
MaxParallelism: 0
56
OverwriteCache: false

pkg/compiler/test/testdata/snacks-core/k8s/015_core.containerization.use_secrets.my_secret_workflow_2_wf.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
apiVersion: flyte.lyft.com/v1alpha1
22
executionConfig:
3+
EnvironmentVariables: null
34
Interruptible: null
45
MaxParallelism: 0
56
OverwriteCache: false

pkg/compiler/test/testdata/snacks-core/k8s/019_core.control_flow.chain_tasks.chain_tasks_wf_2_wf.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
apiVersion: flyte.lyft.com/v1alpha1
22
executionConfig:
3+
EnvironmentVariables: null
34
Interruptible: null
45
MaxParallelism: 0
56
OverwriteCache: false

pkg/compiler/test/testdata/snacks-core/k8s/022_core.control_flow.checkpoint.example_2_wf.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
apiVersion: flyte.lyft.com/v1alpha1
22
executionConfig:
3+
EnvironmentVariables: null
34
Interruptible: null
45
MaxParallelism: 0
56
OverwriteCache: false

pkg/compiler/test/testdata/snacks-core/k8s/026_core.control_flow.conditions.multiplier_2_wf.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
apiVersion: flyte.lyft.com/v1alpha1
22
executionConfig:
3+
EnvironmentVariables: null
34
Interruptible: null
45
MaxParallelism: 0
56
OverwriteCache: false

pkg/compiler/test/testdata/snacks-core/k8s/028_core.control_flow.conditions.multiplier_2_2_wf.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
apiVersion: flyte.lyft.com/v1alpha1
22
executionConfig:
3+
EnvironmentVariables: null
34
Interruptible: null
45
MaxParallelism: 0
56
OverwriteCache: false

0 commit comments

Comments
 (0)