Skip to main content

Posts

Showing posts from November, 2014

Unit testing OpenStack with tox

Testing is and will always be an integral part of any software development. OpenStack is no exception. In OpenStack, unit testing is done using tox. Installing tox, [apt-get | yum] install python-pip; pip install tox Tox has various tests defined in the envlist. One can open tox.ini for a complete list of envs defined. OpenStack defines, py27 and pep8 test. Former is for unittests and later for style checks. How to run tox and testr Tox can use used to list unit tests and execute all of them or any subset of them using regex. To run all tests, tox -e py27                        # you can chose any other                                                          ...

Devstack installation with cells in multiple machines

  Devstack is a testing and development package for OpenStack . The official devstack website has excellent but terse installation instructions, which could be daunting to a newbie. Normally, a traditional install is pretty straightforward but problems creep in when you have to go for some particular configuration or installation like cells or a simple code-test-debug setup, the information on the main site is insufficient. In this blog, I will enumerate the steps for setting up a cell-ular devstack installation with one parent and one child. Parent will not be instantiating any VMs s it's only a 'command centre'. 1. On both machines, install git and vim, clone the devstack repo using git. yum install git vim git clone https://git.openstack.org/openstack-dev/devstack 2. On both machines, open up the file 'local.conf' inside the cloned directory 'devstack' cd devstack; vim local.conf 3. Copy the parameters below to the file...