Questions tagged [packer]

PACKER QUESTIONS MUST BE PROGRAMMING RELATED. Packer is a tool for creating identical machine images for multiple platforms from a single source configuration.

"Packer is a modern tool that embraces best benefits. It's completely automated, simply run a packer build, no human touches it, Packer builds it for you. " - Mitchell Hashimoto (Creator)

Packer is an open source tool for creating identical machine images for multiple platforms from a single source configuration. Packer is lightweight, runs on every major operating system, and is highly performant, creating machine images for multiple platforms in parallel. Packer does not replace configuration management like Chef or Puppet. In fact, when building images, Packer is able to use tools like Chef or Puppet to install software onto the image.

A machine image is a single static unit that contains a pre-configured operating system and installed software which is used to quickly create new running machines. Machine image formats change for each platform. Some examples include AMIs for EC2, VMDK/VMX files for VMware, OVF exports for VirtualBox, etc.

Resources

852 questions
3
votes
1 answer

Packer: How do I create an AWS AMI with multiple block devices having different kms keys

I am trying to use packer version 1.3.2 to bake an AMI with multiple block devices where each block device is encrypted with a different KMS key, which is different then the KMS key used to encrypt the boot device. At first I started to think that…
Starlton
  • 429
  • 5
  • 14
3
votes
2 answers

Packer Waiting for SSH

I am new to Packer. I have researched this issue(above) in great detail. I am currently trying to create an UBuntu 32 bit VM. I am running Packer on a WIndows 10 OS. Once the installation is complete and the VM reboots and I am then prompted with…
Sam
  • 145
  • 2
  • 14
3
votes
1 answer

How do I set locale information for all user accounts (including system user & network service user) in windows 2016

I am currently working on building an AWS AMI for a Windows 2016 base image. I'm doing this by creating a template for packer and I'm having issues getting the system and default user accounts to have their Locale set properly. I need to get the…
3
votes
2 answers

Getting IP address of the AWS instance when using packer and ansible

I am building an AMI image on AWS using packer and Ansible. My end goal is to have an AMI image such that when it is built into an EC2 instance, it has my web app running. For me to reach my end goal, I need to configure Nginx server in my AMI. My…
Harith
  • 539
  • 5
  • 16
3
votes
2 answers

Disabling Internet Explorer Enhanced Security Configuration using PowerShell in Packer on AWS Fails

I'm trying to disable Internet Explorer Enhanced Security Configuration using PowerShell in Packer on AWS when building a Windows Server 2016 instance from their latest AMI. I'm calling the following function in PS from one of the packer…
3
votes
2 answers

Checking if an ELF is packed with UPX in Linux

I have zero knowledge of how the ELF format works or how to access its headers and data via code, however I need to check whether an ELF binary has been compressed (packed?) with UPX for Linux. Checking the binary with strings I saw the string UPX!…
Jessica
  • 2,005
  • 4
  • 28
  • 44
3
votes
2 answers

Terraform creating VM from managed disk image made in Packer

I have created a custom VM image using Packer, and now I am trying to create a new VM based on this image using Terraform, but I am confused on how I need to set up my .TF file . I can create the rest of the infrastructure okay. I think my packer…
Ciaránimo
  • 517
  • 1
  • 9
  • 21
3
votes
2 answers

Why don't Packer provisioner changes show up in Vagrant box even though they are reported successful?

I feel like I'm going crazy here. I am trying to create a Vagrant VirtualBox image from a CentOS 7 ISO using Packer. More specifically, I am running the virtualbox-iso builder and using the Vagrant post-processor. According to the output from the…
ndusek
  • 31
  • 4
3
votes
1 answer

Packer Script exited with non-zero exit status : 127

I am trying to provision an AWS AMI but the packer script terminates with the following error. Build 'amazon-ebs' errored: Script exited with non-zero exit status: 127 ==> Some builds didn't complete successfully and had errors: -->…
lft93ryt
  • 948
  • 1
  • 16
  • 32
3
votes
2 answers

Packer installation Issues on EC2 Amazon AMI Linux distribution

I am having issues installing packer onto the EC2 machine. I have downloaded the Linux packer binary file on my Windows PC and uploaded it to the instance. I put it into the directory ~/packer_new, and have been trying two different ways for adding…
J. H
  • 125
  • 4
  • 10
3
votes
1 answer

Cannot copy an image due to mysterious error about EC2 BillingProduct code

I am attempting to copy an EC2 image for the purpose of encrypting it. The command line I issue is: $ aws ec2 copy-image --name encrypted-kafka-201707121432 \ --source-region ap-southeast-2 --encrypted --source-image-id ami-2a617249 \ --region…
Alex Harvey
  • 14,494
  • 5
  • 61
  • 97
3
votes
2 answers

How to resize the root filesystem during AMI creation with packer?

I faced the the problem that some apache logs filled so quick that the root filesystem was not big enough. I am using an AMI created with packer and centos 6. How can I resize the root FS during the AMI creation to have it ready for later usage?
Zioalex
  • 3,441
  • 2
  • 33
  • 30
3
votes
1 answer

Running Ansible on Windows using Packer in AWS

I'm trying to provision Ansible playbook using packer on Windows AMI. That's my packer template: { "variables": { "aws_access_key": "{{env `AWS_ACCESS_KEY_ID`}}", "aws_secret_key": "{{env `AWS_SECRET_ACCESS_KEY`}}", "aws_region":…
Adamba4
  • 181
  • 1
  • 2
  • 9
3
votes
1 answer

How to pass Packer.io ISO_URL as a command line parameter

I would like to pass ISO_URL as a command line parameter. I tried to follow an example at https://www.packer.io/docs/templates/user-variables.html Where my variable section looks like "variables": { "build_version": "1.0.0", …
Roman Mik
  • 3,179
  • 3
  • 27
  • 49
3
votes
2 answers

Can I use one packer builder with many provisioners and still run parallel builds?

I have what seems to be like a valid use case for an unsupported - afaik - scenario, using packer.io and I'm worried I might be missing something... So, in packer, I can add: many builders, have a different name per builder, use the builder name…
gsaslis
  • 3,066
  • 2
  • 26
  • 32