Cole Robinson
54b73f4502
cli: Centralize most option handling dispatch
...
Rather than require tools to do multiple parse_* calls. This infrastructure
will help with virt-xml as well.
2014-01-22 10:42:05 -05:00
Cole Robinson
269339f29f
cli: drop get_* helpers, just make parse_* helpers handle all cases
2014-01-22 10:40:48 -05:00
Cole Robinson
d216c44157
Stub out --check-cpu option
...
It's old, uninteresting, and I don't think anyone is depending on it
to work. Parse the command line option, but don't do anything differently.
2014-01-22 10:38:42 -05:00
Cole Robinson
6c7439d625
cli: Drop useless get_uuid helper
2014-01-22 10:36:21 -05:00
Cole Robinson
d1edce1ca5
cli: Drop dest= from most arguments, it was redundant
2014-01-22 10:36:14 -05:00
Cole Robinson
41a84bae9f
cli: Rework adhoc CLI parsing into a class structure
...
This adds:
VirtCLIArgument: a single foo=bar mapping
VirtOptionString: A collection of VirtCLIArguments, that parses the whole thing
VirtCLIParser: Represents a single cli option like --disk, --network, etc.
Centralizing this infrastructure opens up a lot of doors for future
improvements, like cli option introspection.
2014-01-22 10:35:30 -05:00
Chen Hanxiao
a98515a4da
virt-install: add support for '--panic option'
...
Signed-off-by: Chen Hanxiao <chenhanxiao@cn.fujitsu.com>
(crobinso: man page and cli tweaks)
2014-01-22 09:33:18 -05:00
Martin Kletzander
10331a5f14
pylint: Skip hashlib import hackery and remove unused variable
...
hashlib's dynamic import hackery makes pylint very sad since it cannot
realize that the module has sha256 member (just created dynamically),
so let's just make it skip this error.
Also remove unused variable in virtinst.cli
Signed-off-by: Martin Kletzander <mkletzan@redhat.com>
2014-01-20 14:42:07 +01:00
Cole Robinson
c426a30511
Convert all command line handling to argparse
...
Allows us to drop some hacks, and we may need it for a new upcoming
tool.
2014-01-19 11:32:08 -05:00
Cole Robinson
6d2f937c99
virt-install: --host-device: add driver_name option
2014-01-14 18:09:21 -05:00
Cole Robinson
66096a7eeb
choosecd: Check path-in-use collision (bz 1028197)
2014-01-14 17:11:51 -05:00
Cole Robinson
95170e8892
virt-install: Support --network source, source_mode, target
...
The latter two bits are needed for macvtap configuration.
2014-01-06 15:17:32 -05:00
Giuseppe Scrivano
5798c5b9b4
virt-manager: prefer os.makedirs to os.mkdir when creating cache dir
...
Ensure the parent directories exist when attempting to create the
cache directory.
Closes: https://bugzilla.redhat.com/show_bug.cgi?id=1016435
Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2013-11-05 18:15:11 +01:00
Giuseppe Scrivano
a832d77559
virt-install: EGD RNG devs need a host to connect to if backend_mode=bind
...
Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2013-10-28 17:32:06 +01:00
Giuseppe Scrivano
2a040ccd17
mass update: remove double spaces from comments
...
Updated by this script:
find -name '*.py' -exec sed -i "s|^\(#.*[^.?\!]\) \(.*[^#]\)$|\1 \2|g" \{\} \;
Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2013-10-28 17:22:31 +01:00
Cole Robinson
d4103eac26
virt-install: Add '--console none' and '--channel none'
...
For skipping the default channel and default console behavior
2013-10-06 09:43:56 -04:00
Cole Robinson
d0b067f2fc
virt-install: Add --clock option
2013-10-05 16:48:07 -04:00
Fred A. Kemp
05254479db
virt-install: Add --disk removable option
2013-10-04 07:57:13 -04:00
Cole Robinson
d83b2c02fa
virt-manager: Add USB3 convenience option to the controller UI
...
and a --controller usb3 option to virt-install
2013-10-03 16:34:28 -04:00
Giuseppe Scrivano
8e85840546
virt-install: allow to specify "startupPolicy" for --disk
...
Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2013-10-03 16:51:23 +02:00
Cole Robinson
475ec1252e
virt-install: Allow --disk target
...
Shouldn't be needed often, but just in case
2013-10-02 20:15:49 -04:00
Cole Robinson
18d8512699
Move the 'default graphics type' logic into Guest
...
So we can share it, and make virt-install more robust
2013-10-02 18:06:52 -04:00
Cole Robinson
fa0ee32172
virt-install: Fix multiple invocation of --disk pool=default
...
Don't use a global counter, just correctly specify a collidelist with
not yet created disk images
2013-10-02 13:20:27 -04:00
Cole Robinson
dd823d2d8c
cli: Don't log to debug files from the test suite
...
We shouldn't be doing it anyways, but my recent cache_dir change broke
a bunch of stuff without this.
2013-10-01 10:14:46 -04:00
Cole Robinson
0b58badfc1
Storage debug and scratch files in ~/.cache/virt-manager (bz 693028)
2013-10-01 08:28:15 -04:00
Cole Robinson
34c502560f
storage: Drop unused static function
...
This allows us to simplify the parameters for find_free_name
2013-09-30 16:22:12 -04:00
Cole Robinson
86a98f0d39
virt-install: Add --disk backing_store option
2013-09-29 11:23:59 -04:00
Cole Robinson
d414beb3a9
Warn that --prompt mode will likely be removed in the future.
2013-09-28 11:34:03 -04:00
Cole Robinson
4c15da439b
cli: Combine registering a bunch of common options
2013-09-28 11:27:26 -04:00
Cole Robinson
b1fb6c2567
cli: Pass key name to set_param convert_cb for error handling
2013-09-28 10:58:27 -04:00
Cole Robinson
5329a9afc9
virt-install: Add --tpm /dev/tpm convenience option
2013-09-28 10:28:04 -04:00
Cole Robinson
b3719f25ac
cli: s/yes_or_no/yes_no/g
2013-09-28 10:06:52 -04:00
Cole Robinson
b3a72bcb95
cli: Remove unneeded parameter to optparse.add_option
2013-09-28 10:03:08 -04:00
Cole Robinson
eca87838fb
virt-install: Add --features option
...
And hide docs about old --noacpi/--noacpi options. I don't think
anyone really uses them anyways, but if anyone complains we should
just implement --features for the other CLI commands.
2013-09-28 09:58:57 -04:00
Cole Robinson
16a190a0dc
cli: Add some consistency to deprecated option handling
...
Take all the old options and convert them to new style, so the rest
of the app only needs to deal with new style bits.
2013-09-27 22:31:52 -04:00
Cole Robinson
fd00ad74e2
devicehostdev: Drop device creation helper
...
Goes against other device paradigms, and is cleaner when we unwind it.
2013-09-27 18:28:28 -04:00
Cole Robinson
6013622da4
cli: Make option handling more consistent
2013-09-27 16:52:41 -04:00
Giuseppe Scrivano
601eb5f15e
virt-install: accept a single argument form for RNG devices
...
Detect the "--rng /dev/random" case and assume it is the "random" type.
Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2013-09-26 10:09:33 +02:00
Cole Robinson
a2e5206730
deviceinterface: Fix creating direct interfaces (bz 1006324)
...
And take the opportunity to standarize on setting net.source,
rather than have API users have to do net.bridge/network/source_dev
2013-09-24 10:00:01 -04:00
Giuseppe Scrivano
a55438f880
virt-install: add support for virtio-rng devices
...
Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2013-09-20 18:56:19 -04:00
Cole Robinson
fd52fb2c32
util: Drop 'partition' helper, we require python 2.5 these days
2013-09-20 10:05:42 -04:00
Cole Robinson
aff0ddb259
Use XMLBuilder for Storage object handling
...
Simplify the API a bunch while we are at it, add tests, etc.
2013-09-20 10:00:08 -04:00
Cole Robinson
67cc81f6b1
virt-install: Add --boot useserial=on
...
Which gives bios output over serial console via sgabios
2013-09-04 11:57:26 -04:00
Daniel Gollub
1730a8e5ff
virtinst: add nwfilter support
...
This allows to make use of libvirt network filtering support with virt-install.
With the additional option "filterref" in the --network parameter one can
configure any defined nwfilter per network interface, i.e.:
virt-install ... --network network=mynet,model=virtio,filterref=clean-traffic
(crobinso: add an xmlparse test case)
2013-08-29 11:44:40 -04:00
Cole Robinson
e02fa9b4fe
virt-install: Add --boot dtb=DTB support
...
Allows passing in a device tree binary to the guest. Needed for
some non-x86 configurations.
2013-08-16 19:25:26 -04:00
Cole Robinson
c426d5a16f
Guest: Drop os_type, just use single os_variant
...
Internally the distinction hasn't been valuable for a long time,
so simplify the API here.
2013-08-11 12:39:36 -04:00
Cole Robinson
45d2db887d
virt-*: Unify handling of --os-variant
...
And hide --os-type from the cli since it is long since redundant.
2013-08-11 12:39:28 -04:00
Cole Robinson
3e158b80bf
guest: Move cpuset static functions to DomainNumatune
2013-08-11 12:39:28 -04:00
Cole Robinson
00e0057868
cli: Fix some comment spacing
2013-07-31 09:28:35 -04:00
Cole Robinson
85f1e1d4b1
Fix remote URL installs
...
We need to make sure the pool cache is invalidated if we create
the boot-scratch pool. Also share code that builds a volinstall instance.
2013-07-25 16:21:30 -04:00