hashicorp / setup-packer

Run HashiCorp Packer as part of your GitHub Actions Workflow
https://github.com/marketplace/actions/setup-hashicorp-packer
Apache License 2.0
144 stars 83 forks source link

docs: correct argument limitation #36

Closed toast-gear closed 2 years ago

toast-gear commented 2 years ago

I am able to provide arguments over multiple lines e.g.

      - name: Build
        uses: hashicorp/packer-github-actions@master
        with:
          command: build
          arguments: |
            -on-error=abort
            -var security_group_id=sg-123123121231
            -var subnet_id=subnet-123dsad4sa54dsa
          target: images/linux-amzn2/github_agent.linux.pkr.hcl
        env:
          PACKER_LOG: 1
hashicorp-cla commented 2 years ago

CLA assistant check
All committers have signed the CLA.

toast-gear commented 2 years ago

This may not be accurate then. I had issues with the below. This limitation really sucks as it makes arguments far less readable in the pipeline.

      - name: Build
        uses: hashicorp/packer-github-actions@master
        with:
          command: build
          arguments: |
            -on-error=abort
            -var security_group_id=sg-123123121231
            -var subnet_id=subnet-123dsad4sa54dsa
            -var tags="{ sandbox=${{ github.event.inputs.sandbox }} }"
          target: images/linux-amzn2/github_agent.linux.pkr.hcl
        env:
          PACKER_LOG: 1
toast-gear commented 2 years ago

Raised an issue against https://github.com/hashicorp/packer-github-actions/issues/37, closing as a result.