<p>I've been attempting to use Tekton to deploy some AWS infrastructure via Terraform but not having much success.</p>
<p>The pipeline clones a Github repo containing TF code , it then attempts to use the terraform-cli task to provision the AWS infrastructure.  For initial testing I just want to perform the initial TF init and provision the AWS VPC.</p>
<p><strong>Expected behaviour</strong></p>
<ul>
<li>Clone Github Repo</li>
<li>Perform Terraform Init</li>
<li>Create the VPC using targeted TF apply</li>
</ul>
<p><strong>Actual Result</strong></p>
<p>task terraform-init has failed: failed to create task run pod &quot;my-infra-pipelinerun-terraform-init&quot;: Pod &quot;my-infra-pipelinerun-terraform-init-pod&quot; is invalid: spec.initContainers[1].name: Duplicate value: &quot;step-init&quot;. Maybe missing or invalid Task default/terraform-cli
pod for taskrun my-infra-pipelinerun-terraform-init not available yet
Tasks Completed: 2 (Failed: 1, Cancelled 0), Skipped: 1</p>
<p><strong>Steps to Reproduce the Problem</strong></p>
<p>Prerequisites: Install Tekton command line tool, git-clone and terraform-cli</p>
<p>create this pipeline in Minikube</p>
<pre><code>apiVersion: tekton.dev/v1beta1
kind: Pipeline
metadata:
  name: my-infra-pipeline
spec:
  description: Pipeline for TF deployment
  params:
  - name: repo-url
    type: string
    description: Git repository URL
  - name: branch-name
    type: string
    description: The git branch
  workspaces:
  - name: tf-config
    description: The workspace where the tf config code will be stored
  tasks:
  - name: clone-repo
    taskRef:
      name: git-clone
    workspaces:
    - name: output
      workspace: tf-config
    params:
    - name: url
      value: $(params.repo-url) 
    - name: revision
      value: $(params.branch-name)
  - name: terraform-init
    runAfter: [&quot;clone-repo&quot;]
    taskRef:
      name: terraform-cli
    workspaces:
    - name: source
      workspace: tf-config
    params:
     - name: terraform-secret
       value: &quot;tf-auth&quot;
     - name: ARGS
       value:
         - init
  - name: build-vpc
    runAfter: [&quot;terraform-init&quot;]
    taskRef:
      name: terraform-cli
    workspaces:
    - name: source
      workspace: tf-config
    params:
     - name: terraform-secret
       value: &quot;tf-auth&quot;
     - name: ARGS
       value:
         - apply
         - &quot;-target=aws_vpc.vpc -auto-approve&quot;
</code></pre>
<p>Run the pipeline by creating a pipelinerun resource in k8s</p>
<p>Review the logs &gt; tkn pipelinerun logs my-tf-pipeline -a</p>
<p><strong>Additional Information</strong></p>
<p>Pipeline version: v0.35.1</p>

800711
<p>There is a known issue regarding &quot;step-init&quot; in some earlier versions - I suggest you upgrade to latest version (0.36.0) and try again.</p>
