Move install responsibilities to domU

As we are moving forward to test XenAPI in the gate, it is necessary to
move dom0 related modifications to be performed from domU. For this
purpose, a new user is created, and that user should be used to talk to
dom0 from domU. This change creates that user, makes it possible for
dom0 to log in to domU with that account, and configure that account to
be able to talk down to dom0.

Also move several steps to the nova xenserver plugin:
 - dom0 plugin installation
 - create kernels and images directory
 - install console rotate script
 - configure a cron to execute console rotate script

Configuration changes:
    A new configuration option, DOMZERO_USER has been created, that
    specifies a user account that is configured to be able to do
    passwordless ssh to dom0.

Change-Id: If9de0b297a67b7cdb5de78d8dd0e8b2ca578b601
Cleanup cinder-rootwrap support

cinder_rootwrap support in devstack handled a number of now-abandoned
use cases:

- no $CINDER_DIR/etc/cinder/rootwrap.d (old-style rootwrap)
- using oslo-rootwrap instead of cinder-rootwrap (abandoned experiment)

This change removes unused code paths and aligns
configure_cinder_rootwrap() with configure_nova_rootwrap().

Change-Id: I387808dae0e064cc9c894c74ab78e86124f08dd2
Install glance images before starting Nova

The docker driver for Nova needs a registry service to be running.
It is being run inside a container using an image -- that image must
be downloaded. The registry service must be started via
nova_plugins/hypervisor-docker, but this is presently called
before Glance's image download.

The reordering is being done such that Glance may download the
registry image, but prior to starting Nova such that "hypervisor-docker"
may have an image downloaded and available to launch the registry.

This change should cause no negative effects on other hypervisors.

Change-Id: I7bccb42517e4c6187f2a90c64f39cda4577f89a3
blueprint: docker-glance-uploads
Split functions

Move shared and non-DevStack-specific functions to `functions-common`.  This is
a code move only with some updated comments.  The functions are now
sorted alphabetically within function groups, eg. all git-related functions
are grouped together.  The groups are listed at the top of the file.

'functions' sources 'functions-common' so no additional changes are required
for backward-compatability.

All functions shared with Grenade have also been moved.

functions-common was created from commit e0ed8ea038299952826b27a16753775472f108d8

Change-Id: I73bf7134fd6a60ec1ea44a5bfab08b0569b60ded
Add Fedora support to install_docker.sh

On Fedora, just install the docker-io package as supplied in the
Fedora repository.

Change-Id: Iea74878d3e1c434863c188ea2253817384e56bf4
Fix tee statement for catching tempest output

The use of exec and tee doesn't seem to be quite right, and was
unreliable in terms of catching the exit status of the tempest
test as well as not catching the output when things went wrong.

This changes the way we do the redirect and the tee to something
that should be more robust and seems to work reliably in testing.

Change-Id: Ieb9d725839fb8e3f9e2e63a2b7b2e9c7c86713a2
Fix MARCONI_USER

This patch fixes the MARCONI_USER in create_marconi_accounts().

Change-Id: I9618530fa20ee84d25646107c7450017ada908df
Marconi fixes for precise

Fix a couple of problems found on Ubuntu:
* $MARCONI_DIR/etc/marconi/policy.json doesn't exist; removed the copy to /etc/marconi
* added a seting of nssize in /etc/mongodb.conf for Ubuntu
* restart the correct serice name on Ubuntu

Change-Id: I9bd2ab1aa4fb94ff96559e069e5b62138c358fb5
Revert the tempest service name to marconi

This patch is to rollback the change introduced by
https://review.openstack.org/#/c/73100/. 73100 is no longer needed
because of the recent https://review.openstack.org/#/c/69497/.
Using 'marconi' as the service name will keep us aligned with the
naming convention used by other projects.

Change-Id: I5da6d2aaeb5c9dc29a1cbc70c8425449807eb34c
Optionally enable file injection

There is a patch up for nova right now that disables file injection by default.
This is a corresponding devstack change that only sets file injection options if
it is enabled in the devstack config.  This is good to keep around so that we
can easily turn it on for testing.

The nova change is id Icff1304fc816acc843f8962727aef8bbbc7bbaa3.

Change-Id: I5015f2c351b1d680c205d7f9a5204febca490b91
Merge "Fix MARCONI_USER"
Merge "Add Fedora support to install_docker.sh"
Merge "Marconi fixes for precise"
Merge "Revert the tempest service name to marconi"
Merge "Move install responsibilities to domU"
Merge "Cleanup cinder-rootwrap support"
Merge "Install glance images before starting Nova"
Merge "Split functions"
Merge "Optionally enable file injection"