Statistics
| Branch: | Tag: | Revision:

root / snf-cyclades-app / docs / index.rst @ 27a54f35

History | View | Annotate | Download (3 kB)

1 b1996c81 Kostas Papadimitriou
.. _snf-cyclades-app:
2 4a3e83c6 Kostas Papadimitriou
3 b1996c81 Kostas Papadimitriou
Component snf-cyclades-app
4 9940eacf Kostas Papadimitriou
==========================
5 b72adcc5 Kostas Papadimitriou
6 b1996c81 Kostas Papadimitriou
synnefo component :ref:`snf-cyclades-app <snf-cyclades-app>` defines
7 b1996c81 Kostas Papadimitriou
the web application for cyclades. It includes the following:
8 4a3e83c6 Kostas Papadimitriou
9 9940eacf Kostas Papadimitriou
    * A set of Django applications that define among others:
10 9940eacf Kostas Papadimitriou
        * web UI
11 9940eacf Kostas Papadimitriou
        * API implementation
12 9940eacf Kostas Papadimitriou
        * business logic layer
13 9940eacf Kostas Papadimitriou
        * admin web UI
14 9940eacf Kostas Papadimitriou
    * :ref:`snf-dispatcher <snf-dispatcher>`, the logic dispatcher
15 e609b1ba Vangelis Koukis
16 9940eacf Kostas Papadimitriou
.. todo:: make this section more complete.
17 e609b1ba Vangelis Koukis
18 9940eacf Kostas Papadimitriou
.. _snf-dispatcher:
19 4a3e83c6 Kostas Papadimitriou
20 9940eacf Kostas Papadimitriou
snf-dispatcher
21 9940eacf Kostas Papadimitriou
--------------
22 4a3e83c6 Kostas Papadimitriou
23 9940eacf Kostas Papadimitriou
The logic dispatcher provides the context to run the business logic layer of
24 b1996c81 Kostas Papadimitriou
:ref:`cyclades <snf-cyclades>`. It must run on :ref:`LOGIC <LOGIC_NODE>` nodes.
25 e609b1ba Vangelis Koukis
26 9940eacf Kostas Papadimitriou
The dispatcher retrieves messages from the queue, over AMQP, and calls the
27 9940eacf Kostas Papadimitriou
appropriate handler function, based on the type of the message.
28 4a3e83c6 Kostas Papadimitriou
29 9940eacf Kostas Papadimitriou
.. _snf-admin:
30 dbe32d94 Vangelis Koukis
31 9940eacf Kostas Papadimitriou
snf-admin
32 9940eacf Kostas Papadimitriou
---------
33 4a3e83c6 Kostas Papadimitriou
34 9940eacf Kostas Papadimitriou
command :command:`snf-admin` provides the command-line admin interface
35 b1996c81 Kostas Papadimitriou
for :ref:`cyclades <snf-cyclades>`.
36 9940eacf Kostas Papadimitriou
37 9940eacf Kostas Papadimitriou
Package installation
38 9940eacf Kostas Papadimitriou
--------------------
39 9940eacf Kostas Papadimitriou
40 9940eacf Kostas Papadimitriou
.. todo:: kpap: verify instructions for installation from source.
41 9940eacf Kostas Papadimitriou
42 9940eacf Kostas Papadimitriou
Use ``pip`` to install the latest version of the package from source,
43 b1996c81 Kostas Papadimitriou
or request a specific version as ``snf-cyclades-app==x.y.z``.
44 9940eacf Kostas Papadimitriou
45 9940eacf Kostas Papadimitriou
.. code-block:: console
46 9940eacf Kostas Papadimitriou
47 34e79416 Constantinos Venetsanopoulos
   $ pip install snf-cyclades-app -f https://www.synnefo.org/packages/pypi
48 9940eacf Kostas Papadimitriou
49 b1996c81 Kostas Papadimitriou
On Debian Squeeze, install the ``snf-cyclades-app`` Debian package.
50 9940eacf Kostas Papadimitriou
51 9940eacf Kostas Papadimitriou
Package configuration
52 9940eacf Kostas Papadimitriou
---------------------
53 9940eacf Kostas Papadimitriou
54 9940eacf Kostas Papadimitriou
Web application
55 9940eacf Kostas Papadimitriou
***************
56 9940eacf Kostas Papadimitriou
57 9940eacf Kostas Papadimitriou
Please see the configuration section of :ref:`snf-webproject <snf-webproject>`
58 b1996c81 Kostas Papadimitriou
on how to serve :ref:`snf-cyclades-app <snf-cyclades-app>` as part of a
59 9940eacf Kostas Papadimitriou
Django project.
60 9940eacf Kostas Papadimitriou
61 9940eacf Kostas Papadimitriou
snf-dispatcher
62 9940eacf Kostas Papadimitriou
**************
63 9940eacf Kostas Papadimitriou
64 cfa5eb53 Kostas Papadimitriou
.. note:: 
65 cfa5eb53 Kostas Papadimitriou
    The Debian package configures the init script for
66 cfa5eb53 Kostas Papadimitriou
    ``snf-dispatcher`` automatically, see ``/etc/default/snf-dispatcher``.
67 9940eacf Kostas Papadimitriou
68 9940eacf Kostas Papadimitriou
.. todo:: package an initscript for :command:`snf-dispatcher`
69 9940eacf Kostas Papadimitriou
70 9940eacf Kostas Papadimitriou
Make sure the logic dispatcher starts automatically on system boot of
71 9940eacf Kostas Papadimitriou
:ref:`LOGIC <LOGIC_NODE>` nodes. Initscript ``conf/init.d/snf-dispatcher``
72 9940eacf Kostas Papadimitriou
is provided for your convenience.
73 9940eacf Kostas Papadimitriou
74 9940eacf Kostas Papadimitriou
You may also start the dispatcher by hand:
75 9940eacf Kostas Papadimitriou
76 9940eacf Kostas Papadimitriou
.. code-block:: console
77 9940eacf Kostas Papadimitriou
78 9940eacf Kostas Papadimitriou
  $ snf-dispatcher
79 9940eacf Kostas Papadimitriou
80 9940eacf Kostas Papadimitriou
The dispatcher should run in at least 2 instances to ensure high
81 9940eacf Kostas Papadimitriou
(actually, increased) availability.
82 9940eacf Kostas Papadimitriou
83 9940eacf Kostas Papadimitriou
Package settings
84 9940eacf Kostas Papadimitriou
----------------
85 9940eacf Kostas Papadimitriou
86 b1996c81 Kostas Papadimitriou
Component :ref:`snf-cyclades-app <snf-cyclades-app>` requires the following
87 9940eacf Kostas Papadimitriou
settings, as managed by :ref:`snf-common <snf-common>`:
88 9940eacf Kostas Papadimitriou
89 9940eacf Kostas Papadimitriou
.. literalinclude:: ../synnefo/app_settings/default/api.py
90 9940eacf Kostas Papadimitriou
    :lines: 4-
91 9940eacf Kostas Papadimitriou
.. literalinclude:: ../synnefo/app_settings/default/logging.py
92 9940eacf Kostas Papadimitriou
    :lines: 4-
93 9940eacf Kostas Papadimitriou
.. literalinclude:: ../synnefo/app_settings/default/backend.py
94 9940eacf Kostas Papadimitriou
    :lines: 4-
95 9940eacf Kostas Papadimitriou
.. literalinclude:: ../synnefo/app_settings/default/plankton.py
96 9940eacf Kostas Papadimitriou
    :lines: 4-
97 9940eacf Kostas Papadimitriou
.. literalinclude:: ../synnefo/app_settings/default/queues.py
98 9940eacf Kostas Papadimitriou
    :lines: 4-
99 9940eacf Kostas Papadimitriou
.. literalinclude:: ../synnefo/app_settings/default/ui.py
100 9940eacf Kostas Papadimitriou
    :lines: 4-
101 9940eacf Kostas Papadimitriou
.. literalinclude:: ../synnefo/app_settings/default/userdata.py
102 9940eacf Kostas Papadimitriou
    :lines: 4-
103 9940eacf Kostas Papadimitriou
104 9940eacf Kostas Papadimitriou
.. todo:: make sure the file headers are included properly in documentation.
105 9940eacf Kostas Papadimitriou
          If not change the :lines setting accordingly.