From 4593d9a0401e3a1756caddd052c797d72f1c63d5 Mon Sep 17 00:00:00 2001 From: Alex Collins Date: Mon, 11 May 2020 13:32:34 -0700 Subject: [PATCH] test: Upgrade to argosay:v2 (#3001) --- Makefile | 14 ++- config/config.go | 26 ++--- docs/fields.md | 2 - examples/forever.yaml | 2 - .../workflow-controller-deployment.yaml | 2 +- test/e2e/argo_server_test.go | 30 ++--- .../expectedfailures/failed-step-event.yaml | 4 +- test/e2e/fixtures/given.go | 1 + test/e2e/functional/stop-terminate.yaml | 8 +- test/e2e/functional/success-event.yaml | 2 +- test/e2e/functional_test.go | 25 ++-- test/e2e/images/argosay/v1/Dockerfile | 17 +++ test/e2e/images/argosay/v2/.gitignore | 1 + test/e2e/images/argosay/v2/Dockerfile | 5 + test/e2e/images/argosay/v2/main/argosay.go | 110 ++++++++++++++++++ .../images/argosay/v2/main/argosay_test.go | 33 ++++++ test/e2e/smoke/artifact-passing.yaml | 18 +-- test/e2e/smoke/basic-2.yaml | 2 +- test/e2e/smoke/basic.yaml | 4 +- ...r-workflow-template-whalesay-template.yaml | 5 +- .../workflow-template-whalesay-template.yaml | 5 +- test/e2e/stress/massive-workflow.yaml | 56 +++++++++ test/e2e/stress/pod-limits.yaml | 8 +- test/e2e/testdata/exit-1.yaml | 2 +- test/e2e/testdata/retry-test.yaml | 5 +- test/e2e/testdata/sleep-3s.yaml | 4 +- .../ui-dag-parameter-aggregation-empty.yaml | 2 +- test/e2e/ui/ui-dag-retries.yaml | 4 +- test/e2e/ui/ui-dag-with-params.yaml | 4 +- test/e2e/ui/ui-nested-steps.yaml | 11 +- .../ui/ui-parameter-aggregation-empty.yaml | 2 +- 31 files changed, 315 insertions(+), 99 deletions(-) create mode 100644 test/e2e/images/argosay/v1/Dockerfile create mode 100644 test/e2e/images/argosay/v2/.gitignore create mode 100644 test/e2e/images/argosay/v2/Dockerfile create mode 100644 test/e2e/images/argosay/v2/main/argosay.go create mode 100644 test/e2e/images/argosay/v2/main/argosay_test.go create mode 100644 test/e2e/stress/massive-workflow.yaml diff --git a/Makefile b/Makefile index a6b38858ab74..0e0f80289e9d 100644 --- a/Makefile +++ b/Makefile @@ -157,7 +157,7 @@ endif @mkdir -p ui/dist touch ui/dist/node_modules.marker -ui/dist/app/index.html: ui/dist/node_modules.marker ui/src +ui/dist/app/index.html: ui/dist/node_modules.marker $(UI_FILES) # Build UI @mkdir -p ui/dist/app ifeq ($(CI),false) @@ -344,9 +344,21 @@ endif pull-build-images: ./hack/pull-build-images.sh +.PHONY: argosay +argosay: test/e2e/images/argosay/v2/argosay + cd test/e2e/images/argosay/v2 && docker build . -t argoproj/argosay:v2 +ifeq ($(K3D),true) + k3d import-images argoproj/argosay:v2 +endif + docker push argoproj/argosay:v2 + +test/e2e/images/argosay/v2/argosay: $(shell find test/e2e/images/argosay/v2/main -type f) + cd test/e2e/images/argosay/v2 && GOOS=linux CGO_ENABLED=0 go build -ldflags '-w -s' -o argosay ./main + .PHONY: test-images test-images: docker pull argoproj/argosay:v1 + docker pull argoproj/argosay:v2 docker pull python:alpine3.6 .PHONY: stop diff --git a/config/config.go b/config/config.go index 8a202b74fc90..02d050293ff6 100644 --- a/config/config.go +++ b/config/config.go @@ -135,7 +135,7 @@ type PersistConfig struct { // in days ArchiveTTL TTL `json:"archiveTTL,omitempty"` ClusterName string `json:"clusterName,omitempty"` - ConnectionPool *ConnectionPool `json:"connectionPool"` + ConnectionPool *ConnectionPool `json:"connectionPool,omitempty"` PostgreSQL *PostgreSQLConfig `json:"postgresql,omitempty"` MySQL *MySQLConfig `json:"mysql,omitempty"` } @@ -148,16 +148,16 @@ func (c PersistConfig) GetClusterName() string { } type ConnectionPool struct { - MaxIdleConns int `json:"maxIdleConns"` - MaxOpenConns int `json:"maxOpenConns"` + MaxIdleConns int `json:"maxIdleConns,omitempty"` + MaxOpenConns int `json:"maxOpenConns,omitempty"` } type PostgreSQLConfig struct { Host string `json:"host"` Port string `json:"port"` Database string `json:"database"` - TableName string `json:"tableName"` - UsernameSecret apiv1.SecretKeySelector `json:"userNameSecret"` - PasswordSecret apiv1.SecretKeySelector `json:"passwordSecret"` + TableName string `json:"tableName,omitempty"` + UsernameSecret apiv1.SecretKeySelector `json:"userNameSecret,omitempty"` + PasswordSecret apiv1.SecretKeySelector `json:"passwordSecret,omitempty"` SSL bool `json:"ssl,omitempty"` SSLMode string `json:"sslMode,omitempty"` } @@ -166,10 +166,10 @@ type MySQLConfig struct { Host string `json:"host"` Port string `json:"port"` Database string `json:"database"` - TableName string `json:"tableName"` - Options map[string]string `json:"options"` - UsernameSecret apiv1.SecretKeySelector `json:"userNameSecret"` - PasswordSecret apiv1.SecretKeySelector `json:"passwordSecret"` + TableName string `json:"tableName,omitempty"` + Options map[string]string `json:"options,omitempty"` + UsernameSecret apiv1.SecretKeySelector `json:"userNameSecret,omitempty"` + PasswordSecret apiv1.SecretKeySelector `json:"passwordSecret,omitempty"` } // S3ArtifactRepository defines the controller configuration for an S3 artifact repository @@ -220,9 +220,9 @@ type HDFSArtifactRepository struct { // PrometheusConfig defines a config for a metrics server type PrometheusConfig struct { - Enabled bool `json:"enabled,omitempty"` - DisableLegacy bool `json:"disableLegacy"` - MetricsTTL TTL `json:"metricsTTL"` + Enabled bool `json:"enabled"` + DisableLegacy bool `json:"disableLegacy,omitempty"` + MetricsTTL TTL `json:"metricsTTL,omitempty"` Path string `json:"path,omitempty"` Port string `json:"port,omitempty"` } diff --git a/docs/fields.md b/docs/fields.md index 5cf4e5cf0895..503aab4c2dbb 100644 --- a/docs/fields.md +++ b/docs/fields.md @@ -3002,8 +3002,6 @@ MetricLabel is a single label for a prometheus metric - [`custom-metrics.yaml`](../examples/custom-metrics.yaml) -- [`forever.yaml`](../examples/forever.yaml) - - [`pod-metadata.yaml`](../examples/pod-metadata.yaml) - [`resource-delete-with-flags.yaml`](../examples/resource-delete-with-flags.yaml) diff --git a/examples/forever.yaml b/examples/forever.yaml index 6fb5139604c4..ee3d7123411f 100644 --- a/examples/forever.yaml +++ b/examples/forever.yaml @@ -3,8 +3,6 @@ apiVersion: argoproj.io/v1alpha1 kind: Workflow metadata: name: forever - labels: - argo-e2e: true spec: entrypoint: main templates: diff --git a/manifests/base/workflow-controller/workflow-controller-deployment.yaml b/manifests/base/workflow-controller/workflow-controller-deployment.yaml index d33a90a43da0..eaeb1d782008 100644 --- a/manifests/base/workflow-controller/workflow-controller-deployment.yaml +++ b/manifests/base/workflow-controller/workflow-controller-deployment.yaml @@ -23,4 +23,4 @@ spec: - --executor-image - argoproj/argoexec:latest nodeSelector: - kubernetes.io/os: linux \ No newline at end of file + kubernetes.io/os: linux diff --git a/test/e2e/argo_server_test.go b/test/e2e/argo_server_test.go index 840df403b71e..1322fe9cda05 100644 --- a/test/e2e/argo_server_test.go +++ b/test/e2e/argo_server_test.go @@ -220,7 +220,7 @@ func (s *ArgoServerSuite) TestPermission() { { "name": "run-workflow", "container": { - "image": "argoproj/argosay:v1", + "image": "argoproj/argosay:v2", "command": ["sh"], "args": ["-c", "sleep 1"] } @@ -268,7 +268,7 @@ func (s *ArgoServerSuite) TestPermission() { { "name": "run-workflow", "container": { - "image": "argoproj/argosay:v1", + "image": "argoproj/argosay:v2", "imagePullPolicy": "IfNotPresent", "command": ["sh"], "args": ["-c", "sleep 1"] @@ -391,7 +391,7 @@ func (s *ArgoServerSuite) TestLintWorkflow() { { "name": "run-workflow", "container": { - "image": "argoproj/argosay:v1", + "image": "argoproj/argosay:v2", "imagePullPolicy": "IfNotPresent" } } @@ -422,7 +422,7 @@ func (s *ArgoServerSuite) TestCreateWorkflowDryRun() { { "name": "run-workflow", "container": { - "image": "argoproj/argosay:v1", + "image": "argoproj/argosay:v2", "imagePullPolicy": "IfNotPresent" } } @@ -456,7 +456,7 @@ func (s *ArgoServerSuite) TestWorkflowService() { { "name": "run-workflow", "container": { - "image": "argoproj/argosay:v1", + "image": "argoproj/argosay:v2", "imagePullPolicy": "IfNotPresent", "command": ["sh"], "args": ["-c", "sleep 10"] @@ -612,7 +612,7 @@ func (s *ArgoServerSuite) TestCronWorkflowService() { { "name": "whalesay", "container": { - "image": "argoproj/argosay:v1", + "image": "argoproj/argosay:v2", "imagePullPolicy": "IfNotPresent" } } @@ -650,7 +650,7 @@ spec: templates: - name: whalesay container: - image: argoproj/argosay:v1 + image: argoproj/argosay:v2 imagePullPolicy: IfNotPresent command: ["sh", -c] args: ["echo hello"] @@ -702,7 +702,7 @@ spec: { "name": "whalesay", "container": { - "image": "argoproj/argosay:v1", + "image": "argoproj/argosay:v2", "imagePullPolicy": "IfNotPresent" } } @@ -865,7 +865,7 @@ spec: templates: - name: run-archie container: - image: argoproj/argosay:v1 + image: argoproj/argosay:v2 command: [cowsay, ":) Hello Argo!"] imagePullPolicy: IfNotPresent`). When(). @@ -887,7 +887,7 @@ spec: templates: - name: run-betty container: - image: argoproj/argosay:v1 + image: argoproj/argosay:v2 command: [cowsay, ":) Hello Argo!"] imagePullPolicy: IfNotPresent`). When(). @@ -1015,7 +1015,7 @@ func (s *ArgoServerSuite) TestWorkflowTemplateService() { "name": "run-workflow", "container": { "name": "", - "image": "argoproj/argosay:v1", + "image": "argoproj/argosay:v2", "imagePullPolicy": "IfNotPresent" } } @@ -1044,7 +1044,7 @@ func (s *ArgoServerSuite) TestWorkflowTemplateService() { "name": "run-workflow", "container": { "name": "", - "image": "argoproj/argosay:v1", + "image": "argoproj/argosay:v2", "imagePullPolicy": "IfNotPresent" } } @@ -1148,7 +1148,7 @@ func (s *ArgoServerSuite) TestSubmitWorkflowFromResource() { "name": "run-workflow", "container": { "name": "", - "image": "argoproj/argosay:v1", + "image": "argoproj/argosay:v2", "imagePullPolicy": "IfNotPresent" } } @@ -1190,7 +1190,7 @@ func (s *ArgoServerSuite) TestSubmitWorkflowFromResource() { { "name": "whalesay", "container": { - "image": "argoproj/argosay:v1", + "image": "argoproj/argosay:v2", "imagePullPolicy": "IfNotPresent" } } @@ -1231,7 +1231,7 @@ func (s *ArgoServerSuite) TestSubmitWorkflowFromResource() { "name": "run-workflow", "container": { "name": "", - "image": "argoproj/argosay:v1", + "image": "argoproj/argosay:v2", "imagePullPolicy": "IfNotPresent" } } diff --git a/test/e2e/expectedfailures/failed-step-event.yaml b/test/e2e/expectedfailures/failed-step-event.yaml index 1d04bae0c6d3..e6c0064b9fe3 100644 --- a/test/e2e/expectedfailures/failed-step-event.yaml +++ b/test/e2e/expectedfailures/failed-step-event.yaml @@ -12,5 +12,5 @@ spec: templates: - name: exit container: - image: argoproj/argosay:v1 - command: [sh, -c, exit 1] + image: argoproj/argosay:v2 + args: [exit, 1] diff --git a/test/e2e/fixtures/given.go b/test/e2e/fixtures/given.go index 5c4d020120a1..fe598dcf6aae 100644 --- a/test/e2e/fixtures/given.go +++ b/test/e2e/fixtures/given.go @@ -76,6 +76,7 @@ func (g *Given) checkImages(templates []wfv1.Template) { imageWhitelist := map[string]bool{ "argoexec:" + imageTag: true, "argoproj/argosay:v1": true, + "argoproj/argosay:v2": true, "python:alpine3.6": true, } for _, t := range templates { diff --git a/test/e2e/functional/stop-terminate.yaml b/test/e2e/functional/stop-terminate.yaml index 2db0bb1cdf76..9c6ea383608f 100644 --- a/test/e2e/functional/stop-terminate.yaml +++ b/test/e2e/functional/stop-terminate.yaml @@ -22,10 +22,10 @@ spec: parameters: - name: message container: - image: argoproj/argosay:v1 - command: [sleep, "10"] + image: argoproj/argosay:v2 + args: [sleep, "10s"] - name: exit container: - image: argoproj/argosay:v1 - command: [echo, "one exit"] + image: argoproj/argosay:v2 + args: [echo, "one exit"] diff --git a/test/e2e/functional/success-event.yaml b/test/e2e/functional/success-event.yaml index 0447e093d1ac..6284969d40d2 100644 --- a/test/e2e/functional/success-event.yaml +++ b/test/e2e/functional/success-event.yaml @@ -12,4 +12,4 @@ spec: templates: - name: exit container: - image: argoproj/argosay:v1 + image: argoproj/argosay:v2 diff --git a/test/e2e/functional_test.go b/test/e2e/functional_test.go index cc1e89e0e12b..07e0c2bad682 100644 --- a/test/e2e/functional_test.go +++ b/test/e2e/functional_test.go @@ -53,12 +53,12 @@ spec: - name: whalesay container: - image: argoproj/argosay:v1 + image: argoproj/argosay:v2 imagePullPolicy: IfNotPresent - name: whalesplosion container: - image: argoproj/argosay:v1 + image: argoproj/argosay:v2 imagePullPolicy: IfNotPresent command: ["sh", "-c", "sleep 5 ; exit 1"] `). @@ -124,12 +124,12 @@ spec: - name: whalesay container: imagePullPolicy: IfNotPresent - image: argoproj/argosay:v1 + image: argoproj/argosay:v2 - name: whalesplosion container: imagePullPolicy: IfNotPresent - image: argoproj/argosay:v1 + image: argoproj/argosay:v2 command: ["sh", "-c", "sleep 10; exit 1"] `). When(). @@ -262,9 +262,8 @@ spec: - name: cowsay resubmitPendingPods: true container: - image: argoproj/argosay:v1 - command: [sh, -c] - args: ["cowsay a"] + image: argoproj/argosay:v2 + args: ["echo", "a"] resources: limits: memory: 128M @@ -314,9 +313,8 @@ spec: retryStrategy: limit: 1 container: - image: argoproj/argosay:v1 - command: [sh, -c] - args: ["cowsay a"] + image: argoproj/argosay:v2 + args: ["echo", "a"] resources: limits: memory: 128M @@ -470,11 +468,8 @@ spec: - name: generate container: - image: argoproj/argosay:v1 - command: [sh, -c] - args: [" - echo 'my-output-parameter' > /tmp/my-output-parameter.txt - "] + image: argoproj/argosay:v2 + args: [echo, my-output-parameter, /tmp/my-output-parameter.txt] outputs: parameters: - name: out-parameter diff --git a/test/e2e/images/argosay/v1/Dockerfile b/test/e2e/images/argosay/v1/Dockerfile new file mode 100644 index 000000000000..870b2676f30f --- /dev/null +++ b/test/e2e/images/argosay/v1/Dockerfile @@ -0,0 +1,17 @@ +FROM ubuntu:14.04 + +RUN apt-get update && \ + apt-get install -y apt-utils ca-certificates apt-transport-https cowsay --no-install-recommends && \ + apt-get clean \ + && rm -rf \ + /var/lib/apt/lists/* \ + /tmp/* \ + /var/tmp/* \ + /usr/share/man \ + /usr/share/doc \ + /usr/share/doc-base + +# "cowsay" installs to /usr/games +ENV PATH $PATH:/usr/games + +CMD ["cowsay"] diff --git a/test/e2e/images/argosay/v2/.gitignore b/test/e2e/images/argosay/v2/.gitignore new file mode 100644 index 000000000000..d91f8b4b0136 --- /dev/null +++ b/test/e2e/images/argosay/v2/.gitignore @@ -0,0 +1 @@ +/argosay diff --git a/test/e2e/images/argosay/v2/Dockerfile b/test/e2e/images/argosay/v2/Dockerfile new file mode 100644 index 000000000000..813ee3a580a5 --- /dev/null +++ b/test/e2e/images/argosay/v2/Dockerfile @@ -0,0 +1,5 @@ +FROM scratch + +ADD argosay / + +ENTRYPOINT ["/argosay"] diff --git a/test/e2e/images/argosay/v2/main/argosay.go b/test/e2e/images/argosay/v2/main/argosay.go new file mode 100644 index 000000000000..b427859c330a --- /dev/null +++ b/test/e2e/images/argosay/v2/main/argosay.go @@ -0,0 +1,110 @@ +package main + +import ( + "errors" + "fmt" + "io" + "io/ioutil" + "os" + "path/filepath" + "strconv" + "time" +) + +func main() { + err := argosay(os.Args[1:]...) + if err != nil { + if exitErr, ok := err.(exitError); ok { + os.Exit(exitErr.code) + } + panic(err) + } +} +func argosay(args ...string) error { + if len(args) == 0 { + args = []string{"echo"} + } + switch args[0] { + case "cat": + return cat(args[1:]) + case "echo": + return echo(args[1:]) + case "exit": + return exit(args[1:]) + case "sleep": + return sleep(args[1:]) + } + return errors.New("usage: argosay [cat [file...]|echo [string] [file]|sleep duration|exit [code]]") +} + +func cat(args []string) error { + for _, file := range args { + open, err := os.Open(file) + if err != nil { + return err + } + _, err = io.Copy(os.Stdout, open) + if err != nil { + return err + } + } + return nil +} + +func echo(args []string) error { + switch len(args) { + case 0: + println("hello argo") + return nil + case 1: + println(args[0]) + return nil + case 2: + file := args[1] + err := os.MkdirAll(filepath.Dir(file), 0777) + if err != nil { + return err + } + err = ioutil.WriteFile(file, []byte(args[0]), 0666) + if err != nil { + return err + } + return nil + } + return errors.New("usage: argosay echo [string] [file]") +} + +type exitError struct { + code int +} + +func (e exitError) Error() string { + return fmt.Sprintf("exit code %v", e.code) +} + +func exit(args []string) error { + switch len(args) { + case 1: + code, err := strconv.Atoi(args[0]) + if err != nil { + return err + } + if code != 0 { + return exitError{code} + } + } + return nil +} + +func sleep(args []string) error { + switch len(args) { + case 1: + duration, err := time.ParseDuration(args[0]) + if err != nil { + return err + } + time.Sleep(duration) + return nil + } + return errors.New("usage: argosay sleep duration") +} diff --git a/test/e2e/images/argosay/v2/main/argosay_test.go b/test/e2e/images/argosay/v2/main/argosay_test.go new file mode 100644 index 000000000000..3fd4fc8546b9 --- /dev/null +++ b/test/e2e/images/argosay/v2/main/argosay_test.go @@ -0,0 +1,33 @@ +package main + +import ( + "testing" + + "github.com/stretchr/testify/assert" +) + +func Test(t *testing.T) { + t.Run("root", func(t *testing.T) { + assert.NoError(t, argosay()) + assert.Error(t, argosay("garbage")) + }) + t.Run("echo", func(t *testing.T) { + assert.NoError(t, argosay("echo")) + assert.NoError(t, argosay("echo", "foo")) + assert.NoError(t, argosay("echo", "foo", "/tmp/foo")) + assert.Error(t, argosay("echo", "foo", "/tmp/foo", "garbage")) + }) + t.Run("cat", func(t *testing.T) { + assert.NoError(t, argosay("cat", "/tmp/foo", "/tmp/foo")) + assert.Error(t, argosay("cat", "/tmp/non")) + }) + t.Run("sleep", func(t *testing.T) { + assert.NoError(t, argosay("sleep", "1s")) + assert.Error(t, argosay("sleep", "garbage")) + }) + t.Run("exit", func(t *testing.T) { + assert.NoError(t, argosay("exit")) + assert.NoError(t, argosay("exit", "0")) + assert.Equal(t, exitError{1}, argosay("exit", "1")) + }) +} diff --git a/test/e2e/smoke/artifact-passing.yaml b/test/e2e/smoke/artifact-passing.yaml index e66752b02597..f7f0ecebe3f5 100644 --- a/test/e2e/smoke/artifact-passing.yaml +++ b/test/e2e/smoke/artifact-passing.yaml @@ -28,10 +28,8 @@ spec: - name: generate-message container: - image: argoproj/argosay:v1 - command: [sh, -c] - args: ["cowsay hello world | tee /tmp/hello_world.txt"] - imagePullPolicy: IfNotPresent + image: argoproj/argosay:v2 + args: ["echo", "hello world", "/tmp/hello_world.txt"] outputs: artifacts: - name: hello-art @@ -43,10 +41,8 @@ spec: - name: message path: /tmp/message container: - image: argoproj/argosay:v1 - imagePullPolicy: IfNotPresent - command: [sh, -c] - args: ["cat /tmp/message"] + image: argoproj/argosay:v2 + args: ["cat", "/tmp/message"] - name: print-message-with-volume inputs: @@ -57,7 +53,5 @@ spec: volumeMounts: - mountPath: /test-volume name: test-volume - image: argoproj/argosay:v1 - imagePullPolicy: IfNotPresent - command: [sh, -c] - args: ["cat /test-volume/message"] + image: argoproj/argosay:v2 + args: ["cat", "/test-volume/message"] diff --git a/test/e2e/smoke/basic-2.yaml b/test/e2e/smoke/basic-2.yaml index 1ec1c38f6d55..2848be5f309a 100644 --- a/test/e2e/smoke/basic-2.yaml +++ b/test/e2e/smoke/basic-2.yaml @@ -9,5 +9,5 @@ spec: templates: - name: run-workflow container: - image: argoproj/argosay:v1 + image: argoproj/argosay:v2 imagePullPolicy: IfNotPresent \ No newline at end of file diff --git a/test/e2e/smoke/basic.yaml b/test/e2e/smoke/basic.yaml index b7ce4f6e1964..18fa9e0dc0cb 100644 --- a/test/e2e/smoke/basic.yaml +++ b/test/e2e/smoke/basic.yaml @@ -9,6 +9,6 @@ spec: templates: - name: run-workflow container: - image: argoproj/argosay:v1 - command: [cowsay, ":) Hello Argo!"] + image: argoproj/argosay:v2 + args: [echo, ":) Hello Argo!"] imagePullPolicy: IfNotPresent \ No newline at end of file diff --git a/test/e2e/smoke/cluster-workflow-template-whalesay-template.yaml b/test/e2e/smoke/cluster-workflow-template-whalesay-template.yaml index 182993f70bbd..1d64db295c7a 100644 --- a/test/e2e/smoke/cluster-workflow-template-whalesay-template.yaml +++ b/test/e2e/smoke/cluster-workflow-template-whalesay-template.yaml @@ -16,7 +16,6 @@ spec: parameters: - name: message container: - image: argoproj/argosay:v1 - command: [cowsay] - args: ["{{inputs.parameters.message}}"] + image: argoproj/argosay:v2 + args: ["echo", "{{inputs.parameters.message}}"] imagePullPolicy: IfNotPresent diff --git a/test/e2e/smoke/workflow-template-whalesay-template.yaml b/test/e2e/smoke/workflow-template-whalesay-template.yaml index 297b2218c0f1..704e79bad8ca 100644 --- a/test/e2e/smoke/workflow-template-whalesay-template.yaml +++ b/test/e2e/smoke/workflow-template-whalesay-template.yaml @@ -16,7 +16,6 @@ spec: parameters: - name: message container: - image: argoproj/argosay:v1 - command: [cowsay] - args: ["{{inputs.parameters.message}}"] + image: argoproj/argosay:v2 + args: ["echo", "{{inputs.parameters.message}}"] imagePullPolicy: IfNotPresent diff --git a/test/e2e/stress/massive-workflow.yaml b/test/e2e/stress/massive-workflow.yaml new file mode 100644 index 000000000000..e1886e7ea421 --- /dev/null +++ b/test/e2e/stress/massive-workflow.yaml @@ -0,0 +1,56 @@ +# massive workflows +# DAGs with 9 tasks a piece +apiVersion: argoproj.io/v1alpha1 +kind: Workflow +metadata: + name: massive-workflow +spec: + entrypoint: main + arguments: + parameters: + - name: limit + value: 1000 + + podGC: + strategy: OnPodCompletion + + templates: + - name: main + steps: + - - name: dag + template: dag + withSequence: + count: "{{workflow.parameters.limit}}" + - name: dag + dag: + tasks: + - name: A + template: whalesay + - name: B + template: whalesay + dependencies: [A] + - name: C + template: whalesay + dependencies: [A] + - name: D + template: whalesay + dependencies: [B, C] + - name: E + template: whalesay + dependencies: [B, C] + - name: F + template: whalesay + dependencies: [B, C] + - name: G + template: whalesay + dependencies: [D, E, F] + - name: H + template: whalesay + dependencies: [D, E, F] + - name: I + template: whalesay + dependencies: [D, E, F] + - name: whalesay + container: + image: argoproj/argosay:v2 + args: [sleep, 1s] diff --git a/test/e2e/stress/pod-limits.yaml b/test/e2e/stress/pod-limits.yaml index b067e7eac5a6..bfe03c8f6eff 100644 --- a/test/e2e/stress/pod-limits.yaml +++ b/test/e2e/stress/pod-limits.yaml @@ -10,6 +10,9 @@ spec: - name: limit value: 1000 + podGC: + strategy: OnPodCompletion + templates: - name: pod-limits steps: @@ -20,6 +23,5 @@ spec: - name: run-pod container: - image: "alpine:3.7" - command: [sh, -c] - args: ["echo sleeping 1s; sleep 1"] + image: argoproj/argosay:v2 + args: [sleep, 1s] diff --git a/test/e2e/testdata/exit-1.yaml b/test/e2e/testdata/exit-1.yaml index a9f027d293e7..77b33bfff595 100644 --- a/test/e2e/testdata/exit-1.yaml +++ b/test/e2e/testdata/exit-1.yaml @@ -9,6 +9,6 @@ spec: templates: - name: exit container: - image: argoproj/argosay:v1 + image: argoproj/argosay:v2 command: [sh, -c, "exit 1"] imagePullPolicy: IfNotPresent \ No newline at end of file diff --git a/test/e2e/testdata/retry-test.yaml b/test/e2e/testdata/retry-test.yaml index 3e61d74e7083..5d117447ecf4 100644 --- a/test/e2e/testdata/retry-test.yaml +++ b/test/e2e/testdata/retry-test.yaml @@ -26,6 +26,5 @@ spec: - name: whalesay container: - image: argoproj/argosay:v1 - command: [cowsay] - args: ["hello world"] \ No newline at end of file + image: argoproj/argosay:v2 + args: [echo, "hello world"] \ No newline at end of file diff --git a/test/e2e/testdata/sleep-3s.yaml b/test/e2e/testdata/sleep-3s.yaml index 70ee70b0ce4e..bc13a89c32f8 100644 --- a/test/e2e/testdata/sleep-3s.yaml +++ b/test/e2e/testdata/sleep-3s.yaml @@ -9,5 +9,5 @@ spec: templates: - name: sleep-3s container: - image: argoproj/argosay:v1 - command: [sh, -c, "sleep 3"] + image: argoproj/argosay:v2 + args: ["sleep", "3s"] diff --git a/test/e2e/ui/ui-dag-parameter-aggregation-empty.yaml b/test/e2e/ui/ui-dag-parameter-aggregation-empty.yaml index 6001e998d694..86f0c90b9f36 100644 --- a/test/e2e/ui/ui-dag-parameter-aggregation-empty.yaml +++ b/test/e2e/ui/ui-dag-parameter-aggregation-empty.yaml @@ -34,7 +34,7 @@ spec: parameters: - name: message script: - image: alpine:latest + image: argoproj/argosay:v1 command: [sh, -x] source: | #!/bin/sh diff --git a/test/e2e/ui/ui-dag-retries.yaml b/test/e2e/ui/ui-dag-retries.yaml index fb0ce340e4b7..6120390a90f4 100644 --- a/test/e2e/ui/ui-dag-retries.yaml +++ b/test/e2e/ui/ui-dag-retries.yaml @@ -11,8 +11,8 @@ spec: parameters: - name: message container: - image: alpine:3.7 - command: [echo, "{{inputs.parameters.message}}"] + image: argoproj/argosay:v2 + args: [echo, "{{inputs.parameters.message}}"] retryStrategy: limit: 1 - name: echo-thrice diff --git a/test/e2e/ui/ui-dag-with-params.yaml b/test/e2e/ui/ui-dag-with-params.yaml index 9756cda593e3..61e3a3555d4f 100644 --- a/test/e2e/ui/ui-dag-with-params.yaml +++ b/test/e2e/ui/ui-dag-with-params.yaml @@ -11,8 +11,8 @@ spec: parameters: - name: message container: - image: alpine:latest - command: [echo, "{{inputs.parameters.message}}"] + image: argoproj/argosay:v2 + args: [echo, "{{inputs.parameters.message}}"] - name: subpipeline-a dag: diff --git a/test/e2e/ui/ui-nested-steps.yaml b/test/e2e/ui/ui-nested-steps.yaml index c091c6827a24..85afa7ad5410 100644 --- a/test/e2e/ui/ui-nested-steps.yaml +++ b/test/e2e/ui/ui-nested-steps.yaml @@ -26,10 +26,8 @@ spec: - name: locate-faces container: - image: alpine:latest - command: [sh, -c] - args: - - echo '[1, 2, 3]' > /workdir/result.json + image: argoproj/argosay:v2 + args: [echo, "[1, 2, 3]", /workdir/result.json] volumeMounts: - name: workdir mountPath: /workdir @@ -48,6 +46,5 @@ spec: - name: noop container: - image: alpine:latest - command: ["sh", "-c"] - args: ["sleep 1"] + image: argoproj/argosay:v2 + args: ["sleep", "1s"] diff --git a/test/e2e/ui/ui-parameter-aggregation-empty.yaml b/test/e2e/ui/ui-parameter-aggregation-empty.yaml index 99df884ed1a8..21c67926a096 100644 --- a/test/e2e/ui/ui-parameter-aggregation-empty.yaml +++ b/test/e2e/ui/ui-parameter-aggregation-empty.yaml @@ -38,7 +38,7 @@ spec: parameters: - name: message script: - image: alpine:latest + image: argoproj/argosay:v1 command: [sh, -x] source: | #!/bin/sh