github.com/orivej/packer@v0.10.1/examples/azure/debian.json (about) 1 { 2 "variables": { 3 "client_id": "{{env `ARM_CLIENT_ID`}}", 4 "client_secret": "{{env `ARM_CLIENT_SECRET`}}", 5 "resource_group": "{{env `ARM_RESOURCE_GROUP`}}", 6 "storage_account": "{{env `ARM_STORAGE_ACCOUNT`}}", 7 "subscription_id": "{{env `ARM_SUBSCRIPTION_ID`}}", 8 "tenant_id": "{{env `ARM_TENANT_ID`}}", 9 "ssh_user": "packer", 10 "ssh_pass": null 11 }, 12 "builders": [{ 13 "type": "azure-arm", 14 15 "client_id": "{{user `client_id`}}", 16 "client_secret": "{{user `client_secret`}}", 17 "resource_group_name": "{{user `resource_group`}}", 18 "storage_account": "{{user `storage_account`}}", 19 "subscription_id": "{{user `subscription_id`}}", 20 "tenant_id": "{{user `tenant_id`}}", 21 22 "capture_container_name": "images", 23 "capture_name_prefix": "packer", 24 25 "ssh_username": "{{user `ssh_user`}}", 26 "ssh_password": "{{user `ssh_pass`}}", 27 28 "os_type": "Linux", 29 "image_publisher": "credativ", 30 "image_offer": "Debian", 31 "image_sku": "8", 32 "ssh_pty": "true", 33 34 "location": "South Central US", 35 "vm_size": "Standard_A2" 36 }], 37 "provisioners": [{ 38 "execute_command": "echo '{{user `ssh_pass`}}' | {{ .Vars }} sudo -S -E sh '{{ .Path }}'", 39 "inline": [ 40 "apt-get update", 41 "apt-get upgrade -y", 42 43 "/usr/sbin/waagent -force -deprovision+user && export HISTSIZE=0 && sync" 44 ], 45 "inline_shebang": "/bin/sh -x", 46 "type": "shell" 47 }] 48 }