yaml
type: "io.kestra.plugin.docker.run"
yaml
id: docker_run
namespace: company.team

tasks:
  - id: run
    type: io.kestra.plugin.docker.Run
    containerImage: alpine:latest

yaml
id: docker_run
namespace: company.team

tasks:
  - id: write
    type: io.kestra.plugin.core.storage.Write
       content: |
         extensions:
           health_check: {}

         receivers:
           otlp:
             protocols:
               grpc:
                 endpoint: 0.0.0.0:4317
               http:
                 endpoint: 0.0.0.0:4318

         exporters:
           debug: {}

         service:
           pipelines:
             logs:
               receivers: [otlp]
               exporters: [debug]
       extension: .yaml

  - id: run
    type: io.kestra.plugin.docker.Run
    containerImage: otel/opentelemetry-collector:latest
    inputFiles:
      otel.yaml: "{{ outputs.write.uri }}"
    commands:
      - --config
      - otel.yaml
    portBindings:
      - "4318:4318"
    wait: false

yaml
id: docker_run_with_output_file
namespace: company.team

inputs:
  - id: greetings
    type: STRING
    defaults: HELLO WORLD !!

tasks:
  - id: docker_run_output_file
    type: io.kestra.plugin.docker.Run
    containerImage: ubuntu:22.04
    commands:
      - "/bin/sh"
      - "-c"
      - echo {{ inputs.greetings }} > file.txt
    outputFiles:
      - file.txt

  - id: log
    type: io.kestra.plugin.core.log.Log
    message: "{{ read(outputs.docker_run_output_file.outputFiles['file.txt']) }}"
Properties
SubTypestring
Default[]
Definitions
cpusnumberstring
Definitions
authstring
identityTokenstring
passwordstring
registrystring
registryTokenstring
usernamestring
Definitions
capabilitiesarray
SubTypearray
countintegerstring
deviceIdsarray
SubTypestring
driverstring
optionsobject
SubTypestring
SubTypestring
SubTypestring
SubTypestring
Definitions
kernelMemorystring
memorystring
memoryReservationstring
memorySwapstring
memorySwappinessstring
oomKillDisablebooleanstring
Definitions
enabledbooleanstring
Defaulttrue
excludearray
SubTypestring
folderPerNamespacebooleanstring
Defaultfalse
ifExistsstring
DefaultOVERWRITE
Possible Values
OVERWRITEFAILWARNIGNORE
includearray
SubTypestring
namespacesarray
SubTypestring
Default["{{flow.namespace}}"]
SubTypestring
SubTypestring
DefaultIF_NOT_PRESENT
Possible Values
IF_NOT_PRESENTALWAYSNEVER
SubTypestring
Defaulttrue
Default0
SubTypestring
Definitions