Skip to content

Instantly share code, notes, and snippets.

@deltamualpha
Created July 29, 2016 20:57
Show Gist options
  • Save deltamualpha/01e9114aae9d3e0da4a5b73345c83ffe to your computer and use it in GitHub Desktop.
Save deltamualpha/01e9114aae9d3e0da4a5b73345c83ffe to your computer and use it in GitHub Desktop.
{
"variables": {
"timestamp": null,
"aws_access_key": null,
"aws_secret_key": null
},
"builders": [
{
"type": "amazon-ebs",
"region": "us-east-1",
"source_ami": "ami-9c39ba8b",
"instance_type": "m4.large",
"user_data_file": "scripts/setup.ps1",
"winrm_username": "Administrator",
"communicator": "winrm",
"access_key": "{{ user `aws_access_key` }}",
"secret_key": "{{ user `aws_secret_key` }}",
"ami_name": "ami-rms-base-{{user `timestamp`}}"
}
],
"provisioners": [
{
"type": "powershell",
"script": "scripts/puppet.ps1"
},
{
"type": "file",
"source": "./puppet/modules/",
"destination": "C:\\Windows\\Temp\\modules"
},
{
"type": "file",
"source": "./puppet/site.pp",
"destination": "C:\\Windows\\Temp\\site.pp"
},
{
"type": "powershell",
"inline": [
"puppet apply --verbose --modulepath C:\\Windows\\Temp\\modules\\ C:\\Windows\\Temp\\site.pp"
]
}
]
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment