Skip to content

packer build exit error without any explanation in CI #81

@namgk

Description

@namgk

Is it mandatory to have HCP_CLIENT_ID for the build to succeed? It builds fine in my laptop but not in the Github Action. Why?

Expected Behavior

packer build should succeed.

Current Behavior

+ packer init main.pkr.hcl
Installed plugin github.com/hashicorp/amazon v1.2.6 in "/home/runner/.config/packer/plugins/github.com/hashicorp/amazon/packer-plugin-amazon_v1.2.6_x5.0_linux_amd64"
+ packer build main.pkr.hcl
Error: Process completed with exit code 1.

Steps to Reproduce

jobs:
  packer:
    runs-on: ubuntu-latest
    name: Run Packer
    steps:
      - name: Checkout
        uses: actions/checkout@v3

      - name: Setup `packer`
        uses: hashicorp/setup-packer@main
        with:
          version: ${{ env.PACKER_VERSION }}

      - name: Build Image
        id: build
        run: |
          set -ex
          packer init $IMAGE_NAME.pkr.hcl
          packer build $IMAGE_NAME.pkr.hcl

Environment

see above

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions