DbtCLI
DbtCLI Certified

Run dbt commands via CLI

yaml
type: io.kestra.plugin.dbt.cli.DbtCLI
yaml
id: dbt_build
namespace: company.team

tasks:
  - id: dbt
    type: io.kestra.plugin.core.flow.WorkingDirectory
    tasks:
      - id: cloneRepository
        type: io.kestra.plugin.git.Clone
        url: https://github.com/kestra-io/dbt-example
        branch: main

      - id: dbt-build
        type: io.kestra.plugin.dbt.cli.DbtCLI
        containerImage: ghcr.io/kestra-io/dbt-duckdb:latest
        taskRunner:
          type: io.kestra.plugin.scripts.runner.docker.Docker
        commands:
          - dbt build
        profiles: |
          my_dbt_project:
            outputs:
              dev:
                type: duckdb
                path: ":memory:"
            target: dev

yaml
id: dbt_build
namespace: company.team

tasks:
  - id: sync
    type: io.kestra.plugin.git.SyncNamespaceFiles
    url: https://github.com/kestra-io/dbt-example
    branch: master
    namespace: "{{ flow.namespace }}"
    gitDirectory: dbt
    dryRun: false

  - id: dbt_build
    type: io.kestra.plugin.dbt.cli.DbtCLI
    containerImage: ghcr.io/kestra-io/dbt-duckdb:latest
    namespaceFiles:
      enabled: true
      exclude:
        - profiles.yml
    taskRunner:
      type: io.kestra.plugin.scripts.runner.docker.Docker
    commands:
      - dbt build
    profiles: |
      my_dbt_project:
        outputs:
          prod:
            type: duckdb
            path: ":memory:"
            schema: main
            threads: 8
        target: prod

yaml
id: dbt_custom_dependencies
namespace: company.team

inputs:
  - id: dbt_version
    type: STRING
    defaults: "dbt-duckdb==1.6.0"

tasks:
  - id: git
    type: io.kestra.plugin.core.flow.WorkingDirectory
    tasks:
      - id: clone_repository
        type: io.kestra.plugin.git.Clone
        url: https://github.com/kestra-io/dbt-example
        branch: main

      - id: dbt
        type: io.kestra.plugin.dbt.cli.DbtCLI
        taskRunner:
          type: io.kestra.plugin.scripts.runner.docker.Docker
          memory:
            memory: 1GB
        containerImage: python:3.11-slim
        beforeCommands:
          - pip install uv
          - uv venv --quiet
          - . .venv/bin/activate --quiet
          - uv pip install --quiet {{ inputs.dbt_version }}
        commands:
          - dbt deps
          - dbt build
        profiles: |
          my_dbt_project:
            outputs:
              dev:
                type: duckdb
                path: ":memory:"
                fixed_retries: 1
                threads: 16
                timeout_seconds: 300
            target: dev

yaml
id: dwh_and_analytics
namespace: company.team

tasks:
  - id: dbt
    type: io.kestra.plugin.core.flow.WorkingDirectory
    tasks:
    - id: clone_repository
      type: io.kestra.plugin.git.Clone
      url: https://github.com/kestra-io/dbt-example
      branch: master

    - id: dbt_build
      type: io.kestra.plugin.dbt.cli.DbtCLI
      taskRunner:
        type: io.kestra.plugin.scripts.runner.docker.Docker
      containerImage: ghcr.io/kestra-io/dbt-duckdb:latest
      commands:
        - dbt deps --target prod
        - dbt build --target prod
      projectDir: dbt
      profiles: |
        my_dbt_project:
          outputs:
            dev:
              type: duckdb
              path: dbt.duckdb
              extensions:
                - parquet
              fixed_retries: 1
              threads: 16
              timeout_seconds: 300
            prod:
              type: duckdb
              path: dbt2.duckdb
              extensions:
                - parquet
              fixed_retries: 1
              threads: 16
              timeout_seconds: 300
          target: dev

yaml
id: dbt_defer
namespace: company.team
inputs:
  - id: dbt_command
    type: SELECT
    allowCustomValue: true
    defaults: dbt build --project-dir dbt --target prod --no-partial-parse
    values:
      - dbt build --target prod --no-partial-parse
      - dbt build --target prod --no-partial-parse --select state:modified+ --defer --state ./target

tasks:
  - id: dbt
    type: io.kestra.plugin.core.flow.WorkingDirectory
    tasks:
      - id: clone_repository
        type: io.kestra.plugin.git.Clone
        url: https://github.com/kestra-io/dbt-example
        branch: master

      - id: dbt_build
        type: io.kestra.plugin.dbt.cli.DbtCLI
        taskRunner:
          type: io.kestra.plugin.scripts.runner.docker.Docker
          delete: true
        containerImage: ghcr.io/kestra-io/dbt-duckdb:latest
        loadManifest:
          key: manifest.json
          namespace: "{{ flow.namespace }}"
        storeManifest:
          key: manifest.json
          namespace: "{{ flow.namespace }}"
        projectDir: dbt
        commands:
          - "{{ inputs.dbt_command }}"
        profiles: |
          my_dbt_project:
            outputs:
              dev:
                type: duckdb
                path: ":memory:"
                fixed_retries: 1
                threads: 16
                timeout_seconds: 300
              prod:
                type: duckdb
                path: dbt2.duckdb
                extensions:
                  - parquet
                fixed_retries: 1
                threads: 16
                timeout_seconds: 300
            target: dev
Properties
SubTypestring
SubTypestring
Defaultghcr.io/kestra-io/dbt
DefaultCORE
Possible Values
COREFUSION
SubTypestring
Defaulttrue
SubTypestring
Default["/bin/sh","-c"]
Definitions
key*Requiredstring
namespace*Requiredstring
DefaultJSON
Possible Values
JSONTEXTDEBUGNONE
Definitions
enabledbooleanstring
Defaulttrue
excludearray
SubTypestring
folderPerNamespacebooleanstring
Defaultfalse
ifExistsstring
DefaultOVERWRITE
Possible Values
OVERWRITEFAILWARNIGNORE
includearray
SubTypestring
namespacesarray
SubTypestring
Default["{{flow.namespace}}"]
SubTypestring
Defaulttrue
Definitions
key*Requiredstring
namespace*Requiredstring
DefaultAUTO
Possible Values
LINUXWINDOWSAUTO
Definitions
Example
yaml
id: simple_shell_example
namespace: company.team

tasks:
  - id: shell
    type: io.kestra.plugin.scripts.shell.Commands
    taskRunner:
      type: io.kestra.plugin.scripts.runner.docker.Docker
    commands:
    - echo "Hello World"

yaml
id: shell_example_with_files
namespace: company.team

inputs:
  - id: file
    type: FILE

tasks:
  - id: shell
    type: io.kestra.plugin.scripts.shell.Commands
    inputFiles:
      data.txt: "{{ inputs.file }}"
    outputFiles:
      - "*.txt"
    containerImage: centos
    taskRunner:
      type: io.kestra.plugin.scripts.runner.docker.Docker
    commands:
    - cp {{ workingDir }}/data.txt {{ workingDir }}/out.txt

yaml
id: allocate_memory_to_python_script
namespace: company.team

tasks:
  - id: script
    type: io.kestra.plugin.scripts.python.Script
    taskRunner:
      type: io.kestra.plugin.scripts.runner.docker.Docker
      pullPolicy: IF_NOT_PRESENT
      cpu:
        cpus: 1
      memory: 
        memory: "512Mb"
    containerImage: ghcr.io/kestra-io/kestrapy:latest
    script: |
      from kestra import Kestra
      
      data = dict(message="Hello from Kestra!")
      Kestra.outputs(data)
type*Requiredobject
configstringobject
cpu
cpusnumberstring
credentials
authstring
identityTokenstring
passwordstring
registrystring
registryTokenstring
usernamestring
deletebooleanstring
Defaulttrue
deviceRequestsarray
capabilitiesarray
SubTypearray
countintegerstring
deviceIdsarray
SubTypestring
driverstring
optionsobject
SubTypestring
entryPointarray
SubTypestring
Default[ "" ]
extraHostsarray
SubTypestring
fileHandlingStrategystring
DefaultVOLUME
Possible Values
MOUNTVOLUME
hoststring
killGracePeriodstring
DefaultPT0S
Formatduration
memory
kernelMemorystring
memorystring
memoryReservationstring
memorySwapstring
memorySwappinessstring
oomKillDisablebooleanstring
networkModestring
portBindingsarray
SubTypestring
privilegedbooleanstring
pullPolicyobject
resumebooleanstring
Defaulttrue
shmSizestring
userstring
versionstring
volumesarray
SubTypestring
waitbooleanstring
Defaulttrue
Example
yaml
id: new_shell
namespace: company.team

tasks:
  - id: shell
    type: io.kestra.plugin.scripts.shell.Commands
    taskRunner:
      type: io.kestra.plugin.core.runner.Process
    commands:
      - echo "Hello World"

yaml
id: before_commands_example
namespace: company.team

inputs:
  - id: url
    type: URI
    defaults: https://jsonplaceholder.typicode.com/todos/1

tasks:
  - id: transform
    type: io.kestra.plugin.scripts.python.Script
    taskRunner:
      type: io.kestra.plugin.core.runner.Process
    beforeCommands:
      - pip install kestra requests --break-system-packages
    script: |
      import requests
      from kestra import Kestra

      url = "{{ inputs.url }}"

      response = requests.get(url)
      print('Status Code:', response.status_code)
      Kestra.outputs(response.json())

yaml
id: new_shell_with_file
namespace: company.team

inputs:
  - id: file
    type: FILE

tasks:
  - id: shell
    type: io.kestra.plugin.scripts.shell.Commands
    inputFiles:
      data.txt: "{{inputs.file}}"
    outputFiles:
      - out.txt
    taskRunner:
      type: io.kestra.plugin.core.runner.Process
    commands:
      - cp {{workingDir}}/data.txt {{workingDir}}/out.txt
type*Requiredobject
versionstring
Example
yaml
id: new_shell
namespace: company.team

tasks:
  - id: shell
    type: io.kestra.plugin.scripts.shell.Commands
    taskRunner:
      type: io.kestra.plugin.ee.azure.runner.Batch
      account: "{{secrets.account}}"
      accessKey: "{{secrets.accessKey}}"
      endpoint: "{{secrets.endpoint}}"
      poolId: "{{vars.poolId}}"
    commands:
      - echo "Hello World"

yaml
id: new_shell_with_file
namespace: company.team

inputs:
  - id: file
    type: FILE

tasks:
  - id: shell
    type: io.kestra.plugin.scripts.shell.Commands
    inputFiles:
      data.txt: "{{inputs.file}}"
    outputFiles:
      - out.txt
    containerImage: centos
    taskRunner:
      type: io.kestra.plugin.azure.ee.runner.Batch
      account: "{{secrets.account}}"
      accessKey: "{{secrets.accessKey}}"
      endpoint: "{{secrets.endpoint}}"
      poolId: "{{vars.poolId}}"
      blobStorage:
        connectionString: "{{secrets.connectionString}}"
        containerName: "{{vars.containerName}}"
    commands:
      - cp {{workingDir}}/data.txt {{workingDir}}/out.txt

yaml
id: azure_batch_runner
namespace: company.team

variables:
  pool_id: poolId
  container_name: containerName

tasks:
  - id: scrape_environment_info
    type: io.kestra.plugin.scripts.python.Commands
    containerImage: ghcr.io/kestra-io/pydata:latest
    taskRunner:
      type: io.kestra.plugin.ee.azure.runner.Batch
      account: "{{ secret('AZURE_ACCOUNT') }}"
      accessKey: "{{ secret('AZURE_ACCESS_KEY') }}"
      endpoint: "{{ secret('AZURE_ENDPOINT') }}"
      poolId: "{{ vars.pool_id }}"
      blobStorage:
        containerName: "{{ vars.container_name }}"
        connectionString: "{{ secret('AZURE_CONNECTION_STRING') }}"
    commands:
      - python {{ workingDir }}/main.py
    namespaceFiles:
      enabled: true
    outputFiles:
      - environment_info.json
    inputFiles:
      main.py: |
        import platform
        import socket
        import sys
        import json

        from kestra import Kestra

        print("Hello from Azure Batch and kestra!")

        def print_environment_info():
            print(f"Host's network name: {platform.node()}")
            print(f"Python version: {platform.python_version()}")
            print(f"Platform information (instance type): {platform.platform()}")
            print(f"OS/Arch: {sys.platform}/{platform.machine()}")

            env_info = {
                "host": platform.node(),
                "platform": platform.platform(),
                "OS": sys.platform,
                "python_version": platform.python_version(),
            }
            Kestra.outputs(env_info)

            filename = 'environment_info.json'
            with open(filename, 'w') as json_file:
                json.dump(env_info, json_file, indent=4)

        if __name__ == '__main__':
          print_environment_info()
account*Requiredstring
endpoint*Requiredstring
poolId*Requiredstring
type*Requiredobject
Possible Values
io.kestra.plugin.ee.azure.runner.Batchio.kestra.plugin.azure.runner.Batch
accessKeystring
blobStorage
containerName*Requiredstring
connectionStringstring
endpointstring
sharedKeyAccountAccessKeystring
sharedKeyAccountNamestring
completionCheckIntervalstring
DefaultPT5S
deletebooleanstring
Defaulttrue
registry
identityReference
resourceIdstring
passwordstring
registryServerstring
userNamestring
resumebooleanstring
Defaulttrue
streamLogsbooleanstring
Defaultfalse
syncWorkingDirectorybooleanstring
Defaultfalse
versionstring
waitUntilCompletionstring
DefaultPT1H
Example
yaml
id: run_container
namespace: company.team

variables:
  region: eu-west-2
  computeEnvironmentArn: "arn:aws:batch:eu-central-1:123456789012:compute-environment/kestraFargateEnvironment"

tasks:
  - id: shell
    type: io.kestra.plugin.scripts.shell.Commands
    taskRunner:
      type: io.kestra.plugin.ee.aws.runner.Batch
      accessKeyId: "{{ secret('AWS_ACCESS_KEY_ID') }}"
      secretKeyId: "{{ secret('AWS_SECRET_KEY_ID') }}"
      region: "{{ vars.region }}"
      computeEnvironmentArn: "{{ vars.computeEnvironmentArn }}"
    commands:
      - echo "Hello World"

yaml
id: container_with_input_files
namespace: company.team

inputs:
  - id: file
    type: FILE

variables:
  region: eu-west-2
  computeEnvironmentArn: "arn:aws:batch:eu-central-1:123456789012:compute-environment/kestraFargateEnvironment"

tasks:
  - id: shell
    type: io.kestra.plugin.scripts.shell.Commands
    inputFiles:
      data.txt: "{{ inputs.file }}"
    outputFiles:
      - out.txt
    containerImage: centos
    taskRunner:
      type: io.kestra.plugin.ee.aws.runner.Batch
      accessKeyId: "{{ secret('AWS_ACCESS_KEY_ID') }}"
      secretKeyId: "{{ secret('AWS_SECRET_KEY_ID') }}"
      region: "{{ vars.region }}"
      bucket: "{{ vars.bucket }}"
      computeEnvironmentArn: "{{ vars.computeEnvironmentArn }}"
    commands:
      - cp {{ workingDir }}/data.txt {{ workingDir }}/out.txt

yaml
id: aws_batch_runner
namespace: company.team

variables:
  compute_environment_arn: arn:aws:batch:us-east-1:123456789:compute-environment/kestra
  job_queue_arn: arn:aws:batch:us-east-1:123456789:job-queue/kestra
  execution_role_arn: arn:aws:iam::123456789:role/ecsTaskExecutionRole
  task_role_arn: arn:aws:iam::123456789:role/ecsTaskRole

tasks:
  - id: send_data
    type: io.kestra.plugin.scripts.python.Script
    containerImage: ghcr.io/kestra-io/pydata:latest
    taskRunner:
      type: io.kestra.plugin.ee.aws.runner.Batch
      region: us-east-1
      accessKeyId: "{{ secret('AWS_ACCESS_KEY_ID') }}"
      secretKeyId: "{{ secret('AWS_SECRET_KEY_ID') }}"
      computeEnvironmentArn: "{{ vars.compute_environment_arn }}"
      jobQueueArn: "{{ vars.job_queue_arn}}"
      executionRoleArn: "{{ vars.execution_role_arn }}"
      taskRoleArn: "{{ vars.task_role_arn }}"
      bucket: kestra-us
    script: |
      import platform
      import socket
      import sys

      print("Hello from AWS Batch and kestra!")

      def print_environment_info():
          print(f"Host's network name: {platform.node()}")
          print(f"Python version: {platform.python_version()}")
          print(f"Platform information (instance type): {platform.platform()}")
          print(f"OS/Arch: {sys.platform}/{platform.machine()}")

          try:
              hostname = socket.gethostname()
              ip_address = socket.gethostbyname(hostname)
              print(f"Host IP Address: {ip_address}")
          except socket.error as e:
              print("Unable to obtain IP address.")

      if __name__ == '__main__':
          print_environment_info()
computeEnvironmentArn*Requiredstring
region*Requiredstring
type*Requiredobject
accessKeyIdstring
bucketstring
completionCheckIntervalstring
DefaultPT5S
deletebooleanstring
Defaulttrue
endpointOverridestring
executionRoleArnstring
jobQueueArnstring
resources
Default{ "request": { "memory": "2048", "cpu": "1" } }
request*Required
cpu*Requiredstring
memory*Requiredstring
resumebooleanstring
Defaulttrue
secretKeyIdstring
sessionTokenstring
sidecarResources
request*Required
cpu*Requiredstring
memory*Requiredstring
stsEndpointOverridestring
stsRoleArnstring
stsRoleExternalIdstring
stsRoleSessionDurationstring
DefaultPT15M
stsRoleSessionNamestring
syncWorkingDirectorybooleanstring
Defaultfalse
taskRoleArnstring
versionstring
waitUntilCompletionstring
DefaultPT1H
Example
yaml
id: new_shell
namespace: company.team

variables:
  projectId: "myproject"
  region: "europe-west2"

tasks:
  - id: shell
    type: io.kestra.plugin.scripts.shell.Commands
    taskRunner:
      type: io.kestra.plugin.ee.gcp.runner.Batch
      projectId: "{{vars.projectId}}"
      region: "{{ vars.region} }"
      serviceAccount: "{{ secret('GOOGLE_SA') }}"
    commands:
      - echo "Hello World"

yaml
id: new_shell_with_file
namespace: company.team

inputs:
  - id: file
    type: FILE

variables:
  projectId: "myProject"
  region: "europe-west2"
  bucket: "myBucket"

tasks:
  - id: shell
    type: io.kestra.plugin.scripts.shell.Commands
    inputFiles:
      data.txt: "{{ inputs.file }}"
    outputFiles:
      - out.txt
    containerImage: centos
    taskRunner:
      type: io.kestra.plugin.ee.gcp.runner.Batch
      projectId: "{{ vars.projectId }}"
      region: "{{ vars.region }}"
      bucket: "{{ vars.bucket }}"
      serviceAccount: "{{ secret('GOOGLE_SA') }}"
    commands:
      - cp {{workingDir}}/data.txt {{workingDir}}/out.txt

yaml
id: gcp_batch_runner
namespace: company.team

tasks:
  - id: scrape_environment_info
    type: io.kestra.plugin.scripts.python.Commands
    containerImage: ghcr.io/kestra-io/pydata:latest
    taskRunner:
      type: io.kestra.plugin.ee.gcp.runner.Batch
      projectId: "{{ secret('GCP_PROJECT_ID') }}"
      region: "europe-west9"
      bucket: "{{ secret('GCS_BUCKET')}}"
      serviceAccount: "{{ secret('GOOGLE_SA') }}"
    commands:
      - python {{ workingDir }}/main.py
    namespaceFiles:
      enabled: true
    outputFiles:
      - environment_info.json
    inputFiles:
      main.py: |
        import platform
        import socket
        import sys
        import json
        from kestra import Kestra

        print("Hello from GCP Batch and kestra!")

        def print_environment_info():
            print(f"Host's network name: {platform.node()}")
            print(f"Python version: {platform.python_version()}")
            print(f"Platform information (instance type): {platform.platform()}")
            print(f"OS/Arch: {sys.platform}/{platform.machine()}")

            env_info = {
                "host": platform.node(),
                "platform": platform.platform(),
                "OS": sys.platform,
                "python_version": platform.python_version(),
            }
            Kestra.outputs(env_info)

            filename = '{{ workingDir }}/environment_info.json'
            with open(filename, 'w') as json_file:
                json.dump(env_info, json_file, indent=4)

        if __name__ == '__main__':
          print_environment_info()
region*Requiredstring
type*Requiredobject
Possible Values
io.kestra.plugin.ee.gcp.runner.Batchio.kestra.plugin.gcp.runner.Batch
bucketstring
completionCheckIntervalstring
DefaultPT5S
computeResource
bootDiskstring
cpustring
memorystring
deletebooleanstring
Defaulttrue
entryPointarray
SubTypestring
impersonatedServiceAccountstring
lifecyclePoliciesarray
actionstring
Possible Values
ACTION_UNSPECIFIEDRETRY_TASKFAIL_TASKUNRECOGNIZED
actionCondition
exitCodesarray
SubTypeinteger
machineTypestring
Defaulte2-medium
maxCreateJobRetryCountintegerstring
Default2
maxRetryCountinteger
Minimum>= 0
Maximum<= 10
networkInterfacesarray
network*Requiredstring
subnetworkstring
projectIdstring
reservationstring
resumebooleanstring
Defaulttrue
scopesarray
SubTypestring
Default["https://www.googleapis.com/auth/cloud-platform"]
serviceAccountstring
syncWorkingDirectorybooleanstring
Defaultfalse
versionstring
waitForLogIntervalstring
DefaultPT5S
waitUntilCompletionstring
DefaultPT1H
Example
yaml
id: new-shell
namespace: company.team

variables:
  projectId: "projectId"
  region: "europe-west2"

tasks:
  - id: shell
    type: io.kestra.plugin.scripts.shell.Commands
    taskRunner:
      type: io.kestra.plugin.ee.gcp.runner.CloudRun
      projectId: "{{ vars.projectId }}"
      region: "{{ vars.region }}"
      serviceAccount: "{{ secret('GOOGLE_SA') }}"
    commands:
      - echo "Hello World"

yaml
id: new-shell-with-file
namespace: company.team

inputs:
  - id: file
    type: FILE

variables:
  projectId: "projectId"
  bucket: "bucket"
  region: "europe-west2"

tasks:
  - id: shell
    type: io.kestra.plugin.scripts.shell.Commands
    inputFiles:
      data.txt: "{{ inputs.file }}"
    outputFiles:
      - out.txt
    containerImage: centos
    taskRunner:
      type: io.kestra.plugin.ee.gcp.runner.CloudRun
      projectId: "{{ vars.projectId }}"
      region: "{{ vars.region }}"
      bucket: "{{ vars.bucket }}"
      serviceAccount: "{{ secret('GOOGLE_SA') }}"
    commands:
      - cp {{ workingDir }}/data.txt {{ workingDir }}/out.txt

yaml
id: shell-direct-vpc-egress
namespace: company.team

variables:
  projectId: "projectId"
  region: "europe-west1"
  network: "projects/projectId/global/networks/my-vpc"
  subnetwork: "projects/projectId/regions/europe-west1/subnetworks/my-subnet"

tasks:
  - id: shell
    type: io.kestra.plugin.scripts.shell.Commands
    taskRunner:
      type: io.kestra.plugin.ee.gcp.runner.CloudRun
      projectId: "{{ vars.projectId }}"
      region: "{{ vars.region }}"
      network: "{{ vars.network }}"
      subnetwork: "{{ vars.subnetwork }}"
      vpcEgress: ALL_TRAFFIC
      serviceAccount: "{{ secret('GOOGLE_SA') }}"
    commands:
      - echo "Hello from Direct VPC Egress"
region*Requiredstring
type*Requiredobject
Possible Values
io.kestra.plugin.ee.gcp.runner.CloudRunio.kestra.plugin.gcp.runner.CloudRun
bucketstring
completionCheckIntervalstring
DefaultPT5S
deletebooleanstring
Defaulttrue
impersonatedServiceAccountstring
maxRetriesintegerstring
Default3
networkstring
projectIdstring
resources
cpustring
memorystring
resumebooleanstring
Defaulttrue
runtimeServiceAccountstring
scopesarray
SubTypestring
Default["https://www.googleapis.com/auth/cloud-platform"]
serviceAccountstring
subnetworkstring
syncWorkingDirectorybooleanstring
versionstring
vpcAccessConnectorstring
vpcEgressstring
Possible Values
VPC_EGRESS_UNSPECIFIEDALL_TRAFFICPRIVATE_RANGES_ONLYUNRECOGNIZED
waitForLogIntervalstring
DefaultPT5S
waitUntilCompletionstring
DefaultPT1H
Example
yaml
id: new-shell
namespace: company.team

tasks:
  - id: shell
    type: io.kestra.plugin.scripts.shell.Commands
    taskRunner:
      type: io.kestra.plugin.ee.kubernetes.runner.Kubernetes
    commands:
      - echo "Hello World"

yaml
id: new-shell-with-file
namespace: company.team

inputs:
  - id: file
    type: FILE

tasks:
  - id: shell
    type: io.kestra.plugin.scripts.shell.Commands
    inputFiles:
      data.txt: "{{ inputs.file }}"
    outputFiles:
      - out.txt
    containerImage: centos
    taskRunner:
      type: io.kestra.plugin.ee.kubernetes.runner.Kubernetes
    commands:
      - cp {{ workingDir }}/data.txt {{ workingDir }}/out.txt
type*Requiredobject
Possible Values
io.kestra.plugin.ee.kubernetes.runner.Kubernetesio.kestra.plugin.kubernetes.runner.Kubernetes
config
apiVersionstring
Defaultv1
caCertDatastring
caCertFilestring
clientCertDatastring
clientCertFilestring
clientKeyAlgostring
DefaultRSA
clientKeyDatastring
clientKeyFilestring
clientKeyPassphrasestring
disableHostnameVerificationbooleanstring
keyStoreFilestring
keyStorePassphrasestring
masterUrlstring
Defaulthttps://kubernetes.default.svc
namespacestring
oauthTokenstring
oauthTokenProvider
outputstring
task
passwordstring
trustCertsbooleanstring
trustStoreFilestring
trustStorePassphrasestring
usernamestring
containerDefaultSpecobject
containerSpecobject
deletebooleanstring
Defaulttrue
fileSideCarSpecobject
fileSidecar
Default{ "image": "busybox" }
defaultSpecobject
imagestring
Defaultbusybox
resourcesobject
killed
Defaultfalse
labelsobject
namespacestring
Defaultdefault
nodeSelectorobject
podSpecobject
pullPolicystring
DefaultALWAYS
Possible Values
IF_NOT_PRESENTALWAYSNEVER
resources
limit
cpustring
memorystring
request
cpustring
memorystring
resumebooleanstring
Defaulttrue
serviceAccountNamestring
syncWorkingDirectorybooleanstring
Defaultfalse
versionstring
waitForLogsstring
DefaultPT30S
waitUntilCompletionstring
DefaultPT1H
waitUntilRunningstring
DefaultPT10M
Default0
SubTypestring
Definitions
Unitrecords
Unitrecords
Unitrecords