root / docs / scale / i-cms.rst @ 0be81d73
History | View | Annotate | Download (3.4 kB)
1 |
.. _i-cms: |
---|---|
2 |
|
3 |
Synnefo |
4 |
------- |
5 |
|
6 |
:ref:`synnefo <i-synnefo>` || |
7 |
:ref:`ns <i-ns>` || |
8 |
:ref:`apt <i-apt>` || |
9 |
:ref:`mq <i-mq>` || |
10 |
:ref:`db <i-db>` || |
11 |
:ref:`gunicorn <i-gunicorn>` || |
12 |
:ref:`apache <i-apache>` || |
13 |
:ref:`webproject <i-webproject>` || |
14 |
:ref:`astakos <i-astakos>` || |
15 |
:ref:`qh <i-qh>` || |
16 |
cms || |
17 |
:ref:`pithos <i-pithos>` || |
18 |
:ref:`cyclades <i-cyclades>` || |
19 |
:ref:`kamaki <i-kamaki>` || |
20 |
:ref:`backends <i-backends>` |
21 |
|
22 |
CMS Setup |
23 |
+++++++++ |
24 |
|
25 |
The following apply to ``cms`` node. In the following sections |
26 |
we will refer to its IP as ``cms.example.com`` . Before install make sure |
27 |
you have db, apache and gunicorn setup already. |
28 |
|
29 |
IMPORTANT: Currently cms cannot coexist with astakos, synnefo and pithos roles |
30 |
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
31 |
|
32 |
First install the corresponding package: |
33 |
|
34 |
.. code-block:: console |
35 |
|
36 |
# apt-get install snf-cloudcms |
37 |
|
38 |
|
39 |
In `/etc/synnefo/cloudcms.conf` add: |
40 |
|
41 |
.. code-block:: console |
42 |
|
43 |
CLOUDBAR_ACTIVE = True |
44 |
CLOUDBAR_LOCATION = 'https://accounts.example.com/static/im/cloudbar/' |
45 |
CLOUDBAR_SERVICES_URL = 'https://accounts.example.com/astakos/api/get_services' |
46 |
CLOUDBAR_MENU_URL = 'https://accounts.example.com/im/get_menu' |
47 |
|
48 |
WEBPROJECT_SERVE_STATIC = True |
49 |
|
50 |
Then restart the services and initialize database: |
51 |
|
52 |
.. code-block:: console |
53 |
|
54 |
# /etc/init.d/gunicorn restart |
55 |
# /etc/init.d/apache2 restart |
56 |
# snf-manage syncdb |
57 |
# snf-manage migrate |
58 |
|
59 |
Here we can load some initial data. Add in `/tmp/sites.json` : |
60 |
|
61 |
.. code-block:: console |
62 |
|
63 |
[ |
64 |
{ |
65 |
"pk": 1, |
66 |
"model": "sites.site", |
67 |
"fields": { |
68 |
"domain": "okeanos.grnet.gr", |
69 |
"name": "okeanos.grnet.gr" |
70 |
} |
71 |
} |
72 |
] |
73 |
|
74 |
|
75 |
and in `/tmp/pages.json`: |
76 |
|
77 |
.. code-block:: console |
78 |
|
79 |
[ |
80 |
{ |
81 |
"fields": { |
82 |
"_cached_url": "/", |
83 |
"_content_title": "", |
84 |
"_page_title": "", |
85 |
"active": true, |
86 |
"creation_date": "2012-11-16 14:52:19", |
87 |
"in_navigation": false, |
88 |
"language": "en", |
89 |
"level": 0, |
90 |
"lft": 1, |
91 |
"meta_description": "", |
92 |
"meta_keywords": "", |
93 |
"modification_date": "2012-11-16 14:52:19", |
94 |
"navigation_extension": null, |
95 |
"override_url": "/", |
96 |
"parent": null, |
97 |
"publication_date": "2012-11-16 14:50:00", |
98 |
"publication_end_date": null, |
99 |
"redirect_to": "", |
100 |
"rght": 2, |
101 |
"site": 1, |
102 |
"slug": "okeanos", |
103 |
"symlinked_page": null, |
104 |
"template_key": "twocolwide", |
105 |
"title": "Okeanos", |
106 |
"translation_of": null, |
107 |
"tree_id": 1 |
108 |
}, |
109 |
"model": "page.page", |
110 |
"pk": 1 |
111 |
}, |
112 |
{ |
113 |
"fields": { |
114 |
"ordering": 0, |
115 |
"parent": 1, |
116 |
"region": "main", |
117 |
"text": "Welcome to Okeanos!!\r\n\r\n" |
118 |
}, |
119 |
"model": "page.rawcontent", |
120 |
"pk": 1 |
121 |
} |
122 |
] |
123 |
|
124 |
|
125 |
|
126 |
and finally run: |
127 |
|
128 |
.. code-block:: console |
129 |
|
130 |
# snf-manage loaddata /tmp/sites.json |
131 |
# snf-manage loaddata /tmp/page.json |
132 |
# snf-manage createsuperuser --username=admin --email=admin@example --noinput |
133 |
|
134 |
|
135 |
Test your Setup: |
136 |
++++++++++++++++ |
137 |
|
138 |
Visit https://cms.example.com/ |