Marek Marczykowski-Górecki
06189b4a5b
wni: set path to qrexec-daemon
2014-11-19 12:50:30 +01:00
Marek Marczykowski-Górecki
4bd14f5011
windows: installer
2014-11-19 12:50:30 +01:00
Marek Marczykowski-Górecki
63eccac025
wni: use win32net module for creating new user
...
This require UAC disabled (or already started as administrator), but
works much more reliable ("net user" sometimes fails _silently_).
2014-11-19 12:50:30 +01:00
Marek Marczykowski-Górecki
e5c2448af4
copy & paste error (VM rename fix)
2014-11-19 12:50:30 +01:00
Marek Marczykowski-Górecki
27b031c59f
Check for None before calling method (VM rename fix)
2014-11-19 12:50:29 +01:00
Marek Marczykowski-Górecki
39918fa9e2
Makefile: add entries for windows build
2014-11-19 12:50:29 +01:00
Marek Marczykowski-Górecki
c3d9b1971a
Handle the case when libvirt object doesn't exists for given VM
...
This can be some "virtual" VM (like dom0).
2014-11-19 12:50:29 +01:00
Marek Marczykowski-Górecki
5763beb898
HVM: do not fail on non-Xen systems (without xenstore)
...
Currently getting Stubdom XID is (the last one?) read directly from
Xenstore as there is no libvirt function for it.
This means that even if HVM is running it can have not connection to
Xenstore. For now give -1 in such situation.
2014-11-19 12:50:29 +01:00
Marek Marczykowski-Górecki
4300d778a5
qvm-toos: import dbus only when needed
...
Void import errors when 'dbus' module not really needed.
2014-11-19 12:50:29 +01:00
Marek Marczykowski-Górecki
d88da1e66b
wni: add missing parameter
2014-11-19 12:50:29 +01:00
Marek Marczykowski-Górecki
f6729b4968
wni: use generated password
2014-11-19 12:50:29 +01:00
Marek Marczykowski-Górecki
5dbad01796
Fill some more WNI settings
...
Especially use new "wni" libvirt driver.
2014-11-19 12:50:29 +01:00
Marek Marczykowski-Górecki
7e355c5dad
core: ignore error when PCI device already "detached"
...
This can be the case at startup, when all network devices are connected
to pciback module by initramfs.
2014-11-19 12:50:29 +01:00
Marek Marczykowski-Górecki
5b0b62ee5b
rpm: fix path
2014-11-19 12:50:28 +01:00
Marek Marczykowski-Górecki
8d0863d40f
storage: Force sync after preparing volatile.img
...
This makes possible to release d-m partitions devices sooner (so avoid
race with kpartx).
2014-11-19 12:50:28 +01:00
Marek Marczykowski-Górecki
ea68c6a766
xen: fix template vm storage code
2014-11-19 12:50:28 +01:00
Marek Marczykowski-Górecki
11047bf427
Use platform specific locking method
...
None of found existing portable locking module does support RW locks.
Use lowlevel system locking support - both Windows and Linux support
such feature.
Drop locking code in write_firewall_conf() b/c is is called with
QubesVmCollection lock held anyway.
2014-11-19 12:50:28 +01:00
Marek Marczykowski-Górecki
a5a2c0b97c
Revert "release qubes.xml lock on object destroy"
...
This reverts commit 39e056b74acca3854c5707d8f2cbcd199b8cac75.
This change rely on reverted python-locking use.
2014-11-19 12:50:28 +01:00
Marek Marczykowski-Górecki
5fb1991ad5
QubesWniVmStorage: prefix system user with "qubes-vm-".
2014-11-19 12:50:28 +01:00
Marek Marczykowski-Górecki
f927f12e39
QubesWniVmStorage: pass all positional parameters to base class
2014-11-19 12:50:28 +01:00
Marek Marczykowski-Górecki
392b70a4d8
Create missing private.img when needed
...
Not only for HVM, but any VM type which support private.img.
2014-11-19 12:50:28 +01:00
Marek Marczykowski-Górecki
21c908b9b2
Move storage-related VM rename code to storage class
2014-11-19 12:50:28 +01:00
Marek Marczykowski-Górecki
ada5ebd784
Use "None" in *_img attr for "not applicable"
...
Some VM types do not have particular disk image. Instead of enumerating
cases in storage class, signal unused image from VM class by setting
appropriate attr to None.
2014-11-19 12:50:27 +01:00
Marek Marczykowski-Górecki
396011e227
Fix initialization of storage class
...
Move it earlier - before first access to *_img attrs.
2014-11-19 12:50:27 +01:00
Marek Marczykowski-Górecki
7b5dd67b58
Completely move *_img attrs to QubesVmStorage class
2014-11-19 12:50:27 +01:00
Marek Marczykowski-Górecki
e2bea656b4
Add vm-configs for WNI
2014-11-19 12:50:27 +01:00
Marek Marczykowski-Górecki
ec37a4e681
Rename vm-configs directory to be more generic
2014-11-19 12:50:27 +01:00
Marek Marczykowski-Górecki
35ecfc82ef
wni: QubesWniVmStorage and update settings file
2014-11-19 12:50:27 +01:00
Marek Marczykowski-Górecki
2457a705d0
Load Qubes DB python module only when needed.
...
This is temporary band aid for the python module problems.
This should also slightly speed up some tools (not all uses Qubes DB).
2014-11-19 12:50:27 +01:00
Marek Marczykowski-Górecki
e8715cd561
release qubes.xml lock on object destroy
...
This will ensure that lock will be released even in case of error.
2014-11-19 12:50:27 +01:00
Marek Marczykowski-Górecki
50188c8832
Use relative path in system_path dict instead of path templates
...
This will allow use of correct slashes/backslashes (os.path.join instead
of hardcoded '/').
2014-11-19 12:50:27 +01:00
Marek Marczykowski-Górecki
a17f6ef779
Update QubesHVM to use QubesVmStorage classes
...
Also add external drive support to QubesXenVmStorage (move from
QubesHVM).
2014-11-19 12:50:27 +01:00
Marek Marczykowski-Górecki
66b39ac2a2
Typo fix in error message.
2014-11-19 12:50:26 +01:00
Marek Marczykowski-Górecki
4ae720956d
Use file copy instead of symlink on Windows
2014-11-19 12:50:26 +01:00
Marek Marczykowski-Górecki
467477409d
makefile/windows: install qvm-tools with .py extension
...
So system will automatically run them with python interpreter (wherever
it is installed). This require to have ".py" in PATHEXT variable.
2014-11-19 12:50:26 +01:00
Marek Marczykowski-Górecki
675a164e7d
makefile/windows: use c:\qubes as default data dir
2014-11-19 12:50:26 +01:00
Marek Marczykowski-Górecki
eaac99bf64
qvm-tools: check if running as root only on systems with os.geteuid
2014-11-19 12:50:26 +01:00
Marek Marczykowski-Górecki
b323a4d1e3
core: Fix handling the case when no settings file present.
2014-11-19 12:50:26 +01:00
Marek Marczykowski-Górecki
50e44ce22d
makefile: Improve readability of settings.py install command
2014-11-19 12:50:26 +01:00
Marek Marczykowski-Górecki
ec17f7d329
core/xen: setup xen-specific defaults in separate settings file
2014-11-19 12:50:26 +01:00
Marek Marczykowski-Górecki
d91162e74d
minor comment fix
2014-11-19 12:50:26 +01:00
Marek Marczykowski-Górecki
0a1f3d0a44
core: split VM images handling to separate class
...
This will ease handling different types of VMM (which can require
different image types, location etc).
2014-11-19 12:50:25 +01:00
Marek Marczykowski-Górecki
d5cb05fdc6
Move dispvm+qmemman service files to relevant directories
...
Remove them from global services dir.
2014-11-19 12:50:25 +01:00
Marek Marczykowski-Górecki
a8bee8d978
Ignore error when 'xen.lowlevel.xs' doesn't exists
...
There are still few uses of direct xenstore access, most of them are
xen-specific (so doesn't need to be portable). For now simply don't
connect to xenstore when no 'xen.lowlevel.xs' module present. It will
break such xen-specific accesses - it must be somehow reworked - either
by adding appropriate conditionals, or moving such code somewhere else
(custom methods of libvirt driver?).
2014-11-19 12:50:25 +01:00
Marek Marczykowski-Górecki
bc58ca5edb
Remove import xen.lowlevel.xc
...
There is still use of it: QubesHost.get_free_xen_memory and
QubesHost.measure_cpu_usage. Will migrate them to libvirt later (for now
some things will be broken - namely qubes-manager).
2014-11-19 12:50:25 +01:00
Marek Marczykowski-Górecki
6193b4fea3
Add support for VMM-specific settings.
2014-11-19 12:50:25 +01:00
Marek Marczykowski-Górecki
80c89cc91c
Delay resolving system_path['qubes_base_dir']
...
So changes made by os/vmm-specific settings would be taken into account.
2014-11-19 12:50:25 +01:00
Marek Marczykowski-Górecki
f6835346d4
Move initialization code at the end of file
...
So all of it will be in one place.
2014-11-19 12:50:25 +01:00
Marek Marczykowski-Górecki
aad945e01b
makefile: install only relevant stuff according to OS/VMM
2014-11-19 12:50:25 +01:00
Marek Marczykowski-Górecki
69d1ae645f
Do not use qmemman when not present (installed) on particular VMM
2014-11-19 12:50:25 +01:00