35 Commits

Author SHA1 Message Date
Chmouel Boudjnah
86a8e97679 Add while/until to the for/do rule
Like 'for/do' check that the while/until operator are on
the same line with the do.

Fixes some pep8 error along the way.

Change-Id: I440afe60691263365bf35310bf4212d94f30c339
2014-02-05 07:52:54 +01:00
Sean Dague
16dd8b3ed9 introduce if/then & for/do rules
we mostly have a consistent style on if/then & for/do in devstack,
except when we don't. This attempts to build a set of rules to
enforce this.

Because there are times when lines are legitimately long, and there
is a continuation, this starts off ignoring if and for loops with
continuations. But for short versions, we should enforce this.

Changes to make devstack pass are included. The fact that the
cleanup patch was so small is pretty solid reason that this is
actually the style we've all agreed to.

Part of a git stash from hong kong that I finally cleaned up.

Change-Id: I6376d7afd59cc5ebba9ed69e5ee784a3d5934a10
2014-02-05 07:52:54 +01:00
Sean Dague
0b865a55f2 final bash8 files for the rest of devstack
With this devstack/master is bash8 clean, and ready for enforcement

Change-Id: I03fc89b401e6b7a23224d71472122c1bfa3ad0bd
2013-10-22 13:06:18 -04:00
ZhiQiang Fan
7d56215837 Replace OpenStack LLC with OpenStack Foundation
Change-Id: I7642e7163b615798867881b012240164465c5e43
Fixes-Bug: #1214176
2013-09-20 02:20:35 +08:00
Mate Lakat
16ed068db5 xenapi: Set VM memory before starting it
If someone was re-using an existing template, for a memory change, he
needed to re-install the vm. This change sets the osdomu mem before
starting it, so it doesn't matter how much memory did the VM had
according to the template. It also removes the memory manipulation bits
from install-os-vpx.sh.

Change-Id: Iad85f573b90c23140012c20c552a17277d9c97a0
2013-08-30 14:21:10 +01:00
Jenkins
c31d192262 Merge "manage-vdi: Wait until devices have been created before mounting" 2013-07-31 14:48:21 +00:00
Euan Harris
a3ec804ad9 manage-vdi: Wait until devices have been created before mounting
kpartx creates partition devices asynchronously - it may exit before
the devices have been created.  This may cause a subsequent mount call
to fail, because the device it is trying to mount does not yet exist.
kpartx now has a -s option which makes it wait for the devices to be
created before returning, but the version XenServer's dom0 doesn't have
this option.   Work around this by retrying the mount.

When dom0's kpartx is updated, we will be able to use the -s option.

Change-Id: I823a8eac4f3a2ef313d06e21da0f38ed46d7386a
2013-07-11 15:50:32 +01:00
Jenkins
3c98af20fc Merge "devstack: Add paths specific to XenServer Core" 2013-07-10 20:30:39 +00:00
Euan Harris
12229a77a5 devstack: Add paths specific to XenServer Core
* XenServer Core keeps its Xapi plugins in a different path to XenServer,
   in order to comply with the Filesystem Hierarchy Standard.

 * XenServer Core mounts devices under /dev/xen/blktap-2 in dom0,
   whereas XenServer mounts them under /dev/sm.

Change-Id: I0a66cd03f000f19c8ff63a8ae4231c00fda88380
2013-07-10 14:05:22 +01:00
Jenkins
4ef0c71914 Merge "xenapi: cleanup VM Installation" 2013-07-09 00:13:30 +00:00
Joe Gordon
4640026cc1 Fix spelling mistakes
git ls-files | misspellings -f -
Source: https://github.com/lyda/misspell-check

Change-Id: I7d63578734ca5cc1ec865a7d024c1a013d1ada87
2013-06-30 04:32:27 -07:00
Mate Lakat
2f524bd905 xenapi: cleanup VM Installation
VM installation created a machine with multiple network interfaces. This
is a needless complexity at that point, we only need one interface. This
change removes the complex network interface setup from
install-os-vpx.sh script, so that only one network interface is created,
which is connected to the selected network (management by default). This
change also removes a lot of non-used code from install-os-vpx.sh
Specify the network to be used for ubuntu netinstall with:

    UBUNTU_INST_BRIDGE_OR_NET_NAME

defaults to $MGT_BRIDGE_OR_NET_NAME.

This change also includes:
 - use precise as default

Related to blueprint xenapi-devstack-cleanup

Change-Id: Ib0a0a316e849f2c2651305ea657c84820cd2bb3b
2013-06-20 15:22:58 +01:00
Mate Lakat
8ff33ce75f xenapi: kernel_cmdline moved out from template
The kernel's cmdline was set during the initial devstack machine
installation. Thus, during second runs, the kernel's cmdline was not
updated. This patch extracts append_kernel_cmdline, and configures
domU's kernel cmdline every time. As some networking parameters are
passed through the kernel cmdline, this patch makes it possible to
change the network configuration, even if a cached devstack exists.

Related to blueprint xenapi-devstack-cleanup

Change-Id: I3b7175f4e83326c3e28825ac50625f6bd2a9a029
2013-05-31 10:45:46 +01:00
Mate Lakat
9e32677927 xenapi - cleanup network configuration
The Xenserver/XCP part of devstack was configuring the hypervisor's
connectivity to the outer world, by adding VLANs, and physical
interfaces to the virtual networks. It added a lot of complexity, and
made it hard to get started with XenServer. This patch removes that
extra complexity, so it is left as an exercise for the user.

Related to blueprint blueprint xenapi-devstack-cleanup

Change-Id: If3367335c3da8621d0afe1f6cae77511fbdbb3e2
2013-05-24 12:07:56 +01:00
Mate Lakat
d3740f70b5 xenapi: Ubuntu installation repository/proxy fix
Get rid of UBUNTU_INST_REPOSITORY, use UBUNTU_INST_HTTP_HOSTNAME and
UBUNTU_INST_HTTP_DIRECTORY instead. User can also specify
UBUNTU_INST_HTTP_PROXY to utilize a proxy for the OpenStack VM
installation. The answer file will be edited to contain the specified
values. Also get rid of the magic, undocumented MIRROR variable.

This is related to blueprint xenapi-devstack-cleanup

Change-Id: Ic9fc564c4ad0f43e2e536854335ebe14791d0255
2013-05-14 11:37:07 +01:00
Mate Lakat
0b3804bff7 xenapi - cleanup
Add error on unitialised variable to the scripts. This way some issues
were identified. Also modify README with fresh variables. The patch
includes:
 - Add SWIFT_HASH to the README
 - Add XENAPI_CONNECTION_URL to the README
 - Add VNCSERVER_PROXYCLIENT_ADDRESS to the README
 - Introduce UBUNTU_INST_IFACE which is the OpenStack VM interface used
   for the netinstall. It defaults to eth3. Previously this parameter
   was set by the combination of HOST_IP_IFACE and the undocumented
   NETINSTALL_IP
 - get rid of NETINSTALL_IP
 - xenrc includes CLEAN_TEMPLATES
 - xenrc no longer tries to change directory
 - remove chrooting from prepare_guest.sh (STAGING_DIR was always / )
 - remove DO_TGZ variable from prepare_guest.sh
 - use arguments to call prepare_guest.sh, instead of env vars
 - Fix backslash escaping in prepare_guest_template.sh

NOTE: networking is about to be addressed in a separate change.

Related to blueprint xenapi-devstack-cleanup

Change-Id: Ie9a75321c7f41cc9a0cc051398d1e6ec2c88adfa
2013-05-12 17:27:13 +01:00
Stef T
f993b2353f Enable Xen/DevStackDomU to have larger disk
* Size of xvda can be specified via xenrc

  * Fixes bug 1076430

Change-Id: Ia4ffef98b01fa9572e43c46275a132b2b1e5f689
2012-11-08 10:49:32 -05:00
John Garbutt
d8f1a87a45 Make it easier to use Precise or Oneric with XenServer DevStack
This is a partial fix for bug 1009937

Change-Id: I1fc7059cd812bce1539a5050f60717db4cbd81ef
2012-08-03 12:44:08 +01:00
Armando Migliaccio
1f8efd93d9 fix syntax error in the if test
switch to using -f rather than -a. This has been overlooked
in a review recently merged. Without this fix, devstack on
XenServer is broken.

Change-Id: I1882cc70528772287241848adea3a520738d4144
2012-06-02 01:47:27 +01:00
Jenkins
e959dbc132 Merge "Move the ubuntu template generator to use Squeeze." 2012-06-01 19:21:06 +00:00
John Garbutt
37826bc8c8 Move the ubuntu template generator to use Squeeze.
Newer versions of XenServer don't have lenny templates, so moving
to use Squeeze.

Change-Id: I95473d4cdc6caad86bc53799fe2ecbedd9223026
2012-05-25 13:09:38 +01:00
John Garbutt
030fb2362f Make devstack work with xcp-xapi package on Ubuntu 12.04
- allow you to configure the xenapi_user (often other than root)
- allow you to disable the guest installer network
- install the plugins in the xcp-xapi location
- use alternate webserver location when adding the preseed file
- skip the centos specific ip forwarding configuration
- make use xcp inventory, if no xensource-inventory is found
- correctly deal with kpartx to mount the VM VDI in manage_vdi

Change-Id: I8d51725fc97f0bcaa27a46f7a7ced13c369c809e
2012-05-22 18:12:43 +01:00
John Garbutt
daadf744ed Improvements to DevStack's XenServer scripts
I have ensured:
- template gets re-used on second run
- template includes XenServer tools, and custom user accounts
- take snapshot before first boot, for easy re-run
- make host_ip_iface work with either eth2 or eth3
- make ssh into domU checks looser
- above is all ground work for improved jenkins tests
- added some more comments to make it scripts clearer

Change-Id: I5c45370bf8a1393d669480e196b13f592d29154f
2012-05-22 18:12:43 +01:00
Renuka Apte
d7ed417fec Add script to delete templates
This is a common operation on XenServer, which seems to be a three
step process.

Change-Id: I125b9c11ace0b3454b7c974f9209aca01cdd7ed2
2012-05-10 15:42:29 -07:00
Renuka Apte
668d9cb9fd XenServer: Allow static network config for install
Change-Id: Ief24e21fcd8d4cd61296e4b81051d3332314d45c
2012-04-14 23:24:05 -05:00
Jenkins
4d70e9eb44 Merge "XenServer new install: Keep preseed file in dom0" 2012-04-14 23:00:16 +00:00
Renuka Apte
360e29bc0d XenServer new install: Keep preseed file in dom0
Use dom0 to dish out the preseed.cfg file instead of getting it
from anso

Change-Id: I220948ba9a2cd3006b2c050d976dfcb49b8d956e
2012-04-14 14:50:28 -05:00
Renuka Apte
83f8b1abce XenServer: Add script to mount OS domU in dom0
Change-Id: I1ad3d63c55b95f2588007c5e88704022f54e1c06
2012-04-14 14:49:10 -05:00
Renuka Apte
0af143b34e XenServer: new build and install scripts
Change-Id: Ia13a9c8073e59edf98415ba5b9f3a9cbd1453d32
2012-04-13 23:23:47 -05:00
Renuka Apte
836955f825 XenServer: change install script for new install process
Change-Id: Iee64e19fb21c1c633b5a2df7c4c154702f2a4526
2012-04-13 15:00:18 -07:00
Renuka Apte
4c889349b7 Script for Ubuntu 11.10 on Xenserver
This script creates a template for an Ubuntu 11.10 VM on Xenserver.
This is not officially supported by Citrix, but is useful, as most
of the Openstack development and instructions are based on it.

Change-Id: I8457f88ebe1065429d4c03de11d7ab0ef22f357a
2012-04-11 12:30:41 -07:00
Hengqing Hu
3b719e50fb Remove trailing whitespaces in regular file
Change-Id: I5faf840dd6649afcb53e91f1d033447f9729cee1
2012-03-09 16:04:56 +08:00
Renuka Apte
e98cc1220e Multiple vpx for xen, post splitting of script
Ensure building, installing multiple nova vms works after we
split the build script as build nova vm, install nova vm.

Change-Id: Iadb6e181caec511325a30727bf9e9c79e8afea5a
2012-02-14 15:30:34 -08:00
Anthony Young
fe1c6dedcb fix license 2011-10-26 23:36:25 -07:00
Anthony Young
b62b4ca292 Initial commit of xen devstack support 2011-10-26 22:29:08 -07:00