Overview
An exec
pipeline executes shell commands directly on the host machine without isolation. This is useful for workloads that need to run on the host, or are poorly suited for execution inside containers.
Example pipeline configuration:
1 ---
2 kind: pipeline
3 type: exec
4 name: default
5
6 platform:
7 os: linux
8 arch: amd64
9
10 steps:
11 - name: greeting
12 commands:
13 - echo hello world
14
15 ...
The kind and type attributes define an exec pipeline.
1 ---
2 kind: pipeline
3 type: exec
The platform section configures the target operating system and architecture, and ensures the pipeline is routed to the appropriate instance:
6 platform:
7 os: linux
8 arch: amd64
The steps section defines a series of shell commands. These commands are executed using the default shell on posix, and powershell on windows. If any command returns a non-zero exit code, the pipeline fails and exits.
10 steps:
11 - name: greeting
12 commands:
13 - echo hello world