File: virtualization.md

package info (click to toggle)
python-pynetbox 7.6.1-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 1,296 kB
  • sloc: python: 4,343; makefile: 3
file content (24 lines) | stat: -rw-r--r-- 814 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
# Virtualization

This page documents special methods available for Virtualization models in pyNetBox.

!!! note "Standard API Operations"
    Standard CRUD operations (`.all()`, `.filter()`, `.get()`, `.create()`, `.update()`, `.delete()`) follow NetBox's REST API patterns. Refer to the [NetBox API documentation](https://demo.netbox.dev/api/docs/) for details on available endpoints and filters.

## Virtual Machines

### Config Rendering

The `render_config` property renders virtual machine configuration based on config contexts and templates.

::: pynetbox.models.virtualization.VirtualMachines.render_config
    handler: python
    options:
        show_source: true

**Example:**
```python
vm = nb.virtualization.virtual_machines.get(name='web-vm-01')
config = vm.render_config.create()
print(config)
```