Skip to content

Commit e2edd9e

Browse files
committed
Add pull policy to run container task
1 parent 6390951 commit e2edd9e

File tree

3 files changed

+18
-0
lines changed

3 files changed

+18
-0
lines changed

dsl-reference.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -931,6 +931,7 @@ Enables the execution of external processes encapsulated within a containerized
931931
| stdin | `string` | `no` | A runtime expression, if any, passed as standard input to the command or default container CMD|
932932
| arguments | `string[]` | `no` | A list of the arguments, if any, passed as argv to the command or default container CMD |
933933
| lifetime | [`containerLifetime`](#container-lifetime) | `no` | An object used to configure the container's lifetime. |
934+
| pullPolicy | `string` | `no` | Policy that controls how the container's image should be pulled from the registry. Defaults to `ifNotPresent` |
934935

935936
###### Examples
936937

@@ -958,6 +959,7 @@ do:
958959
arguments:
959960
- Foo
960961
- Bar
962+
pullPolicy: always
961963
```
962964

963965
> [!NOTE]
Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
document:
2+
dsl: '1.0.2'
3+
namespace: test
4+
name: run-container-with-pull-policy
5+
version: '0.1.0'
6+
do:
7+
- runContainer:
8+
run:
9+
container:
10+
image: hello-world
11+
pullPolicy: always

schema/workflow.yaml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -823,6 +823,11 @@ $defs:
823823
$ref: '#/$defs/containerLifetime'
824824
title: ContainerLifetime
825825
description: An object, if any, used to configure the container's lifetime
826+
pullPolicy:
827+
type: string
828+
title: ContainerPullPolicy
829+
description: Policy that controls how the container's image should be pulled from the registry. Defaults to `ifNotPresent`
830+
enum: [ ifNotPresent, always, never ]
826831
required: [ image ]
827832
required: [ container ]
828833
- title: RunScript

0 commit comments

Comments
 (0)