2

Currently trying to build a packer definition and am being met with timeouts once the build gets to the automatic password generation portion. I've included a snippet of my definition below:

        "type": "amazon-ebs",
        "ami_name": "{{user `ami_name`}}-{{isotime \"2006-01-02-150405\"}}",
        "region": "{{user `region_var`}}",
        "source_ami_filter": {
            "filters": {
              "virtualization-type": "hvm",
              "name": "*golden-windows2016-ami*",
              "root-device-type": "ebs"
            },
            "owners": ["XXX"],
            "most_recent": true
          },
        "instance_type": "t2.medium",
        "subnet_id": "{{user `subnet_var`}}",
        "communicator": "winrm",
        "winrm_username": "Administrator",
        "winrm_port": "5985",
        "windows_password_timeout": "30m",
        "iam_instance_profile": "XXX",

and the errors looke like:

1595447190,,ui,message,    amazon-ebs: It is normal for this process to take up to 15 minutes%!(PACKER_COMMA)\n    amazon-ebs: but it usually takes around 5. Please wait.
1595448990,,ui,error,==> amazon-ebs: Timeout waiting for password.
1595448990,,ui,say,==> amazon-ebs: Terminating the source AWS instance...
1595449020,,ui,say,==> amazon-ebs: Cleaning up any extra volumes...
1595449020,,ui,say,==> amazon-ebs: No volumes to clean up%!(PACKER_COMMA) skipping
1595449020,,ui,say,==> amazon-ebs: Deleting temporary keypair...
1595449020,,ui,error,Build 'amazon-ebs' errored: Timeout waiting for password.
1595449020,,error-count,1
1595449020,,ui,error,\n==> Some builds didn't complete successfully and had errors:
1595449020,amazon-ebs,error,Timeout waiting for password.
1595449020,,ui,error,--> amazon-ebs: Timeout waiting for password. 

with the debug flag on.

What am I missing?

  • This doesn't look like programming related, this should be moved here for example https://superuser.com/questions/tagged/packer – Simon Mourier Feb 27 '23 at 18:44
  • @SimonMourier Packer is definitely on topic for stack overflow, it even has its own tag – Paolo Feb 27 '23 at 19:17
  • @Paolo - read what the tag says "PACKER QUESTIONS MUST BE PROGRAMMING RELATED". There doesn't seem to be any programming question here, only config/definition. For other packer questions, superuser has its own packer tag. – Simon Mourier Feb 28 '23 at 05:28
  • @SimonMourier the tag should be changed, to be in line with similar tools such as terraform – Paolo Feb 28 '23 at 07:50
  • What kind of permissions are you running the Packer build with? – Paolo Feb 28 '23 at 07:50

0 Answers0