mirror of
https://github.com/libvirt/libvirt.git
synced 2025-02-25 18:55:26 -06:00
Introduce source flags to virDomainGetHostname()
There is a lots of possibilities to retrieve hostname information from domain. Libvirt could use lease information from dnsmasq to get current hostname too. QEMU supports QEMU-agent but it can use lease source. Signed-off-by: Julio Faracco <jcfaracco@gmail.com> Signed-off-by: Michal Privoznik <mprivozn@redhat.com> Reviewed-by: Erik Skultety <eskultet@redhat.com>
This commit is contained in:
committed by
Michal Privoznik
parent
2033668bc7
commit
3cf12299f6
@@ -1567,6 +1567,12 @@ int virDomainSetMemoryStatsPeriod (virDomainPtr domain,
|
||||
int virDomainGetMaxVcpus (virDomainPtr domain);
|
||||
int virDomainGetSecurityLabel (virDomainPtr domain,
|
||||
virSecurityLabelPtr seclabel);
|
||||
|
||||
typedef enum {
|
||||
VIR_DOMAIN_GET_HOSTNAME_LEASE = (1 << 0), /* Parse DHCP lease file */
|
||||
VIR_DOMAIN_GET_HOSTNAME_AGENT = (1 << 1), /* Query qemu guest agent */
|
||||
} virDomainGetHostnameFlags;
|
||||
|
||||
char * virDomainGetHostname (virDomainPtr domain,
|
||||
unsigned int flags);
|
||||
int virDomainGetSecurityLabelList (virDomainPtr domain,
|
||||
|
||||
@@ -332,6 +332,7 @@ typedef enum {
|
||||
VIR_ERR_INVALID_NETWORK_PORT = 105, /* invalid network port object */
|
||||
VIR_ERR_NETWORK_PORT_EXIST = 106, /* the network port already exist */
|
||||
VIR_ERR_NO_NETWORK_PORT = 107, /* network port not found */
|
||||
VIR_ERR_NO_HOSTNAME = 108, /* no domain's hostname found */
|
||||
|
||||
# ifdef VIR_ENUM_SENTINELS
|
||||
VIR_ERR_NUMBER_LAST
|
||||
|
||||
Reference in New Issue
Block a user