forked from librenms/packer-builds
-
Notifications
You must be signed in to change notification settings - Fork 0
/
ubuntu-18.04-amd64.json
124 lines (124 loc) · 4.97 KB
/
ubuntu-18.04-amd64.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
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
{
"_comment": "Build with `packer build ubuntu.json`",
"builders": [{
"type": "virtualbox-iso",
"boot_command": [
"{{ user `boot_command_prefix` }}",
"/install/vmlinuz noapic ",
"initrd=/install/initrd.gz ",
"preseed/url=http://{{ .HTTPIP }}:{{ .HTTPPort }}/ubuntu-18.04/preseed.cfg ",
"debian-installer=en_US auto locale=en_US kbd-chooser/method=us ",
"hostname={{ user `hostname` }} ",
"grub-installer/bootdev=/dev/sda<wait> ",
"fb=false debconf/frontend=noninteractive ",
"keyboard-configuration/modelcode=SKIP keyboard-configuration/layout=USA ",
"keyboard-configuration/variant=USA console-setup/ask_detect=false ",
"passwd/user-fullname={{ user `ssh_fullname` }} ",
"passwd/user-password={{ user `ssh_password` }} ",
"passwd/user-password-again={{ user `ssh_password` }} ",
"passwd/username={{ user `ssh_username` }} ",
"-- <enter>"
],
"disk_size": "{{ user `disk_size` }}",
"guest_additions_path": "VBoxGuestAdditions_{{.Version}}.iso",
"guest_os_type": "Ubuntu_64",
"headless": "{{ user `headless` }}",
"http_directory": "http",
"iso_checksum": "{{ user `iso_checksum` }}",
"iso_checksum_type": "{{ user `iso_checksum_type` }}",
"iso_urls": [
"{{ user `iso_path` }}/{{ user `iso_name` }}",
"{{ user `mirror` }}/ubuntu/releases/bionic/release/{{ user `iso_name` }}"
],
"shutdown_command": "sudo usermod -L vagrant && sudo chage -d 0 vagrant && sudo systemctl poweroff",
"ssh_password": "{{ user `ssh_password` }}",
"ssh_username": "{{ user `ssh_username` }}",
"ssh_timeout": "{{user `ssh_timeout`}}",
"vboxmanage": [
["modifyvm", "{{.Name}}", "--audio", "none"],
["modifyvm", "{{.Name}}", "--usb", "off"],
["modifyvm", "{{.Name}}", "--vram", "12"],
["modifyvm", "{{.Name}}", "--vrde", "off"],
["modifyvm", "{{.Name}}", "--memory", "{{ user `memory` }}"],
["modifyvm", "{{.Name}}", "--cpus", "{{ user `cpus` }}"],
[ "modifyvm", "{{.Name}}", "--natpf1", "ssh,tcp,,2023,,22" ],
[ "modifyvm", "{{.Name}}", "--natpf1", "http,tcp,,8080,,80" ]
],
"virtualbox_version_file": ".vbox_version",
"output_directory": "output-ubuntu-18.04-amd64-{{build_type}}",
"vm_name": "librenms-ubuntu-18.04-amd64",
"export_opts":
[
"--manifest",
"--vsys", "0",
"--product", "LibreNMS",
"--producturl", "https://www.librenms.org",
"--description", "LibreNMS, a fully featured network monitoring system that provides a wealth of features and device support.",
"--version", "LibreNMS"
],
"format": "ova"
}],
"provisioners": [
{
"type": "file",
"source": "files/ubuntu/librenms.conf",
"destination": "/tmp/librenms.conf"
},
{
"environment_vars": [
"DEBIAN_FRONTEND=noninteractive",
"DESKTOP={{user `desktop`}}",
"UPDATE={{user `update`}}",
"INSTALL_VAGRANT_KEY={{user `install_vagrant_key`}}",
"SSH_USERNAME={{user `ssh_username`}}",
"SSH_PASSWORD={{user `ssh_password`}}",
"http_proxy={{user `http_proxy`}}",
"https_proxy={{user `https_proxy`}}",
"no_proxy={{user `no_proxy`}}",
"LIBRENMS_VERSION={{user `librenms_version`}}",
"OXIDIZED={{user `oxidized`}}",
"SYSLOG_NG={{user `syslog_ng`}}"
],
"execute_command": "echo '{{ user `ssh_password` }}' | {{.Vars}} sudo -E -S bash '{{.Path}}'",
"expect_disconnect": true,
"type": "shell",
"scripts": [
"scripts/ubuntu/update.sh",
"scripts/ubuntu/apt.sh",
"scripts/ubuntu/virtualbox.sh",
"scripts/ubuntu/vmware.sh",
"scripts/common/vagrant.sh",
"scripts/common/sshd.sh",
"scripts/ubuntu/librenms.sh",
"scripts/ubuntu/syslog-ng.sh",
"scripts/ubuntu/oxidized.sh",
"scripts/ubuntu/cleanup.sh",
"scripts/common/finish.sh",
"scripts/ubuntu/minimize.sh",
"scripts/common/clean_users.sh"
]
}],
"variables": {
"boot_command_prefix": "<enter><wait><f6><esc><bs><bs><bs><bs><bs><bs><bs><bs><bs><bs><bs><bs><bs><bs><bs><bs><bs><bs><bs><bs><bs><bs><bs><bs><bs><bs><bs><bs><bs><bs><bs><bs><bs><bs><bs><bs><bs><bs><bs><bs><bs><bs><bs><bs><bs><bs><bs><bs><bs><bs><bs><bs><bs><bs><bs><bs><bs><bs><bs><bs><bs><bs><bs><bs><bs><bs><bs><bs><bs><bs><bs><bs><bs><bs><bs><bs><bs><bs><bs><bs><bs><bs><bs>",
"cpus": "1",
"desktop": "false",
"disk_size": "40960",
"headless": "false",
"http_proxy": "{{env `http_proxy`}}",
"https_proxy": "{{env `https_proxy`}}",
"install_vagrant_key": "true",
"iso_checksum": "a2cb36dc010d98ad9253ea5ad5a07fd6b409e3412c48f1860536970b073c98f5",
"iso_checksum_type": "sha256",
"iso_name": "ubuntu-18.04.2-server-amd64.iso",
"iso_path": "iso",
"mirror": "http://cdimage.ubuntu.com",
"memory": "512",
"no_proxy": "{{env `no_proxy`}}",
"hostname": "librenms",
"ssh_fullname": "vagrant",
"ssh_password": "vagrant",
"ssh_username": "vagrant",
"ssh_timeout": "60m",
"update": "true"
}
}