misp-cloud/dev/packer-aws.json

45 lines
1.2 KiB
JSON

{
"variables": {
"profile": "default",
"destination_regions": "eu-west-1,eu-west-2,eu-west-3,eu-central-1,us-east-1,us-west-1,ap-northeast-1,sa-east-1,us-west-2,ap-south-1",
"hostname": "misp"
},
"builders": [{
"type": "amazon-ebs",
"region": "eu-west-1",
"ami_groups": "all",
"source_ami_filter": {
"filters": {
"virtualization-type": "hvm",
"name": "ubuntu/images/*ubuntu-bionic-18.04-amd64-server-*",
"root-device-type": "ebs"
},
"owners": ["099720109477"],
"most_recent": true
},
"instance_type": "t2.medium",
"ami_regions": "{{user `destination_regions`}}",
"ssh_username": "ubuntu",
"ami_name": "MISP-{{timestamp}}",
"ami_description": "MISP - Malware Information Sharing Platform",
"tags": {
"Amazon_AMI_Management_Identifier": "misp-build"
}
}],
"provisioners": [
{
"type": "shell",
"execute_command" : "{{ .Vars }} sudo -H -E sh '{{ .Path }}'",
"script": "/home/ubuntu/misp/bootstrap",
"pause_before": "10s"
}
],
"post-processors":[{
"type": "amazon-ami-management",
"regions": "{{user `destination_regions`}}",
"identifier": "misp-build",
"keep_releases": "1"
}
]
}