Skip to content

Instantly share code, notes, and snippets.

@Wenzel
Created July 3, 2018 11:50
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save Wenzel/b3e46f5aad2e1b43e72ca4a9184e43a1 to your computer and use it in GitHub Desktop.
Save Wenzel/b3e46f5aad2e1b43e72ca4a9184e43a1 to your computer and use it in GitHub Desktop.
Packer WinRM connection_plugin for Ansible - Ansible v2.4.0 - ./packer build windows10.json
qemu output will be in this color.
==> qemu: Downloading or copying ISO
qemu: Found already downloaded, initial checksum matched, no download needed: http://care.dlservice.microsoft.com/dl/download/C/3/9/C399EEA8-135D-4207-92C9-6AAB3259F6EF/10240.16384.150709-1700.TH1_CLIENTENTERPRISEEVAL_OEMRET_X64FRE_EN-US.ISO
==> qemu: Creating floppy disk...
qemu: Copying files flatly from floppy_files
qemu: Copying file: ./answer_files/10/Autounattend.xml
qemu: Copying file: scripts/fixnetwork.ps1
qemu: Copying file: scripts/setup_winrm_public.bat
qemu: Done copying files from floppy_files
qemu: Collecting paths from floppy_dirs
qemu: Resulting paths from floppy_dirs : []
qemu: Done copying paths from floppy_dirs
==> qemu: Creating hard drive...
==> qemu: Found port for communicator (SSH, WinRM, etc): 3918.
==> qemu: Looking for available port between 5900 and 6000 on 127.0.0.1
==> qemu: Starting VM, booting from CD-ROM
qemu: The VM will be run headless, without a GUI. If you want to
qemu: view the screen of the VM, connect via VNC without a password to
qemu: vnc://127.0.0.1:5984
==> qemu: Overriding defaults Qemu arguments with QemuArgs...
==> qemu: Waiting 10s for boot...
==> qemu: Connecting to VM via VNC
==> qemu: Typing the boot command over VNC...
==> qemu: Waiting for WinRM to become available...
qemu: WinRM connected.
qemu: #< CLIXML
qemu: <Objs Version="1.1.0.1" xmlns="http://schemas.microsoft.com/powershell/2004/04"><Obj S="progress" RefId="0"><TN RefId="0"><T>System.Management.Automation.PSCustomObject</T><T>System.Object</T></TN><MS><I64 N="SourceId">1</I64><PR N="Record"><AV>Preparing modules for first use.</AV><AI>0</AI><Nil /><PI>-1</PI><PC>-1</PC><T>Completed</T><SR>-1</SR><SD> </SD></PR></MS></Obj><Obj S="progress" RefId="1"><TNRef RefId="0" /><MS><I64 N="SourceId">1</I64><PR N="Record"><AV>Preparing modules for first use.</AV><AI>0</AI><Nil /><PI>-1</PI><PC>-1</PC><T>Completed</T><SR>-1</SR><SD> </SD></PR></MS></Obj></Objs>
==> qemu: Connected to WinRM!
==> qemu: Provisioning with Ansible...
==> qemu: Executing Ansible: ansible-playbook --extra-vars packer_build_name=qemu packer_builder_type=qemu -i /tmp/packer-provisioner-ansible463562103 /home/tarrma/tmp/bug_packer/ansible/site.yml -e ansible_ssh_private_key_file=/tmp/ansible-key188329592 --connection=packer --extra-vars ansible_shell_type=powershell ansible_shell_executable=None -v
qemu: No config file found; using defaults
qemu:
qemu: PLAY [all] *********************************************************************
qemu:
qemu: TASK [Gathering Facts] *********************************************************
qemu: ok: [default]
qemu:
qemu: TASK [ping] ********************************************************************
qemu: ok: [default] => {"changed": false, "failed": false, "ping": "pong"}
qemu:
qemu: PLAY RECAP *********************************************************************
qemu: default : ok=2 changed=0 unreachable=0 failed=0
qemu:
==> qemu: Gracefully halting virtual machine...
Build 'qemu' finished.
==> Builds finished. The artifacts of successful builds are:
--> qemu: VM files in directory: output-qemu
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment