admin管理员组

文章数量:1122832

While upgrading packer version getting below error:

Error: Failed to initialize build "amazon-ebs" The builder amazon-ebs is unknown by Packer, and is likely part of a plugin that is not installed.

You may find the needed plugin along with installation instructions documented 904on the Packer integrations page.

[Container] 2024/11/19 17:19:12.070019 Command did not exit successfully cd $CODEBUILD_SRC_DIR/build_config/packer/deployami/ && packer validate ./packer.json exit status 1

[Container] 2024/11/19 17:19:12.074475 Phase complete: PRE_BUILD State: FAILED

[Container] 2024/11/19 17:19:12.074503 Phase context status code: COMMAND_EXECUTION_ERROR Message: Error while executing command: cd $CODEBUILD_SRC_DIR/build_config/packer/deployami/ && packer validate ./packer.json. Reason: exit status 1

Tried to upgrade amazon plugin: packer plugins install github/hashicorp/amazon This time throws some Ansible error:

amazon-ebs: TASK [aws-gather-facts-ec2 : Get EC2 tag value for Name] ***********************

amazon-ebs: task path: /etc/ansible/application/roles/aws-gather-facts-ec2/tasks/main.yml:43

amazon-ebs: fatal: [127.0.0.1]: FAILED! => {

amazon-ebs: "msg": "The task includes an option with an undefined variable. The error was: 'dict object' has no attribute 'Name'\n\nThe error appears to be in '/etc/ansible/application/roles/aws-gather-facts-ec2/tasks/main.yml': line 43, column 3, but may\nbe elsewhere in the file depending on the exact syntax problem.\n\nThe offending line appears to be:\n\n\n- name: Get EC2 tag value for Name\n ^ here\n" amazon-ebs: }

  • name: Get EC2 tag value for Name set_fact: ec2_instance_tag_name: "{{ ec2_tags.tags.Name }}" tags:
    • always
    • base

Any suggestion would be appreciated ?

本文标签: ansibleHashicorp packer version upgrade to latest 1112 from 180Stack Overflow