misp-packer/misp.json

108 lines
3.6 KiB
JSON
Raw Normal View History

2017-08-23 11:55:44 +02:00
{
"variables": {
"ssh_name": "misp",
"ssh_pass": "Password1234",
2017-08-29 11:45:39 +02:00
"hostname": "misp",
2017-08-24 08:35:46 +02:00
"vm_name": "MISP_demo",
"disk_size": "10000"
2017-08-23 11:55:44 +02:00
},
"builders": [{
"type": "virtualbox-iso",
"headless": "true",
2017-08-23 11:55:44 +02:00
"guest_os_type": "Ubuntu_64",
2017-08-24 08:35:46 +02:00
"format": "ova",
"vm_name": "{{user `vm_name`}}",
2017-08-23 11:55:44 +02:00
"vboxmanage": [
["modifyvm", "{{.Name}}", "--vram", "32"]
],
2017-08-24 08:35:46 +02:00
"disk_size": "{{user `disk_size`}}",
2017-08-23 11:55:44 +02:00
2018-01-25 08:50:09 +01:00
"iso_url": "http://releases.ubuntu.com/17.10/ubuntu-17.10.1-server-amd64.iso",
"iso_checksum": "8ff73f1b622276758475c3bd5190b382774626de5a82c50930519381f6c3a3f8",
2017-08-23 11:55:44 +02:00
"iso_checksum_type": "sha256",
"http_directory" : "preseeds",
"http_port_min" : 9001,
"http_port_max" : 9011,
"ssh_username": "{{user `ssh_name`}}",
"ssh_password": "{{user `ssh_pass`}}",
"ssh_wait_timeout": "20m",
"ssh_pty" : "true",
"shutdown_command": "echo {{user `ssh_pass`}} | sudo -S shutdown -P now",
"boot_command" : [
"<esc><esc><enter><wait>",
"/install/vmlinuz noapic ",
"preseed/url=http://{{ .HTTPIP }}:{{ .HTTPPort }}/preseed.cfg ",
"debian-installer=en_US auto locale=en_US kbd-chooser/method=us ",
"hostname={{user `hostname`}} ",
"fb=false debconf/frontend=noninteractive ",
"keyboard-configuration/modelcode=SKIP keyboard-configuration/layout=USA ",
"keyboard-configuration/variant=USA console-setup/ask_detect=false ",
"initrd=/install/initrd.gz -- <enter>"
]
2017-08-24 08:35:46 +02:00
},
{
"type": "vmware-iso",
"headless": "true",
2017-08-24 08:35:46 +02:00
"guest_os_type": "ubuntu-64",
"vm_name": "{{user `vm_name`}}",
"disk_size": "{{user `disk_size`}}",
"iso_url": "http://releases.ubuntu.com/17.10/ubuntu-17.10.1-server-amd64.iso",
"iso_checksum": "8ff73f1b622276758475c3bd5190b382774626de5a82c50930519381f6c3a3f8",
2017-08-24 08:35:46 +02:00
"iso_checksum_type": "sha256",
"http_directory" : "preseeds",
"http_port_min" : 9001,
"http_port_max" : 9011,
"ssh_username": "{{user `ssh_name`}}",
"ssh_password": "{{user `ssh_pass`}}",
"ssh_wait_timeout": "20m",
"ssh_pty" : "true",
"shutdown_command": "echo {{user `ssh_pass`}} | sudo -S shutdown -P now",
"boot_command" : [
"<esc><esc><enter><wait>",
"/install/vmlinuz noapic ",
"preseed/url=http://{{ .HTTPIP }}:{{ .HTTPPort }}/preseed.cfg ",
"debian-installer=en_US auto locale=en_US kbd-chooser/method=us ",
"hostname={{user `hostname`}} ",
"fb=false debconf/frontend=noninteractive ",
"keyboard-configuration/modelcode=SKIP keyboard-configuration/layout=USA ",
"keyboard-configuration/variant=USA console-setup/ask_detect=false ",
"initrd=/install/initrd.gz -- <enter>"
],
"skip_compaction": false
2017-08-23 11:55:44 +02:00
}
],
"provisioners": [{
"type": "shell",
"execute_command": "echo '{{user `ssh_pass`}}' | {{ .Vars }} sudo -E -S sh '{{ .Path }}'",
"inline": [
"echo '%sudo ALL=(ALL) NOPASSWD:ALL' >> /etc/sudoers"
]
},
{
"type": "shell",
"execute_command" : "echo '{{user `ssh_pass`}}' | {{ .Vars }} sudo -E -S sh '{{ .Path }}'",
"script": "scripts/bootstrap.sh",
"pause_before": "10s"
}],
"post-processors":[{
"type": "checksum",
"checksum_types": ["sha1", "sha256", "sha384", "sha512"]
2017-08-23 11:55:44 +02:00
}]
}