Revision ceded986
b/conf/sample_settings.conf | ||
---|---|---|
1 |
# database configuration |
|
2 |
DATABASES = { |
|
3 |
'default': { |
|
4 |
'ENGINE': 'django.db.backends.', # Add 'postgresql_psycopg2', 'mysql', 'sqlite3' or 'oracle'. |
|
5 |
'NAME': '', # Or path to database file if using sqlite3. |
|
6 |
'USER': '', # Not used with sqlite3. |
|
7 |
'PASSWORD': '', # Not used with sqlite3. |
|
8 |
'HOST': '', # Set to empty string for localhost. Not used with sqlite3. |
|
9 |
'PORT': '', # Set to empty string for default. Not used with sqlite3. |
|
10 |
} |
|
11 |
} |
|
12 |
|
|
13 |
# where synnefo static files exist |
|
14 |
MEDIA_ROOT = '/var/lib/synnefo/static/' |
|
15 |
|
|
16 |
# rabitmq configuration |
|
17 |
RABBIT_HOST = "" |
|
18 |
RABBIT_USERNAME = "" |
|
19 |
RABBIT_PASSWORD = "" |
|
20 |
RABBIT_VHOST = "/" |
|
21 |
|
|
22 |
GANETI_MASTER_IP = "" |
|
23 |
GANETI_CLUSTER_INFO = (GANETI_MASTER_IP, 5080, "<username>", "<password>") |
|
24 |
|
|
25 |
# This prefix gets used when determining the instance names |
|
26 |
# of Synnefo VMs at the Ganeti backend. |
|
27 |
# The dash must always appear in the name! |
|
28 |
BACKEND_PREFIX_ID = "<prefix>-" |
b/docs/_static/sample_settings.conf | ||
---|---|---|
1 |
# database configuration |
|
2 |
DATABASES = { |
|
3 |
'default': { |
|
4 |
'ENGINE': 'django.db.backends.', # Add 'postgresql_psycopg2', 'mysql', 'sqlite3' or 'oracle'. |
|
5 |
'NAME': '', # Or path to database file if using sqlite3. |
|
6 |
'USER': '', # Not used with sqlite3. |
|
7 |
'PASSWORD': '', # Not used with sqlite3. |
|
8 |
'HOST': '', # Set to empty string for localhost. Not used with sqlite3. |
|
9 |
'PORT': '', # Set to empty string for default. Not used with sqlite3. |
|
10 |
} |
|
11 |
} |
|
12 |
|
|
13 |
# where synnefo static files exist |
|
14 |
MEDIA_ROOT = '/var/lib/synnefo/static/' |
|
15 |
|
|
16 |
# rabitmq configuration |
|
17 |
RABBIT_HOST = "" |
|
18 |
RABBIT_USERNAME = "" |
|
19 |
RABBIT_PASSWORD = "" |
|
20 |
RABBIT_VHOST = "/" |
|
21 |
|
|
22 |
GANETI_MASTER_IP = "" |
|
23 |
GANETI_CLUSTER_INFO = (GANETI_MASTER_IP, 5080, "<username>", "<password>") |
|
24 |
|
|
25 |
# This prefix gets used when determining the instance names |
|
26 |
# of Synnefo VMs at the Ganeti backend. |
|
27 |
# The dash must always appear in the name! |
|
28 |
BACKEND_PREFIX_ID = "<prefix>-" |
b/docs/_static/users.json | ||
---|---|---|
1 |
[ |
|
2 |
{ |
|
3 |
"model": "db.SynnefoUser", |
|
4 |
"pk": 1, |
|
5 |
"fields": { |
|
6 |
"name": "testdbuser", |
|
7 |
"realname" :"test db user", |
|
8 |
"uniq" :"test@synnefo.gr", |
|
9 |
"credit": 10, |
|
10 |
"auth_token": "46e427d657b20defe352804f0eb6f8a2", |
|
11 |
"auth_token_created": "2011-05-10", |
|
12 |
"auth_token_expires": "2015-05-10", |
|
13 |
"type": "ADMIN", |
|
14 |
"created": "2011-05-10", |
|
15 |
"max_invitations" : 1000 |
|
16 |
} |
|
17 |
}, |
|
18 |
{ |
|
19 |
"model": "db.SynnefoUser", |
|
20 |
"pk": 2, |
|
21 |
"fields": { |
|
22 |
"name": "helpdesk", |
|
23 |
"realname" :"HelpDesk user", |
|
24 |
"uniq" :"helpdesk@synnefo.grnet.gr", |
|
25 |
"credit": 10, |
|
26 |
"auth_token": "839636858b1feafd37010f05dc4582e2", |
|
27 |
"auth_token_created": "2011-05-10", |
|
28 |
"auth_token_expires": "2015-05-10", |
|
29 |
"type": "HELPDESK", |
|
30 |
"created": "2011-05-10", |
|
31 |
"max_invitations" : 10 |
|
32 |
} |
|
33 |
}, |
|
34 |
{ |
|
35 |
"model" : "db.Invitations", |
|
36 |
"pk" : 1, |
|
37 |
"fields": { |
|
38 |
"source": 1, |
|
39 |
"target": 1, |
|
40 |
"accepted": "True", |
|
41 |
"level" : -1, |
|
42 |
"created": "2011-06-01", |
|
43 |
"updated": "2011-06-01" |
|
44 |
} |
|
45 |
} |
|
46 |
] |
b/docs/src/configuration.rst | ||
---|---|---|
74 | 74 |
|
75 | 75 |
$ synnefo-manage sql db |
76 | 76 |
|
77 |
|
|
78 |
.. _database-initialization: |
|
79 |
|
|
80 |
Database initialization |
|
81 |
----------------------- |
|
77 | 82 |
You need to initialize the Synnefo DB:: |
78 | 83 |
|
79 | 84 |
$ synnefo-manage syncdb |
... | ... | |
95 | 100 |
|
96 | 101 |
sample users.json file: |
97 | 102 |
|
98 |
.. code-block::
|
|
99 |
.. include:: ../../synnefo/db/fixtures/users.json
|
|
103 |
.. literalinclude:: ../../synnefo/db/fixtures/users.json
|
|
104 |
:language: json
|
|
100 | 105 |
|
106 |
`download <../_static/users.json>`_ |
|
101 | 107 |
|
102 | 108 |
.. _additional-configuration: |
103 | 109 |
|
b/docs/src/deployment.rst | ||
---|---|---|
1 |
.. _deployment: |
|
2 |
|
|
1 | 3 |
Deployment |
2 | 4 |
========== |
3 | 5 |
|
... | ... | |
72 | 74 |
|
73 | 75 |
WEBAPP |
74 | 76 |
****** |
75 |
. |
|
77 |
Synnefo WEBAPP node is the server that runs the web application contained within |
|
78 |
the synnefo package. At the current state Synnefo provides two web frontends. |
|
76 | 79 |
|
80 |
.. webapp-deploy: |
|
77 | 81 |
|
78 | 82 |
Web application deployment |
79 | 83 |
-------------------------- |
b/docs/src/install.rst | ||
---|---|---|
15 | 15 |
Prerequisites |
16 | 16 |
------------- |
17 | 17 |
|
18 |
|
|
19 |
.. _ganeti-setup: |
|
20 |
|
|
18 | 21 |
Ganeti installation |
19 | 22 |
******************* |
20 | 23 |
Synnefo requires a working Ganeti installation at the backend. Installation |
... | ... | |
128 | 131 |
provided under ``/contrib/ganeti-hooks``. Set ``NFDHCPD_STATE_DIR`` to point |
129 | 132 |
to NFDHCPD's state directory, usually ``/var/lib/nfdhcpd``. |
130 | 133 |
|
134 |
|
|
135 |
.. _rabbitmq-setup: |
|
136 |
|
|
131 | 137 |
RabbitMQ installation |
132 | 138 |
********************* |
133 | 139 |
RabbitMQ is used as a generic message broker for the system. It should be |
... | ... | |
162 | 168 |
Images should be stored under extdump format in a directory |
163 | 169 |
of your choice, configurable as ``IMAGE_DIR`` in ``/etc/default/snf-image``. |
164 | 170 |
|
171 |
|
|
172 |
.. _database-setup: |
|
173 |
|
|
165 | 174 |
Database installation |
166 | 175 |
********************* |
167 | 176 |
|
... | ... | |
273 | 282 |
Required packages |
274 | 283 |
````````````````` |
275 | 284 |
|
285 |
.. todo:: |
|
286 |
Confirm debian package names |
|
287 |
|
|
276 | 288 |
======================= =================== ========== |
277 | 289 |
PyPi package name Debian package name version |
278 | 290 |
======================= =================== ========== |
... | ... | |
363 | 375 |
Notice that Synnefo installation does not handle the creation of |
364 | 376 |
``/etc/synnefo/`` directory which is the place where custom configuration |
365 | 377 |
files are loaded from. You are encouraged to create this directory and place a |
366 |
file named ``settings.conf`` containing the following: |
|
367 |
|
|
368 |
.. code-block:: python |
|
369 |
|
|
370 |
# database configuration |
|
371 |
DATABASES = { |
|
372 |
'default': { |
|
373 |
'ENGINE': 'django.db.backends.', # Add 'postgresql_psycopg2', 'mysql', 'sqlite3' or 'oracle'. |
|
374 |
'NAME': '', # Or path to database file if using sqlite3. |
|
375 |
'USER': '', # Not used with sqlite3. |
|
376 |
'PASSWORD': '', # Not used with sqlite3. |
|
377 |
'HOST': '', # Set to empty string for localhost. Not used with sqlite3. |
|
378 |
'PORT': '', # Set to empty string for default. Not used with sqlite3. |
|
379 |
} |
|
380 |
} |
|
381 |
|
|
382 |
# where synnefo static files exist |
|
383 |
MEDIA_ROOT = '/var/lib/synnefo/static/' |
|
384 |
|
|
385 |
# rabitmq configuration |
|
386 |
RABBIT_HOST = "" |
|
387 |
RABBIT_USERNAME = "" |
|
388 |
RABBIT_PASSWORD = "" |
|
389 |
RABBIT_VHOST = "/" |
|
378 |
file named ``settings.conf`` with the following contents: |
|
390 | 379 |
|
391 |
GANETI_MASTER_IP = "" |
|
392 |
GANETI_CLUSTER_INFO = (GANETI_MASTER_IP, 5080, "<username>", "<password>") |
|
380 |
.. _sample-settings: |
|
381 |
.. literalinclude:: ../_static/sample_settings.conf |
|
382 |
:language: python |
|
393 | 383 |
|
394 |
# This prefix gets used when determining the instance names |
|
395 |
# of Synnefo VMs at the Ganeti backend. |
|
396 |
# The dash must always appear in the name! |
|
397 |
BACKEND_PREFIX_ID = "<prefix>-" |
|
384 |
`download <../_static/sample_settings.conf>`_ |
|
398 | 385 |
|
399 | 386 |
this is just to get you started on how to configure your Synnefo installation. |
400 | 387 |
From this point you can continue your read to the `Initial configuration`_ section |
... | ... | |
402 | 389 |
configuration required for Synnefo to get up and running. |
403 | 390 |
|
404 | 391 |
For additional instructions about Synnefo settings files and what the available |
405 |
options are, you can refer to the :ref:`configuration` guide. |
|
392 |
settings are, you can refer to the :ref:`configuration <configuration>` guide. |
|
393 |
|
|
406 | 394 |
|
407 | 395 |
Initial configuration |
408 | 396 |
--------------------- |
... | ... | |
411 | 399 |
would cover many of the most common installation scenarios. However some basic |
412 | 400 |
settings must be set be set before running Synnefo for the first time. |
413 | 401 |
|
402 |
:ref:`sample settings file <sample-settings>` |
|
403 |
|
|
404 |
|
|
414 | 405 |
Database |
415 | 406 |
******** |
416 | 407 |
|
417 |
See :ref:`database-configuration` |
|
408 |
Changes ``DATABASES`` setting based on your :ref:`database setup <database-setup>` |
|
409 |
and :ref:`initialize/update your database structure <database-initialization>` |
|
410 |
|
|
411 |
.. seealso:: |
|
412 |
:ref:`database-configuration` / |
|
413 |
:ref:`database-initialization` |
|
414 |
|
|
415 |
|
|
416 |
Queue |
|
417 |
***** |
|
418 |
|
|
419 |
Change ``RABBIT_*`` settings to match your :ref:`RabbitMQ setup <rabbitmq-setup>`. |
|
420 |
|
|
418 | 421 |
|
419 | 422 |
Backend |
420 | 423 |
******* |
421 | 424 |
|
422 |
.. todo:: write some documentation here |
|
423 |
|
|
424 |
UI |
|
425 |
** |
|
425 |
Set ``GANETI_NODES``, ``GANETI_MASTER_IP``, ``GANETI_CLUSTER_INFO`` based on your :ref:`Ganeti |
|
426 |
installation <ganeti-setup>` and change BACKEND_PREFIX_ID using an custom `prefix |
|
427 |
id`. |
|
426 | 428 |
|
427 |
.. todo:: write some documentation here |
|
428 | 429 |
|
429 |
Additional configuration
|
|
430 |
************************
|
|
430 |
Web application
|
|
431 |
*************** |
|
431 | 432 |
|
432 |
.. todo:: write some documentation here |
|
433 |
See the extended :ref:`deployment guide <webapp-deploy>` for instructions on how to |
|
434 |
setup the Synnefo web application. |
Also available in: Unified diff