mirror of
https://github.com/vagrant-libvirt/vagrant-libvirt.git
synced 2025-02-25 18:55:27 -06:00
add pxe boot public_network example
This commit is contained in:
18
README.md
18
README.md
@@ -1389,6 +1389,24 @@ Name of network "foreman_managed" is key for define boot order
|
|||||||
end
|
end
|
||||||
```
|
```
|
||||||
|
|
||||||
|
An example VM that is PXE booted from the `br1` device (which must already be configured in the host machine), and if that fails, is booted from the disk:
|
||||||
|
|
||||||
|
```ruby
|
||||||
|
Vagrant.configure("2") do |config|
|
||||||
|
config.vm.define :pxeclient do |pxeclient|
|
||||||
|
pxeclient.vm.network :public_network,
|
||||||
|
dev: 'br1',
|
||||||
|
auto_config: false
|
||||||
|
pxeclient.vm.provider :libvirt do |domain|
|
||||||
|
boot_network = {'dev' => 'br1'}
|
||||||
|
domain.storage :file, :size => '100G'
|
||||||
|
domain.boot boot_network
|
||||||
|
domain.boot 'hd'
|
||||||
|
end
|
||||||
|
end
|
||||||
|
end
|
||||||
|
```
|
||||||
|
|
||||||
## SSH Access To VM
|
## SSH Access To VM
|
||||||
|
|
||||||
vagrant-libvirt supports vagrant's [standard ssh
|
vagrant-libvirt supports vagrant's [standard ssh
|
||||||
|
|||||||
Reference in New Issue
Block a user