-
Notifications
You must be signed in to change notification settings - Fork 458
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Create a CDRom with ISO to boot from ? #1076
Comments
Hi @gabrielmccoll When you provision from virt-manager, you create a VM with a cdrom attached with an install ISO and an extra disk volume where the actual filesystem will be installed. Then virt-manager sets a boot order of disk first, then cdrom. Since the disk is empty, this is how it chooses to boot from cdrom and when you open virt-viewer you see the options "Install or Test OS". Then you make a manual choice and if you chose install - the anakonda installer starts where you need to provide some manual options. To simulate this aspect, please take a look at this main.tf file
The drawback is that you will have to wait for the installation process that can be quite slow. You could automate this process using kickstart files but to my knowledge there is no way to do it with the current provider configuration. This provider is usually made for cloudinit, ignition, and prebuilt images(virt-installer) that already have the entire filesystem and/or whatever services are requires by cloudinit and ignition. If you are well versed with libvirt, the xml option in this provider gives you the liberty to override and provide direct xml configurations that could help with the kickstart workaround. |
To build an image that has the entire vm filesystem, run this command
The kickstart file contains all the options you manually input by hand in the anaconda installer for example in the above step. An example of such kickstart.ks can be the following
virt-install will successfully run and build fedora39_disk.qcow2 - this is the disk image that you can give to the terraform provisioner and will have a complete installed system with user, packages and whatever kickstart allows to customize... |
I think this is related to #1093 |
I am likely just being ignorant but just am trying to mimic what I've done in virt manager and create a vm with a 20GB disk and a cdrom using the iso I have to boot from.
I can get the vm (domain) to boot and make a 20GB disk (tho slightly different) but I can't seem to make a CDRom to boot from.
Any steer please ?
The text was updated successfully, but these errors were encountered: