Something went wrong on our end
-
Nicolas KAROLAK authoredNicolas KAROLAK authored
image.md 1.64 KiB
Image build
Requirements
- Packer: this is the tool that will automate all the steps of image creation
- VMware OVF Tool: this is required by Packer to export the image from the VMware Hypervisor
- A running and reachable VMware ESXi Hypervisor
Prepare Packer file
Copy the example Packer file packer/example.json
, for example to packer/mymediaserver.json
, and edit the copied file.
These variable must be configured:
-
variables.name
: used to set the output filename and the machine hostname -
variables.esx_*
: VMware hypervisor connection settings -
variables.network_*
: used to pre-configure network settings, leave empty to ignore -
variables.skyreach_*
: use eithersystem_key
oractivation_key
and leave the other empty
Then you need the groups that will be applied to the machine, for example for a MediaServer:
{
[...]
"provisioners": [
[...]
{
"type": "ansible",
[...]
"groups": [
"msmonitor",
"postgres",
"mirismanager",
"wowza",
"celerity",
"mediaserver",
"mediaimport"
]
}
]
}
For a worker:
{
[...]
"provisioners": [
[...]
{
"type": "ansible",
[...]
"groups": [
"mediaworker"
]
}
]
}
You can also pass additional variables to ansible in provisionners['1'].extra_arguments
.
Build image
Check that the Packer file is valid (the hypervisor must be reachable):
make image-validate build=packer/mymediaserver.json
Build the OVA:
make image build=packer/mymediaserver.json