Overview

Please note exec pipelines are disabled on Drone Cloud. This feature is only available when self-hosting

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
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
---
kind: pipeline
type: exec
name: default

platform:
  os: linux
  arch: amd64

steps:
- name: greeting
  commands:
  - echo hello world

...

The kind and type attributes define an exec pipeline.

1
2
3
---
kind: pipeline
type: exec

The platform section configures the target operating system and architecture, and ensures the pipeline is routed to the appropriate instance:

6
7
8
platform:
  os: linux
  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
11
12
13
steps:
- name: greeting
  commands:
  - echo hello world