-
Notifications
You must be signed in to change notification settings - Fork 4
/
ubuntu-zfs-efi-single.json
79 lines (79 loc) · 2.89 KB
/
ubuntu-zfs-efi-single.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
78
79
{
"variables": {
"output_dir": "output-ubuntu-zfs-efi-single"
},
"provisioners": [
{
"type": "ansible-local",
"playbook_dir": "ansible",
"playbook_file": "ansible/playbook.yml",
"inventory_file": "ansible/inventory",
"command": "ANSIBLE_FORCE_COLOR=1 PYTHONUNBUFFERED=1 DEFAULT_STDOUT_CALLBACK=yaml ansible-playbook",
"extra_arguments": [
"-v",
"-e", "zfsprep_efi=true",
"-e", "'{\"zfsprep_root_disks\": [sda]}'",
"-e", "'{\"zfsprep_data_disks\": [sdb]}'",
"-e", "'{\"zfsprep_luks_root_names\": [e0]}'",
"-e", "'{\"zfsprep_luks_data_names\": [e1]}'",
"-e", "zfsprep_root_pool_type=''",
"-e", "zfsprep_data_pool_type=''"
]
},
{
"type": "shell",
"script": "ansible/install-vbox-additions.sh"
},
{
"type": "shell",
"inline": [
"true #set to false to pause so we can troubleshoot build"
]
}
],
"builders": [
{
"type": "virtualbox-iso",
"output_directory": "{{ user `output_dir` }}",
"boot_command": [
"<down>e<wait><down><down><down><end><bs><bs><bs><bs><bs><bs><bs><bs><bs><bs><bs><bs><bs><bs><bs><bs><wait>",
"systemd.unit=multi-user.target<f10>",
"<wait10><wait10><wait5>ubuntu<enter><wait><enter><wait>sudo -i<enter><wait>",
"<wait>passwd<enter>vagrant<enter>vagrant<enter><wait>",
"apt-get update && ",
"add-apt-repository universe && ",
"apt-get install -y openssh-server ansible && ",
"echo PermitRootLogin yes >> /etc/ssh/sshd_config && ",
"service ssh restart<enter>"
],
"boot_wait": "5s",
"disk_size": 8192,
"guest_os_type": "Ubuntu_64",
"iso_interface": "sata",
"hard_drive_interface": "sata",
"sata_port_count": "5",
"headless": true,
"http_directory": "http",
"iso_urls": [
"http://releases.ubuntu.com/18.04/ubuntu-18.04.3-desktop-amd64.iso"
],
"iso_checksum_type": "sha256",
"iso_checksum": "add4614b6fe3bb8e7dddcaab0ea97c476fbd4ffe288f2a4912cb06f1a47dcfa0",
"ssh_username": "root",
"ssh_password": "vagrant",
"ssh_port": 22,
"ssh_wait_timeout": "10000s",
"guest_additions_path": "VBoxGuestAdditions.iso",
"virtualbox_version_file": ".vbox_version",
"vm_name": "packer-ubuntu-zfs-efi-x86_64",
"vboxmanage": [
[ "modifyvm", "{{.Name}}", "--firmware", "efi" ],
[ "modifyvm", "{{.Name}}", "--memory", "2048" ],
[ "modifyvm", "{{.Name}}", "--cpus", "2" ],
[ "modifyvm", "{{.Name}}", "--rtcuseutc", "on" ],
[ "createhd", "--format", "VDI", "--filename", "{{ user `output_dir` }}/disk2.vdi", "--size", "8192" ],
[ "storageattach", "{{.Name}}", "--storagectl", "SATA Controller", "--port", "2", "--type", "hdd", "--medium", "{{ user `output_dir` }}/disk2.vdi" ]
]
}
]
}