Skip to content

Instantly share code, notes, and snippets.

@sobi3ch
Created September 10, 2019 04:09
Show Gist options
  • Save sobi3ch/fc896a4554ab1fa283676093cbd435c1 to your computer and use it in GitHub Desktop.
Save sobi3ch/fc896a4554ab1fa283676093cbd435c1 to your computer and use it in GitHub Desktop.
{
"variables": {
"aws_access_key": "",
"aws_secret_key": ""
},
"builders": [{
"type": "amazon-ebs",
"access_key": "{{user `aws_access_key`}}",
"secret_key": "{{user `aws_secret_key`}}",
"region": "eu-north-1",
"source_ami": "ami-07abce0d1fdf6984b",
"instance_type": "t3.micro",
"ssh_username": "ubuntu",
"ami_name": "eclectic-platform {{timestamp}}"
}],
"provisioners": [
{
"type": "file",
"source": "./welcome.txt",
"destination": "/home/ubuntu/"
},
{
"type": "shell",
"inline":[
"ls -al /home/ubuntu",
"cat /home/ubuntu/welcome.txt"
]
},
{
"type": "shell",
"script": "./example.sh"
}
]
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment