-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathubuntu.json
102 lines (96 loc) · 2.93 KB
/
ubuntu.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
{
"builders": [{
"name": "kubernetes",
"vm_name": "VMware-ubuntu-kubernetes",
"type": "vmware-iso",
"guest_os_type": "ubuntu-64",
"tools_upload_flavor": "linux",
"keep_registered": true,
"headless": false,
"disk_size": 20000,
"vmx_data": {
"ethernet0.networkName": "VM Network",
"memsize": "8192",
"numvcpus": "2"
},
"vnc_disable_password": true,
"http_directory": "preseed",
"format": "ova",
"disk_type_id": "thin",
"iso_url": "http://releases.ubuntu.com/xenial/ubuntu-16.04.5-server-amd64.iso",
"iso_checksum": "c94de1cc2e10160f325eb54638a5b5aa38f181d60ee33dae9578d96d932ee5f8",
"iso_checksum_type": "sha256",
"ssh_username": "kube",
"ssh_password": "kube",
"ssh_timeout": "15m",
"boot_command": [
"<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>",
"auto=true ",
"priority=critical ",
"url=http://{{ .HTTPIP }}:{{ .HTTPPort }}/ubuntu.cfg ",
"hostname={{ .Name }} ",
"initrd=/install/initrd.gz ",
"grub-installer/bootdev=/dev/sda ",
"<enter>"
],
"shutdown_command": "echo 'kube' | sudo -S systemctl poweroff",
"remote_type": "esx5",
"remote_host": "{{user `esxi_host`}}",
"remote_datastore": "{{user `esxi_datastore`}}",
"remote_username": "{{user `esxi_username`}}",
"remote_password": "{{user `esxi_password`}}"
}],
"provisioners": [
{
"type": "file",
"source": "scripts/inputrc",
"destination": ".inputrc"
},
{
"type": "file",
"source": "scripts/setup_dispatch.sh",
"destination": "/tmp/setup_dispatch"
},
{
"type": "shell",
"execute_command": "echo 'kube' | {{ .Vars }} sudo -E -S sh '{{ .Path }}'",
"script": "scripts/install.sh"
},
{
"type": "shell",
"execute_command": "echo 'kube' | {{ .Vars }} sudo -E -S sh '{{ .Path }}'",
"script": "scripts/install_kubernetes.sh"
},
{
"type": "shell",
"execute_command": "echo 'kube' | {{ .Vars }} sudo -E -S sh '{{ .Path }}'",
"script": "scripts/network.sh"
},
{
"type": "shell",
"execute_command": "echo 'kube' | {{ .Vars }} sudo -E -S sh '{{ .Path }}'",
"script": "scripts/cleanup.sh"
}
],
"post-processors": [
{
"type": "vsphere-template",
"host": "{{user `vc_host`}}",
"insecure": true,
"username": "{{user `vc_username`}}",
"password": "{{user `vc_password`}}",
"datacenter": "datacenter",
"folder": "/packer-templates/kubernetes"
}
]
}