-
Notifications
You must be signed in to change notification settings - Fork 33
/
bitcrazeVM_provisionVM.json
77 lines (77 loc) · 2.36 KB
/
bitcrazeVM_provisionVM.json
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
{
"builders": [
{
"boot_wait": "30s",
"format": "ova",
"import_opts": "importtovdi",
"shutdown_command": "echo '{{user `password`}}' | sudo -S shutdown -P now",
"source_path": "output-virtualbox-iso/{{user `vm-name`}}.ova",
"ssh_password": "{{user `password`}}",
"ssh_timeout": "10000s",
"ssh_username": "{{user `user`}}",
"type": "virtualbox-ovf",
"vboxmanage": [
["modifyvm", "{{.Name}}", "--audio", "pulse"],
["modifyvm", "{{.Name}}", "--audiocodec", "ad1980"],
["modifyvm", "{{.Name}}", "--usb", "on"],
["modifyvm", "{{.Name}}", "--usb-xhci", "on"],
["modifyvm", "{{.Name}}", "--vrde", "off"],
["modifyvm", "{{.Name}}", "--nictype1", "virtio"],
["modifyvm", "{{.Name}}", "--memory", "2048"],
["modifyvm", "{{.Name}}", "--cpus", "2"],
["modifyvm", "{{.Name}}", "--vram", "64"],
["modifyvm", "{{.Name}}", "--graphicscontroller", "vmsvga"],
["modifyvm", "{{.Name}}", "--mouse", "usbtablet"],
["modifyvm", "{{.Name}}", "--nestedpaging", "off"],
["modifyvm", "{{.Name}}", "--nat-localhostreachable1", "on"],
[
"storageattach",
"{{.Name}}",
"--storagectl",
"SATA Controller",
"--port",
"0",
"--nonrotational",
"on",
"--discard",
"on"
]
],
"virtualbox_version_file": ".vbox_version",
"vm_name": "{{user `vm-name`}}"
}
],
"provisioners": [
{
"source": "{{user `contentDir`}}/update_all_projects.sh",
"destination": "/home/bitcraze/update_all_projects.sh",
"type": "file"
},
{
"source": "{{user `contentDir`}}/Desktop",
"destination": "/home/bitcraze",
"type": "file"
},
{
"source": "{{user `contentDir`}}/Pictures",
"destination": "/home/bitcraze",
"type": "file"
},
{
"execute_command": "echo '{{user `password`}}' | {{ .Vars }} sh '{{ .Path }}'",
"script": "provision.sh",
"type": "shell"
},
{
"execute_command": "echo '{{user `password`}}' | {{ .Vars }} sudo -E -S sh '{{ .Path }}'",
"script": "provision-sudo.sh",
"type": "shell"
}
],
"variables": {
"contentDir": "contentForVM",
"password": "crazyflie",
"user": "bitcraze",
"vm-name": "BitcrazeVM"
}
}