Skip to content

Commit c86c5d2

Browse files
author
Prasanna Santhanam
committed
Uniting all the READMEs from tools and test
There are various READMEs under Cloudstack. This makes it confusing for finding the purpose of each directory and tool within the project. All the necessary information can now be found in the top-level README.tools that is markdown editable. For the most updated information however it is best to provide a wiki link to the tool you have added. Each tool lies in a seperate section, please keep formatting unchanged.
1 parent 7804686 commit c86c5d2

6 files changed

Lines changed: 220 additions & 172 deletions

File tree

README.tools.md

Lines changed: 220 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,220 @@
1+
> Licensed to the Apache Software Foundation (ASF) under one
2+
> or more contributor license agreements. See the NOTICE file
3+
> distributed with this work for additional information
4+
> regarding copyright ownership. The ASF licenses this file
5+
> to you under the Apache License, Version 2.0 (the
6+
> "License"); you may not use this file except in compliance
7+
> with the License. You may obtain a copy of the License at
8+
>
9+
> http://www.apache.org/licenses/LICENSE-2.0
10+
>
11+
> Unless required by applicable law or agreed to in writing,
12+
> software distributed under the License is distributed on an
13+
> "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
14+
> KIND, either express or implied. See the License for the
15+
> specific language governing permissions and limitations
16+
> under the License.
17+
18+
19+
---------------------------------------------------------------------------
20+
This README describes the various tools available with Apache Cloudstack -
21+
for compiling, deploying, building and testing the project
22+
---------------------------------------------------------------------------
23+
24+
DevCloud
25+
=========================================================
26+
Under tools/devcloud
27+
28+
NOTE - DevCloud (tools/devcloud) is a work in progress. The project has not
29+
determined how to best establish a nightly DevCloud build process, or how to
30+
distribute the image.
31+
32+
#### Contents: ####
33+
34+
Under tools/devcloud are various scripts used to build the devcloud image.
35+
devcloudsetup.sh - the origional devcloud build script (assumes an Ubuntu 12.04
36+
VM image)
37+
38+
$ cd tools/devcloud
39+
40+
* build_vagrant_basebox.sh - a script that uses VirtualBox, VeeWee, Vagrant
41+
(patched) and puppet to create a devcloud basebox
42+
* veewee - configuration files used to build a basic Ubuntu 12.04 vagrant box
43+
via VeeWee
44+
* basebuild - The Vagrantfile and puppet module that gets applied to the basic
45+
Ubuntu 12.04 box
46+
* devcloudbox - The Vagrantfile and puppet module that is used with the
47+
[hopefully] distributed devcloud base box
48+
49+
#### Instructions: ####
50+
51+
To build a "devcloud base box", run you need a system with VirtualBox and rvm
52+
installed (use ruby 1.9.2). Run build_vagrant_basebox.sh to build the base
53+
box.
54+
55+
To use the "devcloud base box" that is created in the previous step, you need
56+
to have installed a forked version of Vagrant (until we make the changes
57+
plugins instead of direct source patches) that can be found here:
58+
59+
Once installed per the Vagrant installation process, run:
60+
61+
$ vagrant box add devcloud [path to devcloud.box]
62+
63+
Then, either go into the devcloudbox folder of your checked out version of the
64+
CloudStack code (incubator-cloudstack/tools/devcloud/devcloudbox), or copy the
65+
contents of that folder to another location.
66+
67+
Assuming the patched Vagrant installation is working, you then
68+
simply run "vagrant up" from within that directory.
69+
70+
#### Installation ####
71+
72+
Install DevCloud Base system:
73+
74+
1. get code from https://github.com/jedi4ever/veewee, and install
75+
2. veewee vbox define devcloud ubuntu-12.04-server-i386
76+
3. put these two files(definition.rb and preseed.cfg) under ./definition/devcloud/
77+
3. veewee vbox build devcloud
78+
79+
80+
Marvin
81+
=========================================================
82+
Under tools/marvin
83+
84+
Marvin is the functional testing framework for CloudStack written in python.
85+
Writing of unittests and functional tests with Marvin makes testing with
86+
cloudstack easier
87+
88+
Visit the
89+
[wiki](https://cwiki.apache.org/confluence/display/CLOUDSTACK/Testing+with+Python)
90+
for the most updated information
91+
92+
#### Installation ####
93+
94+
$ untar Marvin-0.1.0.tar.gz
95+
$ cd Marvin-0.1.0
96+
$ python setup.py install
97+
98+
#### Features ####
99+
100+
1. very handy cloudstack API python wrapper
101+
2. support async job executing in parallel
102+
3. remote ssh login/execute command
103+
4. mysql query
104+
105+
#### Examples ####
106+
107+
Examples on how to develop your own configuration can be found in the marvin sandbox.
108+
Under tools/marvin/marvin/sandbox
109+
110+
To generate the config for a deployment. Alter the .properties file in the sandbox. For example the
111+
simualtordemo.properties after modification can generate the config file as
112+
shown below
113+
114+
$ python simulator_setup.py -i simulatordemo.properties -o simulatordemo.cfg
115+
116+
To deploy the environment and run the tests
117+
118+
$ python -m marvin.deployAndRun -c simulatordemo.cfg -t /tmp/t.log -r /tmp/r.log -d testcase
119+
120+
#### Tests ####
121+
122+
Functional Tests written using marvin can be found under test/integration
123+
folder. These are tests that are written to be run against a live deployed
124+
system.
125+
126+
To run the tests - you should have marvin installed and correctly importable.
127+
The tests are long running and are best monitored by external hudson jobs.
128+
129+
Also you will have to point marvin to the right configuration file that has
130+
details about your cloudstack deployment. For more help on how to write the
131+
config file and run tests check the tutorial at :
132+
133+
[] (https://cwiki.apache.org/confluence/display/CLOUDSTACK/Testing+with+Python)
134+
135+
#### Build Verification Testing (BVT) ####
136+
137+
These test cases are the core functionality tests that ensure the application
138+
is stable and can be tested thoroughly. These BVT cases definitions are
139+
located at :
140+
[] (https://docs.google.com/a/cloud.com/spreadsheet/ccc?key=0Ak8acbfxQG8ndEppOGZSLV9mUF9idjVkTkZkajhTZkE&invite=CPij0K0L)
141+
142+
##### Guidelines on tests #####
143+
144+
BVT test cases are being developed using Python unittests2. Following are
145+
certain guidelines being followed
146+
147+
1. Tests exercised for the same resource should ideally be present under a
148+
single suite or file.
149+
150+
2. Time-consuming operations that create new cloud resources like server
151+
creation, volume creation etc should not necessarily be exercised per unit
152+
test. The resources can be shared by creating them at the class-level using
153+
setUpClass and shared across all instances during a single run.
154+
155+
3. Certain tests pertaining to NAT, Firewall and Load Balancing warrant fresh
156+
resources per test. Hence a call should be taken by the stakeholders regarding
157+
sharing resources.
158+
159+
4. Ensure that the tearDown/tearDownClass functions clean up all the resources
160+
created during the test run.
161+
162+
For more information about unittests: [] (http://docs.python.org/library/unittest.html)
163+
164+
##### BVT Tests #####
165+
Under test/integration/smoke
166+
167+
The following files contain these BVT cases:
168+
169+
1. test_vm_life_cycle.py - VM Life Cycle tests
170+
2. test_volumes.py - Volumes related tests
171+
3. test_snapshots.py - Snapshots related tests
172+
4. test_disk_offerings.py - Disk Offerings related tests
173+
5. test_service_offerings.py - Service Offerings related tests
174+
6. test_hosts.py - Hosts and Clusters related tests
175+
7. test_iso.py - ISO related tests
176+
8. test_network.py - Network related tests
177+
9. test_primary_storage.py - Primary storage related tests
178+
10. test_secondary_storage.py - Secondary storage related tests
179+
11. test_ssvm.py - SSVM & CPVM related tests
180+
12. test_templates.py - Templates related tests
181+
13. test_routers.py - Router related tests
182+
183+
184+
##### P1 Tests #####
185+
Under test/integration/component
186+
187+
These test cases are the core functionality tests that ensure the application
188+
is stable and can be tested thoroughly. These P1 cases definitions are located
189+
at :
190+
[] (https://docs.google.com/a/clogeny.com/spreadsheet/ccc?key=0Aq5M2ldK6eyedDJBa0EzM0RPNmdVNVZOWnFnOVJJcHc&hl=en_US)
191+
192+
The following files contain these P1 cases:
193+
194+
1. test_snapshots.py - Snapshots related tests
195+
2. test_routers.py - Router related tests
196+
3. test_usage.py - Usage realted tests
197+
4. test_account.py - Account related tests
198+
5. test_resource_limits.py - Resource limits tests
199+
6. test_security_groups.py - Security groups related tests
200+
7. test_templates.py - templates related tests
201+
8. test_volumes.py - Volumes related tests
202+
9. test_blocker_bugs.py - Blocker bugs tests
203+
10. test_project_configs.py - Project global configuration related tests
204+
11. test_project_limits.py - Project resource limits related tests
205+
12. test_project_resources.py - Project resource creation related tests
206+
13. test_project_usage.py - Project usage related tests
207+
14. test_projects - Projects functionality tests
208+
209+
210+
test/conf - EC2 script
211+
=========================================================
212+
213+
To run submitCertEC2 and deleteCertEC2 scripts, update parameters in conf/tool.properties file:
214+
215+
* host - ip address of the host where cloud-bridge software is installed
216+
* port - port cloud-bridge software is listening to
217+
* accesspoint - access point for cloud-bridge REST request
218+
* version - Amazon EC2 api version supported by cloud-bridge
219+
* signaturemethod - HmacSHA1 or HmacSHA256
220+
* expires - the date when certificate expires

test/conf/README

Lines changed: 0 additions & 8 deletions
This file was deleted.

test/integration/README

Lines changed: 0 additions & 74 deletions
This file was deleted.

tools/devcloud/README

Lines changed: 0 additions & 56 deletions
This file was deleted.

tools/devcloud/veewee/README

Lines changed: 0 additions & 5 deletions
This file was deleted.

tools/marvin/README

Lines changed: 0 additions & 29 deletions
This file was deleted.

0 commit comments

Comments
 (0)