Merge heads
This commit is contained in:
commit
03128a2442
9
AUTHORS
9
AUTHORS
|
@ -3,16 +3,19 @@
|
|||
|
||||
Virtual Machine Manager code is developed by:
|
||||
|
||||
Daniel Berrange <berrange@redhat.com>
|
||||
Hugh O. Brock <hbrock@redhat.com>
|
||||
Daniel Berrange <berrange-at-redhat-dot-com>
|
||||
Hugh O. Brock <hbrock-at-redhat-dot-com>
|
||||
Jeremy Katz <katzj-at-redhat-dot-com>
|
||||
|
||||
The user interaction / interface design and artwork is
|
||||
done by:
|
||||
|
||||
Máirín Duffy <duffy@redhat.com>
|
||||
Máirín Duffy <duffy-at-redhat-dot-com>
|
||||
|
||||
Further patches have been submitted by:
|
||||
|
||||
William Sheehan <william-dot-sheehan-at-openinterface-dot-com>
|
||||
|
||||
<...send a patch & get your name here...>
|
||||
|
||||
|
||||
|
|
707
ChangeLog
707
ChangeLog
|
@ -1,8 +1,655 @@
|
|||
2006-09-15 "Daniel P. Berrange <berrange@redhat.com>
|
||||
|
||||
* po/Makefile.am, po/en_GB.po, po/virt-manager.pot:
|
||||
Refreshd POT files
|
||||
[d5b685a8f1e4] [tip]
|
||||
|
||||
* src/virt-manager.glade:
|
||||
Always enable VNC toolbars to avoid GTK window resizing issues
|
||||
[a1a7e46e23a4]
|
||||
|
||||
2006-09-13 "Daniel P. Berrange <berrange@redhat.com>
|
||||
|
||||
* Merge heads
|
||||
[e8947829c1e6]
|
||||
|
||||
* src/vncViewer/rfb.py, src/vncViewer/vnc.py:
|
||||
Added support for batching of redraws. Initial support for hextile,
|
||||
albeit faaaaar to slow to turn on. Fix signature of cursor method
|
||||
[4db02411579c]
|
||||
|
||||
2006-09-12 berrange <berrange@dhcp-4-245.virt.boston.redhat.com>
|
||||
|
||||
* src/virt-manager.glade, src/virtManager/create.py:
|
||||
Re-factor the install wizard to only grab values at end of process.
|
||||
Also display a config summary at end
|
||||
[e8a823f31a35]
|
||||
|
||||
2006-09-11 berrange <berrange@dhcp-4-245.virt.boston.redhat.com>
|
||||
|
||||
* src/virt-manager.glade, src/virtManager/about.py:
|
||||
Since we don't run the blocking event loop, hook up the response
|
||||
signal for the close button. bz 205943
|
||||
[493496779f6a]
|
||||
|
||||
2006-09-04 "Daniel P. Berrange <berrange@redhat.com>
|
||||
|
||||
* .hgtags:
|
||||
Added tag RELEASE-0.2.1-1 for changeset
|
||||
4aba9106462877a7df2bf1211bc41eb5321af1ee
|
||||
[d94ce2d634e1]
|
||||
|
||||
* ChangeLog, configure.ac, po/virt-manager.pot, virt-manager.spec.in:
|
||||
Bump to 0.2.1 for new release
|
||||
[4aba91064628] [RELEASE-0.2.1-1]
|
||||
|
||||
2006-09-01 "Daniel P. Berrange <berrange@redhat.com>
|
||||
|
||||
* po/virt-manager.pot, src/Makefile.am, src/virt-manager.glade, src
|
||||
/virt-manager.schemas.in, src/virtManager/preferences.py, virt-
|
||||
manager.spec.in:
|
||||
Hide preference for stats history length. Add gconf schema to setup
|
||||
default config settings.
|
||||
[1ab3b1657a5b]
|
||||
|
||||
* src/virt-manager.glade, src/virtManager/details.py,
|
||||
src/virtManager/manager.py:
|
||||
Hide / disable stuff we're not implementing yet - ie disk/net stats
|
||||
& new hardware
|
||||
[d41ce447fd19]
|
||||
|
||||
* src/virt-manager.glade, src/virtManager/details.py:
|
||||
Change slider to spin box for adjusting memory
|
||||
[80753ab23d1b]
|
||||
|
||||
2006-09-01 "Jeremy Katz <katzj@redhat.com>
|
||||
|
||||
* src/virt-manager.glade, src/virtManager/console.py:
|
||||
merge
|
||||
[8a71c82f3208]
|
||||
|
||||
* src/virt-manager.glade, src/virtManager/create.py:
|
||||
some text tweaks. also, don't ask about PV vs FV if not on a FV
|
||||
capable box
|
||||
[d73bd51d34a4]
|
||||
|
||||
* src/virt-manager.glade:
|
||||
switch memory config to spin buttons
|
||||
[be2ff5d5065e]
|
||||
|
||||
* src/virt-manager.glade, src/virtManager/details.py:
|
||||
add a menu bar for the details view, move some things around to be
|
||||
similar to the console view
|
||||
[10efc7ee07d0]
|
||||
|
||||
* src/virtManager/console.py:
|
||||
tie together pause buttons
|
||||
[a222c2f9bfe6]
|
||||
|
||||
* pixmaps/icon_shutdown.png, src/virt-manager.glade,
|
||||
src/virtManager/console.py:
|
||||
various UI tweaks for the graphical console to match the HIG as well
|
||||
as to be a little cleaner looking
|
||||
[b212dd69d528]
|
||||
|
||||
2006-09-01 "Daniel P. Berrange <berrange@redhat.com>
|
||||
|
||||
* src/virt-manager.glade:
|
||||
Merge heads
|
||||
[89413ec479a2]
|
||||
|
||||
* po/virt-manager.pot, src/virt-manager.glade,
|
||||
src/virtManager/console.py:
|
||||
Grab keyboard when going full screen. Center vnc/image widgets so it
|
||||
looks better full screen
|
||||
[5ac5dd9841d7]
|
||||
|
||||
2006-09-01 "Jeremy Katz <katzj@redhat.com>
|
||||
|
||||
* src/virt-manager.glade:
|
||||
merge
|
||||
[e32d7b41e2fd]
|
||||
|
||||
* src/virt-manager.glade, src/virtManager/create.py:
|
||||
some UI cleanups for domain creation wizard
|
||||
[a19f67306922]
|
||||
|
||||
2006-08-31 "Daniel P. Berrange <berrange@redhat.com>
|
||||
|
||||
* src/virt-manager.glade:
|
||||
Switched memory slider policy to discontinuous & ensure adjustments
|
||||
are in units of 1, not fractional
|
||||
[fa21d7642401]
|
||||
|
||||
2006-08-29 "Jeremy Katz <katzj@redhat.com>
|
||||
|
||||
* merge
|
||||
[0db881092cda]
|
||||
|
||||
2006-08-28 "Jeremy Katz <katzj@redhat.com>
|
||||
|
||||
* src/virtManager/create.py:
|
||||
support for graphics console with PV guests, show the appropriate
|
||||
console once the guest is created
|
||||
[d1df8674daf9]
|
||||
|
||||
2006-08-29 "Daniel P. Berrange <berrange@redhat.com>
|
||||
|
||||
* src/virt-manager.glade, src/virtManager/console.py:
|
||||
Added button to make VNC window fullscreen
|
||||
[5b6f6e513dfd]
|
||||
|
||||
* src/virt-manager.glade, src/virtManager/details.py,
|
||||
src/virtManager/domain.py:
|
||||
Extract disk & network device information from domain XML
|
||||
[1a988faa3844]
|
||||
|
||||
2006-08-28 "Daniel P. Berrange <berrange@redhat.com>
|
||||
|
||||
* src/virtManager/manager.py:
|
||||
Use a stock label for popup menu
|
||||
[c519f8a691c6]
|
||||
|
||||
* po/virt-manager.pot, src/virtManager/connect.py,
|
||||
src/virtManager/console.py, src/virtManager/details.py,
|
||||
src/virtManager/remote.py, src/vncViewer/rfb.py,
|
||||
src/vncViewer/vnc.py:
|
||||
Re-factor VNC auth protocol handling to allow caller to determine
|
||||
whether a password is needed or not. Go straight to VNC viewer if no
|
||||
auth is needed. Set default button/focus handling.
|
||||
[a7281bebdce3]
|
||||
|
||||
* src/virtManager/details.py:
|
||||
Disable hardware config if we're read only. Hide unused 'add
|
||||
hardware' option
|
||||
[219fbd513836]
|
||||
|
||||
2006-08-25 "Daniel P. Berrange <berrange@redhat.com>
|
||||
|
||||
* docs/dbus-remote-control.txt, src/virtManager/remote.py:
|
||||
Hook up the serial console to dbus service
|
||||
[41b18c50618d]
|
||||
|
||||
* virt-manager.spec.in:
|
||||
Pulled in latest changes to spec file from Fedora
|
||||
[047346ff3818]
|
||||
|
||||
2006-08-24 "Hugh O. Brock <hbrock@redhat.com>
|
||||
|
||||
* src/virtManager/create.py:
|
||||
remove ugly print spew
|
||||
[959bff8e7c94]
|
||||
|
||||
2006-08-23 "Hugh O. Brock <hbrock@redhat.com>
|
||||
|
||||
* src/virtManager/create.py:
|
||||
Fix default value on file size spinner
|
||||
[e3c10baaa3e3]
|
||||
|
||||
* merge Dan's changes
|
||||
[9a395dff3d21]
|
||||
|
||||
* src/virt-manager.glade, src/virtManager/create.py:
|
||||
Pull cdrom path from HAL -- allow installs from CD as well as iso
|
||||
[658a94a58d9b]
|
||||
|
||||
2006-08-22 "Daniel P. Berrange <berrange@redhat.com>
|
||||
|
||||
* .hgtags:
|
||||
Added tag RELEASE-0.2.0-1 for changeset
|
||||
869707b48d518080f877bace387fa43458e197e0
|
||||
[59614715161b]
|
||||
|
||||
* po/Makefile.am:
|
||||
Rename one of the targets to avoid accidental build artifacts
|
||||
getting into the dist tarball
|
||||
[869707b48d51] [RELEASE-0.2.0-1]
|
||||
|
||||
* Merged heads
|
||||
[ddd0925ecb0f]
|
||||
|
||||
* README, configure.ac, po/virt-manager.pot, virt-manager.spec.in:
|
||||
Incremented deps on xeninst & libvirt. Bumped release to 0.2.0
|
||||
[815a974f1e27]
|
||||
|
||||
2006-08-22 "Hugh O. Brock <hbrock@redhat.com>
|
||||
|
||||
* src/virtManager/create.py:
|
||||
Fix typo
|
||||
[43d3fe453377]
|
||||
|
||||
* src/virtManager/create.py:
|
||||
properly unmount nfs dirs when done, do better with error handling
|
||||
[140b26d878c9]
|
||||
|
||||
2006-08-21 "Hugh O. Brock <hbrock@redhat.com>
|
||||
|
||||
* src/virtManager/config.py, src/virtManager/create.py:
|
||||
Add proper python logging, better kickstart URL validation, better
|
||||
create error handling.
|
||||
[f91df0c68be8]
|
||||
|
||||
* src/virtManager/create.py:
|
||||
Add URL validation, better error handling. Better logging coming.
|
||||
[ded6e0492a04]
|
||||
|
||||
* src/virtManager/connection.py, src/virtManager/create.py,
|
||||
src/virtManager/engine.py, src/virtManager/manager.py:
|
||||
Add code to register/unregister vm-added signal to stop consoles
|
||||
from spontaneously popping up
|
||||
[9ef14336af51]
|
||||
|
||||
2006-08-18 "Daniel P. Berrange <berrange@redhat.com>
|
||||
|
||||
* src/virt-manager.glade:
|
||||
Wrap message about max memory in details dialog box
|
||||
[548990eead29]
|
||||
|
||||
* po/virt-manager.pot, src/virt-manager.glade:
|
||||
Reverting a bunch of stuff an old version of glade-2 changed when it
|
||||
shouldn't have from changeset d189201f4cf6
|
||||
[695c219eb1d1]
|
||||
|
||||
* docs/dbus-remote-control.txt, src/virtManager/remote.py:
|
||||
Hook up domain creator to dbus service. Fix dbus docs
|
||||
[c43faf7c5a63]
|
||||
|
||||
* src/virtManager/serialcon.py:
|
||||
Fix method naming to be consistent with other widgets - this makes
|
||||
auto-close upon domain destroy work
|
||||
[0d628d6f6b76]
|
||||
|
||||
* po/virt-manager.pot, src/virtManager/serialcon.py:
|
||||
Catch & ignore errors when closing serial console
|
||||
[ee203d7879f5]
|
||||
|
||||
* po/virt-manager.pot, src/virtManager/create.py,
|
||||
src/virtManager/engine.py:
|
||||
If creating a PV domain, show the serial terminal instead of VNC
|
||||
console (temporary until PV vfb works)
|
||||
[1d44b35da842]
|
||||
|
||||
* po/virt-manager.pot, src/virtManager/console.py:
|
||||
Print error message when failing to use console
|
||||
[15affad10836]
|
||||
|
||||
* src/virt-manager.glade:
|
||||
Merge heads
|
||||
[d189201f4cf6]
|
||||
|
||||
* po/virt-manager.pot, src/virt-manager.glade:
|
||||
Remove the 'secure connection' radiobutton (again). Rename
|
||||
restoremenu
|
||||
[7d7ca9b9dea0]
|
||||
|
||||
* src/virtManager/manager.py:
|
||||
Disable new domain, restore domain menus / buttons for a read only
|
||||
connections
|
||||
[e5f4bbbd0fb3]
|
||||
|
||||
* src/virtManager/engine.py:
|
||||
Destroy serial console window when a domain goes away
|
||||
[82e8bf8761f0]
|
||||
|
||||
2006-08-18 "Hugh O. Brock <hbrock@redhat.com>
|
||||
|
||||
* src/virtManager/create.py:
|
||||
Fix vcpu bug and memory-size-int issue
|
||||
[43100d1ef03d]
|
||||
|
||||
2006-08-18 "Daniel P. Berrange <berrange@redhat.com>
|
||||
|
||||
* src/virt-manager.glade:
|
||||
Tweak layout / text for VCPU / memory config
|
||||
[5d6d5cd90301]
|
||||
|
||||
2006-08-17 "Daniel P. Berrange <berrange@redhat.com>
|
||||
|
||||
* src/virt-manager.glade:
|
||||
Merge heads
|
||||
[5c362a797b91]
|
||||
|
||||
* virt-manager.spec.in:
|
||||
Added requirement on python-xeninst for VM creation
|
||||
[5f14a423a71e]
|
||||
|
||||
* src/virt-manager.glade, src/virtManager/console.py,
|
||||
src/vncViewer/rfb.py, src/vncViewer/vnc.py:
|
||||
Added support for desktop resize protocol, auto-resize window to fit
|
||||
VNC widget
|
||||
[fbbdc266efd3]
|
||||
|
||||
* src/virt-manager.py.in:
|
||||
Added commandline flag to disable dbus service (useful in testing)
|
||||
[a0233e84b761]
|
||||
|
||||
2006-08-17 "Hugh O. Brock <hbrock@redhat.com>
|
||||
|
||||
* merged Dan's changes
|
||||
[ea99084d949d]
|
||||
|
||||
* src/virt-manager.glade, src/virtManager/create.py,
|
||||
src/virtManager/engine.py:
|
||||
UI bugs fixed, make the create wizard exit after the machine is
|
||||
created
|
||||
[4954d625ae46]
|
||||
|
||||
2006-08-17 "Daniel P. Berrange <berrange@redhat.com>
|
||||
|
||||
* Merge heads
|
||||
[56b0410be677]
|
||||
|
||||
* src/virtManager/config.py:
|
||||
Make keyring use a little more safe
|
||||
[102100b937ac]
|
||||
|
||||
* src/virt-manager.py.in:
|
||||
Initialize threads, otherwise GNOME VFS goes crash-tastic
|
||||
[115d33e9aaa9]
|
||||
|
||||
2006-08-16 "Hugh O. Brock <hbrock@redhat.com>
|
||||
|
||||
* src/virt-manager.glade:
|
||||
merge Dan's changes
|
||||
[f86064a1f371]
|
||||
|
||||
* src/virt-manager.glade, src/virtManager/create.py,
|
||||
src/virtManager/engine.py:
|
||||
pop up the console window for the new VM
|
||||
[2baf9f2ba2e2]
|
||||
|
||||
* src/virtManager/create.py:
|
||||
first pass at progress bar while creating the VM
|
||||
[a43541ecdbfd]
|
||||
|
||||
2006-08-16 "Daniel P. Berrange <berrange@redhat.com>
|
||||
|
||||
* src/virtManager/keyring.py:
|
||||
We have to make sure the 'default' keyring is created or we'll
|
||||
abort() on an NULL pointer. Also handle keyring failure gracefully
|
||||
[6c0627fddd85]
|
||||
|
||||
2006-08-16 berrange <berrange@dhcp-5-251.virt.boston.redhat.com>
|
||||
|
||||
* src/virt-manager.glade:
|
||||
Merge heads
|
||||
[9c8b03120525]
|
||||
|
||||
* README, virt-manager.spec.in:
|
||||
Bump min required libvirt to 0.1.4 to pull in requsite bug fixes /
|
||||
features we need
|
||||
[f7708cb34e88]
|
||||
|
||||
* pixmaps/icon_screenshot.png, src/virt-manager.glade,
|
||||
src/virtManager/console.py:
|
||||
Added UI for taking a screenshot of the VNC window
|
||||
[e43deaae9dcd]
|
||||
|
||||
* src/virtManager/keyring.py:
|
||||
Catch exceptions from gnomekeyring - eg the daemon not running is
|
||||
one problem
|
||||
[cbd393bba558]
|
||||
|
||||
2006-08-15 "Hugh O. Brock <hbrock@redhat.com>
|
||||
|
||||
* src/virt-manager.glade:
|
||||
resolve danpb's changes
|
||||
[5ae165154544]
|
||||
|
||||
* src/virtManager/create.py:
|
||||
create works *if* xeninst is present -- waiting on packaging
|
||||
[ac360ad91a71]
|
||||
|
||||
* src/virt-manager.glade, src/virtManager/create.py:
|
||||
Kickstart arg is optional, URL is required -- it's not either/or
|
||||
like we thought.
|
||||
[75fbb1545570]
|
||||
|
||||
* src/virtManager/create.py:
|
||||
Try for better error handling again
|
||||
[813b554fc640]
|
||||
|
||||
* src/virtManager/create.py:
|
||||
Try for better error handling
|
||||
[3786c4ded0ed]
|
||||
|
||||
* src/virtManager/create.py:
|
||||
Oops better set the install location too
|
||||
[4b1381515e1e]
|
||||
|
||||
* src/virtManager/create.py:
|
||||
first pass at making it actually do something
|
||||
[610dc5684837]
|
||||
|
||||
2006-08-14 "Hugh O. Brock <hbrock@redhat.com>
|
||||
|
||||
* src/virt-manager.glade, src/virtManager/create.py:
|
||||
Add validation for system name: must be nonblank, less than 50
|
||||
chars, no spaces
|
||||
[db64ec6b8135]
|
||||
|
||||
2006-08-15 berrange <berrange@dhcp-5-251.virt.boston.redhat.com>
|
||||
|
||||
* virt-manager.spec.in:
|
||||
Fixed dependancy on gnomekeyring
|
||||
[868497d237a9]
|
||||
|
||||
* po/virt-manager.pot:
|
||||
Re-generate translations
|
||||
[89b85d664a94]
|
||||
|
||||
* README, src/virtManager/config.py, src/virtManager/console.py,
|
||||
src/virtManager/keyring.py, src/virtManager/secret.py, virt-
|
||||
manager.spec.in:
|
||||
Switched keyring code to use gnomekeyring module. Disable keyring
|
||||
support if not available
|
||||
[f0a6b8bf93b4]
|
||||
|
||||
* src/virt-manager.glade:
|
||||
Mark bullet points as non-translatable
|
||||
[ce0e4d313ea8]
|
||||
|
||||
2006-08-15 "Daniel P. Berrange <berrange@redhat.com>
|
||||
|
||||
* src/virtManager/console.py, src/virtManager/domain.py:
|
||||
Set the 'launch terminal' button sensitivity according ot whether we
|
||||
can access the /dev/pts/* device
|
||||
[e18bee199c04]
|
||||
|
||||
2006-08-14 "Daniel P. Berrange <berrange@redhat.com>
|
||||
|
||||
* src/virtManager/domain.py:
|
||||
Fix extract of VNC port attribute XPath expression
|
||||
[8fe8e7a9992f]
|
||||
|
||||
2006-08-10 "Hugh O. Brock <hbrock@redhat.com>
|
||||
|
||||
* src/virt-manager.glade, src/virtManager/create.py:
|
||||
Forgot to add the system name to the last page, there it is
|
||||
[7718e37241cb]
|
||||
|
||||
* src/virtManager/engine.py:
|
||||
Merging unrelated changes to engine.py
|
||||
[2de0218bfd22]
|
||||
|
||||
* src/virt-manager.glade, src/virtManager/create.py,
|
||||
src/virtManager/engine.py, src/virtManager/manager.py:
|
||||
UI with events complete. Still doesn't actually create the VM.
|
||||
[4ab689140d17]
|
||||
|
||||
2006-08-10 "Daniel P. Berrange <berrange@redhat.com>
|
||||
|
||||
* README, src/virtManager/console.py, src/virtManager/details.py,
|
||||
src/virtManager/domain.py, src/virtManager/engine.py,
|
||||
src/virtManager/serialcon.py, virt-manager.spec.in:
|
||||
Added support for connecting to & displaying the serial console for
|
||||
guest VMs using the 'vte' module
|
||||
[6e342b12eb3c]
|
||||
|
||||
2006-08-10 "Hugh O. Brock <hbrock@redhat.com>
|
||||
|
||||
* src/virt-manager.glade, src/virtManager/create.py:
|
||||
All but the memory/cpu page now behaves and gathers data correctly
|
||||
[13051516541e]
|
||||
|
||||
2006-08-09 "Hugh O. Brock <hbrock@redhat.com>
|
||||
|
||||
* src/virt-manager.glade, src/virtManager/create.py,
|
||||
src/virtManager/engine.py:
|
||||
Some things actually work now. Working out collecting data, and
|
||||
obnoxious edge cases.
|
||||
[fdab871d7b35]
|
||||
|
||||
2006-08-09 "Daniel P. Berrange <berrange@redhat.com>
|
||||
|
||||
* po/Makefile.am:
|
||||
Fixed typo in target pre-requisite
|
||||
[d0390538d4a9]
|
||||
|
||||
2006-08-09 "Hugh O. Brock <hbrock@redhat.com>
|
||||
|
||||
* src/virtManager/create.py:
|
||||
a working version this time
|
||||
[7c4488e92850]
|
||||
|
||||
* src/virtManager/create.py:
|
||||
left this one out
|
||||
[d35245e861d9]
|
||||
|
||||
2006-08-08 "Hugh O. Brock <hbrock@redhat.com>
|
||||
|
||||
* src/virt-manager.glade, src/virtManager/engine.py,
|
||||
src/virtManager/manager.py:
|
||||
create wizard now actually appears when you push the new button.
|
||||
Still doesn't do anything.
|
||||
[39c8b502a7c2]
|
||||
|
||||
2006-08-08 "Daniel P. Berrange <berrange@redhat.com>
|
||||
|
||||
* src/virt-manager.glade:
|
||||
Merge heads
|
||||
[9d64e79bd07d]
|
||||
|
||||
* Makefile.am, configure.ac, po/Makefile.am, po/en_GB.po, po/virt-
|
||||
manager.pot, src/virt-manager.py.in, virt-manager.spec.in:
|
||||
Added infrastructure for generating & packaging .po files, with
|
||||
dummy en_GB.po file as example
|
||||
[e57e4982c5e3]
|
||||
|
||||
* src/virtManager/config.py, src/virtManager/domain.py:
|
||||
Lookup status icons based on libvirt constant, not the
|
||||
translatable(!) string
|
||||
[7d9081af70bd]
|
||||
|
||||
* src/virt-manager.glade:
|
||||
Remove 'secure connection' checkbox from connection form
|
||||
[f018fbda2e9c]
|
||||
|
||||
2006-08-07 hbrock <hbrock@puck.indigologic.com>
|
||||
|
||||
* src/virt-manager.glade:
|
||||
Finished Glade work on create wizard
|
||||
[052a78d8a000]
|
||||
|
||||
* src/vncViewer/image.py:
|
||||
merge Dan's changes
|
||||
[c413960b9a31]
|
||||
|
||||
* src/virt-manager.glade:
|
||||
First cut at Glade UI for create wizard.
|
||||
[e98b05c31cf9]
|
||||
|
||||
2006-08-07 "Daniel P. Berrange <berrange@redhat.com>
|
||||
|
||||
* TODO:
|
||||
Added TODO list
|
||||
[38068e41a8b5]
|
||||
|
||||
* src/virtManager/manager.py:
|
||||
Fixed sorting of name column
|
||||
[f59798957105]
|
||||
|
||||
2006-08-04 "Daniel P. Berrange <berrange@redhat.com>
|
||||
|
||||
* src/Makefile.am, src/virt-manager.py.in, src/virtManager/about.py,
|
||||
src/virtManager/config.py, src/virtManager/console.py,
|
||||
src/virtManager/details.py, src/virtManager/domain.py,
|
||||
src/virtManager/engine.py, src/virtManager/manager.py:
|
||||
Added gettext support. Internationalize all strings which could be
|
||||
shown to user. Fix about dialog to show corect version number
|
||||
[bed31aa3e813]
|
||||
|
||||
* README, src/vncViewer/image.py, src/vncViewer/rfb.py, virt-
|
||||
manager.spec.in:
|
||||
Remove python-imaging related code since we dont need it for the
|
||||
specialized VNC widget code paths
|
||||
[f676abe070e8]
|
||||
|
||||
* Merge heads
|
||||
[a98827d19456]
|
||||
|
||||
2006-07-25 "Daniel P. Berrange <berrange@redhat.com>
|
||||
|
||||
* virt-manager.spec.in:
|
||||
Updates required to RPM spec by Fedora review
|
||||
[b4e38784109b]
|
||||
|
||||
2006-07-28 "Hugh O. Brock <hbrock@redhat.com>
|
||||
|
||||
* src/virtManager/details.py:
|
||||
Make the memory slider react properly
|
||||
[0b519d2958eb]
|
||||
|
||||
* src/virtManager/details.py:
|
||||
Add back end to correctly alter memory in a VM
|
||||
[a89f3a0e9514]
|
||||
|
||||
2006-07-26 "Hugh O. Brock <hbrock@redhat.com>
|
||||
|
||||
* src/virtManager/domain.py:
|
||||
setMemory wants an int, give it
|
||||
[5907ec70aecf]
|
||||
|
||||
* src/virt-manager.glade, src/virtManager/details.py,
|
||||
src/virtManager/domain.py:
|
||||
Add teeth to set-memory page, and almost teeth to set-cpus page
|
||||
[75e7e671a3e1]
|
||||
|
||||
* src/virt-manager.glade, src/virtManager/details.py:
|
||||
Add physical CPU backing for UI
|
||||
[874a8f72be8e]
|
||||
|
||||
* src/virt-manager.glade:
|
||||
Finished HW tab UI
|
||||
[adfb6810a88e]
|
||||
|
||||
2006-07-25 "Hugh O. Brock <hbrock@redhat.com>
|
||||
|
||||
* src/virt-manager.glade:
|
||||
Added widgets for CPU and memory VM changes.
|
||||
[c7e7f28b9c16]
|
||||
|
||||
2006-07-24 "Hugh O. Brock <hbrock@redhat.com>
|
||||
|
||||
* src/virtManager/asyncjob.py, src/virtManager/connection.py,
|
||||
src/virtManager/engine.py, src/virtManager/manager.py:
|
||||
Added error dialog for domain restore errors
|
||||
[442d020f0617]
|
||||
|
||||
2006-07-20 "Daniel P. Berrange <berrange@redhat.com>
|
||||
|
||||
* .hgtags:
|
||||
Added tag RELEASE-0.1.5-1 for changeset
|
||||
a5976d3f807f516d06b8890e754f9b0265f2bd52
|
||||
[1e8a1c3157d0]
|
||||
|
||||
* ChangeLog, configure.ac, virt-manager.spec.in:
|
||||
Bump release to 0.1.5
|
||||
[a5976d3f807f] [RELEASE-0.1.5-1]
|
||||
|
||||
* src/virtManager/keyring.py:
|
||||
Initialize self.secrets hash, accidentally removed
|
||||
[debbdd9bf168] [tip]
|
||||
[debbdd9bf168]
|
||||
|
||||
* src/virt-manager.py.in:
|
||||
Switch to gtk.gdk.threads_init() since gtk.threasd_init() is
|
||||
|
@ -58,14 +705,6 @@
|
|||
Merge heads
|
||||
[6bf18e0fa53b]
|
||||
|
||||
2006-07-20 "Hugh O. Brock <hbrock@redhat.com>
|
||||
|
||||
* src/virtManager/engine.py:
|
||||
fix indentation typo in engine
|
||||
[9e460be02a18]
|
||||
|
||||
2006-07-20 "Daniel P. Berrange <berrange@redhat.com>
|
||||
|
||||
* src/virt-manager.py.in:
|
||||
Merge heads
|
||||
[25428779caf0]
|
||||
|
@ -74,22 +713,6 @@
|
|||
Bump to 0.1.4 in preparation for new release
|
||||
[af11fb18282e]
|
||||
|
||||
2006-07-20 "Hugh O. Brock <hbrock@redhat.com>
|
||||
|
||||
* src/virt-manager.glade, src/virtManager/engine.py:
|
||||
merged Dan's changes
|
||||
[470f388572a8]
|
||||
|
||||
* src/virt-manager.glade, src/virt-manager.py.in,
|
||||
src/virtManager/asyncjob.py, src/virtManager/connection.py,
|
||||
src/virtManager/engine.py, src/virtManager/manager.py:
|
||||
Make the progress bar threaded so that it will bounce back and forth
|
||||
in the background (still doesn't work) and abstract the progress bar
|
||||
functionality
|
||||
[c2ddab7f68ee]
|
||||
|
||||
2006-07-20 "Daniel P. Berrange <berrange@redhat.com>
|
||||
|
||||
* src/Makefile.am, src/virt-manager.py.in,
|
||||
src/virtManager/Makefile.am, src/vncViewer/Makefile.am,
|
||||
src/vncViewer/crippled_des.py, src/vncViewer/image.py,
|
||||
|
@ -107,6 +730,24 @@
|
|||
Filled out the README file
|
||||
[3d706b59224e]
|
||||
|
||||
2006-07-20 "Hugh O. Brock <hbrock@redhat.com>
|
||||
|
||||
* src/virtManager/engine.py:
|
||||
fix indentation typo in engine
|
||||
[9e460be02a18]
|
||||
|
||||
* src/virt-manager.glade, src/virtManager/engine.py:
|
||||
merged Dan's changes
|
||||
[470f388572a8]
|
||||
|
||||
* src/virt-manager.glade, src/virt-manager.py.in,
|
||||
src/virtManager/asyncjob.py, src/virtManager/connection.py,
|
||||
src/virtManager/engine.py, src/virtManager/manager.py:
|
||||
Make the progress bar threaded so that it will bounce back and forth
|
||||
in the background (still doesn't work) and abstract the progress bar
|
||||
functionality
|
||||
[c2ddab7f68ee]
|
||||
|
||||
2006-07-19 "Daniel P. Berrange <berrange@redhat.com>
|
||||
|
||||
* ChangeLog:
|
||||
|
@ -130,6 +771,12 @@
|
|||
Merge heads
|
||||
[12b3b2c7d26d]
|
||||
|
||||
* src/virtManager/config.py, src/virtManager/console.py,
|
||||
src/virtManager/keyring.py, src/virtManager/secret.py, virt-
|
||||
manager.spec.in:
|
||||
Added initial support for saving VNC password in the GNOME keyring
|
||||
[884f6fda6c3b]
|
||||
|
||||
* pixmaps/icon_shutdown.png, src/virtManager/console.py,
|
||||
src/virtManager/details.py:
|
||||
Added icon for shutdown button
|
||||
|
@ -178,16 +825,6 @@
|
|||
Pop up dialog for saving images (still doesn't actually do anything)
|
||||
[fa854bc44f20]
|
||||
|
||||
2006-07-19 "Daniel P. Berrange <berrange@redhat.com>
|
||||
|
||||
* src/virtManager/config.py, src/virtManager/console.py,
|
||||
src/virtManager/keyring.py, src/virtManager/secret.py, virt-
|
||||
manager.spec.in:
|
||||
Added initial support for saving VNC password in the GNOME keyring
|
||||
[884f6fda6c3b]
|
||||
|
||||
2006-07-17 "Hugh O. Brock <hbrock@redhat.com>
|
||||
|
||||
* src/virt-manager.glade, src/virtManager/details.py,
|
||||
src/virtManager/engine.py:
|
||||
Add UI bits for saving vm snapshots. Actual "save" dialog and save
|
||||
|
|
7
TODO
7
TODO
|
@ -15,13 +15,6 @@ order / importance:
|
|||
|
||||
3. Support for dealing with inactive / passive domains
|
||||
|
||||
4. Auto-resize console window to match size of virtual displays
|
||||
|
||||
5. Deal with VNC display resizing
|
||||
|
||||
6. Ability to send arbitrary keystrokes to VNC (ie keys which local
|
||||
WM would otherwise capture, eg Ctrl+Alt+F1 to switch console)
|
||||
|
||||
7. Implement 'open terminal' to get serial console
|
||||
|
||||
8. Pick up VNC port from domain's XML
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
AC_INIT(virt-manager.spec.in)
|
||||
AM_INIT_AUTOMAKE(virt-manager, 0.2.0)
|
||||
AM_INIT_AUTOMAKE(virt-manager, 0.2.2)
|
||||
|
||||
AC_PROG_CC
|
||||
AC_PROG_LIBTOOL
|
||||
|
|
|
@ -18,7 +18,7 @@ all: $(FMTCATALOGS)
|
|||
|
||||
EXTRA_DIST = $(POTFILE) $(POS)
|
||||
|
||||
$(POTFILE): $(POTFILES) $(GLADESCRATCHFILE)
|
||||
refresh-pot: $(POTFILES) $(GLADESCRATCHFILE)
|
||||
xgettext --default-domain=$(PACKAGE) \
|
||||
--keyword=_ --keyword=N_ $(POTFILES) $(GLADESCRATCHFILE)
|
||||
if cmp -s $(PACKAGE).po $(POTFILE); then \
|
||||
|
@ -31,7 +31,7 @@ $(GLADESCRATCHFILE): $(GLADEFILE)
|
|||
rm -rf tmp/
|
||||
intltool-extract --type=gettext/glade -l $<
|
||||
|
||||
update-po: Makefile $(POTFILE) refresh-po
|
||||
update-po: Makefile refresh-pot refresh-po
|
||||
|
||||
refresh-po: Makefile
|
||||
for cat in $(POS); do \
|
||||
|
|
1082
po/en_GB.po
1082
po/en_GB.po
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
|
@ -31,6 +31,20 @@ gettext_dir = "::GETTEXTDIR::"
|
|||
locale.setlocale(locale.LC_ALL, '')
|
||||
gettext.install(gettext_app, gettext_dir)
|
||||
|
||||
# Urgh, pygtk merely logs a warning when failing to open
|
||||
# the X11 display connection, and lets everything carry
|
||||
# on as if all were fine. Ultimately bad stuff happens,
|
||||
# so lets catch it here & get the hell out...
|
||||
import warnings
|
||||
warnings.filterwarnings('error', module='gtk')
|
||||
try:
|
||||
import gtk
|
||||
except Warning, e:
|
||||
# ...the risk is we catch too much though
|
||||
# Damned if we do, damned if we dont :-)(
|
||||
print _("Unable to initialize GTK: ") + str(e)
|
||||
sys.exit(1)
|
||||
warnings.resetwarnings()
|
||||
|
||||
import gtk
|
||||
gtk.gdk.threads_init()
|
||||
|
|
|
@ -27,6 +27,7 @@ class vmmAbout:
|
|||
|
||||
self.window.signal_autoconnect({
|
||||
"on_vmm_about_delete_event": self.close,
|
||||
"on_vmm_about_response": self.close,
|
||||
})
|
||||
|
||||
def show(self):
|
||||
|
|
|
@ -34,7 +34,7 @@ from rhpl.translate import _, N_, textdomain, utf8
|
|||
|
||||
from virtManager.asyncjob import vmmAsyncJob
|
||||
|
||||
VM_PARAVIRT = 1
|
||||
VM_PARA_VIRT = 1
|
||||
VM_FULLY_VIRT = 2
|
||||
|
||||
VM_INSTALL_FROM_ISO = 1
|
||||
|
@ -72,44 +72,20 @@ class vmmCreate(gobject.GObject):
|
|||
"on_create_back_clicked" : self.back,
|
||||
"on_create_forward_clicked" : self.forward,
|
||||
"on_create_finish_clicked" : self.finish,
|
||||
"on_create_vm_name_focus_out_event" : self.set_name,
|
||||
"on_virt_method_toggled" : self.set_virt_method,
|
||||
"on_media_toggled" : self.set_install_from,
|
||||
"on_fv_iso_location_browse_clicked" : self.browse_iso_location,
|
||||
"on_create_memory_max_value_changed": self.set_max_memory,
|
||||
"on_storage_partition_address_browse_clicked" : self.browse_storage_partition_address,
|
||||
"on_storage_file_address_browse_clicked" : self.browse_storage_file_address,
|
||||
"on_storage_toggled" : self.set_storage_type,
|
||||
"on_storage_file_size_changed" : self.set_storage_file_size,
|
||||
"on_create_memory_max_value_changed" : self.set_max_memory,
|
||||
"on_create_memory_startup_value_changed" : self.set_startup_memory,
|
||||
"on_create_vcpus_changed" : self.set_vcpus,
|
||||
"on_cd_focus_out_event" : self.choose_media_location,
|
||||
"on_cd_path_changed" : self.choose_media_location,
|
||||
"on_storage_file_address_changed": self.toggle_storage_size,
|
||||
"on_storage_toggled" : self.change_storage_type,
|
||||
"on_media_toggled" : self.change_media_type,
|
||||
})
|
||||
|
||||
self.set_initial_state()
|
||||
|
||||
def show(self):
|
||||
self.vm_added_handle = self.connection.connect("vm-added", self.open_vm_console)
|
||||
self.topwin.show()
|
||||
|
||||
def _init_members(self):
|
||||
#the dahta
|
||||
self.vm_name = None
|
||||
self.virt_method = VM_PARAVIRT
|
||||
self.install_fv_media_type = VM_INSTALL_FROM_ISO
|
||||
self.install_media_address = None
|
||||
self.install_kickstart_address = None
|
||||
self.storage_method = VM_STORAGE_PARTITION
|
||||
self.storage_partition_address = None
|
||||
self.storage_file_address = None
|
||||
self.storage_file_size = DEFAULT_STORAGE_FILE_SIZE
|
||||
self.max_memory = 0
|
||||
self.startup_memory = 0
|
||||
self.vcpus = 1
|
||||
self.vm_uuid = None
|
||||
self.vm_added_handle = None
|
||||
self.install_error = None
|
||||
self.reset_state()
|
||||
self.topwin.present()
|
||||
|
||||
def set_initial_state(self):
|
||||
notebook = self.window.get_widget("create-pages")
|
||||
|
@ -128,17 +104,20 @@ class vmmCreate(gobject.GObject):
|
|||
self.window.get_widget("page6-title").modify_bg(gtk.STATE_NORMAL,black)
|
||||
|
||||
# set up the list for the cd-path widget
|
||||
self.opt_media_list = self.window.get_widget("cd-path")
|
||||
model = gtk.ListStore(str)
|
||||
self.opt_media_list.set_model(model)
|
||||
cd_list = self.window.get_widget("cd-path")
|
||||
# Fields are raw device path, volume label, flag indicating
|
||||
# whether volume is present or not, and HAL path
|
||||
cd_model = gtk.ListStore(str, str, bool, str)
|
||||
cd_list.set_model(cd_model)
|
||||
text = gtk.CellRendererText()
|
||||
self.opt_media_list.pack_start(text, True)
|
||||
self.opt_media_list.add_attribute(text, 'text', 0)
|
||||
cd_list.pack_start(text, True)
|
||||
cd_list.add_attribute(text, 'text', 1)
|
||||
cd_list.add_attribute(text, 'sensitive', 2)
|
||||
self.populate_opt_media(cd_model)
|
||||
|
||||
self.reset_state()
|
||||
self.window.get_widget("create-cpus-physical").set_text(str(self.connection.host_maximum_processor_count()))
|
||||
|
||||
def reset_state(self):
|
||||
self._init_members()
|
||||
notebook = self.window.get_widget("create-pages")
|
||||
notebook.set_current_page(0)
|
||||
# Hide the "finish" button until the appropriate time
|
||||
|
@ -147,6 +126,24 @@ class vmmCreate(gobject.GObject):
|
|||
self.window.get_widget("create-back").set_sensitive(False)
|
||||
self.window.get_widget("storage-file-size").set_sensitive(False)
|
||||
|
||||
self.change_media_type()
|
||||
self.change_storage_type()
|
||||
self.window.get_widget("create-vm-name").set_text("")
|
||||
self.window.get_widget("virt-method-pv").set_active(True)
|
||||
self.window.get_widget("media-iso-image").set_active(True)
|
||||
self.window.get_widget("fv-iso-location").set_text("")
|
||||
self.window.get_widget("pv-media-url").set_text("")
|
||||
self.window.get_widget("pv-ks-url").set_text("")
|
||||
self.window.get_widget("storage-partition").set_active(True)
|
||||
self.window.get_widget("storage-partition-address").set_text("")
|
||||
self.window.get_widget("storage-file-address").set_text("")
|
||||
self.window.get_widget("storage-file-size").set_value(2000)
|
||||
self.window.get_widget("create-memory-max").set_value(500)
|
||||
self.window.get_widget("create-memory-startup").set_value(500)
|
||||
self.window.get_widget("create-vcpus").set_value(1)
|
||||
|
||||
self.install_error = None
|
||||
|
||||
|
||||
def forward(self, ignore=None):
|
||||
notebook = self.window.get_widget("create-pages")
|
||||
|
@ -155,10 +152,9 @@ class vmmCreate(gobject.GObject):
|
|||
|
||||
if notebook.get_current_page() == 1 and not xeninst.util.is_hvm_capable():
|
||||
notebook.set_current_page(4)
|
||||
self.virt_method = VM_PARAVIRT
|
||||
elif (notebook.get_current_page() == 2 and self.virt_method == VM_PARAVIRT):
|
||||
elif (notebook.get_current_page() == 2 and self.get_config_method() == VM_PARA_VIRT):
|
||||
notebook.set_current_page(4)
|
||||
elif (notebook.get_current_page() == 3 and self.virt_method == VM_FULLY_VIRT):
|
||||
elif (notebook.get_current_page() == 3 and self.get_config_method() == VM_FULLY_VIRT):
|
||||
notebook.set_current_page(5)
|
||||
else:
|
||||
notebook.next_page()
|
||||
|
@ -168,230 +164,180 @@ class vmmCreate(gobject.GObject):
|
|||
# do this always, since there's no "leaving a notebook page" event.
|
||||
self.window.get_widget("create-finish").hide()
|
||||
self.window.get_widget("create-forward").show()
|
||||
if notebook.get_current_page() == 4 and self.virt_method == VM_PARAVIRT:
|
||||
if notebook.get_current_page() == 4 and self.get_config_method() == VM_PARA_VIRT:
|
||||
if xeninst.util.is_hvm_capable():
|
||||
notebook.set_current_page(2)
|
||||
elif notebook.get_current_page() == 5 and self.virt_method == VM_FULLY_VIRT:
|
||||
else:
|
||||
notebook.set_current_page(1)
|
||||
elif notebook.get_current_page() == 5 and self.get_config_method() == VM_FULLY_VIRT:
|
||||
notebook.set_current_page(3)
|
||||
else:
|
||||
notebook.prev_page()
|
||||
|
||||
def get_config_name(self):
|
||||
return self.window.get_widget("create-vm-name").get_text()
|
||||
|
||||
def get_config_method(self):
|
||||
if self.window.get_widget("virt-method-pv").get_active():
|
||||
return VM_PARA_VIRT
|
||||
elif self.window.get_widget("virt-method-fv").get_active():
|
||||
return VM_FULLY_VIRT
|
||||
else:
|
||||
return VM_PARA_VIRT
|
||||
|
||||
def get_config_install_source(self):
|
||||
if self.get_config_method() == VM_PARA_VIRT:
|
||||
return self.window.get_widget("pv-media-url").get_text()
|
||||
else:
|
||||
if self.window.get_widget("media-iso-image").get_active():
|
||||
return self.window.get_widget("fv-iso-location").get_text()
|
||||
else:
|
||||
cd = self.window.get_widget("cd-path")
|
||||
model = cd.get_model()
|
||||
return model.get_value(cd.get_active_iter(), 0)
|
||||
|
||||
def get_config_kickstart_source(self):
|
||||
if self.get_config_method() == VM_PARA_VIRT:
|
||||
return self.window.get_widget("pv-ks-url").get_text()
|
||||
else:
|
||||
return ""
|
||||
|
||||
def get_config_disk_image(self):
|
||||
if self.window.get_widget("storage-partition").get_active():
|
||||
return self.window.get_widget("storage-partition-address").get_text()
|
||||
else:
|
||||
return self.window.get_widget("storage-file-address").get_text()
|
||||
|
||||
def get_config_disk_size(self):
|
||||
if self.window.get_widget("storage-partition").get_active():
|
||||
return None
|
||||
else:
|
||||
return self.window.get_widget("storage-file-size").get_value()
|
||||
|
||||
def get_config_maximum_memory(self):
|
||||
return self.window.get_widget("create-memory-max").get_value()
|
||||
|
||||
def get_config_initial_memory(self):
|
||||
return self.window.get_widget("create-memory-startup").get_value()
|
||||
|
||||
def get_config_virtual_cpus(self):
|
||||
return self.window.get_widget("create-vcpus").get_value()
|
||||
|
||||
def page_changed(self, notebook, page, page_number):
|
||||
# would you like some spaghetti with your salad, sir?
|
||||
|
||||
if page_number == 0:
|
||||
#set up the front page
|
||||
self.window.get_widget("create-back").set_sensitive(False)
|
||||
|
||||
elif page_number == 1:
|
||||
#set up the system-name page
|
||||
name_widget = self.window.get_widget("create-vm-name")
|
||||
if self.vm_name != None:
|
||||
name_widget.set_text(self.vm_name)
|
||||
else:
|
||||
name_widget.set_text("")
|
||||
name_widget.grab_focus()
|
||||
|
||||
elif page_number == 2:
|
||||
#set up the virt method page
|
||||
if self.virt_method == VM_PARAVIRT:
|
||||
self.window.get_widget("virt-method-pv").set_active(True)
|
||||
else:
|
||||
self.window.get_widget("virt-method-fv").set_active(True)
|
||||
|
||||
pass
|
||||
elif page_number == 3:
|
||||
#set up the fv install media page
|
||||
model = self.opt_media_list.get_model()
|
||||
model.clear()
|
||||
#make sure the model has one empty item
|
||||
model.append()
|
||||
devs = self._get_optical_devices()
|
||||
for dev in devs:
|
||||
model.append([dev])
|
||||
if self.install_media_address != None:
|
||||
self.window.get_widget("fv-iso-location").set_text(self.install_media_address)
|
||||
else:
|
||||
self.window.get_widget("fv-iso-location").set_text("")
|
||||
if self.install_fv_media_type == VM_INSTALL_FROM_ISO:
|
||||
self.window.get_widget("media-iso-image").set_active(True)
|
||||
self.window.get_widget("fv-iso-location-box").set_sensitive(True)
|
||||
else:
|
||||
self.window.get_widget("media-physical").set_active(True)
|
||||
self.window.get_widget("fv-iso-location-box").set_sensitive(False)
|
||||
|
||||
pass
|
||||
elif page_number == 4:
|
||||
#set up the pv install media page
|
||||
url_widget = self.window.get_widget("pv-media-url")
|
||||
ks_widget = self.window.get_widget("pv-ks-url")
|
||||
if self.install_media_address != None:
|
||||
url_widget.set_text(self.install_media_address)
|
||||
else:
|
||||
url_widget.set_text("")
|
||||
if self.install_kickstart_address != None:
|
||||
ks_widget.set_text(self.install_kickstart_address)
|
||||
else:
|
||||
ks_widget.set_text("")
|
||||
url_widget.grab_focus()
|
||||
|
||||
elif page_number == 5:
|
||||
#set up the storage space page
|
||||
partwidget = self.window.get_widget("storage-partition-address")
|
||||
filewidget = self.window.get_widget("storage-file-address")
|
||||
|
||||
if self.storage_partition_address != None:
|
||||
partwidget.set_text(self.storage_partition_address)
|
||||
else:
|
||||
partwidget.set_text("")
|
||||
if self.storage_file_address != None:
|
||||
filewidget.set_text(self.storage_file_address)
|
||||
else:
|
||||
filewidget.set_text("")
|
||||
if self.storage_method == VM_STORAGE_PARTITION:
|
||||
self.window.get_widget("storage-partition").set_active(True)
|
||||
self.window.get_widget("storage-partition-box").set_sensitive(True)
|
||||
self.window.get_widget("storage-file-box").set_sensitive(False)
|
||||
else:
|
||||
self.window.get_widget("storage-file-backed").set_active(True)
|
||||
self.window.get_widget("storage-partition-box").set_sensitive(False)
|
||||
self.window.get_widget("storage-file-box").set_sensitive(True)
|
||||
|
||||
elif page_number == 6:
|
||||
# memory stuff
|
||||
max_mem = self.connection.host_memory_size()/1024 # in megabytes from henceforth
|
||||
|
||||
#avoid absurdity, hopefully
|
||||
if self.max_memory == 0:
|
||||
self.max_memory = int(max_mem / 2)
|
||||
if self.startup_memory > self.max_memory:
|
||||
self.startup_memory = self.max_memory
|
||||
|
||||
max_mem_slider = self.window.get_widget("create-memory-max")
|
||||
self.window.get_widget("create-host-memory").set_text("%d MB" % max_mem)
|
||||
max_mem_slider.get_adjustment().upper = max_mem
|
||||
max_mem_slider.get_adjustment().value = self.max_memory
|
||||
startup_mem_slider = self.window.get_widget("create-memory-startup")
|
||||
startup_mem_slider.get_adjustment().upper = self.max_memory
|
||||
startup_mem_slider.get_adjustment().value = self.startup_memory
|
||||
startup_mem_slider.set_value(self.max_memory)
|
||||
|
||||
#vcpu stuff
|
||||
max_cpus = self.connection.host_maximum_processor_count()
|
||||
self.window.get_widget("create-cpus-physical").set_text(`max_cpus`)
|
||||
cpu_spinbox = self.window.get_widget("create-vcpus").get_adjustment()
|
||||
cpu_spinbox.upper = max_cpus
|
||||
cpu_spinbox.value = self.vcpus
|
||||
|
||||
pass
|
||||
elif page_number == 7:
|
||||
#set up the congrats page
|
||||
congrats = self.window.get_widget("create-congrats-label")
|
||||
|
||||
# XXX the validation doesn't really go here
|
||||
if self.vm_name == None: self.vm_name = "No Name"
|
||||
|
||||
congrats.set_text(_("Congratulations, you have successfully created a new virtual system, <b>\"%s\"</b>. \nYou'll now be able to view and work with \"%s\" in the virtual machine manager.") % (self.vm_name, self.vm_name) )
|
||||
congrats.set_use_markup(True)
|
||||
self.window.get_widget("summary-name").set_text(self.get_config_name())
|
||||
if self.get_config_method() == VM_PARA_VIRT:
|
||||
self.window.get_widget("summary-method").set_text(_("Paravirtualized"))
|
||||
else:
|
||||
self.window.get_widget("summary-method").set_text(_("Fully virtualized"))
|
||||
self.window.get_widget("summary-install-source").set_text(self.get_config_install_source())
|
||||
self.window.get_widget("summary-kickstart-source").set_text(self.get_config_kickstart_source())
|
||||
self.window.get_widget("summary-disk-image").set_text(self.get_config_disk_image())
|
||||
disksize = self.get_config_disk_size()
|
||||
if disksize != None:
|
||||
self.window.get_widget("summary-disk-size").set_text(str(int(disksize)) + " MB")
|
||||
else:
|
||||
self.window.get_widget("summary-disk-size").set_text("-")
|
||||
self.window.get_widget("summary-max-memory").set_text(str(int(self.get_config_maximum_memory())) + " MB")
|
||||
self.window.get_widget("summary-initial-memory").set_text(str(int(self.get_config_initial_memory())) + " MB")
|
||||
self.window.get_widget("summary-virtual-cpus").set_text(str(int(self.get_config_virtual_cpus())))
|
||||
self.window.get_widget("create-forward").hide()
|
||||
self.window.get_widget("create-finish").show()
|
||||
|
||||
def close(self, ignore1=None,ignore2=None):
|
||||
self.connection.disconnect(int(self.vm_added_handle))
|
||||
self.vm_added_handle = None
|
||||
self.topwin.hide()
|
||||
return 1
|
||||
|
||||
def finish(self, ignore=None):
|
||||
#begin DEBUG STUFF
|
||||
if self.install_kickstart_address == None:
|
||||
ks = "None"
|
||||
else:
|
||||
ks = self.install_kickstart_address
|
||||
if self.storage_file_size==None:
|
||||
sfs = "Preset"
|
||||
else:
|
||||
sfs = `self.storage_file_size/1024`
|
||||
if self.storage_method == VM_STORAGE_PARTITION:
|
||||
saddr = self.storage_partition_address
|
||||
else:
|
||||
saddr = self.storage_file_address
|
||||
logging.debug("your vm properties: \n Name=" + self.vm_name + \
|
||||
"\n Virt method: " + `self.virt_method` + \
|
||||
"\n Install media type (fv): " + `self.install_fv_media_type` + \
|
||||
"\n Install media address: " + self.install_media_address + \
|
||||
"\n Install kickstart address: " + ks + \
|
||||
"\n Install storage type: " + `self.storage_method` + \
|
||||
"\n Install storage address: " + saddr + \
|
||||
"\n Install storage file size: " + sfs + \
|
||||
"\n Install max kernel memory: " + `int(self.max_memory)` + \
|
||||
"\n Install startup kernel memory: " + `int(self.startup_memory)` + \
|
||||
"\n Install vcpus: " + `int(self.vcpus)`)
|
||||
# end DEBUG STUFF
|
||||
|
||||
# first things first, are we trying to create a fully virt guest?
|
||||
if self.virt_method == VM_FULLY_VIRT:
|
||||
if self.get_config_method() == VM_FULLY_VIRT:
|
||||
guest = xeninst.FullVirtGuest()
|
||||
try:
|
||||
guest.cdrom = self.install_media_address
|
||||
guest.cdrom = self.get_config_install_source()
|
||||
except ValueError, e:
|
||||
self._validation_error_box(_("Invalid FV media address"),e.args[0])
|
||||
self.install_media_address = None
|
||||
else:
|
||||
guest = xeninst.ParaVirtGuest()
|
||||
try:
|
||||
guest.location = self.install_media_address
|
||||
guest.location = self.get_config_install_source()
|
||||
except ValueError, e:
|
||||
self._validation_error_box(_("Invalid PV media address"), e.args[0])
|
||||
self.install_media_address = None
|
||||
return
|
||||
if self.install_kickstart_address != None and self.install_kickstart_address != "":
|
||||
guest.extraargs = "ks=%s" % self.install_kickstart_address
|
||||
ks = self.get_config_kickstart_source()
|
||||
if ks != None and len(ks) != 0:
|
||||
guest.extraargs = "ks=%s" % ks
|
||||
|
||||
# set the name
|
||||
try:
|
||||
guest.name = self.vm_name
|
||||
guest.name = self.get_config_name()
|
||||
except ValueError, e:
|
||||
self._validation_error_box(_("Invalid system name"), e.args[0])
|
||||
self.vm_name = None
|
||||
return
|
||||
|
||||
# set the memory
|
||||
try:
|
||||
guest.memory = int(self.max_memory)
|
||||
guest.memory = int(self.get_config_maximum_memory())
|
||||
except ValueError:
|
||||
self._validation_error_box(_("Invalid memory setting"), e.args[0])
|
||||
self.max_memory = None
|
||||
return
|
||||
|
||||
# set vcpus
|
||||
guest.vcpus = int(self.vcpus)
|
||||
guest.vcpus = int(self.get_config_virtual_cpus())
|
||||
|
||||
# disks
|
||||
if self.storage_method == VM_STORAGE_PARTITION:
|
||||
saddr = self.storage_partition_address
|
||||
else:
|
||||
saddr = self.storage_file_address
|
||||
|
||||
filesize = None
|
||||
if self.storage_file_size != None:
|
||||
filesize = int(self.storage_file_size)/1024
|
||||
if self.get_config_disk_size() != None:
|
||||
filesize = self.get_config_disk_size() / 1024.0
|
||||
try:
|
||||
d = xeninst.XenDisk(saddr, filesize)
|
||||
d = xeninst.XenDisk(self.get_config_disk_image(), filesize)
|
||||
except ValueError, e:
|
||||
self._validation_error_box(_("Invalid storage address"), e.args[0])
|
||||
self.storage_partition_address = self.storage_file_address = self.storage_file_size = None
|
||||
return
|
||||
guest.disks.append(d)
|
||||
|
||||
# uuid
|
||||
guest.uuid = xeninst.util.uuidToString(xeninst.util.randomUUID())
|
||||
|
||||
# network
|
||||
n = xeninst.XenNetworkInterface(None)
|
||||
guest.nics.append(n)
|
||||
|
||||
#grab the uuid before we start
|
||||
self.vm_uuid = xeninst.util.uuidToString(xeninst.util.randomUUID())
|
||||
guest.set_uuid(self.vm_uuid)
|
||||
|
||||
# set up the graphics to use SDL
|
||||
guest.graphics = "vnc"
|
||||
|
||||
logging.debug("Creating a VM " + guest.name + \
|
||||
"\n UUID: " + guest.uuid + \
|
||||
"\n Source: " + self.get_config_install_source() + \
|
||||
"\n Kickstart: " + self.get_config_kickstart_source() + \
|
||||
"\n Memory: " + str(guest.memory) + \
|
||||
"\n # VCPUs: " + str(guest.vcpus) + \
|
||||
"\n Filesize: " + str(filesize) + \
|
||||
"\n Disk image: " + str(self.get_config_disk_image()))
|
||||
|
||||
#let's go
|
||||
self.install_error = None
|
||||
progWin = vmmAsyncJob(self.config, self.do_install, [guest],
|
||||
|
@ -400,6 +346,13 @@ class vmmCreate(gobject.GObject):
|
|||
if self.install_error != None:
|
||||
self._validation_error_box(_("Guest Install Error"), self.install_error)
|
||||
return
|
||||
|
||||
vm = self.connection.get_vm(guest.uuid)
|
||||
(gtype, host, port) = vm.get_graphics_console()
|
||||
if gtype == "vnc":
|
||||
self.emit("action-show-console", self.connection.get_uri(), guest.uuid)
|
||||
else:
|
||||
self.emit("action-show-terminal", self.connection.get_uri(), guest.uuid)
|
||||
self.close()
|
||||
|
||||
def do_install(self, guest):
|
||||
|
@ -410,38 +363,10 @@ class vmmCreate(gobject.GObject):
|
|||
logging.exception(e)
|
||||
return
|
||||
|
||||
def set_name(self, src, ignore=None):
|
||||
self.vm_name = src.get_text()
|
||||
|
||||
def set_virt_method(self, button):
|
||||
if button.get_active():
|
||||
if button.name == "virt-method-pv":
|
||||
self.virt_method = VM_PARAVIRT
|
||||
else:
|
||||
self.virt_method = VM_FULLY_VIRT
|
||||
self.install_media_address = None
|
||||
|
||||
def set_install_from(self, button):
|
||||
if button.get_active():
|
||||
if button.name == "media-iso-image":
|
||||
self.install_fv_media_type = VM_INSTALL_FROM_ISO
|
||||
self.window.get_widget("fv-iso-location-box").set_sensitive(True)
|
||||
self.opt_media_list.set_sensitive(False)
|
||||
elif button.name == "media-physical":
|
||||
self.install_fv_media_type = VM_INSTALL_FROM_CD
|
||||
self.window.get_widget("fv-iso-location-box").set_sensitive(False)
|
||||
self.opt_media_list.set_sensitive(True)
|
||||
self.opt_media_list.set_active(0)
|
||||
|
||||
def choose_media_location(self, src):
|
||||
model = self.opt_media_list.get_model()
|
||||
logging.debug("User chose: " + model.get_value(self.opt_media_list.get_active_iter(), 0))
|
||||
self.install_media_address = model.get_value(self.opt_media_list.get_active_iter(), 0)
|
||||
|
||||
def browse_iso_location(self, ignore1=None, ignore2=None):
|
||||
self.install_media_address = self._browse_file(_("Locate ISO Image"))
|
||||
if self.install_media_address != None:
|
||||
self.window.get_widget("fv-iso-location").set_text(self.install_media_address)
|
||||
file = self._browse_file(_("Locate ISO Image"))
|
||||
if file != None:
|
||||
self.window.get_widget("fv-iso-location").set_text(file)
|
||||
|
||||
def _browse_file(self, dialog_name, folder=None):
|
||||
# user wants to browse for an ISO
|
||||
|
@ -463,27 +388,12 @@ class vmmCreate(gobject.GObject):
|
|||
fcdialog.destroy()
|
||||
return None
|
||||
|
||||
def set_media_address(self, src, ignore=None):
|
||||
self.install_media_address = src.get_text().strip()
|
||||
|
||||
def set_kickstart_address(self, src, ignore=None):
|
||||
self.install_kickstart_address = src.get_text().strip()
|
||||
|
||||
def set_storage_partition_address(self, src, ignore=None):
|
||||
self.storage_partition_address = src.get_text()
|
||||
|
||||
def set_storage_file_address(self, src, ignore=None):
|
||||
self.storage_file_address = src.get_text()
|
||||
|
||||
def browse_storage_partition_address(self, src, ignore=None):
|
||||
self.storage_partition_address = self._browse_file(_("Locate Storage Partition"), "/dev")
|
||||
if self.storage_partition_address != None:
|
||||
self.window.get_widget("storage-partition-address").set_text(self.storage_partition_address)
|
||||
part = self._browse_file(_("Locate Storage Partition"), "/dev")
|
||||
if part != None:
|
||||
self.window.get_widget("storage-partition-address").set_text(part)
|
||||
|
||||
def browse_storage_file_address(self, src, ignore=None):
|
||||
# Reset the storage_file_size value
|
||||
if self.storage_file_size == None:
|
||||
self.storage_file_size = STORAGE_FILE_SIZE
|
||||
self.window.get_widget("storage-file-size").set_sensitive(True)
|
||||
fcdialog = gtk.FileChooserDialog(_("Locate or Create New Storage File"),
|
||||
self.window.get_widget("vmm-create"),
|
||||
|
@ -495,45 +405,50 @@ class vmmCreate(gobject.GObject):
|
|||
fcdialog.connect("confirm-overwrite", self.confirm_overwrite_callback)
|
||||
response = fcdialog.run()
|
||||
fcdialog.hide()
|
||||
file = None
|
||||
if(response == gtk.RESPONSE_ACCEPT):
|
||||
self.storage_file_address = fcdialog.get_filename()
|
||||
file = fcdialog.get_filename()
|
||||
|
||||
if self.storage_file_address != None:
|
||||
self.window.get_widget("storage-file-address").set_text(self.storage_file_address)
|
||||
if file != None:
|
||||
self.window.get_widget("storage-file-address").set_text(file)
|
||||
|
||||
def toggle_storage_size(self, ignore1=None, ignore2=None):
|
||||
file = self.get_config_disk_image()
|
||||
if file != None and len(file) > 0 and not(os.path.exists(file)):
|
||||
self.window.get_widget("storage-file-size").set_sensitive(True)
|
||||
else:
|
||||
self.window.get_widget("storage-file-size").set_sensitive(False)
|
||||
|
||||
def confirm_overwrite_callback(self, chooser):
|
||||
# Only called when the user has chosen an existing file
|
||||
self.window.get_widget("storage-file-size").set_sensitive(False)
|
||||
self.storage_file_size = None
|
||||
return gtk.FILE_CHOOSER_CONFIRMATION_ACCEPT_FILENAME
|
||||
|
||||
def change_media_type(self, ignore=None):
|
||||
if self.window.get_widget("media-iso-image").get_active():
|
||||
self.window.get_widget("fv-iso-location-box").set_sensitive(True)
|
||||
self.window.get_widget("cd-path").set_sensitive(False)
|
||||
else:
|
||||
self.window.get_widget("fv-iso-location-box").set_sensitive(False)
|
||||
self.window.get_widget("cd-path").set_sensitive(True)
|
||||
self.window.get_widget("cd-path").set_active(-1)
|
||||
|
||||
def set_storage_type(self, button):
|
||||
if button.get_active():
|
||||
if button.name == "storage-partition":
|
||||
self.storage_method = VM_STORAGE_PARTITION
|
||||
def change_storage_type(self, ignore=None):
|
||||
if self.window.get_widget("storage-partition").get_active():
|
||||
self.window.get_widget("storage-partition-box").set_sensitive(True)
|
||||
self.window.get_widget("storage-file-box").set_sensitive(False)
|
||||
self.window.get_widget("storage-file-size").set_sensitive(False)
|
||||
else:
|
||||
self.storage_method = VM_STORAGE_FILE
|
||||
self.window.get_widget("storage-partition-box").set_sensitive(False)
|
||||
self.window.get_widget("storage-file-box").set_sensitive(True)
|
||||
|
||||
def set_storage_file_size(self, src):
|
||||
self.storage_file_size = src.get_adjustment().value
|
||||
self.toggle_storage_size()
|
||||
|
||||
def set_max_memory(self, src):
|
||||
self.max_memory = src.get_adjustment().value
|
||||
max_memory = src.get_adjustment().value
|
||||
startup_mem_adjustment = self.window.get_widget("create-memory-startup").get_adjustment()
|
||||
if startup_mem_adjustment.value > self.max_memory:
|
||||
startup_mem_adjustment.value = self.max_memory
|
||||
startup_mem_adjustment.upper = self.max_memory
|
||||
|
||||
def set_startup_memory(self, src):
|
||||
self.startup_memory = src.get_adjustment().value
|
||||
|
||||
def set_vcpus(self, src):
|
||||
self.vcpus = src.get_adjustment().value
|
||||
if startup_mem_adjustment.value > max_memory:
|
||||
startup_mem_adjustment.value = max_memory
|
||||
startup_mem_adjustment.upper = max_memory
|
||||
|
||||
def validate(self, page_num):
|
||||
if page_num == 1: # the system name page
|
||||
|
@ -544,34 +459,38 @@ class vmmCreate(gobject.GObject):
|
|||
return False
|
||||
|
||||
elif page_num == 2: # the virt method page
|
||||
if self.virt_method == VM_FULLY_VIRT and not xeninst.util.is_hvm_capable():
|
||||
if self.get_config_method() == VM_FULLY_VIRT and not xeninst.util.is_hvm_capable():
|
||||
self._validation_error_box(_("Hardware Support Required"), \
|
||||
_("Your hardware does not appear to support full virtualization. Only paravirtualized guests will be available on this hardware."))
|
||||
return False
|
||||
|
||||
elif page_num == 3: # the fully virt media page
|
||||
if self.install_fv_media_type == VM_INSTALL_FROM_ISO:
|
||||
self.set_media_address(self.window.get_widget("fv-iso-location"))
|
||||
if (self.install_media_address == None or len(self.install_media_address) == 0):
|
||||
self._validation_error_box(_("ISO Location Required"), \
|
||||
_("You must specify an ISO location for the guest install image"))
|
||||
if self.window.get_widget("media-iso-image").get_active():
|
||||
src = self.get_config_install_source()
|
||||
if src == None or len(src) == 0:
|
||||
self._validation_error_box(_("ISO Path Required"), \
|
||||
_("You must specify an ISO location for the guest installation"))
|
||||
return False
|
||||
elif not(os.path.exists(src)):
|
||||
self._validation_error_box(_("ISO Path Not Found"), \
|
||||
_("You must specify a valid path to the ISO image for guest installation"))
|
||||
return False
|
||||
else:
|
||||
cdlist = self.window.get_widget("cd-path")
|
||||
if cdlist.get_active() == -1:
|
||||
self._validation_error_box(_("Install media required"), \
|
||||
_("You must select the CDROM install media for guest installation"))
|
||||
return False
|
||||
|
||||
elif page_num == 4: # the paravirt media page
|
||||
self.set_media_address(self.window.get_widget("pv-media-url"))
|
||||
self.set_kickstart_address(self.window.get_widget("pv-ks-url"))
|
||||
if self.install_media_address == None or len(self.install_media_address) == 0:
|
||||
src = self.get_config_install_source()
|
||||
if src == None or len(src) == 0:
|
||||
self._validation_error_box(_("URL Required"), \
|
||||
_("You must specify a URL for the install image for the guest install"))
|
||||
return False
|
||||
|
||||
elif page_num == 5: # the storage page
|
||||
if self.window.get_widget("storage-partition").get_active():
|
||||
self.set_storage_partition_address(self.window.get_widget("storage-partition-address"))
|
||||
else:
|
||||
self.set_storage_file_address(self.window.get_widget("storage-file-address"))
|
||||
|
||||
if (self.storage_partition_address == None or len(self.storage_partition_address) == 0) and (self.storage_file_address == None or len(self.storage_file_address) == 0):
|
||||
disk = self.get_config_disk_image()
|
||||
if disk == None or len(disk) == 0:
|
||||
self._validation_error_box(_("Storage Address Required"), \
|
||||
_("You must specify a partition or a file for storage for the guest install"))
|
||||
return False
|
||||
|
@ -591,24 +510,71 @@ class vmmCreate(gobject.GObject):
|
|||
message_box.run()
|
||||
message_box.destroy()
|
||||
|
||||
def open_vm_console(self,ignore,uri,uuid):
|
||||
if uuid == self.vm_uuid:
|
||||
vm = self.connection.get_vm(uuid)
|
||||
(gtype, host, port) = vm.get_graphics_console()
|
||||
if gtype == "vnc":
|
||||
self.emit("action-show-console", self.connection.get_uri(), self.vm_uuid)
|
||||
else:
|
||||
self.emit("action-show-terminal", self.connection.get_uri(), self.vm_uuid)
|
||||
|
||||
def _get_optical_devices(self):
|
||||
def populate_opt_media(self, model):
|
||||
# get a list of optical devices with data discs in, for FV installs
|
||||
optical_device_list = []
|
||||
vollabel = {}
|
||||
volpath = {}
|
||||
# Track device add/removes so we can detect newly inserted CD media
|
||||
self.hal_iface.connect_to_signal("DeviceAdded", self._device_added)
|
||||
self.hal_iface.connect_to_signal("DeviceRemoved", self._device_removed)
|
||||
|
||||
# Find info about all current present media
|
||||
for d in self.hal_iface.FindDeviceByCapability("volume"):
|
||||
vol = self.bus.get_object("org.freedesktop.Hal", d)
|
||||
if vol.GetPropertyBoolean("volume.is_disc") and \
|
||||
vol.GetPropertyBoolean("volume.disc.has_data"):
|
||||
devnode = vol.GetProperty("block.device")
|
||||
label = vol.GetProperty("volume.label")
|
||||
if label == None or len(label) == 0:
|
||||
label = devnode
|
||||
vollabel[devnode] = label
|
||||
volpath[devnode] = d
|
||||
|
||||
|
||||
for d in self.hal_iface.FindDeviceByCapability("storage.cdrom"):
|
||||
dev = self.bus.get_object("org.freedesktop.Hal", d)
|
||||
if dev.GetPropertyBoolean("volume.is_disc") and \
|
||||
dev.GetPropertyBoolean("volume.disc.has_data") and \
|
||||
dev.GetPropertyBoolean("volume.is_mounted"):
|
||||
optical_device_list.append(dev.GetProperty("volume.mount_point"))
|
||||
return optical_device_list
|
||||
devnode = dev.GetProperty("block.device")
|
||||
if vollabel.has_key(devnode):
|
||||
model.append([devnode, vollabel[devnode], True, volpath[devnode]])
|
||||
else:
|
||||
model.append([devnode, _("No media present"), False, None])
|
||||
|
||||
def _device_added(self, path):
|
||||
vol = self.bus.get_object("org.freedesktop.Hal", path)
|
||||
if vol.QueryCapability("volume"):
|
||||
if vol.GetPropertyBoolean("volume.is_disc") and \
|
||||
vol.GetPropertyBoolean("volume.disc.has_data"):
|
||||
devnode = vol.GetProperty("block.device")
|
||||
label = vol.GetProperty("volume.label")
|
||||
if label == None or len(label) == 0:
|
||||
label = devnode
|
||||
|
||||
cdlist = self.window.get_widget("cd-path")
|
||||
model = cdlist.get_model()
|
||||
|
||||
# Search for the row with matching device node and
|
||||
# fill in info about inserted media
|
||||
for row in model:
|
||||
if row[0] == devnode:
|
||||
row[1] = label
|
||||
row[2] = True
|
||||
row[3] = path
|
||||
|
||||
def _device_removed(self, path):
|
||||
vol = self.bus.get_object("org.freedesktop.Hal", path)
|
||||
cdlist = self.window.get_widget("cd-path")
|
||||
model = cdlist.get_model()
|
||||
|
||||
active = cdlist.get_active()
|
||||
idx = 0
|
||||
# Search for the row containing matching HAL volume path
|
||||
# and update (clear) it, de-activating it if its currently
|
||||
# selected
|
||||
for row in model:
|
||||
if row[3] == path:
|
||||
row[1] = _("No media present")
|
||||
row[2] = False
|
||||
row[3] = None
|
||||
if idx == active:
|
||||
cdlist.set_active(-1)
|
||||
idx = idx + 1
|
||||
|
|
|
@ -102,7 +102,7 @@ class vmmDetails(gobject.GObject):
|
|||
"on_details_menu_view_toolbar_activate": self.toggle_toolbar,
|
||||
|
||||
"on_config_cpus_apply_clicked": self.config_cpus_apply,
|
||||
"on_config_vm_cpus_changed": self.config_vm_cpus,
|
||||
"on_config_vcpus_changed": self.config_vm_cpus,
|
||||
"on_config_memory_changed": self.config_memory_value,
|
||||
"on_config_memory_apply_clicked": self.config_memory_apply
|
||||
})
|
||||
|
@ -251,7 +251,6 @@ class vmmDetails(gobject.GObject):
|
|||
else:
|
||||
self.window.get_widget("details-menu-serial").set_sensitive(False)
|
||||
|
||||
|
||||
def refresh_resources(self, vm):
|
||||
self.window.get_widget("overview-cpu-usage-text").set_text("%d %%" % self.vm.cpu_time_percentage())
|
||||
vm_maxmem = self.vm.maximum_memory()
|
||||
|
@ -278,18 +277,23 @@ class vmmDetails(gobject.GObject):
|
|||
self.window.get_widget("state-vm-maxmem").set_text("%d MB" % (vm_maxmem/1024))
|
||||
self.window.get_widget("state-vm-memory").set_text("%d MB" % (vm_memory/1024))
|
||||
|
||||
self.window.get_widget("state-host-cpus").set_text("%d" % self.vm.get_connection().host_active_processor_count())
|
||||
self.window.get_widget("config-vcpus").get_adjustment().upper = vm.vcpu_max_count()
|
||||
self.window.get_widget("state-vm-vcpus").set_text("%d" % (vm.vcpu_count()))
|
||||
self.window.get_widget("state-vm-max-vcpus").set_text("%d" % (vm.vcpu_max_count()))
|
||||
|
||||
def update_config_memory(self):
|
||||
self.window.get_widget("config-memory").get_adjustment().value = self.vm.current_memory()/1024
|
||||
|
||||
def update_config_cpus(self):
|
||||
self.window.get_widget("config-vm-cpus").get_adjustment().value = self.vm.vcpu_count()
|
||||
self.window.get_widget("config-vcpus").get_adjustment().value = self.vm.vcpu_count()
|
||||
|
||||
def update_state_cpus(self):
|
||||
self.window.get_widget("state-host-cpus").set_text(`(self.vm.get_connection().host_maximum_processor_count())`)
|
||||
def config_cpus_apply(self, src):
|
||||
# Apply the change to the number of CPUs
|
||||
|
||||
vcpus = self.window.get_widget("config-vm-cpus").get_adjustment().value
|
||||
vcpus = self.window.get_widget("config-vcpus").get_adjustment().value
|
||||
|
||||
# if requested # of CPUS > host CPUS, pop up warning dialog (not implemented yet)
|
||||
|
||||
|
|
|
@ -186,6 +186,10 @@ class vmmDomain(gobject.GObject):
|
|||
return 0
|
||||
return self.record[0]["vcpuCount"]
|
||||
|
||||
def vcpu_max_count(self):
|
||||
cpus = self.get_xml_string("/domain/vcpu")
|
||||
return int(cpus)
|
||||
|
||||
def cpu_time_vector(self):
|
||||
vector = []
|
||||
stats = self.record
|
||||
|
|
|
@ -210,7 +210,6 @@ class vmmEngine:
|
|||
self.connections[uri]["windowManager"].show()
|
||||
|
||||
def show_create(self, uri):
|
||||
|
||||
if self.windowCreate == None:
|
||||
self.windowCreate = vmmCreate(self.get_config(), self.get_connection(uri, False))
|
||||
self.windowCreate.connect("action-show-console", self._do_show_console)
|
||||
|
|
|
@ -95,7 +95,7 @@ class RFBFrameBuffer:
|
|||
raise NotImplementedError
|
||||
|
||||
# data is given as ARGB
|
||||
def change_cursor(self, width, height, data):
|
||||
def change_cursor(self, width, height, x, y, data):
|
||||
#print >>stderr, 'change_cursor'
|
||||
raise NotImplementedError
|
||||
|
||||
|
|
|
@ -21,7 +21,7 @@
|
|||
import gobject
|
||||
import rfb
|
||||
import sys
|
||||
from struct import pack
|
||||
from struct import pack, unpack
|
||||
import pygtk
|
||||
import gtk
|
||||
|
||||
|
@ -40,6 +40,7 @@ class GRFBFrameBuffer(rfb.RFBFrameBuffer, gobject.GObject):
|
|||
self.canvas = canvas
|
||||
self.pixmap = None
|
||||
self.name = "VNC"
|
||||
self.dirtyregion = None
|
||||
|
||||
def get_name(self):
|
||||
return self.name
|
||||
|
@ -62,6 +63,7 @@ class GRFBFrameBuffer(rfb.RFBFrameBuffer, gobject.GObject):
|
|||
|
||||
def resize_screen(self, width, height):
|
||||
self.pixmap = gtk.gdk.Pixmap(self.canvas.window, width, height)
|
||||
self.gc = self.pixmap.new_gc()
|
||||
self.emit("resize", width, height)
|
||||
return (0, 0, width, height)
|
||||
|
||||
|
@ -69,19 +71,43 @@ class GRFBFrameBuffer(rfb.RFBFrameBuffer, gobject.GObject):
|
|||
if self.pixmap == None:
|
||||
return
|
||||
|
||||
gc = self.pixmap.new_gc()
|
||||
self.pixmap.draw_rgb_32_image(gc, x, y, width, height, gtk.gdk.RGB_DITHER_NONE, data)
|
||||
self.emit("invalidate", x, y, width, height)
|
||||
self.pixmap.draw_rgb_32_image(self.gc, x, y, width, height, gtk.gdk.RGB_DITHER_NONE, data)
|
||||
self.dirty(x,y,width,height)
|
||||
|
||||
def dirty(self, x, y, width, height):
|
||||
if self.dirtyregion == None:
|
||||
self.dirtyregion = { "x1": x, "y1": y, "x2": x+width, "y2": y+height }
|
||||
else:
|
||||
if x < self.dirtyregion["x1"]:
|
||||
self.dirtyregion["x1"] = x
|
||||
if (x + width) > self.dirtyregion["x2"]:
|
||||
self.dirtyregion["x2"] = (x + width)
|
||||
if y < self.dirtyregion["y1"]:
|
||||
self.dirtyregion["y1"] = y
|
||||
if (y + height) > self.dirtyregion["y2"]:
|
||||
self.dirtyregion["y2"] = (y + height)
|
||||
|
||||
def process_solid(self, x, y, width, height, color):
|
||||
print >>stderr, 'process_solid: %dx%d at (%d,%d), color=%r' % (width,height,x,y, color)
|
||||
# XXX very very evil assumes pure 32-bit RGBA format
|
||||
(r,g,b,a) = unpack('BBBB', color)
|
||||
self.gc.set_rgb_fg_color(gtk.gdk.Color(red=r*255,green=g*255,blue=b*255))
|
||||
if width == 1 and height == 1:
|
||||
self.pixmap.draw_point(self.gc, x, y)
|
||||
else:
|
||||
self.pixmap.draw_rectangle(self.gc, True, x, y, width, height)
|
||||
self.dirty(x,y,width,height)
|
||||
|
||||
def update_screen(self, t):
|
||||
#print >>stderr, 'update_screen'
|
||||
pass
|
||||
if self.dirtyregion != None:
|
||||
x1 = self.dirtyregion["x1"]
|
||||
x2 = self.dirtyregion["x2"]
|
||||
y1 = self.dirtyregion["y1"]
|
||||
y2 = self.dirtyregion["y2"]
|
||||
#print "Update %d,%d (%dx%d)" % (x1, y1, (x2-x1), (y2-y1))
|
||||
self.emit("invalidate", x1, y1, x2-x1, y2-y1)
|
||||
self.dirtyregion = None
|
||||
|
||||
def change_cursor(self, width, height, data):
|
||||
def change_cursor(self, width, height, x, y, data):
|
||||
print >>stderr, 'change_cursor'
|
||||
|
||||
def move_cursor(self, x, y):
|
||||
|
@ -95,8 +121,8 @@ class GRFBNetworkClient(rfb.RFBNetworkClient, gobject.GObject):
|
|||
"disconnected": (gobject.SIGNAL_RUN_FIRST, gobject.TYPE_NONE, [])
|
||||
}
|
||||
|
||||
def __init__(self, host, port, converter, debug=0):
|
||||
rfb.RFBNetworkClient.__init__(self, host, port, converter, debug=debug,preferred_encoding=(rfb.ENCODING_RAW,rfb.ENCODING_DESKTOP_RESIZE))
|
||||
def __init__(self, host, port, converter, debug=0, preferred_encoding=(rfb.ENCODING_RAW)):
|
||||
rfb.RFBNetworkClient.__init__(self, host, port, converter, debug=debug,preferred_encoding=preferred_encoding)
|
||||
self.__gobject_init__()
|
||||
|
||||
self.watch = None
|
||||
|
@ -115,7 +141,8 @@ class GRFBNetworkClient(rfb.RFBNetworkClient, gobject.GObject):
|
|||
|
||||
try:
|
||||
self.loop1()
|
||||
except:
|
||||
except Exception, e:
|
||||
print str(e)
|
||||
self.close()
|
||||
self.emit("disconnected")
|
||||
return 0
|
||||
|
@ -158,6 +185,10 @@ class GRFBViewer(gtk.DrawingArea):
|
|||
self.authenticated = False
|
||||
self.needpw = True
|
||||
self.autograbkey = autograbkey
|
||||
self.preferred_encoding = (rfb.ENCODING_RAW, rfb.ENCODING_DESKTOP_RESIZE)
|
||||
# Current impl of draw_solid is *far* too slow to be practical
|
||||
# for Hextile which likes lots of 1x1 pixels solid rectangles
|
||||
self.preferred_encoding = (rfb.ENCODING_HEXTILE, rfb.ENCODING_RAW, rfb.ENCODING_DESKTOP_RESIZE)
|
||||
|
||||
self.fb.connect("resize", self.resize_display)
|
||||
self.fb.connect("invalidate", self.repaint_region)
|
||||
|
@ -206,12 +237,12 @@ class GRFBViewer(gtk.DrawingArea):
|
|||
def get_framebuffer_name(self):
|
||||
return self.fb.get_name()
|
||||
|
||||
def connect_to_host(self, host, port):
|
||||
def connect_to_host(self, host, port, debug=0):
|
||||
if self.client != None:
|
||||
self.disconnect_from_host()
|
||||
self.client = NOne
|
||||
|
||||
client = GRFBNetworkClient(host, port, self.fb)
|
||||
client = GRFBNetworkClient(host, port, self.fb, debug=debug, preferred_encoding=self.preferred_encoding)
|
||||
client.connect("disconnected", self._client_disconnected)
|
||||
|
||||
auth_types = client.init()
|
||||
|
@ -225,6 +256,7 @@ class GRFBViewer(gtk.DrawingArea):
|
|||
self.needpw = False
|
||||
else:
|
||||
self.needpw = True
|
||||
return self.needpw
|
||||
|
||||
def _client_disconnected(self, src):
|
||||
self.client = None
|
||||
|
@ -302,7 +334,7 @@ class GRFBViewer(gtk.DrawingArea):
|
|||
return self.autograbkey
|
||||
|
||||
def grab_keyboard(self):
|
||||
gtk.gdk.keyboard_grab(win.window, 1, long(0))
|
||||
gtk.gdk.keyboard_grab(self.window, 1, long(0))
|
||||
self.grabbedKeyboard = True
|
||||
|
||||
def ungrab_keyboard(self):
|
||||
|
@ -315,7 +347,7 @@ class GRFBViewer(gtk.DrawingArea):
|
|||
|
||||
def leave_notify(self, win, event):
|
||||
if self.autograbkey:
|
||||
gtk.ungrab_keyboard()
|
||||
self.ungrab_keyboard()
|
||||
|
||||
def key_press(self, win, event):
|
||||
# Key handling in VNC is screwy. The event.keyval from GTK is
|
||||
|
@ -428,14 +460,16 @@ def main():
|
|||
vp = gtk.Viewport()
|
||||
pane.add(vp)
|
||||
|
||||
vnc = GRFBViewer()
|
||||
vnc = GRFBViewer(autograbkey=True)
|
||||
vp.add(vnc)
|
||||
|
||||
win.show_all()
|
||||
win.present()
|
||||
|
||||
if vnc.connect_to_host(host, port):
|
||||
if vnc.connect_to_host(host, port, debug=0):
|
||||
print "Need password"
|
||||
if password == None:
|
||||
return 1
|
||||
else:
|
||||
print "No password needed"
|
||||
vnc.authenticate(password)
|
||||
|
|
|
@ -4,11 +4,11 @@
|
|||
# allows an extra fragment based on the timestamp to be appended
|
||||
# to the release. This distinguishes automated builds, from formal
|
||||
# Fedora RPM builds
|
||||
%define _extra_release %{?extra_release:%{extra_release}}
|
||||
%define _extra_release %{?dist:%{dist}}%{!?dist:%{?extra_release:%{extra_release}}}
|
||||
|
||||
Name: @PACKAGE@
|
||||
Version: @VERSION@
|
||||
Release: 3%{_extra_release}
|
||||
Release: 1%{_extra_release}
|
||||
Summary: Virtual Machine Manager
|
||||
|
||||
Group: Applications/Emulators
|
||||
|
@ -25,7 +25,6 @@ Requires: libvirt-python >= 0.1.4-3
|
|||
# Definitely does not work with earlier due to python API changes
|
||||
Requires: dbus-python >= 0.61
|
||||
# Might work with earlier, but this is what we've tested
|
||||
# We use 'ctypes' so don't need the 'gnome-keyring-python' bits
|
||||
Requires: gnome-keyring >= 0.4.9
|
||||
# Minimum we've tested with
|
||||
# Although if you don't have this, comment it out and the app
|
||||
|
@ -36,8 +35,11 @@ Requires: gnome-python2-gnomekeyring >= 2.15.4
|
|||
Requires: libxml2-python >= 2.6.23
|
||||
# Required to install Xen guests
|
||||
Requires: python-xeninst >= 0.90.1
|
||||
|
||||
# Earlier vte han broken python binding module
|
||||
# Required for loading the glade UI
|
||||
Requires: pygtk2-libglade
|
||||
# Required for our graphics which are currently SVG format
|
||||
Requires: librsvg2
|
||||
# Earlier vte had broken python binding module
|
||||
Requires: vte >= 0.12.2
|
||||
|
||||
ExclusiveArch: %{ix86} x86_64 ia64
|
||||
|
@ -47,6 +49,10 @@ BuildRequires: gtk2-devel
|
|||
BuildRequires: python-devel
|
||||
BuildRequires: gettext
|
||||
|
||||
Requires(pre): GConf2
|
||||
Requires(post): GConf2
|
||||
Requires(preun): GConf2
|
||||
|
||||
%description
|
||||
Virtual Machine Manager provides a graphical tool for administering
|
||||
virtual machines such as Xen. It uses libvirt as the backend management
|
||||
|
@ -70,17 +76,30 @@ rm -f $RPM_BUILD_ROOT%{_libdir}/%{name}/sparkline.la
|
|||
%clean
|
||||
rm -rf $RPM_BUILD_ROOT
|
||||
|
||||
%pre
|
||||
if [ "$1" -gt 1 ]; then
|
||||
export GCONF_CONFIG_SOURCE=`gconftool-2 --get-default-source`
|
||||
gconftool-2 --makefile-uninstall-rule \
|
||||
%{_sysconfdir}/gconf/schemas/%{name}.schemas > /dev/null || :
|
||||
fi
|
||||
|
||||
%post
|
||||
export GCONF_CONFIG_SOURCE=`gconftool-2 --get-default-source`
|
||||
SCHEMAS="%{name}.schemas"
|
||||
for S in $SCHEMAS; do
|
||||
gconftool-2 --makefile-install-rule /etc/gconf/schemas/$S > /dev/null
|
||||
done
|
||||
gconftool-2 --makefile-install-rule \
|
||||
%{_sysconfdir}/gconf/schemas/%{name}.schemas > /dev/null || :
|
||||
|
||||
update-desktop-database %{_datadir}/applications
|
||||
|
||||
%postun
|
||||
update-desktop-database %{_datadir}/applications
|
||||
|
||||
%preun
|
||||
if [ "$1" -eq 0 ]; then
|
||||
export GCONF_CONFIG_SOURCE=`gconftool-2 --get-default-source`
|
||||
gconftool-2 --makefile-uninstall-rule \
|
||||
%{_sysconfdir}/gconf/schemas/%{name}.schemas > /dev/null || :
|
||||
fi
|
||||
|
||||
%files -f %{name}.lang
|
||||
%defattr(-,root,root,-)
|
||||
%doc README COPYING AUTHORS ChangeLog NEWS
|
||||
|
@ -95,21 +114,41 @@ update-desktop-database %{_datadir}/applications
|
|||
|
||||
%{_datadir}/%{name}/*.py
|
||||
%{_datadir}/%{name}/*.pyc
|
||||
%ghost %{_datadir}/%{name}/*.pyo
|
||||
%{_datadir}/%{name}/*.pyo
|
||||
|
||||
%{_datadir}/%{name}/virtManager/*.py
|
||||
%{_datadir}/%{name}/virtManager/*.pyc
|
||||
%ghost %{_datadir}/%{name}/virtManager/*.pyo
|
||||
%{_datadir}/%{name}/virtManager/*.pyo
|
||||
|
||||
%{_datadir}/%{name}/vncViewer/*.py
|
||||
%{_datadir}/%{name}/vncViewer/*.pyc
|
||||
%ghost %{_datadir}/%{name}/vncViewer/*.pyo
|
||||
%{_datadir}/%{name}/vncViewer/*.pyo
|
||||
|
||||
|
||||
%{_datadir}/applications/%{name}.desktop
|
||||
%{_datadir}/dbus-1/services/%{name}.service
|
||||
|
||||
%changelog
|
||||
* Fri Sep 15 2006 Daniel Berrange <berrange@redhat.com> - 0.2.2-1
|
||||
- Fix event handling in create VM wizard (bz 206660 & 206186)
|
||||
- Fix close button in about dialog (bz 205943)
|
||||
- Refresh .pot files
|
||||
- Turn on VNC scrollbars fulltime to avoid GTK window sizing issue
|
||||
which consistently resize too small.
|
||||
|
||||
* Mon Sep 11 2006 Daniel Berrange <berrange@redhat.com> - 0.2.1-3
|
||||
- Added requires on pygtk2-libglade & librsvg2 (bz 205941 & 205942)
|
||||
- Re-arrange to use console-helper to launch app
|
||||
- Added 'dist' component to release number
|
||||
|
||||
* Wed Sep 6 2006 Jeremy Katz <katzj@redhat.com> - 0.2.1-2
|
||||
- don't ghost pyo files (#205448)
|
||||
|
||||
* Mon Sep 4 2006 Daniel Berrange <berrange@redhat.com> - 0.2.1-1
|
||||
- Updated to 0.2.1 tar.gz
|
||||
- Added rules to install/uninstall gconf schemas in preun,post,pre
|
||||
scriptlets
|
||||
|
||||
* Thu Aug 24 2006 Jeremy Katz <katzj@redhat.com> - 0.2.0-3
|
||||
- BR gettext
|
||||
|
||||
|
|
Loading…
Reference in New Issue