[PATCH v2] Change all CSS files indentation to 4 spaces
by Crístian Viana
This is the difference between this patchset and the previous one (v1):
- Do not change the indentation level in "ui/css/theme-default/topbar.css";
that file contains a @media block, therefore the properties defined inside
of it have another indentation level (8 spaces). That case was not
considered by the sed regular expression that generated this patch.
10 years, 10 months
[PATCH V2 0/4] improve controller
by shaohef@linux.vnet.ibm.com
From: ShaoHe Feng <shaohef(a)linux.vnet.ibm.com>
V1 -> V2
fix typo.
remove print
use url_auth instead of _url_sub_node_auth
improve the commit description
add a method to load root sub collections/resouces automatically
ShaoHe Feng (4):
improve controller: add a method to load root sub collections/resouces
automatically
improve controller: tag the collections/resouces of root with
@urlSubNode
improve controller: Root loads collections/resouces automatically
improve controller: set authentication automatically
src/kimchi/control/__init__.py | 8 ++++++++
src/kimchi/control/config.py | 2 ++
src/kimchi/control/debugreports.py | 2 ++
src/kimchi/control/host.py | 2 ++
src/kimchi/control/interfaces.py | 2 ++
src/kimchi/control/networks.py | 2 ++
src/kimchi/control/plugins.py | 2 ++
src/kimchi/control/storagepools.py | 2 ++
src/kimchi/control/tasks.py | 2 ++
src/kimchi/control/templates.py | 2 ++
src/kimchi/control/vms.py | 2 ++
src/kimchi/root.py | 26 +++++--------------------
src/kimchi/server.py | 12 +++++-------
src/kimchi/utils.py | 39 ++++++++++++++++++++++++++++++++++++++
14 files changed, 77 insertions(+), 28 deletions(-)
--
1.8.4.2
10 years, 10 months
[PATCHv6 0/2] nfs prevalidation
by lvroyce0210@gmail.com
From: Royce Lv <lvroyce(a)linux.vnet.ibm.com>
v4>v5, make temp dir during try mount instead of using the pool mount point
v1>v4, Address naming comments,
integrate run_command patch and use context manager to deal with umount
Royce Lv (2):
utils: Add nfs prevalication
Integrate nfs path check before create nfs pool
src/kimchi/model.py | 34 +++++++++++++++++++++++++++++++---
src/kimchi/utils.py | 8 ++++++++
2 files changed, 39 insertions(+), 3 deletions(-)
--
1.8.1.2
10 years, 10 months
[PATCH 1/5] Ubuntu: Add the LVM dependency package to README
by Crístian Viana
The README file contains instructions to build Kimchi from the source
tree, including the exact command to install the dependencies on Ubuntu.
But that command does not contain the LVM package which is needed to probe LVM
devices when creating a logical storage pool.
Add the LVM package ("lvm2") to the apt-get install command in the README file.
Signed-off-by: Crístian Viana <vianac(a)linux.vnet.ibm.com>
---
docs/README.md | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/docs/README.md b/docs/README.md
index d80486b..a1f02ee 100644
--- a/docs/README.md
+++ b/docs/README.md
@@ -60,7 +60,7 @@ for more information on how to configure your system to access this repository.
python-pam python-m2crypto python-jsonschema \
qemu-kvm libtool python-psutil python-ethtool \
sosreport python-ipaddr python-lxml nfs-common \
- open-iscsi
+ open-iscsi lvm2
Packages version requirement:
python-jsonschema >= 1.3.0
--
1.8.4.2
10 years, 10 months
[PATCH] Use cherrypy's default dispatcher for subcollection
by Mark Wu
Currently, we override the dispatchers of resource StoragePool
and IsoPool when the request targets to storagevolumes it holds.
But it's not necessary to use a customized dispatcher. It can be
done by add an attribute to associate with the subcollcetion. In
this case, it's 'storagevolumes'.
Signed-off-by: Mark Wu <wudxw(a)linux.vnet.ibm.com>
---
src/kimchi/control/storagepools.py | 16 ++--------------
1 file changed, 2 insertions(+), 14 deletions(-)
diff --git a/src/kimchi/control/storagepools.py b/src/kimchi/control/storagepools.py
index 782f5a6..06b7196 100644
--- a/src/kimchi/control/storagepools.py
+++ b/src/kimchi/control/storagepools.py
@@ -83,6 +83,7 @@ class StoragePool(Resource):
self.uri_fmt = "/storagepools/%s"
self.activate = self.generate_action_handler('activate')
self.deactivate = self.generate_action_handler('deactivate')
+ self.storagevolumes = StorageVolumes(self.model, ident.decode("utf-8"))
@property
def data(self):
@@ -103,27 +104,14 @@ class StoragePool(Resource):
return res
- def _cp_dispatch(self, vpath):
- if vpath:
- subcollection = vpath.pop(0)
- if subcollection == 'storagevolumes':
- # incoming text, from URL, is not unicode, need decode
- return StorageVolumes(self.model, self.ident.decode("utf-8"))
-
class IsoPool(Resource):
def __init__(self, model):
super(IsoPool, self).__init__(model, ISO_POOL_NAME)
+ self.storagevolumes = IsoVolumes(self.model, ISO_POOL_NAME)
@property
def data(self):
return {'name': self.ident,
'state': self.info['state'],
'type': self.info['type']}
-
- def _cp_dispatch(self, vpath):
- if vpath:
- subcollection = vpath.pop(0)
- if subcollection == 'storagevolumes':
- # incoming text, from URL, is not unicode, need decode
- return IsoVolumes(self.model, self.ident.decode("utf-8"))
--
1.8.4.2
10 years, 10 months
[PATCHv8 0/8] storage server and target support
by lvroyce0210@gmail.com
From: Royce Lv <lvroyce(a)linux.vnet.ibm.com>
v7>v8, address model break, change xml construction to libxml
v6>v7, adopt lxml to parse xml, move parse params to get() to avoid duplicate code,
fix bugs when one server support multiple target type.
v5>v6, change GET param support to cover more scenario of filter collected results.
v4>v5, remove storage server list reload function,
merge storage server and targets
v3>v4, fix inconsistency between doc and json schema
v1>v3, fix racing problem, fix style.
Royce Lv (8):
Support params for GET method
Add testcase for GET param
Storage server: Update API.md
storage server: update controller.py
storage server: Update model and mockmodel
storage target: Update API.md
storage target: Update controller and json schema
storage target: Add model support
docs/API.md | 22 +++++++++++
src/kimchi/API.json | 20 ++++++++++
src/kimchi/control/base.py | 24 ++++++++----
src/kimchi/control/storagepools.py | 4 +-
src/kimchi/control/storageserver.py | 61 +++++++++++++++++++++++++++++
src/kimchi/control/storagevolumes.py | 2 +-
src/kimchi/control/utils.py | 7 ++++
src/kimchi/mockmodel.py | 30 +++++++++++++++
src/kimchi/model.py | 75 ++++++++++++++++++++++++++++++++++++
src/kimchi/root.py | 2 +
tests/test_rest.py | 36 +++++++++++++++++
11 files changed, 272 insertions(+), 11 deletions(-)
create mode 100644 src/kimchi/control/storageserver.py
--
1.8.1.2
10 years, 10 months
[PATCH 0/4] improve controller
by shaohef@linux.vnet.ibm.com
From: ShaoHe Feng <shaohef(a)linux.vnet.ibm.com>
add a method to load root sub collections/resouces automatically
ShaoHe Feng (4):
improve controller: add a method to load root sub collections/resouces
automatically
improve controller: tag the collections/resouces of root with
@urlSubNode
improve controller: Root loads collections/resouces automatically
improve controller: set authentication automatically
src/kimchi/control/__init__.py | 8 ++++++++
src/kimchi/control/config.py | 2 ++
src/kimchi/control/debugreports.py | 2 ++
src/kimchi/control/host.py | 2 ++
src/kimchi/control/interfaces.py | 2 ++
src/kimchi/control/networks.py | 2 ++
src/kimchi/control/plugins.py | 2 ++
src/kimchi/control/storagepools.py | 2 ++
src/kimchi/control/tasks.py | 2 ++
src/kimchi/control/templates.py | 2 ++
src/kimchi/control/vms.py | 2 ++
src/kimchi/root.py | 26 +++++--------------------
src/kimchi/server.py | 12 +++++-------
src/kimchi/utils.py | 39 ++++++++++++++++++++++++++++++++++++++
14 files changed, 77 insertions(+), 28 deletions(-)
--
1.8.4.2
10 years, 10 months
debugreport generation error
by Christy Perez
Hi,
I randomly decided to try out the debugreport feature on my Fedora 20
latptop today and ran into an issue. The first odd thing was that I was
asked to login to the kimchi portal again, but maybe that's on purpose?
Next, the action seems to hang indefinitely. I scrolled back up and
found this call trace:
127.0.0.1 - christy [20/Jan/2014:15:23:45] "GET /tasks/1 HTTP/1.1" 200
54 "https://localhost:8001/" "Mozilla/5.0 (X11; Linux x86_64; rv:26.0)
Gecko/20100101 Firefox/26.0"
gluster
Traceback (most recent call last):
File "/usr/lib/python2.7/site-packages/sos/sosreport.py", line 937, in
setup
plug.setup()
File "/usr/lib/python2.7/site-packages/sos/plugins/gluster.py", line
91, in setup
gluster_major = int((pkg["version"])[:1])
TypeError: string indices must be integers, not str
127.0.0.1 - christy [20/Jan/2014:15:23:45] "GET /tasks/1 HTTP/1.1" 200
54 "https://localhost:8001/" "Mozilla/5.0 (X11; Linux x86_64; rv:26.0)
Gecko/20100101 Firefox/26.0"
yum
Traceback (most recent call last):
File "/usr/lib/python2.7/site-packages/sos/sosreport.py", line 937, in
setup
plug.setup()
File "/usr/lib/python2.7/site-packages/sos/plugins/yum.py", line 29,
in setup
rhelver = self.policy().rhel_version()
AttributeError: 'FedoraPolicy' object has no attribute 'rhel_version'
I did find that someone else is hitting this issue:
https://bugzilla.redhat.com/show_bug.cgi?id=1028102 (which is actually
from an IBM bug...)
https://bugzilla.linux.ibm.com/show_bug.cgi?id=99234
And I also found this opened against kimchi:
https://bugzilla.linux.ibm.com/show_bug.cgi?id=101135
So I tried running it myself in a terminal, and I got an error:
$ sosreport
sosreport (version 3.0)
no valid plugins were enabled
So I tried running it as root:
$ sudo sosreport
[sudo] password for christy:
sosreport (version 3.0)
This command will collect system configuration and
diagnostic information from this Fedora system. An archive
containing the collected information will be generated in
/var/tmp.
For more information on the Fedora Project visit:
https://fedoraproject.org/
The generated archive may contain data considered
sensitive and its content should be reviewed by the
originating organization before being passed to any third
party.
No changes will be made to system configuration.
Press ENTER to continue, or CTRL-C to quit.
Please enter your first initial and last name [christy-toshiba]:
cperezPlease enter the case number that you are generating this report
for:
gluster
Traceback (most recent call last):
File "/usr/lib/python2.7/site-packages/sos/sosreport.py", line 937, in
setup
plug.setup()
File "/usr/lib/python2.7/site-packages/sos/plugins/gluster.py", line
91, in setup
gluster_major = int((pkg["version"])[:1])
TypeError: string indices must be integers, not str
yum
Traceback (most recent call last):
File "/usr/lib/python2.7/site-packages/sos/sosreport.py", line 937, in
setup
plug.setup()
File "/usr/lib/python2.7/site-packages/sos/plugins/yum.py", line 29,
in setup
rhelver = self.policy().rhel_version()
AttributeError: 'FedoraPolicy' object has no attribute 'rhel_version'
Running plugins. Please wait ...
Running 39/65: networking...
So this time it worked better, but, not completely. It hung again there
at 39/65.
I eventually got an sosreport (including the above traceback still) by
using:
$ sudo sosreport -v --batch -n networking -n systemd
Running plugins. Please wait ...
Running 25/63: kernel... caught IO error
copying /sys/module/kdb_main/parameters/enable_nmi
Running 46/63: processor... caught IO error
copying /sys/devices/system/cpu/cpu0/power/autosuspend_delay_ms
caught IO error
copying /sys/devices/system/cpu/cpu1/power/autosuspend_delay_ms
caught IO error
copying /sys/devices/system/cpu/cpu2/power/autosuspend_delay_ms
caught IO error
copying /sys/devices/system/cpu/cpu3/power/autosuspend_delay_ms
caught IO error
copying /sys/devices/system/cpu/power/autosuspend_delay_ms
Running 63/63: yum...
Creating compressed archive...
Your sosreport has been generated and saved in:
/var/tmp/sosreport-christy-toshiba-20140120155033.tar.xz
The checksum is: dd42f749b1d6ae0952a71bd6ce12b80c
Please send this file to your support representative.
===
I just wanted to share my findings, in case there are more bugs opened
for this. It seems to be a problem for Power and x86.
Regards,
- Christy
10 years, 10 months
Re: [Kimchi-devel] [project-kimchi] [PATCH V3 0/5] Host's package management support
by Hongliang Wang
Hi Paulo, I'm working on the UI for package management, though this
patch set seems needs rebased. Could send a new one?
On 12/07/2013 04:19 AM, Paulo Vital wrote:
> V3 -> V2:
> Fixed API.json file
> Modified _repos_storage type to dictionary, and adjust methods to use it
> Changed return of some functions to raise exceptions instead of boolean
>
> V1 -> V2:
> Cleaned whitespaces and fixed some typos
> Changed return of backend functions to raise exceptions instead of boolean
>
> V1:
>
> This patch set provides support to host's package management operations.
> At this point, an agnostic class is providing support to backend and
> REST API operations.
>
> In backend, YUM support to operate with repositories is provided by this
> patch set. The support to APT repositories will be provided in a close
> future.
>
> To test the backend execute the following commands:
> $ sudo tests/run_tests.sh test_model.ModelTests.test_repository_create
> $ sudo tests/run_tests.sh test_model.ModelTests.test_repository_update
> $ sudo tests/run_tests.sh test_model.ModelTests.test_repository_disable_enable
>
> To test the REST API, execute the following commands (all them are agnostic of the
> host's distro):
>
> 1) Get list of all repositories enabled in the host:
> $curl -H 'Content-type: application/json' -H 'Accept: application/json' http://localhost:8000/repositories/ -X GET
>
> 2) Create a new repository:
> $ curl -H 'Content-type: application/json' -H 'Accept: application/json' http://localhost:8000/repositories/ -X POST -d'
> {
> "repo_id":"fedora-fake",
> "repo_name":"Fedora 19 FAKE",
> "baseurl": "http://www.fedora.org"
> }
> '
>
> 3) Get information from a specific repository:
> $curl -H 'Content-type: application/json' -H 'Accept: application/json' http://localhost:8000/repositories/fedora-fake
>
> 4) Update a specific repository:
> $ curl -H 'Content-type: application/json' -H 'Accept: application/json' http://localhost:8000/repositories/fedora-fake -X PUT -d'
> {
> "repo_id":"fedora-fake",
> "repo_name":"Fedora 19 FAKEs",
> "baseurl": "http://www.fedora.org/downloads"
> }
> '
>
> 5) Disable a specific repository:
> $ curl -H 'Content-type: application/json' -H 'Accept: application/json' http://localhost:8000/repositories/fedora-fake/disable -X POST -d ''
>
> 6) Enable a specific repository:
> $ curl -H 'Content-type: application/json' -H 'Accept: application/json' http://localhost:8000/repositories/fedora-fake/enable -X POST -d ''
>
> 6) Delete a specific repository:
> $ curl -H 'Content-type: application/json' -H 'Accept: application/json' http://localhost:8000/repositories/fedora-fake -X DELETE
>
>
> Paulo Vital (5):
> Host's package management: Update API.md
> Host's package management: Update REST API
> Host's package management: Update backend.
> Host's package management: Update Makefile
> Host's package management: Update test-cases
>
> docs/API.md | 90 ++++++++++
> src/kimchi/API.json | 65 +++++++
> src/kimchi/Makefile.am | 1 +
> src/kimchi/controller.py | 20 +++
> src/kimchi/mockmodel.py | 33 ++++
> src/kimchi/model.py | 33 ++++
> src/kimchi/repositories.py | 419 +++++++++++++++++++++++++++++++++++++++++++++
> src/kimchi/server.py | 1 +
> tests/test_model.py | 99 +++++++++++
> tests/test_rest.py | 32 ++++
> 10 files changed, 793 insertions(+)
> create mode 100644 src/kimchi/repositories.py
>
10 years, 10 months