#packer (2019-09)

packer

Discuss Packer for building AMIs and Docker Images

Archive: https://archive.sweetops.com/packer/

2019-09-17

Callum Robertson avatar
Callum Robertson

Hey @davidvasandani maybe you can help with my headache. I’m fairly new to Packer, I’ve written and aws ebs backed AMI template that runs an powershell script that connects a PS Drive to a remote file system and then runs an executable from that PSDrive, my logs says it runs the script defined in the packer template but I see no effect on the AMI once I deploy it, can you help?

Callum Robertson avatar
Callum Robertson
Callum Robertson avatar
Callum Robertson
Callum Robertson avatar
Callum Robertson

I get the above output when I run the packer template, any idea on whats going on?

davidvasandani avatar
davidvasandani

@Callum Robertson I don’t have much experience with Packer and Windows but I will need to practice for an upcoming project. Have you attempted to run Packer in debug mode and remote into the instance to run the command before it terminates?

Callum Robertson avatar
Callum Robertson

Yeah doing that now, also upskilling my powershell logic to have logging and debugging

Callum Robertson avatar
Callum Robertson

(why can’t the world run on linux)

1
davidvasandani avatar
davidvasandani

Let us know what you find! (if anything) otherwise we can revisit and try to help you figure out.

2019-09-18

Callum Robertson avatar
Callum Robertson

Hey if anyone was interested, the problem was actually how Packer handles persistent consoles when it runs it’s provisioners, I had to increase the scope of the PS Drive to a global for it to persist past the instance of the scripting console.

1
1

2019-09-30

sweetops avatar
sweetops

Anyone here use the checksum post processor to tag docker images with the checksum? Trying to figure this out

    keyboard_arrow_up