blob: 50c0100578e01578b8569a44522b1db99809b679 [file] [log] [blame]
Dean Troyer0986a7b2014-10-29 22:08:13 -05001============
2Contributing
3============
Sean M. Collins09e550c2014-10-21 11:40:08 -04004
5DevStack uses the standard OpenStack contribution process as outlined in
Jeremy Stanley3eeed232014-12-05 03:30:41 +00006`the OpenStack developer
7guide <http://docs.openstack.org/infra/manual/developers.html>`__. This
8means that you will need to meet the requirements of the Contribututors
Sean M. Collins09e550c2014-10-21 11:40:08 -04009License Agreement (CLA). If you have already done that for another
10OpenStack project you are good to go.
11
12Things To Know
Sean Dague32930462014-11-18 06:51:16 -050013==============
Sean M. Collins09e550c2014-10-21 11:40:08 -040014
Sean Dague32930462014-11-18 06:51:16 -050015|
Sean M. Collins09e550c2014-10-21 11:40:08 -040016| **Where Things Are**
17
18The official DevStack repository is located at
19``git://git.openstack.org/openstack-dev/devstack.git``, replicated from
20the repo maintained by Gerrit. GitHub also has a mirror at
21``git://github.com/openstack-dev/devstack.git``.
22
23The `blueprint <https://blueprints.launchpad.net/devstack>`__ and `bug
24trackers <https://bugs.launchpad.net/devstack>`__ are on Launchpad. It
25should be noted that DevStack generally does not use these as strongly
26as other projects, but we're trying to change that.
27
28The `Gerrit review
29queue <https://review.openstack.org/#/q/project:openstack-dev/devstack,n,z>`__
30is, however, used for all commits except for the text of this website.
31That should also change in the near future.
32
Sean Dague32930462014-11-18 06:51:16 -050033|
Sean M. Collins09e550c2014-10-21 11:40:08 -040034| **HACKING.rst**
35
36Like most OpenStack projects, DevStack includes a ``HACKING.rst`` file
37that describes the layout, style and conventions of the project. Because
38``HACKING.rst`` is in the main DevStack repo it is considered
39authoritative. Much of the content on this page is taken from there.
40
Sean Dague32930462014-11-18 06:51:16 -050041|
Sean M. Collins09e550c2014-10-21 11:40:08 -040042| **bashate Formatting**
43
44Around the time of the OpenStack Havana release we added a tool to do
45style checking in DevStack similar to what pep8/flake8 do for Python
46projects. It is still \_very\_ simplistic, focusing mostly on stray
47whitespace to help prevent -1 on reviews that are otherwise acceptable.
48Oddly enough it is called ``bashate``. It will be expanded to enforce
49some of the documentation rules in comments that are used in formatting
50the script pages for devstack.org and possibly even simple code
51formatting. Run it on the entire project with ``./run_tests.sh``.
52
53Code
Sean Dague32930462014-11-18 06:51:16 -050054====
Sean M. Collins09e550c2014-10-21 11:40:08 -040055
Sean Dague32930462014-11-18 06:51:16 -050056|
Sean M. Collins09e550c2014-10-21 11:40:08 -040057| **Repo Layout**
58
59The DevStack repo generally keeps all of the primary scripts at the root
60level.
61
Dean Troyerea3cdfa2014-11-08 08:29:16 -060062``doc`` - Contains the Sphinx source for the documentation.
63``tools/build_docs.sh`` is used to generate the HTML versions of the
64DevStack scripts. A complete doc build can be run with ``tox -edocs``.
Sean M. Collins09e550c2014-10-21 11:40:08 -040065
Dean Troyerea3cdfa2014-11-08 08:29:16 -060066``exercises`` - Contains the test scripts used to sanity-check and
Sean M. Collins09e550c2014-10-21 11:40:08 -040067demonstrate some OpenStack functions. These scripts know how to exit
68early or skip services that are not enabled.
69
70``extras.d`` - Contains the dispatch scripts called by the hooks in
Dean Troyerea3cdfa2014-11-08 08:29:16 -060071``stack.sh``, ``unstack.sh`` and ``clean.sh``. See :doc:`the plugins
72docs <plugins>` for more information.
Sean M. Collins09e550c2014-10-21 11:40:08 -040073
74``files`` - Contains a variety of otherwise lost files used in
75configuring and operating DevStack. This includes templates for
76configuration files and the system dependency information. This is also
77where image files are downloaded and expanded if necessary.
78
79``lib`` - Contains the sub-scripts specific to each project. This is
80where the work of managing a project's services is located. Each
81top-level project (Keystone, Nova, etc) has a file here. Additionally
82there are some for system services and project plugins.
83
84``samples`` - Contains a sample of the local files not included in the
85DevStack repo.
86
87``tests`` - the DevStack test suite is rather sparse, mostly consisting
Dean Troyerea3cdfa2014-11-08 08:29:16 -060088of test of specific fragile functions in the ``functions`` and
89``functions-common`` files.
Sean M. Collins09e550c2014-10-21 11:40:08 -040090
Dean Troyerea3cdfa2014-11-08 08:29:16 -060091``tools`` - Contains a collection of stand-alone scripts. While these
Sean M. Collins09e550c2014-10-21 11:40:08 -040092may reference the top-level DevStack configuration they can generally be
93run alone. There are also some sub-directories to support specific
94environments such as XenServer.