~ajkavanagh/openstack-mojo-specs/remove-cinder-from-vrrp-ha

204.1.3 by Liam Young
More tidyup and updates to README
1
General
2
=======
3
4
These are the Mojo specs for running deployments of Openstack. For more
5
information on installing and running Mojo see lp:mojo
6
7
Directoy Layouts
8
================
9
10
Top Level
11
---------
12
13
This branch contains the following top level assets:
14
15
* *specs* directory contains the specs themselves.
16
* *SPEC\_SUMMARY.txt* contains descriptions of each spec
17
* *Makefile* has targets for checking lint and generating SPEC\_SUMMARY.txt
18
* *helper* directory contains scripts and libraries used by the specs
19
20
spec directory
21
--------------
22
23
The specs fall into the following catagories:
24
25
* *dev*: Specs which are still under development (these are not lint checked)
26
* *full\_stack*: These perform a full openstack deployment
27
* *bugs*: Specs that reproduce a bug. These are useful for verifying a bugs
28
  existence and then once the fix has landed they can be used to verify a
29
  regression has not occured.
30
* *features*: These do a minimal deployment to demonstrate a new feature.
31
* *object\_storage*: Specs for deploying a standalone object storage environment
32
33
Tip directory
34
-------------
35
36
The tip directory should be used to differentiate between Openstack versions.
37
38
Example
39
-------
40
41
*specs/full_stack/charmhelper_upgrade/juno/*
42
43
This spec is used to do a deployment of a full Juno Openstack environment and
44
to test an upgrade of charmhelpers
45
46
helper directory
47
----------------
48
49
The helper directory contains the following:
50
51
* *bundles*: Juju deployer bundles
52
* *collect*: Mojo collect and repo files, used to collect branches prior to
53
           running Juju Deployer
54
* *scripts*: Scripts for running lint checks etc
55
* *setup*: Manipulate the overcloud or provider
56
* *template*: An example spec
57
* *tests*: Tests to run against the deployment
58
* *utils*: Core set of utilities used by tests and setup
59
60
Spec Bulding Blocks
61
===================
62
63
Phase 1: Collection
64
-------------------
65
66
Directives: collect and repo
67
68
These specs collect the charm branches as a seperate step from deploying the
69
charms. Although Juju deployer can do the branch collection, having this done
70
as a seperate phase has a few advantages. It allows for the branches to be
71
manipulated prior to deployment, the charmhelper upgrade spec does exactly this
72
to check that a charmhelper sync will not break a deployment. It also allows
73
for an alternative branch location for a given charm to be clearly specified,
74
this is particulalry useful when an unmerged branch needs testing.
75
76
Phase 2: Deployment
77
-------------------
78
79
Directives: deploy
80
81
Mojo uses juju deployer to do the charm deployment. When specifying the target
82
to use in the bundle the ${MOJO\_SERIES} environment variable should be used in
204.1.4 by Liam Young
More detail to readme
83
place of the Ubuntu release version. This allows the same spec to be used for
204.1.3 by Liam Young
More tidyup and updates to README
84
deployments on different Ubuntu release.
85
86
deploy config=haphase1.yaml delay=0 target=${MOJO\_SERIES}-juno
87
88
Phase 3: Cloud Setup
89
--------------------
90
91
Directives: script
92
93
There are a number of helper scripts used to setup the cloud once it has been
94
deployed. In general they consist of the script to do the setup and a YAML file
95
of options.
96
97
* *image\_setup.py*: This script downloads guest images and uploads them to
98
                  Glance. *images.yaml* lists the images to be downloaded and
99
		  information about those images.
100
* *keystone\_setup.py*: Setup keystone users and roles. *keystone_users.yaml*
101
                     lists the users to be created and what roles they should
102
		     be given
103
* *network\_setup.py*: This sets up the SDN on the cloud. *network.yaml* describes
104
                    the SDN topology
105
106
Phase 4: Test
107
-------------
108
109
Directives: verify
110
111
There are a number of tests to choose from, some are specific to particular
112
bugs or features. However, the main tests used to verify the cloud are:
113
114
* *simple\_os\_checks.py*: This script creates guests on the cloud, associates
115
                           floating ips and then uses ssh to connect to the
116
			   cloud and verifies its hostname. This ensure that
117
			   the guest got a network and metadata on boot.
118
* *test\_obj\_store.py*: This script fires two streams of objects and the
119
                         object store and retireves them
120
* *tempest.py*: This doesn't actually exist in any real sense but will do rsn!
121
122
Phase 5: Manipulate the cloud
204.1.4 by Liam Young
More detail to readme
123
-----------------------------
204.1.3 by Liam Young
More tidyup and updates to README
124
125
Directives: script
126
127
There are scripts for manipulating the cloud, usually at the Juju level. These
128
include:
129
130
* *add_unit.py*: Use juju to add a unit to a given service
131
* *chaos_pony.py*: Kill, test and add units to all services
132
* *delete_crm_leader.py*: Delete the unit Corosync reports is the leader for a
133
                          given service
134
* *delete_router_home.py*: Delete the unit housing a particular Neutron router
135
* *delete_unit.py*: Delete a given unit
136
* *juju_set.py*: Juju set a kv pair for a given service
137
* *upgrade_all_services.py*: Perform a Juju charm upgrade on all services
138
* *upgrade_services.py*: Perform a Juju charm upgrade on a given service
139
204.1.4 by Liam Young
More detail to readme
140
Helper Libraries
141
================
142
143
There are two helper libraries in *helper/utils/*.
144
145
* *mojo_os_utils.py*: Functions for manipulating the deployed Openstack cloud.
146
* *mojo_utils.py*: Functions for manipulating the providor environment. Juju
147
                   add/remove unit etc
148
204.1.3 by Liam Young
More tidyup and updates to README
149
Using mojo
150
==========
151
152
Install mojo (Stolen from https://launchpad.net/mojo)
153
sudo add-apt-repository ppa:mojo-maintainers/ppa
154
sudo apt-get update
155
sudo apt-get install mojo
156
157
sudo mojo project-new --series trusty mojo-openstack-specs
158
sudo adduser ubuntu mojo
159
sudo chmod 755 /var/lib/lxc/mojo-openstack-specs.trusty && sudo chmod 755 /var/lib/lxc
160
161
mojo workspace-new --project mojo-openstack-specs --series trusty --stage full_stack/next_deploy lp:~ost-maintainers/openstack-mojo-specs/mojo-openstack-specs run1
162
mojo run --project mojo-openstack-specs --series trusty --stage full_stack/next_deploy lp:~ost-maintainers/openstack-mojo-specs/mojo-openstack-specs run1