Skip to content

Commit

Permalink
Fix argo lint errors in misc folder
Browse files Browse the repository at this point in the history
Signed-off-by: Ukjae Jeong <[email protected]>
  • Loading branch information
jeongukjae committed Oct 17, 2024
1 parent bc12280 commit 889f911
Show file tree
Hide file tree
Showing 15 changed files with 24 additions and 8 deletions.
3 changes: 2 additions & 1 deletion docs/examples/workflows/misc/data.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
Workflow,
)

with Workflow(generate_name="data-") as w:
with Workflow(generate_name="data-", entrypoint="list-log-files") as w:
Data(
name="list-log-files",
source=S3Artifact(name="test-bucket", bucket="my-bucket"),
Expand All @@ -33,6 +33,7 @@
metadata:
generateName: data-
spec:
entrypoint: list-log-files
templates:
- data:
source:
Expand Down
2 changes: 2 additions & 0 deletions docs/examples/workflows/misc/env.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@

with Workflow(generate_name="secret-env-from-", entrypoint="whalesay") as w:
whalesay = Container(
name="whalesay",
image="docker/whalesay:latest",
command=["cowsay"],
env_from=[
Expand Down Expand Up @@ -76,5 +77,6 @@
optional: false
prefix: abc
image: docker/whalesay:latest
name: whalesay
```

2 changes: 2 additions & 0 deletions docs/examples/workflows/misc/env_from.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@

with Workflow(generate_name="secret-env-from-", entrypoint="whalesay") as w:
whalesay = Container(
name="whalesay",
image="docker/whalesay:latest",
command=["cowsay"],
env_from=[
Expand Down Expand Up @@ -44,5 +45,6 @@
optional: false
prefix: abc
image: docker/whalesay:latest
name: whalesay
```

6 changes: 4 additions & 2 deletions docs/examples/workflows/misc/http.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,10 +11,10 @@
from hera.expr import g
from hera.workflows import HTTP, Parameter, Workflow

with Workflow(generate_name="http-") as w:
with Workflow(generate_name="http-", entrypoint="http") as w:
HTTP(
name="http",
inputs=[Parameter(name="url")],
inputs=[Parameter(name="url", value="https://example.com")],
timeout_seconds=20,
url=f"{g.inputs.parameters.url:$}",
method="GET",
Expand All @@ -32,6 +32,7 @@
metadata:
generateName: http-
spec:
entrypoint: http
templates:
- http:
body: test body
Expand All @@ -45,6 +46,7 @@
inputs:
parameters:
- name: url
value: https://example.com
name: http
```

3 changes: 2 additions & 1 deletion docs/examples/workflows/misc/suspend.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
```python linenums="1"
from hera.workflows import Parameter, Suspend, Workflow

with Workflow(generate_name="suspend-") as w:
with Workflow(generate_name="suspend-", entrypoint="suspend-without-duration") as w:
Suspend(name="suspend-without-duration")
Suspend(name="suspend-with-duration", duration=30)
Suspend(
Expand All @@ -31,6 +31,7 @@
metadata:
generateName: suspend-
spec:
entrypoint: suspend-without-duration
templates:
- name: suspend-without-duration
suspend: {}
Expand Down
2 changes: 1 addition & 1 deletion examples/workflows/misc/data.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
Workflow,
)

with Workflow(generate_name="data-") as w:
with Workflow(generate_name="data-", entrypoint="list-log-files") as w:
Data(
name="list-log-files",
source=S3Artifact(name="test-bucket", bucket="my-bucket"),
Expand Down
1 change: 1 addition & 0 deletions examples/workflows/misc/data.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ kind: Workflow
metadata:
generateName: data-
spec:
entrypoint: list-log-files
templates:
- data:
source:
Expand Down
1 change: 1 addition & 0 deletions examples/workflows/misc/env-from.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -18,3 +18,4 @@ spec:
optional: false
prefix: abc
image: docker/whalesay:latest
name: whalesay
1 change: 1 addition & 0 deletions examples/workflows/misc/env.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@

with Workflow(generate_name="secret-env-from-", entrypoint="whalesay") as w:
whalesay = Container(
name="whalesay",
image="docker/whalesay:latest",
command=["cowsay"],
env_from=[
Expand Down
1 change: 1 addition & 0 deletions examples/workflows/misc/env.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -35,3 +35,4 @@ spec:
optional: false
prefix: abc
image: docker/whalesay:latest
name: whalesay
1 change: 1 addition & 0 deletions examples/workflows/misc/env_from.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@

with Workflow(generate_name="secret-env-from-", entrypoint="whalesay") as w:
whalesay = Container(
name="whalesay",
image="docker/whalesay:latest",
command=["cowsay"],
env_from=[
Expand Down
4 changes: 2 additions & 2 deletions examples/workflows/misc/http.py
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
from hera.expr import g
from hera.workflows import HTTP, Parameter, Workflow

with Workflow(generate_name="http-") as w:
with Workflow(generate_name="http-", entrypoint="http") as w:
HTTP(
name="http",
inputs=[Parameter(name="url")],
inputs=[Parameter(name="url", value="https://example.com")],
timeout_seconds=20,
url=f"{g.inputs.parameters.url:$}",
method="GET",
Expand Down
2 changes: 2 additions & 0 deletions examples/workflows/misc/http.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ kind: Workflow
metadata:
generateName: http-
spec:
entrypoint: http
templates:
- http:
body: test body
Expand All @@ -16,4 +17,5 @@ spec:
inputs:
parameters:
- name: url
value: https://example.com
name: http
2 changes: 1 addition & 1 deletion examples/workflows/misc/suspend.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
from hera.workflows import Parameter, Suspend, Workflow

with Workflow(generate_name="suspend-") as w:
with Workflow(generate_name="suspend-", entrypoint="suspend-without-duration") as w:
Suspend(name="suspend-without-duration")
Suspend(name="suspend-with-duration", duration=30)
Suspend(
Expand Down
1 change: 1 addition & 0 deletions examples/workflows/misc/suspend.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ kind: Workflow
metadata:
generateName: suspend-
spec:
entrypoint: suspend-without-duration
templates:
- name: suspend-without-duration
suspend: {}
Expand Down

0 comments on commit 889f911

Please sign in to comment.