Bug 538378 - Would be nice to provide virsh with defaults in config file for connection
Summary: Would be nice to provide virsh with defaults in config file for connection
Keywords:
Status: CLOSED UPSTREAM
Alias: None
Product: Virtualization Tools
Classification: Community
Component: libvirt
Version: unspecified
Hardware: All
OS: Linux
low
low
Target Milestone: ---
Assignee: Libvirt Maintainers
QA Contact:
URL:
Whiteboard:
: 732364 (view as bug list)
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2009-11-18 12:41 UTC by Olivier Berger
Modified: 2015-04-08 11:38 UTC (History)
5 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2015-04-08 11:38:17 UTC
Embargoed:


Attachments (Terms of Use)

Description Olivier Berger 2009-11-18 12:41:16 UTC
Description of problem:

virsh seems to have no other way to specify the default connection it has to use other than by environment var VIRSH_DEFAULT_CONNECT_URI

It would be great to be able to store this in a kind of ~/.virshrc file

Version-Release number of selected component (if applicable):

0.7.2

How reproducible:

All times

This is obviously a wishlist.

Comment 1 Ján Tomko 2015-03-16 16:49:30 UTC
*** Bug 732364 has been marked as a duplicate of this bug. ***

Comment 2 Martin Kletzander 2015-04-08 11:38:17 UTC
There is a possibility to setting the default connection (even without using an alias or shell wrapper function) in cat ~/.config/libvirt/libvirt.conf; that file has the same syntax as the system-wide config file /etc/libvirt/libvirt.conf, but sets it for the user only.  Also applies to all connections, not just virsh.

Example config file is the system-wide one, we cannot initialize example file for all users on the system during installation.  Therefore I believe this bug is fixed.


Note You need to log in before you can comment on or make changes to this bug.