root / docs / admin-guide.rst @ 6d86f5b3
History | View | Annotate | Download (66.5 kB)
1 | bc055d09 | Constantinos Venetsanopoulos | .. _admin-guide: |
---|---|---|---|
2 | bc055d09 | Constantinos Venetsanopoulos | |
3 | bc055d09 | Constantinos Venetsanopoulos | Synnefo Administrator's Guide |
4 | bc055d09 | Constantinos Venetsanopoulos | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ |
5 | bc055d09 | Constantinos Venetsanopoulos | |
6 | bc055d09 | Constantinos Venetsanopoulos | This is the complete Synnefo Administrator's Guide. |
7 | bc055d09 | Constantinos Venetsanopoulos | |
8 | bc055d09 | Constantinos Venetsanopoulos | |
9 | 14267d89 | Constantinos Venetsanopoulos | .. _syn+archip: |
10 | bc055d09 | Constantinos Venetsanopoulos | |
11 | eab73849 | Constantinos Venetsanopoulos | General Synnefo Architecture |
12 | eab73849 | Constantinos Venetsanopoulos | ============================ |
13 | eab73849 | Constantinos Venetsanopoulos | |
14 | 14267d89 | Constantinos Venetsanopoulos | The following figure shows a detailed view of the whole Synnefo architecture |
15 | 14267d89 | Constantinos Venetsanopoulos | and how it interacts with multiple Ganeti clusters. We hope that after reading |
16 | 14267d89 | Constantinos Venetsanopoulos | the Administrator's Guide you will be able to understand every component and |
17 | 14267d89 | Constantinos Venetsanopoulos | all the interactions between them. |
18 | eab73849 | Constantinos Venetsanopoulos | |
19 | 301294a9 | Constantinos Venetsanopoulos | .. image:: images/synnefo-arch2.png |
20 | 16539dad | Kostas Papadimitriou | :width: 100% |
21 | 301294a9 | Constantinos Venetsanopoulos | :target: _images/synnefo-arch2.png |
22 | eab73849 | Constantinos Venetsanopoulos | |
23 | 14267d89 | Constantinos Venetsanopoulos | Synnefo also supports RADOS as an alternative storage backend for |
24 | 14267d89 | Constantinos Venetsanopoulos | Files/Images/VM disks. You will find the :ref:`corresponding figure |
25 | 14267d89 | Constantinos Venetsanopoulos | <syn+archip+rados>` later in this guide. |
26 | eab73849 | Constantinos Venetsanopoulos | |
27 | a1c707c9 | Constantinos Venetsanopoulos | |
28 | eab73849 | Constantinos Venetsanopoulos | Identity Service (Astakos) |
29 | eab73849 | Constantinos Venetsanopoulos | ========================== |
30 | f846d8df | Constantinos Venetsanopoulos | |
31 | f846d8df | Constantinos Venetsanopoulos | |
32 | eab73849 | Constantinos Venetsanopoulos | Authentication methods |
33 | 3a0ce98e | Constantinos Venetsanopoulos | ---------------------- |
34 | eab73849 | Constantinos Venetsanopoulos | |
35 | 3a0ce98e | Constantinos Venetsanopoulos | Astakos supports multiple authentication methods: |
36 | eab73849 | Constantinos Venetsanopoulos | |
37 | 3a0ce98e | Constantinos Venetsanopoulos | * local username/password |
38 | 3a0ce98e | Constantinos Venetsanopoulos | * LDAP / Active Directory |
39 | 3a0ce98e | Constantinos Venetsanopoulos | * SAML 2.0 (Shibboleth) federated logins |
40 | 3a0ce98e | Constantinos Venetsanopoulos | |
41 | 3a0ce98e | Constantinos Venetsanopoulos | |
42 | 3a0ce98e | Constantinos Venetsanopoulos | |
43 | eab73849 | Constantinos Venetsanopoulos | |
44 | eab73849 | Constantinos Venetsanopoulos | .. _shibboleth-auth: |
45 | eab73849 | Constantinos Venetsanopoulos | |
46 | eab73849 | Constantinos Venetsanopoulos | Shibboleth Authentication |
47 | 3a0ce98e | Constantinos Venetsanopoulos | ~~~~~~~~~~~~~~~~~~~~~~~~~ |
48 | eab73849 | Constantinos Venetsanopoulos | |
49 | eab73849 | Constantinos Venetsanopoulos | Astakos can delegate user authentication to a Shibboleth federation. |
50 | eab73849 | Constantinos Venetsanopoulos | |
51 | eab73849 | Constantinos Venetsanopoulos | To setup shibboleth, install package:: |
52 | eab73849 | Constantinos Venetsanopoulos | |
53 | eab73849 | Constantinos Venetsanopoulos | apt-get install libapache2-mod-shib2 |
54 | eab73849 | Constantinos Venetsanopoulos | |
55 | eab73849 | Constantinos Venetsanopoulos | Change appropriately the configuration files in ``/etc/shibboleth``. |
56 | eab73849 | Constantinos Venetsanopoulos | |
57 | eab73849 | Constantinos Venetsanopoulos | Add in ``/etc/apache2/sites-available/synnefo-ssl``:: |
58 | eab73849 | Constantinos Venetsanopoulos | |
59 | eab73849 | Constantinos Venetsanopoulos | ShibConfig /etc/shibboleth/shibboleth2.xml |
60 | eab73849 | Constantinos Venetsanopoulos | Alias /shibboleth-sp /usr/share/shibboleth |
61 | eab73849 | Constantinos Venetsanopoulos | |
62 | fb814235 | Kostas Papadimitriou | <Location /ui/login/shibboleth> |
63 | eab73849 | Constantinos Venetsanopoulos | AuthType shibboleth |
64 | eab73849 | Constantinos Venetsanopoulos | ShibRequireSession On |
65 | eab73849 | Constantinos Venetsanopoulos | ShibUseHeaders On |
66 | eab73849 | Constantinos Venetsanopoulos | require valid-user |
67 | eab73849 | Constantinos Venetsanopoulos | </Location> |
68 | eab73849 | Constantinos Venetsanopoulos | |
69 | eab73849 | Constantinos Venetsanopoulos | and before the line containing:: |
70 | eab73849 | Constantinos Venetsanopoulos | |
71 | eab73849 | Constantinos Venetsanopoulos | ProxyPass / http://localhost:8080/ retry=0 |
72 | eab73849 | Constantinos Venetsanopoulos | |
73 | eab73849 | Constantinos Venetsanopoulos | add:: |
74 | eab73849 | Constantinos Venetsanopoulos | |
75 | eab73849 | Constantinos Venetsanopoulos | ProxyPass /Shibboleth.sso ! |
76 | f846d8df | Constantinos Venetsanopoulos | |
77 | eab73849 | Constantinos Venetsanopoulos | Then, enable the shibboleth module:: |
78 | eab73849 | Constantinos Venetsanopoulos | |
79 | eab73849 | Constantinos Venetsanopoulos | a2enmod shib2 |
80 | f846d8df | Constantinos Venetsanopoulos | |
81 | eab73849 | Constantinos Venetsanopoulos | After passing through the apache module, the following tokens should be |
82 | eab73849 | Constantinos Venetsanopoulos | available at the destination:: |
83 | eab73849 | Constantinos Venetsanopoulos | |
84 | eab73849 | Constantinos Venetsanopoulos | eppn # eduPersonPrincipalName |
85 | eab73849 | Constantinos Venetsanopoulos | Shib-InetOrgPerson-givenName |
86 | eab73849 | Constantinos Venetsanopoulos | Shib-Person-surname |
87 | eab73849 | Constantinos Venetsanopoulos | Shib-Person-commonName |
88 | eab73849 | Constantinos Venetsanopoulos | Shib-InetOrgPerson-displayName |
89 | eab73849 | Constantinos Venetsanopoulos | Shib-EP-Affiliation |
90 | eab73849 | Constantinos Venetsanopoulos | Shib-Session-ID |
91 | eab73849 | Constantinos Venetsanopoulos | |
92 | eab73849 | Constantinos Venetsanopoulos | Finally, add 'shibboleth' in ``ASTAKOS_IM_MODULES`` list. The variable resides |
93 | eab73849 | Constantinos Venetsanopoulos | inside the file ``/etc/synnefo/20-snf-astakos-app-settings.conf`` |
94 | eab73849 | Constantinos Venetsanopoulos | |
95 | e0975bbf | Sofia Papagiannaki | Twitter Authentication |
96 | 3a0ce98e | Constantinos Venetsanopoulos | ~~~~~~~~~~~~~~~~~~~~~~ |
97 | e0975bbf | Sofia Papagiannaki | |
98 | e0975bbf | Sofia Papagiannaki | To enable twitter authentication while signed in under a Twitter account, |
99 | e0975bbf | Sofia Papagiannaki | visit dev.twitter.com/apps. |
100 | e0975bbf | Sofia Papagiannaki | |
101 | e0975bbf | Sofia Papagiannaki | Click Create an application. |
102 | e0975bbf | Sofia Papagiannaki | |
103 | e0975bbf | Sofia Papagiannaki | Fill the necessary information and for callback URL give:: |
104 | e0975bbf | Sofia Papagiannaki | |
105 | e0975bbf | Sofia Papagiannaki | https://node1.example.com/ui/login/twitter/authenticated |
106 | e0975bbf | Sofia Papagiannaki | |
107 | e0975bbf | Sofia Papagiannaki | Finally, add 'twitter' in ``ASTAKOS_IM_MODULES`` list. The variable resides |
108 | e0975bbf | Sofia Papagiannaki | inside the file ``/etc/synnefo/20-snf-astakos-app-settings.conf`` |
109 | e0975bbf | Sofia Papagiannaki | |
110 | e0975bbf | Sofia Papagiannaki | Google Authentication |
111 | 3a0ce98e | Constantinos Venetsanopoulos | ~~~~~~~~~~~~~~~~~~~~~ |
112 | e0975bbf | Sofia Papagiannaki | |
113 | e0975bbf | Sofia Papagiannaki | To enable google authentication while signed in under a Google account, |
114 | e0975bbf | Sofia Papagiannaki | visit https://code.google.com/apis/console/. |
115 | e0975bbf | Sofia Papagiannaki | |
116 | e0975bbf | Sofia Papagiannaki | Under API Access select Create another client ID, select Web application, |
117 | e0975bbf | Sofia Papagiannaki | expand more options in Your site or hostname section and in Authorized |
118 | e0975bbf | Sofia Papagiannaki | Redirect URIs add: |
119 | e0975bbf | Sofia Papagiannaki | |
120 | e0975bbf | Sofia Papagiannaki | |
121 | e0975bbf | Sofia Papagiannaki | Fill the necessary information and for callback URL give:: |
122 | e0975bbf | Sofia Papagiannaki | |
123 | e0975bbf | Sofia Papagiannaki | https://node1.example.com/ui/login/google/authenticated |
124 | e0975bbf | Sofia Papagiannaki | |
125 | e0975bbf | Sofia Papagiannaki | Finally, add 'google' in ``ASTAKOS_IM_MODULES`` list. The variable resides |
126 | e0975bbf | Sofia Papagiannaki | inside the file ``/etc/synnefo/20-snf-astakos-app-settings.conf`` |
127 | e0975bbf | Sofia Papagiannaki | |
128 | eab73849 | Constantinos Venetsanopoulos | |
129 | eab73849 | Constantinos Venetsanopoulos | Working with Astakos |
130 | eab73849 | Constantinos Venetsanopoulos | -------------------- |
131 | eab73849 | Constantinos Venetsanopoulos | |
132 | 77186edf | Kostas Papadimitriou | User registration |
133 | 77186edf | Kostas Papadimitriou | ~~~~~~~~~~~~~~~~~ |
134 | f846d8df | Constantinos Venetsanopoulos | |
135 | 77186edf | Kostas Papadimitriou | When a new user signs up, he/she is not directly marked as active. You can see |
136 | 77186edf | Kostas Papadimitriou | his/her state by running (on the machine that runs the Astakos app): |
137 | f846d8df | Constantinos Venetsanopoulos | |
138 | f846d8df | Constantinos Venetsanopoulos | .. code-block:: console |
139 | f846d8df | Constantinos Venetsanopoulos | |
140 | 4404e02e | Ilias Tsitsimpis | $ snf-manage user-list |
141 | f846d8df | Constantinos Venetsanopoulos | |
142 | 77186edf | Kostas Papadimitriou | More detailed user status is provided in the `status` field of the `user-show` |
143 | 77186edf | Kostas Papadimitriou | command: |
144 | f846d8df | Constantinos Venetsanopoulos | |
145 | 77186edf | Kostas Papadimitriou | .. code-block:: console |
146 | f846d8df | Constantinos Venetsanopoulos | |
147 | 77186edf | Kostas Papadimitriou | $ snf-manage user-show <user-id> |
148 | f846d8df | Constantinos Venetsanopoulos | |
149 | 77186edf | Kostas Papadimitriou | id : 6 |
150 | 77186edf | Kostas Papadimitriou | uuid : 78661411-5eed-412f-a9ea-2de24f542c2e |
151 | 77186edf | Kostas Papadimitriou | status : Accepted/Active (accepted policy: manual) |
152 | 77186edf | Kostas Papadimitriou | email : user@synnefo.org |
153 | 77186edf | Kostas Papadimitriou | .... |
154 | f846d8df | Constantinos Venetsanopoulos | |
155 | 3a0ce98e | Constantinos Venetsanopoulos | Based on the `astakos-app` configuration, there are several ways for a user to |
156 | 3a0ce98e | Constantinos Venetsanopoulos | get verified and activated in order to be able to login. We discuss the user |
157 | 3a0ce98e | Constantinos Venetsanopoulos | verification and activation flow in the following section. |
158 | 77186edf | Kostas Papadimitriou | |
159 | 77186edf | Kostas Papadimitriou | User activation flow |
160 | eab73849 | Constantinos Venetsanopoulos | ```````````````````` |
161 | eab73849 | Constantinos Venetsanopoulos | |
162 | 77186edf | Kostas Papadimitriou | A user can register for an account using the astakos signup form. Once the form |
163 | 77186edf | Kostas Papadimitriou | is submited successfully a user entry is created in astakos database. That entry |
164 | 77186edf | Kostas Papadimitriou | is passed through the astakos activation backend which handles whether the user |
165 | 77186edf | Kostas Papadimitriou | should be automatically verified and activated. |
166 | 77186edf | Kostas Papadimitriou | |
167 | 77186edf | Kostas Papadimitriou | Email verification |
168 | 77186edf | Kostas Papadimitriou | `````````````````` |
169 | 77186edf | Kostas Papadimitriou | |
170 | 77186edf | Kostas Papadimitriou | The verification process takes place in order to ensure that the user owns the |
171 | 77186edf | Kostas Papadimitriou | email provided during the signup process. By default, after each successful |
172 | 77186edf | Kostas Papadimitriou | signup astakos notifies user with an verification url via email. |
173 | 77186edf | Kostas Papadimitriou | |
174 | 77186edf | Kostas Papadimitriou | At this stage: |
175 | 77186edf | Kostas Papadimitriou | |
176 | 77186edf | Kostas Papadimitriou | * subsequent registrations invalidate and delete the previous registrations |
177 | 77186edf | Kostas Papadimitriou | of the same email address. |
178 | 77186edf | Kostas Papadimitriou | |
179 | 77186edf | Kostas Papadimitriou | * in case user misses the initial notification, additional emails can be |
180 | 77186edf | Kostas Papadimitriou | send either via the url which is prompted to the user if he tries to |
181 | 77186edf | Kostas Papadimitriou | login, or by the administrator using the ``snf-manage user-activation-send |
182 | 77186edf | Kostas Papadimitriou | <userid>`` command. |
183 | 77186edf | Kostas Papadimitriou | |
184 | 77186edf | Kostas Papadimitriou | * administrator may also enforce a user to get verified using the |
185 | 77186edf | Kostas Papadimitriou | ``snf-manage user-modify --verify <userid>`` command. |
186 | 77186edf | Kostas Papadimitriou | |
187 | 77186edf | Kostas Papadimitriou | Account activation |
188 | 77186edf | Kostas Papadimitriou | `````````````````` |
189 | 77186edf | Kostas Papadimitriou | |
190 | 3a0ce98e | Constantinos Venetsanopoulos | Once the user gets verified, it is time for Astakos to decide whether or not to |
191 | 77186edf | Kostas Papadimitriou | proceed through user activation process. If ``ASTAKOS_MODERATION_ENABLED`` |
192 | 77186edf | Kostas Papadimitriou | setting is set to ``False`` (default value) user gets activated automatically. |
193 | 77186edf | Kostas Papadimitriou | |
194 | 3a0ce98e | Constantinos Venetsanopoulos | In case the moderation is enabled Astakos may still automatically activate the |
195 | 77186edf | Kostas Papadimitriou | user in the following cases: |
196 | 77186edf | Kostas Papadimitriou | |
197 | 77186edf | Kostas Papadimitriou | * User email matches any of the regular expressions defined in |
198 | 77186edf | Kostas Papadimitriou | ``ASTAKOS_RE_USER_EMAIL_PATTERNS`` (defaults to ``[]``) |
199 | 77186edf | Kostas Papadimitriou | * User used a signup method (e.g. ``shibboleth``) for which automatic |
200 | 77186edf | Kostas Papadimitriou | activation is enabled (see |
201 | 77186edf | Kostas Papadimitriou | :ref:`authentication methods policies <auth_methods_policies>`). |
202 | 77186edf | Kostas Papadimitriou | |
203 | 3a0ce98e | Constantinos Venetsanopoulos | If all of the above fail to trigger automatic activation, an email is sent to |
204 | 3a0ce98e | Constantinos Venetsanopoulos | the persons listed in ``HELPDESK``, ``MANAGERS`` and ``ADMINS`` settings, |
205 | 3a0ce98e | Constantinos Venetsanopoulos | notifing that there is a new user pending for moderation and that it's up to |
206 | 3a0ce98e | Constantinos Venetsanopoulos | the administrator to decide if the user should be activated. The UI also shows |
207 | 3a0ce98e | Constantinos Venetsanopoulos | a corresponding 'pending moderation' message to the user. The administrator can |
208 | 3a0ce98e | Constantinos Venetsanopoulos | activate a user using the ``snf-manage user-modify`` command: |
209 | 77186edf | Kostas Papadimitriou | |
210 | 77186edf | Kostas Papadimitriou | .. code-block:: console |
211 | 77186edf | Kostas Papadimitriou | |
212 | 77186edf | Kostas Papadimitriou | # command to activate a pending user |
213 | 77186edf | Kostas Papadimitriou | $ snf-manage user-modify --accept <userid> |
214 | 77186edf | Kostas Papadimitriou | |
215 | 77186edf | Kostas Papadimitriou | # command to reject a pending user |
216 | 77186edf | Kostas Papadimitriou | $ snf-manage user-modify --reject --reject-reason="spammer" <userid> |
217 | 77186edf | Kostas Papadimitriou | |
218 | 3a0ce98e | Constantinos Venetsanopoulos | Once the activation process finishes, a greeting message is sent to the user |
219 | 3a0ce98e | Constantinos Venetsanopoulos | email address and a notification for the activation to the persons listed in |
220 | 3a0ce98e | Constantinos Venetsanopoulos | ``HELPDESK``, ``MANAGERS`` and ``ADMINS`` settings. Once activated the user is |
221 | 3a0ce98e | Constantinos Venetsanopoulos | able to login and access the Synnefo services. |
222 | 77186edf | Kostas Papadimitriou | |
223 | 77186edf | Kostas Papadimitriou | Additional authentication methods |
224 | 77186edf | Kostas Papadimitriou | ````````````````````````````````` |
225 | 77186edf | Kostas Papadimitriou | |
226 | 77186edf | Kostas Papadimitriou | Astakos supports third party logins from external identity providers. This |
227 | 77186edf | Kostas Papadimitriou | can be usefull since it allows users to use their existing credentials to |
228 | 77186edf | Kostas Papadimitriou | login to astakos service. |
229 | 77186edf | Kostas Papadimitriou | |
230 | 77186edf | Kostas Papadimitriou | Currently astakos supports the following identity providers: |
231 | 77186edf | Kostas Papadimitriou | |
232 | 77186edf | Kostas Papadimitriou | * `Shibboleth <http://www.internet2.edu/shibboleth>`_ (module name |
233 | 77186edf | Kostas Papadimitriou | ``shibboleth``) |
234 | 77186edf | Kostas Papadimitriou | * `Google <https://developers.google.com/accounts/docs/OAuth2>`_ (module |
235 | 77186edf | Kostas Papadimitriou | name ``google``) |
236 | 77186edf | Kostas Papadimitriou | * `Twitter <https://dev.twitter.com/docs/auth>`_ (module name ``twitter``) |
237 | 77186edf | Kostas Papadimitriou | * `LinkedIn <http://developer.linkedin.com/documents/authentication>`_ |
238 | 77186edf | Kostas Papadimitriou | (module name ``linkedin``) |
239 | 77186edf | Kostas Papadimitriou | |
240 | 77186edf | Kostas Papadimitriou | To enable any of the above modules (by default only ``local`` accounts are |
241 | 77186edf | Kostas Papadimitriou | allowed), retrieve and set the required provider settings and append the |
242 | 77186edf | Kostas Papadimitriou | module name in ``ASTAKOS_IM_MODULES``. |
243 | 77186edf | Kostas Papadimitriou | |
244 | 77186edf | Kostas Papadimitriou | .. code-block:: python |
245 | 77186edf | Kostas Papadimitriou | |
246 | 77186edf | Kostas Papadimitriou | # settings from https://code.google.com/apis/console/ |
247 | 77186edf | Kostas Papadimitriou | ASTAKOS_GOOGLE_CLIENT_ID = '1111111111-epi60tvimgha63qqnjo40cljkojcann3.apps.googleusercontent.com' |
248 | 77186edf | Kostas Papadimitriou | ASTAKOS_GOOGLE_SECRET = 'tNDQqTDKlTf7_LaeUcWTWwZM' |
249 | 77186edf | Kostas Papadimitriou | |
250 | 77186edf | Kostas Papadimitriou | # let users signup and login using their google account |
251 | 77186edf | Kostas Papadimitriou | ASTAKOS_IM_MODULES = ['local', 'google'] |
252 | 77186edf | Kostas Papadimitriou | |
253 | 77186edf | Kostas Papadimitriou | |
254 | 77186edf | Kostas Papadimitriou | .. _auth_methods_policies: |
255 | 77186edf | Kostas Papadimitriou | |
256 | 77186edf | Kostas Papadimitriou | Authentication method policies |
257 | 77186edf | Kostas Papadimitriou | `````````````````````````````` |
258 | 77186edf | Kostas Papadimitriou | |
259 | 77186edf | Kostas Papadimitriou | Astakos allows you to override the default policies for each enabled provider |
260 | 77186edf | Kostas Papadimitriou | separately by adding the approriate settings in your ``.conf`` files in the |
261 | 77186edf | Kostas Papadimitriou | following format: |
262 | 77186edf | Kostas Papadimitriou | |
263 | 77186edf | Kostas Papadimitriou | **ASTAKOS_AUTH_PROVIDER_<module>_<policy>_POLICY** |
264 | 77186edf | Kostas Papadimitriou | |
265 | 77186edf | Kostas Papadimitriou | Available policies are: |
266 | 77186edf | Kostas Papadimitriou | |
267 | 77186edf | Kostas Papadimitriou | * **CREATE** Users can signup using that provider (default: ``True``) |
268 | 77186edf | Kostas Papadimitriou | * **REMOVE/ADD** Users can remove/add login method from their profile |
269 | 77186edf | Kostas Papadimitriou | (default: ``True``) |
270 | 77186edf | Kostas Papadimitriou | * **AUTOMODERATE** Automatically activate users that signup using that |
271 | 77186edf | Kostas Papadimitriou | provider (default: ``False``) |
272 | 77186edf | Kostas Papadimitriou | * **LOGIN** Whether or not users can use the provider to login (default: |
273 | 77186edf | Kostas Papadimitriou | ``True``). |
274 | 77186edf | Kostas Papadimitriou | |
275 | 77186edf | Kostas Papadimitriou | e.g. to enable automatic activation for your academic users, while keeping |
276 | 77186edf | Kostas Papadimitriou | locally signed up users under moderation you can apply the following settings. |
277 | 77186edf | Kostas Papadimitriou | |
278 | 77186edf | Kostas Papadimitriou | .. code-block:: python |
279 | 77186edf | Kostas Papadimitriou | |
280 | 77186edf | Kostas Papadimitriou | ASTAKOS_AUTH_PROVIDER_SHIBBOLETH_AUTOMODERATE_POLICY = True |
281 | 77186edf | Kostas Papadimitriou | ASTAKOS_AUTH_PROVIDER_SHIBBOLETH_REMOVE_POLICY = False |
282 | 77186edf | Kostas Papadimitriou | |
283 | 3a0ce98e | Constantinos Venetsanopoulos | User login |
284 | 3a0ce98e | Constantinos Venetsanopoulos | ~~~~~~~~~~ |
285 | 3a0ce98e | Constantinos Venetsanopoulos | |
286 | 3a0ce98e | Constantinos Venetsanopoulos | During the logging procedure, the user is authenticated by the respective |
287 | 3a0ce98e | Constantinos Venetsanopoulos | identity provider. |
288 | 3a0ce98e | Constantinos Venetsanopoulos | |
289 | 3a0ce98e | Constantinos Venetsanopoulos | If ``ASTAKOS_RECAPTCHA_ENABLED`` is set and the user fails several times |
290 | 3a0ce98e | Constantinos Venetsanopoulos | (``ASTAKOS_RATELIMIT_RETRIES_ALLOWED`` setting) to provide the correct |
291 | 3a0ce98e | Constantinos Venetsanopoulos | credentials for a local account, he/she is then prompted to solve a captcha |
292 | 3a0ce98e | Constantinos Venetsanopoulos | challenge. |
293 | 3a0ce98e | Constantinos Venetsanopoulos | |
294 | 3a0ce98e | Constantinos Venetsanopoulos | Upon success, the system renews the token (if it has expired), logins the user |
295 | 3a0ce98e | Constantinos Venetsanopoulos | and sets the cookie, before redirecting the user to the ``next`` parameter |
296 | 3a0ce98e | Constantinos Venetsanopoulos | value. |
297 | eab73849 | Constantinos Venetsanopoulos | |
298 | 2988ae31 | Georgios D. Tsoukalas | Setting quota limits |
299 | 2988ae31 | Georgios D. Tsoukalas | ~~~~~~~~~~~~~~~~~~~~ |
300 | 2988ae31 | Georgios D. Tsoukalas | |
301 | 075b91de | Giorgos Korfiatis | Set default quota |
302 | 075b91de | Giorgos Korfiatis | ````````````````` |
303 | f72ba65d | Giorgos Korfiatis | To inspect current default base quota limits, run:: |
304 | 2988ae31 | Georgios D. Tsoukalas | |
305 | f72ba65d | Giorgos Korfiatis | # snf-manage resource-list |
306 | 2988ae31 | Georgios D. Tsoukalas | |
307 | d61d6007 | Giorgos Korfiatis | You can modify the default base quota limit for all future users with:: |
308 | 2988ae31 | Georgios D. Tsoukalas | |
309 | d61d6007 | Giorgos Korfiatis | # snf-manage resource-modify <resource_name> --default-quota <value> |
310 | 2988ae31 | Georgios D. Tsoukalas | |
311 | 075b91de | Giorgos Korfiatis | Set base quota for individual users |
312 | 075b91de | Giorgos Korfiatis | ``````````````````````````````````` |
313 | 2988ae31 | Georgios D. Tsoukalas | |
314 | 075b91de | Giorgos Korfiatis | For individual users that need different quota than the default |
315 | 2988ae31 | Georgios D. Tsoukalas | you can set it for each resource like this:: |
316 | 2988ae31 | Georgios D. Tsoukalas | |
317 | 075b91de | Giorgos Korfiatis | # use this to display quota / uuid |
318 | 075b91de | Giorgos Korfiatis | # snf-manage user-show 'uuid or email' --quota |
319 | 2988ae31 | Georgios D. Tsoukalas | |
320 | 45112d5a | Giorgos Korfiatis | # snf-manage user-modify <user-uuid> --base-quota 'cyclades.vm' 10 |
321 | 45112d5a | Giorgos Korfiatis | |
322 | 45112d5a | Giorgos Korfiatis | You can set base quota for all existing users, with possible exceptions, using:: |
323 | 45112d5a | Giorgos Korfiatis | |
324 | 45112d5a | Giorgos Korfiatis | # snf-manage user-modify --all --base-quota cyclades.vm 10 --exclude uuid1,uuid2 |
325 | 2988ae31 | Georgios D. Tsoukalas | |
326 | 5a0f9d6c | Giorgos Korfiatis | All quota for which values different from the default have been set, |
327 | 5a0f9d6c | Giorgos Korfiatis | can be listed with:: |
328 | 5a0f9d6c | Giorgos Korfiatis | |
329 | 5a0f9d6c | Giorgos Korfiatis | # snf-manage quota-list --with-custom=True |
330 | 5a0f9d6c | Giorgos Korfiatis | |
331 | 2988ae31 | Georgios D. Tsoukalas | |
332 | 2988ae31 | Georgios D. Tsoukalas | Enable the Projects feature |
333 | 2988ae31 | Georgios D. Tsoukalas | ~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
334 | 2988ae31 | Georgios D. Tsoukalas | |
335 | 2988ae31 | Georgios D. Tsoukalas | If you want to enable the projects feature so that users may apply |
336 | 2988ae31 | Georgios D. Tsoukalas | on their own for resources by creating and joining projects, |
337 | 2988ae31 | Georgios D. Tsoukalas | in ``20-snf-astakos-app-settings.conf`` set:: |
338 | 2988ae31 | Georgios D. Tsoukalas | |
339 | 2988ae31 | Georgios D. Tsoukalas | # this will make the 'projects' page visible in the dashboard |
340 | 2988ae31 | Georgios D. Tsoukalas | ASTAKOS_PROJECTS_VISIBLE = True |
341 | 2988ae31 | Georgios D. Tsoukalas | |
342 | 9770ba6c | Giorgos Korfiatis | You can change the maximum allowed number of pending project applications |
343 | 9770ba6c | Giorgos Korfiatis | per user with:: |
344 | 827de879 | Giorgos Korfiatis | |
345 | d61d6007 | Giorgos Korfiatis | # snf-manage resource-modify astakos.pending_app --default-quota <number> |
346 | 9770ba6c | Giorgos Korfiatis | |
347 | 9770ba6c | Giorgos Korfiatis | You can also set a user-specific limit with:: |
348 | 9770ba6c | Giorgos Korfiatis | |
349 | 45112d5a | Giorgos Korfiatis | # snf-manage user-modify <user-uuid> --base-quota 'astakos.pending_app' 5 |
350 | 827de879 | Giorgos Korfiatis | |
351 | 2988ae31 | Georgios D. Tsoukalas | When users apply for projects they are not automatically granted |
352 | 2988ae31 | Georgios D. Tsoukalas | the resources. They must first be approved by the administrator. |
353 | 2988ae31 | Georgios D. Tsoukalas | |
354 | 2988ae31 | Georgios D. Tsoukalas | To list pending project applications in astakos:: |
355 | 2988ae31 | Georgios D. Tsoukalas | |
356 | 2988ae31 | Georgios D. Tsoukalas | # snf-manage project-list --pending |
357 | 2988ae31 | Georgios D. Tsoukalas | |
358 | 2988ae31 | Georgios D. Tsoukalas | Note the last column, the application id. To approve it:: |
359 | 2988ae31 | Georgios D. Tsoukalas | |
360 | 2988ae31 | Georgios D. Tsoukalas | # <app id> from the last column of project-list |
361 | 2988ae31 | Georgios D. Tsoukalas | # snf-manage project-control --approve <app id> |
362 | 2988ae31 | Georgios D. Tsoukalas | |
363 | 2988ae31 | Georgios D. Tsoukalas | To deny an application:: |
364 | 2988ae31 | Georgios D. Tsoukalas | |
365 | 2988ae31 | Georgios D. Tsoukalas | # snf-manage project-control --deny <app id> |
366 | 2988ae31 | Georgios D. Tsoukalas | |
367 | 827de879 | Giorgos Korfiatis | Users designated as *project admins* can approve, deny, or modify |
368 | 827de879 | Giorgos Korfiatis | an application through the web interface. In |
369 | 827de879 | Giorgos Korfiatis | ``20-snf-astakos-app-settings.conf`` set:: |
370 | 827de879 | Giorgos Korfiatis | |
371 | 827de879 | Giorgos Korfiatis | # UUIDs of users that can approve or deny project applications from the web. |
372 | 827de879 | Giorgos Korfiatis | ASTAKOS_PROJECT_ADMINS = [<uuid>, ...] |
373 | 2988ae31 | Georgios D. Tsoukalas | |
374 | 2988ae31 | Georgios D. Tsoukalas | |
375 | eab73849 | Constantinos Venetsanopoulos | Astakos advanced operations |
376 | eab73849 | Constantinos Venetsanopoulos | --------------------------- |
377 | eab73849 | Constantinos Venetsanopoulos | |
378 | eab73849 | Constantinos Venetsanopoulos | Adding "Terms of Use" |
379 | eab73849 | Constantinos Venetsanopoulos | ~~~~~~~~~~~~~~~~~~~~~ |
380 | eab73849 | Constantinos Venetsanopoulos | |
381 | eab73849 | Constantinos Venetsanopoulos | Astakos supports versioned terms-of-use. First of all you need to create an |
382 | eab73849 | Constantinos Venetsanopoulos | html file that will contain your terms. For example, create the file |
383 | eab73849 | Constantinos Venetsanopoulos | ``/usr/share/synnefo/sample-terms.html``, which contains the following: |
384 | eab73849 | Constantinos Venetsanopoulos | |
385 | eab73849 | Constantinos Venetsanopoulos | .. code-block:: console |
386 | eab73849 | Constantinos Venetsanopoulos | |
387 | 3a0ce98e | Constantinos Venetsanopoulos | <h1>My cloud service terms</h1> |
388 | eab73849 | Constantinos Venetsanopoulos | |
389 | 3a0ce98e | Constantinos Venetsanopoulos | These are the example terms for my cloud service |
390 | eab73849 | Constantinos Venetsanopoulos | |
391 | eab73849 | Constantinos Venetsanopoulos | Then, add those terms-of-use with the snf-manage command: |
392 | eab73849 | Constantinos Venetsanopoulos | |
393 | eab73849 | Constantinos Venetsanopoulos | .. code-block:: console |
394 | eab73849 | Constantinos Venetsanopoulos | |
395 | eab73849 | Constantinos Venetsanopoulos | $ snf-manage term-add /usr/share/synnefo/sample-terms.html |
396 | eab73849 | Constantinos Venetsanopoulos | |
397 | eab73849 | Constantinos Venetsanopoulos | Your terms have been successfully added and you will see the corresponding link |
398 | eab73849 | Constantinos Venetsanopoulos | appearing in the Astakos web pages' footer. |
399 | eab73849 | Constantinos Venetsanopoulos | |
400 | 3a0ce98e | Constantinos Venetsanopoulos | During the account registration, if there are approval terms, the user is |
401 | 3a0ce98e | Constantinos Venetsanopoulos | presented with an "I agree with the Terms" checkbox that needs to get checked |
402 | 3a0ce98e | Constantinos Venetsanopoulos | in order to proceed. |
403 | 3a0ce98e | Constantinos Venetsanopoulos | |
404 | 3a0ce98e | Constantinos Venetsanopoulos | In case there are new approval terms that the user has not signed yet, the |
405 | 3a0ce98e | Constantinos Venetsanopoulos | ``signed_terms_required`` view decorator redirects to the ``approval_terms`` |
406 | 3a0ce98e | Constantinos Venetsanopoulos | view, so the user will be presented with the new terms the next time he/she |
407 | 3a0ce98e | Constantinos Venetsanopoulos | logins. |
408 | 3a0ce98e | Constantinos Venetsanopoulos | |
409 | a23251f4 | Constantinos Venetsanopoulos | Enabling reCAPTCHA |
410 | a23251f4 | Constantinos Venetsanopoulos | ~~~~~~~~~~~~~~~~~~ |
411 | a23251f4 | Constantinos Venetsanopoulos | |
412 | a23251f4 | Constantinos Venetsanopoulos | Astakos supports the `reCAPTCHA <http://www.google.com/recaptcha>`_ feature. |
413 | a23251f4 | Constantinos Venetsanopoulos | If enabled, it protects the Astakos forms from bots. To enable the feature, go |
414 | a23251f4 | Constantinos Venetsanopoulos | to https://www.google.com/recaptcha/admin/create and create your own reCAPTCHA |
415 | a23251f4 | Constantinos Venetsanopoulos | key pair. Then edit ``/etc/synnefo/20-snf-astakos-app-settings.conf`` and set |
416 | a23251f4 | Constantinos Venetsanopoulos | the corresponding variables to reflect your newly created key pair. Finally, set |
417 | a23251f4 | Constantinos Venetsanopoulos | the ``ASTAKOS_RECAPTCHA_ENABLED`` variable to ``True``: |
418 | a23251f4 | Constantinos Venetsanopoulos | |
419 | a23251f4 | Constantinos Venetsanopoulos | .. code-block:: console |
420 | a23251f4 | Constantinos Venetsanopoulos | |
421 | a23251f4 | Constantinos Venetsanopoulos | ASTAKOS_RECAPTCHA_PUBLIC_KEY = 'example_recaptcha_public_key!@#$%^&*(' |
422 | a23251f4 | Constantinos Venetsanopoulos | ASTAKOS_RECAPTCHA_PRIVATE_KEY = 'example_recaptcha_private_key!@#$%^&*(' |
423 | a23251f4 | Constantinos Venetsanopoulos | |
424 | a23251f4 | Constantinos Venetsanopoulos | ASTAKOS_RECAPTCHA_ENABLED = True |
425 | a23251f4 | Constantinos Venetsanopoulos | |
426 | a23251f4 | Constantinos Venetsanopoulos | Restart the service on the Astakos node(s) and you are ready: |
427 | a23251f4 | Constantinos Venetsanopoulos | |
428 | a23251f4 | Constantinos Venetsanopoulos | .. code-block:: console |
429 | a23251f4 | Constantinos Venetsanopoulos | |
430 | a23251f4 | Constantinos Venetsanopoulos | # /etc/init.d/gunicorn restart |
431 | a23251f4 | Constantinos Venetsanopoulos | |
432 | a23251f4 | Constantinos Venetsanopoulos | Checkout your new Sign up page. If you see the reCAPTCHA box, you have setup |
433 | a23251f4 | Constantinos Venetsanopoulos | everything correctly. |
434 | a23251f4 | Constantinos Venetsanopoulos | |
435 | eab73849 | Constantinos Venetsanopoulos | |
436 | 3a0ce98e | Constantinos Venetsanopoulos | Astakos internals |
437 | 3a0ce98e | Constantinos Venetsanopoulos | ----------------- |
438 | 3a0ce98e | Constantinos Venetsanopoulos | |
439 | 3a0ce98e | Constantinos Venetsanopoulos | X-Auth-Token |
440 | 3a0ce98e | Constantinos Venetsanopoulos | ~~~~~~~~~~~~ |
441 | 3a0ce98e | Constantinos Venetsanopoulos | |
442 | 3a0ce98e | Constantinos Venetsanopoulos | Alice requests a specific resource from a cloud service e.g.: Pithos. In the |
443 | 3a0ce98e | Constantinos Venetsanopoulos | request she supplies the `X-Auth-Token` to identify whether she is eligible to |
444 | 3a0ce98e | Constantinos Venetsanopoulos | perform the specific task. The service contacts Astakos through its |
445 | 3a0ce98e | Constantinos Venetsanopoulos | ``/account/v1.0/authenticate`` api call (see :ref:`authenticate-api-label`) |
446 | 3a0ce98e | Constantinos Venetsanopoulos | providing the specific ``X-Auth-Token``. Astakos checkes whether the token |
447 | 3a0ce98e | Constantinos Venetsanopoulos | belongs to an active user and it has not expired and returns a dictionary |
448 | 3a0ce98e | Constantinos Venetsanopoulos | containing user related information. Finally the service uses the ``uniq`` |
449 | 3a0ce98e | Constantinos Venetsanopoulos | field included in the dictionary as the account string to identify the user |
450 | 3a0ce98e | Constantinos Venetsanopoulos | accessible resources. |
451 | 3a0ce98e | Constantinos Venetsanopoulos | |
452 | 3a0ce98e | Constantinos Venetsanopoulos | .. _authentication-label: |
453 | 3a0ce98e | Constantinos Venetsanopoulos | |
454 | 3a0ce98e | Constantinos Venetsanopoulos | Django Auth methods and Backends |
455 | 3a0ce98e | Constantinos Venetsanopoulos | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
456 | 3a0ce98e | Constantinos Venetsanopoulos | |
457 | 3a0ce98e | Constantinos Venetsanopoulos | Astakos incorporates Django user authentication system and extends its User model. |
458 | 3a0ce98e | Constantinos Venetsanopoulos | |
459 | 3a0ce98e | Constantinos Venetsanopoulos | Since username field of django User model has a limitation of 30 characters, |
460 | 3a0ce98e | Constantinos Venetsanopoulos | AstakosUser is **uniquely** identified by the ``email`` instead. Therefore, |
461 | 3a0ce98e | Constantinos Venetsanopoulos | ``astakos.im.authentication_backends.EmailBackend`` is served to authenticate a |
462 | 3a0ce98e | Constantinos Venetsanopoulos | user using email if the first argument is actually an email, otherwise tries |
463 | 3a0ce98e | Constantinos Venetsanopoulos | the username. |
464 | 3a0ce98e | Constantinos Venetsanopoulos | |
465 | 3a0ce98e | Constantinos Venetsanopoulos | A new AstakosUser instance is assigned with a uui as username and also with a |
466 | 3a0ce98e | Constantinos Venetsanopoulos | ``auth_token`` used by the cloud services to authenticate the user. |
467 | 3a0ce98e | Constantinos Venetsanopoulos | ``astakos.im.authentication_backends.TokenBackend`` is also specified in order |
468 | 3a0ce98e | Constantinos Venetsanopoulos | to authenticate the user using the email and the token fields. |
469 | 3a0ce98e | Constantinos Venetsanopoulos | |
470 | 3a0ce98e | Constantinos Venetsanopoulos | Logged on users can perform a number of actions: |
471 | 3a0ce98e | Constantinos Venetsanopoulos | |
472 | 3a0ce98e | Constantinos Venetsanopoulos | * access and edit their profile via: ``/im/profile``. |
473 | 3a0ce98e | Constantinos Venetsanopoulos | * change their password via: ``/im/password`` |
474 | 3a0ce98e | Constantinos Venetsanopoulos | * send feedback for grnet services via: ``/im/send_feedback`` |
475 | 3a0ce98e | Constantinos Venetsanopoulos | * logout (and delete cookie) via: ``/im/logout`` |
476 | 3a0ce98e | Constantinos Venetsanopoulos | |
477 | 3a0ce98e | Constantinos Venetsanopoulos | Internal Astakos requests are handled using cookie-based Django user sessions. |
478 | 3a0ce98e | Constantinos Venetsanopoulos | |
479 | 3a0ce98e | Constantinos Venetsanopoulos | External systems should forward to the ``/login`` URI. The server, |
480 | 3a0ce98e | Constantinos Venetsanopoulos | depending on its configuration will redirect to the appropriate login page. |
481 | 3a0ce98e | Constantinos Venetsanopoulos | When done with logging in, the service's login URI should redirect to the URI |
482 | 3a0ce98e | Constantinos Venetsanopoulos | provided with next, adding user and token parameters, which contain the email |
483 | 3a0ce98e | Constantinos Venetsanopoulos | and token fields respectively. |
484 | 3a0ce98e | Constantinos Venetsanopoulos | |
485 | 3a0ce98e | Constantinos Venetsanopoulos | The login URI accepts the following parameters: |
486 | 3a0ce98e | Constantinos Venetsanopoulos | |
487 | 3a0ce98e | Constantinos Venetsanopoulos | ====================== ========================= |
488 | 3a0ce98e | Constantinos Venetsanopoulos | Request Parameter Name Value |
489 | 3a0ce98e | Constantinos Venetsanopoulos | ====================== ========================= |
490 | 3a0ce98e | Constantinos Venetsanopoulos | next The URI to redirect to when the process is finished |
491 | 3a0ce98e | Constantinos Venetsanopoulos | renew Force token renewal (no value parameter) |
492 | 3a0ce98e | Constantinos Venetsanopoulos | force Force logout current user (no value parameter) |
493 | 3a0ce98e | Constantinos Venetsanopoulos | ====================== ========================= |
494 | 3a0ce98e | Constantinos Venetsanopoulos | |
495 | 3a0ce98e | Constantinos Venetsanopoulos | External systems inside the ``ASTAKOS_COOKIE_DOMAIN`` scope can acquire the |
496 | 3a0ce98e | Constantinos Venetsanopoulos | user information by the cookie identified by ``ASTAKOS_COOKIE_NAME`` setting |
497 | 3a0ce98e | Constantinos Venetsanopoulos | (set during the login procedure). |
498 | 3a0ce98e | Constantinos Venetsanopoulos | |
499 | 3a0ce98e | Constantinos Venetsanopoulos | Finally, backend systems having acquired a token can use the |
500 | 3a0ce98e | Constantinos Venetsanopoulos | :ref:`authenticate-api-label` API call from a private network or through HTTPS. |
501 | 3a0ce98e | Constantinos Venetsanopoulos | |
502 | 3a0ce98e | Constantinos Venetsanopoulos | |
503 | eab73849 | Constantinos Venetsanopoulos | Compute/Network/Image Service (Cyclades) |
504 | eab73849 | Constantinos Venetsanopoulos | ======================================== |
505 | eab73849 | Constantinos Venetsanopoulos | |
506 | eab73849 | Constantinos Venetsanopoulos | Working with Cyclades |
507 | eab73849 | Constantinos Venetsanopoulos | --------------------- |
508 | eab73849 | Constantinos Venetsanopoulos | |
509 | 0768a1df | Christos Stavrakakis | Managing Ganeti Backends |
510 | 90c74332 | Christos Stavrakakis | ~~~~~~~~~~~~~~~~~~~~~~~~ |
511 | 0768a1df | Christos Stavrakakis | |
512 | a1c707c9 | Constantinos Venetsanopoulos | Since v0.11, Synnefo is able to manage multiple Ganeti clusters (backends) |
513 | a1c707c9 | Constantinos Venetsanopoulos | making it capable to scale linearly to tens of thousands of VMs. Backends |
514 | a1c707c9 | Constantinos Venetsanopoulos | can be dynamically added or removed via `snf-manage` commands. |
515 | 0768a1df | Christos Stavrakakis | |
516 | a1c707c9 | Constantinos Venetsanopoulos | Each newly created VM is allocated to a Ganeti backend by the Cyclades backend |
517 | a1c707c9 | Constantinos Venetsanopoulos | allocator. The VM is "pinned" to this backend, and can not change through its |
518 | a1c707c9 | Constantinos Venetsanopoulos | lifetime. The backend allocator decides in which backend to spawn the VM based |
519 | a1c707c9 | Constantinos Venetsanopoulos | on the available resources of each backend, trying to balance the load between |
520 | a1c707c9 | Constantinos Venetsanopoulos | them. |
521 | 0768a1df | Christos Stavrakakis | |
522 | 0768a1df | Christos Stavrakakis | Handling of Networks, as far as backends are concerned, is based on whether the |
523 | a1c707c9 | Constantinos Venetsanopoulos | network is public or not. Public networks are created through the `snf-manage |
524 | a1c707c9 | Constantinos Venetsanopoulos | network-create` command, and are only created on one backend. Private networks |
525 | a1c707c9 | Constantinos Venetsanopoulos | are created on all backends, in order to ensure that VMs residing on different |
526 | a1c707c9 | Constantinos Venetsanopoulos | backends can be connected to the same private network. |
527 | 0768a1df | Christos Stavrakakis | |
528 | a1c707c9 | Constantinos Venetsanopoulos | Listing existing backends |
529 | a1c707c9 | Constantinos Venetsanopoulos | ````````````````````````` |
530 | a1c707c9 | Constantinos Venetsanopoulos | To list all the Ganeti backends known to Synnefo, we run: |
531 | 90c74332 | Christos Stavrakakis | |
532 | 0768a1df | Christos Stavrakakis | .. code-block:: console |
533 | 0768a1df | Christos Stavrakakis | |
534 | 0768a1df | Christos Stavrakakis | $ snf-manage backend-list |
535 | 0768a1df | Christos Stavrakakis | |
536 | 0768a1df | Christos Stavrakakis | Adding a new Ganeti backend |
537 | 90c74332 | Christos Stavrakakis | ``````````````````````````` |
538 | 0768a1df | Christos Stavrakakis | Backends are dynamically added under the control of Synnefo with `snf-manage |
539 | 0768a1df | Christos Stavrakakis | backend-add` command. In this section it is assumed that a Ganeti cluster, |
540 | a1c707c9 | Constantinos Venetsanopoulos | named ``cluster.example.com`` is already up and running and configured to be |
541 | a1c707c9 | Constantinos Venetsanopoulos | able to host Synnefo VMs. |
542 | 0768a1df | Christos Stavrakakis | |
543 | a1c707c9 | Constantinos Venetsanopoulos | To add this Ganeti cluster, we run: |
544 | 90c74332 | Christos Stavrakakis | |
545 | 0768a1df | Christos Stavrakakis | .. code-block:: console |
546 | 0768a1df | Christos Stavrakakis | |
547 | 0768a1df | Christos Stavrakakis | $ snf-manage backend-add --clustername=cluster.example.com --user="synnefo_user" --pass="synnefo_pass" |
548 | 0768a1df | Christos Stavrakakis | |
549 | 46ccbcb9 | Christos Stavrakakis | where ``clustername`` is the Cluster hostname of the Ganeti cluster, and |
550 | 46ccbcb9 | Christos Stavrakakis | ``user`` and ``pass`` are the credentials for the `Ganeti RAPI user |
551 | 46ccbcb9 | Christos Stavrakakis | <http://docs.ganeti.org/ganeti/2.2/html/rapi.html#users-and-passwords>`_. All |
552 | 46ccbcb9 | Christos Stavrakakis | backend attributes can be also changed dynamically using the `snf-manage |
553 | 46ccbcb9 | Christos Stavrakakis | backend-modify` command. |
554 | 0768a1df | Christos Stavrakakis | |
555 | a1c707c9 | Constantinos Venetsanopoulos | ``snf-manage backend-add`` will also create all existing private networks to |
556 | a1c707c9 | Constantinos Venetsanopoulos | the new backend. You can verify that the backend is added, by running |
557 | a1c707c9 | Constantinos Venetsanopoulos | `snf-manage backend-list`. |
558 | 0768a1df | Christos Stavrakakis | |
559 | a1c707c9 | Constantinos Venetsanopoulos | Note that no VMs will be spawned to this backend, since by default it is in a |
560 | a1c707c9 | Constantinos Venetsanopoulos | ``drained`` state after addition and also it has no public network assigned to |
561 | a1c707c9 | Constantinos Venetsanopoulos | it. |
562 | a1c707c9 | Constantinos Venetsanopoulos | |
563 | a1c707c9 | Constantinos Venetsanopoulos | So, first you need to create its public network, make sure everything works as |
564 | a1c707c9 | Constantinos Venetsanopoulos | expected and finally make it active by un-setting the ``drained`` flag. You can |
565 | a1c707c9 | Constantinos Venetsanopoulos | do this by running: |
566 | a1c707c9 | Constantinos Venetsanopoulos | |
567 | a1c707c9 | Constantinos Venetsanopoulos | .. code-block:: console |
568 | a1c707c9 | Constantinos Venetsanopoulos | |
569 | 46ccbcb9 | Christos Stavrakakis | $ snf-manage backend-modify --drained=False <backend_id> |
570 | 0768a1df | Christos Stavrakakis | |
571 | 0768a1df | Christos Stavrakakis | Removing an existing Ganeti backend |
572 | 90c74332 | Christos Stavrakakis | ``````````````````````````````````` |
573 | a1c707c9 | Constantinos Venetsanopoulos | In order to remove an existing backend from Synnefo, we run: |
574 | 90c74332 | Christos Stavrakakis | |
575 | 0768a1df | Christos Stavrakakis | .. code-block:: console |
576 | 0768a1df | Christos Stavrakakis | |
577 | a1c707c9 | Constantinos Venetsanopoulos | # snf-manage backend-remove <backend_id> |
578 | 0768a1df | Christos Stavrakakis | |
579 | a1c707c9 | Constantinos Venetsanopoulos | This command will fail if there are active VMs on the backend. Also, the |
580 | a1c707c9 | Constantinos Venetsanopoulos | backend is not cleaned before removal, so all the Synnefo private networks |
581 | a1c707c9 | Constantinos Venetsanopoulos | will be left on the Ganeti nodes. You need to remove them manually. |
582 | 0768a1df | Christos Stavrakakis | |
583 | a1c707c9 | Constantinos Venetsanopoulos | Allocation of VMs in Ganeti backends |
584 | a1c707c9 | Constantinos Venetsanopoulos | ```````````````````````````````````` |
585 | a1c707c9 | Constantinos Venetsanopoulos | As already mentioned, the Cyclades backend allocator is responsible for |
586 | a1c707c9 | Constantinos Venetsanopoulos | allocating new VMs to backends. This allocator does not choose the exact Ganeti |
587 | a1c707c9 | Constantinos Venetsanopoulos | node that will host the VM but just the Ganeti backend. The exact node is |
588 | a1c707c9 | Constantinos Venetsanopoulos | chosen by the Ganeti cluster's allocator (hail). |
589 | 0768a1df | Christos Stavrakakis | |
590 | 0768a1df | Christos Stavrakakis | The decision about which backend will host a VM is based on the available |
591 | 0768a1df | Christos Stavrakakis | resources. The allocator computes a score for each backend, that shows its load |
592 | 0768a1df | Christos Stavrakakis | factor, and the one with the minimum score is chosen. The admin can exclude |
593 | a1c707c9 | Constantinos Venetsanopoulos | backends from the allocation phase by marking them as ``drained`` by running: |
594 | 90c74332 | Christos Stavrakakis | |
595 | 0768a1df | Christos Stavrakakis | .. code-block:: console |
596 | 0768a1df | Christos Stavrakakis | |
597 | 46ccbcb9 | Christos Stavrakakis | $ snf-manage backend-modify --drained=True <backend_id> |
598 | 0768a1df | Christos Stavrakakis | |
599 | 0768a1df | Christos Stavrakakis | The backend resources are periodically updated, at a period defined by |
600 | a1c707c9 | Constantinos Venetsanopoulos | the ``BACKEND_REFRESH_MIN`` setting, or by running `snf-manage backend-update-status` |
601 | 0768a1df | Christos Stavrakakis | command. It is advised to have a cron job running this command at a smaller |
602 | a1c707c9 | Constantinos Venetsanopoulos | interval than ``BACKEND_REFRESH_MIN`` in order to remove the load of refreshing |
603 | 0768a1df | Christos Stavrakakis | the backends stats from the VM creation phase. |
604 | 0768a1df | Christos Stavrakakis | |
605 | a1c707c9 | Constantinos Venetsanopoulos | Finally, the admin can decide to have a user's VMs being allocated to a |
606 | a1c707c9 | Constantinos Venetsanopoulos | specific backend, with the ``BACKEND_PER_USER`` setting. This is a mapping |
607 | a1c707c9 | Constantinos Venetsanopoulos | between users and backends. If the user is found in ``BACKEND_PER_USER``, then |
608 | 46ccbcb9 | Christos Stavrakakis | Synnefo allocates all his/hers VMs to the specific backend in the variable, |
609 | 46ccbcb9 | Christos Stavrakakis | even if is marked as drained (useful for testing). |
610 | 0768a1df | Christos Stavrakakis | |
611 | 09d07554 | Christos Stavrakakis | Allocation based on disk-templates |
612 | 09d07554 | Christos Stavrakakis | ********************************** |
613 | 09d07554 | Christos Stavrakakis | |
614 | 09d07554 | Christos Stavrakakis | Besides the available resources of each Ganeti backend, the allocator takes |
615 | 09d07554 | Christos Stavrakakis | into consideration the disk template of the instance when trying to allocate it |
616 | 09d07554 | Christos Stavrakakis | to a Ganeti backend. Specifically, the allocator checks if the flavor of the |
617 | 09d07554 | Christos Stavrakakis | instance belongs to the available disk templates of each Ganeti backend. |
618 | 09d07554 | Christos Stavrakakis | |
619 | 09d07554 | Christos Stavrakakis | A Ganeti cluster has a list of enabled disk templates |
620 | 09d07554 | Christos Stavrakakis | (`--enabled-disk-templates`) and a list of allowed disk templates for new |
621 | 09d07554 | Christos Stavrakakis | instances (`--ipolicy-disk-templates`). See the `gnt-cluster` manpage for more |
622 | 09d07554 | Christos Stavrakakis | details about these options. |
623 | 09d07554 | Christos Stavrakakis | |
624 | 09d07554 | Christos Stavrakakis | When Synnefo allocates an instance, it checks whether the disk template of the |
625 | 09d07554 | Christos Stavrakakis | new instance belongs both in the enabled and ipolicy disk templates. You can |
626 | 09d07554 | Christos Stavrakakis | see the list of the available disk-templates by running `snf-manage |
627 | 09d07554 | Christos Stavrakakis | backend-list`. This list should be updated automatically after changing |
628 | 09d07554 | Christos Stavrakakis | these options in Ganeti and it can also be updated by running `snf-manage |
629 | 09d07554 | Christos Stavrakakis | backend-update-status`. |
630 | 09d07554 | Christos Stavrakakis | |
631 | 09d07554 | Christos Stavrakakis | So the administrator, can route instances on different backends based on their |
632 | 09d07554 | Christos Stavrakakis | flavor disk template, by modifying the enabled or ipolicy disk templates of |
633 | 09d07554 | Christos Stavrakakis | each backend. Also, the administrator can route instances between different |
634 | 09d07554 | Christos Stavrakakis | nodes of the same Ganeti backend, by modifying the same options at the |
635 | 09d07554 | Christos Stavrakakis | nodegroup level (see `gnt-group` manpage for mor details). |
636 | 09d07554 | Christos Stavrakakis | |
637 | 09d07554 | Christos Stavrakakis | |
638 | 9492387a | Christos Stavrakakis | Managing Virtual Machines |
639 | 9492387a | Christos Stavrakakis | ~~~~~~~~~~~~~~~~~~~~~~~~~ |
640 | 9492387a | Christos Stavrakakis | |
641 | a1c707c9 | Constantinos Venetsanopoulos | As mentioned, Cyclades uses Ganeti for management of VMs. The administrator can |
642 | a1c707c9 | Constantinos Venetsanopoulos | handle Cyclades VMs just like any other Ganeti instance, via `gnt-instance` |
643 | a1c707c9 | Constantinos Venetsanopoulos | commands. All Ganeti instances that belong to Synnefo, are separated from |
644 | a1c707c9 | Constantinos Venetsanopoulos | others, by a prefix in their names. This prefix is defined in |
645 | a1c707c9 | Constantinos Venetsanopoulos | ``BACKEND_PREFIX_ID`` setting in |
646 | a1c707c9 | Constantinos Venetsanopoulos | ``/etc/synnefo/20-snf-cyclades-app-backend.conf``. |
647 | 9492387a | Christos Stavrakakis | |
648 | a1c707c9 | Constantinos Venetsanopoulos | Apart from handling instances directly in the Ganeti level, a number of `snf-manage` |
649 | 9492387a | Christos Stavrakakis | commands are available: |
650 | 9492387a | Christos Stavrakakis | |
651 | a1c707c9 | Constantinos Venetsanopoulos | * ``snf-manage server-list``: List servers |
652 | a1c707c9 | Constantinos Venetsanopoulos | * ``snf-manage server-show``: Show information about a server in the Cyclades DB |
653 | a1c707c9 | Constantinos Venetsanopoulos | * ``snf-manage server-inspect``: Inspect the state of a server both in DB and Ganeti |
654 | a1c707c9 | Constantinos Venetsanopoulos | * ``snf-manage server-modify``: Modify the state of a server in the Cycldes DB |
655 | a1c707c9 | Constantinos Venetsanopoulos | * ``snf-manage server-create``: Create a new server |
656 | a1c707c9 | Constantinos Venetsanopoulos | * ``snf-manage server-import``: Import an existing Ganeti instance to Cyclades |
657 | 9492387a | Christos Stavrakakis | |
658 | 9492387a | Christos Stavrakakis | |
659 | 9492387a | Christos Stavrakakis | Managing Virtual Networks |
660 | 9492387a | Christos Stavrakakis | ~~~~~~~~~~~~~~~~~~~~~~~~~ |
661 | 9492387a | Christos Stavrakakis | |
662 | a1c707c9 | Constantinos Venetsanopoulos | Cyclades is able to create and manage Virtual Networks. Networking is |
663 | a1c707c9 | Constantinos Venetsanopoulos | desployment specific and must be customized based on the specific needs of the |
664 | a1c707c9 | Constantinos Venetsanopoulos | system administrator. For better understanding of networking please refer to |
665 | a1c707c9 | Constantinos Venetsanopoulos | the :ref:`Network <networks>` section. |
666 | a653c059 | Christos Stavrakakis | |
667 | a653c059 | Christos Stavrakakis | Exactly as Cyclades VMs can be handled like Ganeti instances, Cyclades Networks |
668 | a653c059 | Christos Stavrakakis | can also by handled as Ganeti networks, via `gnt-network commands`. All Ganeti |
669 | a1c707c9 | Constantinos Venetsanopoulos | networks that belong to Synnefo are named with the prefix |
670 | a653c059 | Christos Stavrakakis | `${BACKEND_PREFIX_ID}-net-`. |
671 | a653c059 | Christos Stavrakakis | |
672 | a1c707c9 | Constantinos Venetsanopoulos | There are also the following `snf-manage` commands for managing networks: |
673 | a653c059 | Christos Stavrakakis | |
674 | a1c707c9 | Constantinos Venetsanopoulos | * ``snf-manage network-list``: List networks |
675 | a1c707c9 | Constantinos Venetsanopoulos | * ``snf-manage network-show``: Show information about a network in the Cyclades DB |
676 | a1c707c9 | Constantinos Venetsanopoulos | * ``snf-manage network-inspect``: Inspect the state of the network in DB and Ganeti backends |
677 | a1c707c9 | Constantinos Venetsanopoulos | * ``snf-manage network-modify``: Modify the state of a network in the Cycldes DB |
678 | a1c707c9 | Constantinos Venetsanopoulos | * ``snf-manage network-create``: Create a new network |
679 | a1c707c9 | Constantinos Venetsanopoulos | * ``snf-manage network-remove``: Remove an existing network |
680 | a653c059 | Christos Stavrakakis | |
681 | 9c98c6fc | Christos Stavrakakis | Managing Network Resources |
682 | a1c707c9 | Constantinos Venetsanopoulos | `````````````````````````` |
683 | 9c98c6fc | Christos Stavrakakis | |
684 | a1c707c9 | Constantinos Venetsanopoulos | Proper operation of the Cyclades Network Service depends on the unique |
685 | a1c707c9 | Constantinos Venetsanopoulos | assignment of specific resources to each type of virtual network. Specifically, |
686 | a1c707c9 | Constantinos Venetsanopoulos | these resources are: |
687 | 9c98c6fc | Christos Stavrakakis | |
688 | a1c707c9 | Constantinos Venetsanopoulos | * IP addresses. Cyclades creates a Pool of IPs for each Network, and assigns a |
689 | a1c707c9 | Constantinos Venetsanopoulos | unique IP address to each VM, thus connecting it to this Network. You can see |
690 | a1c707c9 | Constantinos Venetsanopoulos | the IP pool of each network by running `snf-manage network-inspect |
691 | a1c707c9 | Constantinos Venetsanopoulos | <network_ID>`. IP pools are automatically created and managed by Cyclades, |
692 | a1c707c9 | Constantinos Venetsanopoulos | depending on the subnet of the Network. |
693 | 9492387a | Christos Stavrakakis | * Bridges corresponding to physical VLANs, which are required for networks of |
694 | a1c707c9 | Constantinos Venetsanopoulos | type `PRIVATE_PHYSICAL_VLAN`. |
695 | a1c707c9 | Constantinos Venetsanopoulos | * One Bridge corresponding to one physical VLAN which is required for networks of |
696 | a1c707c9 | Constantinos Venetsanopoulos | type `PRIVATE_MAC_PREFIX`. |
697 | 9c98c6fc | Christos Stavrakakis | |
698 | 4573511a | Christos Stavrakakis | IPv4 addresses |
699 | 4573511a | Christos Stavrakakis | ************** |
700 | 4573511a | Christos Stavrakakis | |
701 | 4573511a | Christos Stavrakakis | An allocation pool of IPv4 addresses is automatically created for every network |
702 | 4573511a | Christos Stavrakakis | that has the attribute `dhcp` set to True. The allocation pool contains the |
703 | 4573511a | Christos Stavrakakis | range of IP addresses that are included in the subnet. The gateway and the |
704 | 4573511a | Christos Stavrakakis | broadcast address of the network are excluded from the allocation pool. The |
705 | 4573511a | Christos Stavrakakis | admin can externally reserve IP addresses to exclude them from automatic |
706 | 4573511a | Christos Stavrakakis | allocation with the `--add-reserved-ips` option of `snf-manage network-modify` |
707 | 4573511a | Christos Stavrakakis | command. For example the following command will reserve two IP addresses |
708 | 4573511a | Christos Stavrakakis | from network with ID `42`: |
709 | 9c98c6fc | Christos Stavrakakis | |
710 | 4573511a | Christos Stavrakakis | .. code-block:: console |
711 | 4573511a | Christos Stavrakakis | |
712 | 4573511a | Christos Stavrakakis | snf-manage network-modify --add-reserved-ips=10.0.0.21,10.0.0.22 42 |
713 | 4573511a | Christos Stavrakakis | |
714 | 4573511a | Christos Stavrakakis | .. warning:: Externally reserving IP addresses is also available at the Ganeti. |
715 | 4573511a | Christos Stavrakakis | However, when using Cyclades with multiple Ganeti backends, the handling of |
716 | 4573511a | Christos Stavrakakis | IP pools must be performed from Cyclades! |
717 | 4573511a | Christos Stavrakakis | |
718 | 4573511a | Christos Stavrakakis | Bridges |
719 | 4573511a | Christos Stavrakakis | ******* |
720 | 4573511a | Christos Stavrakakis | |
721 | 4573511a | Christos Stavrakakis | As already mentioned Cyclades use a pool of Bridges that must correspond |
722 | 4573511a | Christos Stavrakakis | to Physical VLAN at the Ganeti level. A bridge from the pool is assigned to |
723 | 4573511a | Christos Stavrakakis | each network of flavor `PHYSICAL_VLAN`. Creation of this pool is done |
724 | 4573511a | Christos Stavrakakis | using `snf-manage pool-create` command. For example the following command |
725 | 4573511a | Christos Stavrakakis | will create a pool containing the brdiges from `prv1` to `prv21`. |
726 | 90c74332 | Christos Stavrakakis | |
727 | 9c98c6fc | Christos Stavrakakis | .. code-block:: console |
728 | 9c98c6fc | Christos Stavrakakis | |
729 | 9c98c6fc | Christos Stavrakakis | # snf-manage pool-create --type=bridge --base=prv --size=20 |
730 | 9c98c6fc | Christos Stavrakakis | |
731 | 9c98c6fc | Christos Stavrakakis | You can verify the creation of the pool, and check its contents by running: |
732 | 90c74332 | Christos Stavrakakis | |
733 | 9c98c6fc | Christos Stavrakakis | .. code-block:: console |
734 | 9c98c6fc | Christos Stavrakakis | |
735 | 9c98c6fc | Christos Stavrakakis | # snf-manage pool-list |
736 | 9c98c6fc | Christos Stavrakakis | # snf-manage pool-show --type=bridge 1 |
737 | 9c98c6fc | Christos Stavrakakis | |
738 | 4573511a | Christos Stavrakakis | Finally you can use the `pool-modify` management command in order to externally |
739 | 4573511a | Christos Stavrakakis | reserve the values from pool, extend or shrink the pool if possible. |
740 | 4573511a | Christos Stavrakakis | |
741 | 4573511a | Christos Stavrakakis | MAC Prefixes |
742 | 4573511a | Christos Stavrakakis | ************ |
743 | 4573511a | Christos Stavrakakis | |
744 | 4573511a | Christos Stavrakakis | Cyclades also use a pool of MAC prefixes to assign to networks of flavor |
745 | 4573511a | Christos Stavrakakis | `MAC_FILTERED`. Handling of this pool is done exactly as with pool of bridges, |
746 | 4573511a | Christos Stavrakakis | except that the type option must be set to mac-prefix: |
747 | 90c74332 | Christos Stavrakakis | |
748 | 9c98c6fc | Christos Stavrakakis | .. code-block:: console |
749 | 9c98c6fc | Christos Stavrakakis | |
750 | 9c98c6fc | Christos Stavrakakis | # snf-manage pool-create --type=mac-prefix --base=aa:00:0 --size=65536 |
751 | 9c98c6fc | Christos Stavrakakis | |
752 | 4573511a | Christos Stavrakakis | The above command will create a pool of MAC prefixes from ``aa:00:1`` to |
753 | 4573511a | Christos Stavrakakis | ``b9:ff:f``. The MAC prefix pool is responsible for providing only unicast and |
754 | 4573511a | Christos Stavrakakis | locally administered MAC addresses, so many of these prefixes will be |
755 | 4573511a | Christos Stavrakakis | externally reserved, to exclude from allocation. |
756 | 4573511a | Christos Stavrakakis | |
757 | 4573511a | Christos Stavrakakis | Pool reconciliation |
758 | 4573511a | Christos Stavrakakis | ******************* |
759 | 4573511a | Christos Stavrakakis | |
760 | 4573511a | Christos Stavrakakis | The management command `snf-manage reconcile-pools` can be used that all the |
761 | 4573511a | Christos Stavrakakis | above mentioned pools are consistent and that all values that come from the |
762 | 4573511a | Christos Stavrakakis | pool are not used more than once. |
763 | 0768a1df | Christos Stavrakakis | |
764 | 426d4ae3 | Constantinos Venetsanopoulos | |
765 | eab73849 | Constantinos Venetsanopoulos | Cyclades advanced operations |
766 | eab73849 | Constantinos Venetsanopoulos | ---------------------------- |
767 | eab73849 | Constantinos Venetsanopoulos | |
768 | eab73849 | Constantinos Venetsanopoulos | Reconciliation mechanism |
769 | eab73849 | Constantinos Venetsanopoulos | ~~~~~~~~~~~~~~~~~~~~~~~~ |
770 | a1c707c9 | Constantinos Venetsanopoulos | |
771 | 06e23415 | Christos Stavrakakis | On certain occasions, such as a Ganeti or RabbitMQ failure, the state of |
772 | 06e23415 | Christos Stavrakakis | Cyclades database may differ from the real state of VMs and networks in the |
773 | 06e23415 | Christos Stavrakakis | Ganeti backends. The reconciliation process is designed to synchronize |
774 | 06e23415 | Christos Stavrakakis | the state of the Cyclades DB with Ganeti. There are two management commands |
775 | 06e23415 | Christos Stavrakakis | for reconciling VMs and Networks |
776 | 06e23415 | Christos Stavrakakis | |
777 | a1c707c9 | Constantinos Venetsanopoulos | Reconciling Virtual Machines |
778 | a1c707c9 | Constantinos Venetsanopoulos | ```````````````````````````` |
779 | a1c707c9 | Constantinos Venetsanopoulos | |
780 | 06e23415 | Christos Stavrakakis | Reconciliation of VMs detects the following conditions: |
781 | a1c707c9 | Constantinos Venetsanopoulos | |
782 | eab73849 | Constantinos Venetsanopoulos | * Stale DB servers without corresponding Ganeti instances |
783 | eab73849 | Constantinos Venetsanopoulos | * Orphan Ganeti instances, without corresponding DB entries |
784 | 06e23415 | Christos Stavrakakis | * Out-of-sync state for DB entries wrt to Ganeti instances |
785 | eab73849 | Constantinos Venetsanopoulos | |
786 | 06e23415 | Christos Stavrakakis | To detect all inconsistencies you can just run: |
787 | 90c74332 | Christos Stavrakakis | |
788 | eab73849 | Constantinos Venetsanopoulos | .. code-block:: console |
789 | a1c707c9 | Constantinos Venetsanopoulos | |
790 | a1c707c9 | Constantinos Venetsanopoulos | $ snf-manage reconcile-servers |
791 | eab73849 | Constantinos Venetsanopoulos | |
792 | 06e23415 | Christos Stavrakakis | Adding the `--fix-all` option, will do the actual synchronization: |
793 | 90c74332 | Christos Stavrakakis | |
794 | 06e23415 | Christos Stavrakakis | .. code-block:: console |
795 | a1c707c9 | Constantinos Venetsanopoulos | |
796 | e30c60eb | Stratos Psomadakis | $ snf-manage reconcile-servers --fix-all |
797 | eab73849 | Constantinos Venetsanopoulos | |
798 | e30c60eb | Stratos Psomadakis | Please see ``snf-manage reconcile-servers --help`` for all the details. |
799 | eab73849 | Constantinos Venetsanopoulos | |
800 | 06e23415 | Christos Stavrakakis | Reconciling Networks |
801 | 90c74332 | Christos Stavrakakis | ```````````````````` |
802 | a1c707c9 | Constantinos Venetsanopoulos | |
803 | 06e23415 | Christos Stavrakakis | Reconciliation of Networks detects the following conditions: |
804 | a1c707c9 | Constantinos Venetsanopoulos | |
805 | 06e23415 | Christos Stavrakakis | * Stale DB networks without corresponding Ganeti networks |
806 | 06e23415 | Christos Stavrakakis | * Orphan Ganeti networks, without corresponding DB entries |
807 | 06e23415 | Christos Stavrakakis | * Private networks that are not created to all Ganeti backends |
808 | 06e23415 | Christos Stavrakakis | * Unsynchronized IP pools |
809 | 06e23415 | Christos Stavrakakis | |
810 | 06e23415 | Christos Stavrakakis | To detect all inconsistencies you can just run: |
811 | 90c74332 | Christos Stavrakakis | |
812 | 06e23415 | Christos Stavrakakis | .. code-block:: console |
813 | a1c707c9 | Constantinos Venetsanopoulos | |
814 | 06e23415 | Christos Stavrakakis | $ snf-manage reconcile-networks |
815 | 06e23415 | Christos Stavrakakis | |
816 | 06e23415 | Christos Stavrakakis | Adding the `--fix-all` option, will do the actual synchronization: |
817 | 90c74332 | Christos Stavrakakis | |
818 | 06e23415 | Christos Stavrakakis | .. code-block:: console |
819 | a1c707c9 | Constantinos Venetsanopoulos | |
820 | 06e23415 | Christos Stavrakakis | $ snf-manage reconcile-networks --fix-all |
821 | 06e23415 | Christos Stavrakakis | |
822 | 06e23415 | Christos Stavrakakis | Please see ``snf-manage reconcile-networks --help`` for all the details. |
823 | eab73849 | Constantinos Venetsanopoulos | |
824 | eab73849 | Constantinos Venetsanopoulos | |
825 | 426d4ae3 | Constantinos Venetsanopoulos | Cyclades internals |
826 | 426d4ae3 | Constantinos Venetsanopoulos | ------------------ |
827 | 426d4ae3 | Constantinos Venetsanopoulos | |
828 | 426d4ae3 | Constantinos Venetsanopoulos | Asynchronous communication with Ganeti backends |
829 | 426d4ae3 | Constantinos Venetsanopoulos | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
830 | 426d4ae3 | Constantinos Venetsanopoulos | Synnefo uses Google Ganeti backends for VM cluster management. In order for |
831 | 426d4ae3 | Constantinos Venetsanopoulos | Cyclades to be able to handle thousands of user requests, Cyclades and Ganeti |
832 | 426d4ae3 | Constantinos Venetsanopoulos | communicate asynchronously. Briefly, requests are submitted to Ganeti through |
833 | 426d4ae3 | Constantinos Venetsanopoulos | Ganeti's RAPI/HTTP interface, and then asynchronous notifications about the |
834 | 426d4ae3 | Constantinos Venetsanopoulos | progress of Ganeti jobs are being created and pushed upwards to Cyclades. The |
835 | 426d4ae3 | Constantinos Venetsanopoulos | architecture and communication with a Ganeti backend is shown in the graph |
836 | 426d4ae3 | Constantinos Venetsanopoulos | below: |
837 | 426d4ae3 | Constantinos Venetsanopoulos | |
838 | 426d4ae3 | Constantinos Venetsanopoulos | .. image:: images/cyclades-ganeti-communication.png |
839 | 426d4ae3 | Constantinos Venetsanopoulos | :width: 50% |
840 | 426d4ae3 | Constantinos Venetsanopoulos | :target: _images/cyclades-ganeti-communication.png |
841 | 426d4ae3 | Constantinos Venetsanopoulos | |
842 | 426d4ae3 | Constantinos Venetsanopoulos | The Cyclades API server is responsible for handling user requests. Read-only |
843 | 426d4ae3 | Constantinos Venetsanopoulos | requests are directly served by looking up the Cyclades DB. If the request |
844 | 426d4ae3 | Constantinos Venetsanopoulos | needs an action in the Ganeti backend, Cyclades submit jobs to the Ganeti |
845 | 426d4ae3 | Constantinos Venetsanopoulos | master using the `Ganeti RAPI interface |
846 | 426d4ae3 | Constantinos Venetsanopoulos | <http://docs.ganeti.org/ganeti/2.2/html/rapi.html>`_. |
847 | 426d4ae3 | Constantinos Venetsanopoulos | |
848 | 5135245b | Christos Stavrakakis | While Ganeti executes the job, `snf-ganeti-eventd`, and `snf-progress-monitor` |
849 | 5135245b | Christos Stavrakakis | are monitoring the progress of the job and send corresponding messages to the |
850 | 5135245b | Christos Stavrakakis | RabbitMQ servers. These components are part of `snf-cyclades-gtools` and must |
851 | 5135245b | Christos Stavrakakis | be installed on all Ganeti nodes. Specially: |
852 | 426d4ae3 | Constantinos Venetsanopoulos | |
853 | 426d4ae3 | Constantinos Venetsanopoulos | * *snf-ganeti-eventd* sends messages about operations affecting the operating |
854 | 426d4ae3 | Constantinos Venetsanopoulos | state of instances and networks. Works by monitoring the Ganeti job queue. |
855 | 426d4ae3 | Constantinos Venetsanopoulos | * *snf-progress_monitor* sends messages about the progress of the Image deployment |
856 | 426d4ae3 | Constantinos Venetsanopoulos | phase which is done by the Ganeti OS Definition `snf-image`. |
857 | 426d4ae3 | Constantinos Venetsanopoulos | |
858 | 426d4ae3 | Constantinos Venetsanopoulos | Finally, `snf-dispatcher` consumes messages from the RabbitMQ queues, processes |
859 | 426d4ae3 | Constantinos Venetsanopoulos | these messages and properly updates the state of the Cyclades DB. Subsequent |
860 | 426d4ae3 | Constantinos Venetsanopoulos | requests to the Cyclades API, will retrieve the updated state from the DB. |
861 | 426d4ae3 | Constantinos Venetsanopoulos | |
862 | 426d4ae3 | Constantinos Venetsanopoulos | |
863 | e81ad3e5 | Constantinos Venetsanopoulos | Synnefo management commands ("snf-manage") |
864 | e81ad3e5 | Constantinos Venetsanopoulos | ========================================== |
865 | e81ad3e5 | Constantinos Venetsanopoulos | |
866 | e81ad3e5 | Constantinos Venetsanopoulos | Each Synnefo service, Astakos, Pithos and Cyclades are controlled by the |
867 | e81ad3e5 | Constantinos Venetsanopoulos | administrator using the "snf-manage" admin tool. This tool is an extension of |
868 | e81ad3e5 | Constantinos Venetsanopoulos | the Django command-line management utility. It is run on the host that runs |
869 | e81ad3e5 | Constantinos Venetsanopoulos | each service and provides different types of commands depending the services |
870 | e81ad3e5 | Constantinos Venetsanopoulos | running on the host. If you are running more than one service on the same host |
871 | e81ad3e5 | Constantinos Venetsanopoulos | "snf-manage" adds all the corresponding commands for each service dynamically, |
872 | e81ad3e5 | Constantinos Venetsanopoulos | providing a unified admin environment. |
873 | e81ad3e5 | Constantinos Venetsanopoulos | |
874 | e81ad3e5 | Constantinos Venetsanopoulos | To run "snf-manage" you just type: |
875 | e81ad3e5 | Constantinos Venetsanopoulos | |
876 | e81ad3e5 | Constantinos Venetsanopoulos | .. code-block:: console |
877 | e81ad3e5 | Constantinos Venetsanopoulos | |
878 | e81ad3e5 | Constantinos Venetsanopoulos | # snf-manage <command> [arguments] |
879 | e81ad3e5 | Constantinos Venetsanopoulos | |
880 | e81ad3e5 | Constantinos Venetsanopoulos | on the corresponding host that runs the service. For example, if you have all |
881 | e81ad3e5 | Constantinos Venetsanopoulos | services running on different physical hosts you would do: |
882 | e81ad3e5 | Constantinos Venetsanopoulos | |
883 | e81ad3e5 | Constantinos Venetsanopoulos | .. code-block:: console |
884 | e81ad3e5 | Constantinos Venetsanopoulos | |
885 | e81ad3e5 | Constantinos Venetsanopoulos | root@astakos-host # snf-manage <astakos-command> [argument] |
886 | e81ad3e5 | Constantinos Venetsanopoulos | root@pithos-host # snf-manage <pithos-command> [argument] |
887 | e81ad3e5 | Constantinos Venetsanopoulos | root@cyclades-host # snf-manage <cyclades-command> [argument] |
888 | e81ad3e5 | Constantinos Venetsanopoulos | |
889 | e81ad3e5 | Constantinos Venetsanopoulos | If you have all services running on the same host you would do: |
890 | e81ad3e5 | Constantinos Venetsanopoulos | |
891 | e81ad3e5 | Constantinos Venetsanopoulos | .. code-block:: console |
892 | e81ad3e5 | Constantinos Venetsanopoulos | |
893 | e81ad3e5 | Constantinos Venetsanopoulos | root@synnefo-host # snf-manage <{astakos,pithos,cyclades}-command> [argument] |
894 | e81ad3e5 | Constantinos Venetsanopoulos | |
895 | e81ad3e5 | Constantinos Venetsanopoulos | Note that you cannot execute a service's command on a host that is not running |
896 | e81ad3e5 | Constantinos Venetsanopoulos | this service. For example, the following will return an error if Astakos and |
897 | e81ad3e5 | Constantinos Venetsanopoulos | Cyclades are installed on different physical hosts: |
898 | e81ad3e5 | Constantinos Venetsanopoulos | |
899 | e81ad3e5 | Constantinos Venetsanopoulos | .. code-block:: console |
900 | e81ad3e5 | Constantinos Venetsanopoulos | |
901 | e81ad3e5 | Constantinos Venetsanopoulos | root@astakos-host # snf-manage <cyclades-command> [argument] |
902 | e81ad3e5 | Constantinos Venetsanopoulos | Unknown command: 'cyclades-command' |
903 | e81ad3e5 | Constantinos Venetsanopoulos | Type 'snf-manage help' for usage. |
904 | e81ad3e5 | Constantinos Venetsanopoulos | |
905 | e81ad3e5 | Constantinos Venetsanopoulos | This is the complete list of "snf-manage" commands for each service. |
906 | e81ad3e5 | Constantinos Venetsanopoulos | |
907 | e81ad3e5 | Constantinos Venetsanopoulos | Astakos snf-manage commands |
908 | e81ad3e5 | Constantinos Venetsanopoulos | --------------------------- |
909 | e81ad3e5 | Constantinos Venetsanopoulos | |
910 | e81ad3e5 | Constantinos Venetsanopoulos | ============================ =========================== |
911 | e81ad3e5 | Constantinos Venetsanopoulos | Name Description |
912 | e81ad3e5 | Constantinos Venetsanopoulos | ============================ =========================== |
913 | e81ad3e5 | Constantinos Venetsanopoulos | fix-superusers Transform superusers created by syncdb into AstakosUser instances |
914 | 5e1ea6f7 | Giorgos Korfiatis | cleanup-full Cleanup sessions and session catalog |
915 | a4451f59 | Giorgos Korfiatis | commission-list List pending commissions |
916 | a4451f59 | Giorgos Korfiatis | commission-show Show details for a pending commission |
917 | 252eef38 | Giorgos Korfiatis | component-add Register a component |
918 | 252eef38 | Giorgos Korfiatis | component-list List components |
919 | 252eef38 | Giorgos Korfiatis | component-modify Modify component attributes |
920 | 6ef1e2eb | Giorgos Korfiatis | component-show Show component details |
921 | e81ad3e5 | Constantinos Venetsanopoulos | project-control Manage projects and applications |
922 | e81ad3e5 | Constantinos Venetsanopoulos | project-list List projects |
923 | e81ad3e5 | Constantinos Venetsanopoulos | project-show Show project details |
924 | a69ad12b | Giorgos Korfiatis | quota-list List user quota |
925 | a69ad12b | Giorgos Korfiatis | quota-verify Check the integrity of user quota |
926 | e81ad3e5 | Constantinos Venetsanopoulos | reconcile-resources-astakos Reconcile resource usage of Quotaholder with Astakos DB |
927 | e81ad3e5 | Constantinos Venetsanopoulos | resource-list List resources |
928 | 5e1ea6f7 | Giorgos Korfiatis | resource-modify Modify a resource's default base quota and boolean flags |
929 | 90e7da53 | Giorgos Korfiatis | service-export-astakos Export Astakos services and resources in JSON format |
930 | bd1f667b | Giorgos Korfiatis | service-import Register services |
931 | e81ad3e5 | Constantinos Venetsanopoulos | service-list List services |
932 | 5e1ea6f7 | Giorgos Korfiatis | service-show Show service details |
933 | e81ad3e5 | Constantinos Venetsanopoulos | term-add Add approval terms |
934 | e81ad3e5 | Constantinos Venetsanopoulos | user-activation-send Send user activation |
935 | e81ad3e5 | Constantinos Venetsanopoulos | user-add Add user |
936 | 9577d199 | Kostas Papadimitriou | authpolicy-add Create a new authentication provider policy profile |
937 | 9577d199 | Kostas Papadimitriou | authpolicy-list List existing authentication provider policy profiles |
938 | 9577d199 | Kostas Papadimitriou | authpolicy-remove Remove an authentication provider policy |
939 | 9577d199 | Kostas Papadimitriou | authpolicy-set Assign an existing authentication provider policy profile to a user or group |
940 | 9577d199 | Kostas Papadimitriou | authpolicy-show Show authentication provider profile details |
941 | 9577d199 | Kostas Papadimitriou | group-add Create a group with the given name |
942 | 9577d199 | Kostas Papadimitriou | group-list List available groups |
943 | e81ad3e5 | Constantinos Venetsanopoulos | user-list List users |
944 | e81ad3e5 | Constantinos Venetsanopoulos | user-modify Modify user |
945 | e81ad3e5 | Constantinos Venetsanopoulos | user-show Show user details |
946 | e81ad3e5 | Constantinos Venetsanopoulos | ============================ =========================== |
947 | e81ad3e5 | Constantinos Venetsanopoulos | |
948 | e81ad3e5 | Constantinos Venetsanopoulos | Pithos snf-manage commands |
949 | e81ad3e5 | Constantinos Venetsanopoulos | -------------------------- |
950 | e81ad3e5 | Constantinos Venetsanopoulos | |
951 | e81ad3e5 | Constantinos Venetsanopoulos | ============================ =========================== |
952 | e81ad3e5 | Constantinos Venetsanopoulos | Name Description |
953 | e81ad3e5 | Constantinos Venetsanopoulos | ============================ =========================== |
954 | 3506f6a0 | Sofia Papagiannaki | reconcile-commissions-pithos Display unresolved commissions and trigger their recovery |
955 | 90e7da53 | Giorgos Korfiatis | service-export-pithos Export Pithos services and resources in JSON format |
956 | 3506f6a0 | Sofia Papagiannaki | reconcile-resources-pithos Detect unsynchronized usage between Astakos and Pithos DB resources and synchronize them if specified so. |
957 | e81ad3e5 | Constantinos Venetsanopoulos | ============================ =========================== |
958 | e81ad3e5 | Constantinos Venetsanopoulos | |
959 | e81ad3e5 | Constantinos Venetsanopoulos | Cyclades snf-manage commands |
960 | e81ad3e5 | Constantinos Venetsanopoulos | ---------------------------- |
961 | e81ad3e5 | Constantinos Venetsanopoulos | |
962 | bf57a264 | Christos Stavrakakis | ============================== =========================== |
963 | bf57a264 | Christos Stavrakakis | Name Description |
964 | bf57a264 | Christos Stavrakakis | ============================== =========================== |
965 | bf57a264 | Christos Stavrakakis | backend-add Add a new Ganeti backend |
966 | bf57a264 | Christos Stavrakakis | backend-list List backends |
967 | bf57a264 | Christos Stavrakakis | backend-modify Modify a backend |
968 | bf57a264 | Christos Stavrakakis | backend-update-status Update backend statistics for instance allocation |
969 | bf57a264 | Christos Stavrakakis | backend-remove Remove a Ganeti backend |
970 | d14155e3 | Giorgos Korfiatis | enforce-resources-cyclades Check and fix quota violations for Cyclades resources |
971 | bf57a264 | Christos Stavrakakis | server-create Create a new server |
972 | bf57a264 | Christos Stavrakakis | server-show Show server details |
973 | bf57a264 | Christos Stavrakakis | server-list List servers |
974 | bf57a264 | Christos Stavrakakis | server-modify Modify a server |
975 | bf57a264 | Christos Stavrakakis | server-import Import an existing Ganeti VM into synnefo |
976 | bf57a264 | Christos Stavrakakis | server-inspect Inspect a server in DB and Ganeti |
977 | bf57a264 | Christos Stavrakakis | network-create Create a new network |
978 | bf57a264 | Christos Stavrakakis | network-list List networks |
979 | bf57a264 | Christos Stavrakakis | network-modify Modify a network |
980 | bf57a264 | Christos Stavrakakis | network-inspect Inspect network state in DB and Ganeti |
981 | bf57a264 | Christos Stavrakakis | network-remove Delete a network |
982 | bf57a264 | Christos Stavrakakis | flavor-create Create a new flavor |
983 | bf57a264 | Christos Stavrakakis | flavor-list List flavors |
984 | bf57a264 | Christos Stavrakakis | flavor-modify Modify a flavor |
985 | bf57a264 | Christos Stavrakakis | image-list List images |
986 | bf57a264 | Christos Stavrakakis | image-show Show image details |
987 | bf57a264 | Christos Stavrakakis | pool-create Create a bridge or mac-prefix pool |
988 | bf57a264 | Christos Stavrakakis | pool-show Show pool details |
989 | bf57a264 | Christos Stavrakakis | pool-list List pools |
990 | bf57a264 | Christos Stavrakakis | pool-modify Modify a pool |
991 | bf57a264 | Christos Stavrakakis | pool-remove Delete a pool |
992 | f61f3fa7 | Christos Stavrakakis | port-create Create a port connecting a server to a network |
993 | f61f3fa7 | Christos Stavrakakis | port-inspect Inspect the state of a port in DB and Ganeti |
994 | f61f3fa7 | Christos Stavrakakis | port-list List ports |
995 | f61f3fa7 | Christos Stavrakakis | port-remove Delete a port |
996 | f61f3fa7 | Christos Stavrakakis | floating-ip-create Create a new floating IP |
997 | f61f3fa7 | Christos Stavrakakis | floating-ip-attach Attach a floating IP to a server |
998 | 6d86f5b3 | Christos Stavrakakis | floating-ip-detach Detach a floating IP from a server |
999 | f61f3fa7 | Christos Stavrakakis | floating-ip-list List floating IPs |
1000 | f61f3fa7 | Christos Stavrakakis | floating-ip-remove Delete a floating IP |
1001 | bf57a264 | Christos Stavrakakis | queue-inspect Inspect the messages of a RabbitMQ queue |
1002 | bf57a264 | Christos Stavrakakis | queue-retry Resend messages from Dead Letter queues to original exchanges |
1003 | 90e7da53 | Giorgos Korfiatis | service-export-cyclades Export Cyclades services and resources in JSON format |
1004 | aab200c6 | Dionysis Grigoropoulos | subnet-create Create a subnet |
1005 | aab200c6 | Dionysis Grigoropoulos | subnet-inspect Inspect a subnet in DB |
1006 | aab200c6 | Dionysis Grigoropoulos | subnet-list List subnets |
1007 | aab200c6 | Dionysis Grigoropoulos | subnet-modify Modify a subnet |
1008 | bf57a264 | Christos Stavrakakis | reconcile-servers Reconcile servers of Synnefo DB with state of Ganeti backend |
1009 | bf57a264 | Christos Stavrakakis | reconcile-networks Reconcile networks of Synnefo DB with state of Ganeti backend |
1010 | bf57a264 | Christos Stavrakakis | reconcile-pools Check consistency of pool resources |
1011 | bf57a264 | Christos Stavrakakis | reconcile-commissions-cyclades Detect and resolve pending commissions to Quotaholder |
1012 | bf57a264 | Christos Stavrakakis | reconcile-resources-cyclades Reconcile resource usage of Astakos with Cyclades DB. |
1013 | bf57a264 | Christos Stavrakakis | ============================== =========================== |
1014 | e81ad3e5 | Constantinos Venetsanopoulos | |
1015 | 44cc2a6a | Constantinos Venetsanopoulos | |
1016 | 11716a83 | Giorgos Korfiatis | Astakos helper scripts |
1017 | 11716a83 | Giorgos Korfiatis | ====================== |
1018 | 11716a83 | Giorgos Korfiatis | |
1019 | 11716a83 | Giorgos Korfiatis | Astakos includes two scripts to facilitate the installation procedure. |
1020 | 11716a83 | Giorgos Korfiatis | Running: |
1021 | 11716a83 | Giorgos Korfiatis | |
1022 | 11716a83 | Giorgos Korfiatis | .. code-block:: console |
1023 | 11716a83 | Giorgos Korfiatis | |
1024 | b4109758 | Giorgos Korfiatis | snf-component-register [<component_name>] |
1025 | 11716a83 | Giorgos Korfiatis | |
1026 | 11716a83 | Giorgos Korfiatis | automates the registration of the standard Synnefo components (astakos, |
1027 | 11716a83 | Giorgos Korfiatis | cyclades, and pithos) in astakos database. It internally uses the script: |
1028 | 11716a83 | Giorgos Korfiatis | |
1029 | 11716a83 | Giorgos Korfiatis | .. code-block:: console |
1030 | 11716a83 | Giorgos Korfiatis | |
1031 | 11716a83 | Giorgos Korfiatis | snf-service-export <component_name> <base_url> |
1032 | 11716a83 | Giorgos Korfiatis | |
1033 | 11716a83 | Giorgos Korfiatis | which simulates the export of service and resource definitions of the |
1034 | 11716a83 | Giorgos Korfiatis | standard Synnefo components. |
1035 | 11716a83 | Giorgos Korfiatis | |
1036 | 44cc2a6a | Constantinos Venetsanopoulos | |
1037 | 3506f6a0 | Sofia Papagiannaki | Pithos managing accounts |
1038 | 3506f6a0 | Sofia Papagiannaki | ======================== |
1039 | 3506f6a0 | Sofia Papagiannaki | |
1040 | 3506f6a0 | Sofia Papagiannaki | Pithos provides a utility tool for managing accounts. |
1041 | 3506f6a0 | Sofia Papagiannaki | To run you just type: |
1042 | 3506f6a0 | Sofia Papagiannaki | |
1043 | 3506f6a0 | Sofia Papagiannaki | .. code-block:: console |
1044 | 3506f6a0 | Sofia Papagiannaki | |
1045 | 3506f6a0 | Sofia Papagiannaki | # pithos-manage-accounts <command> [arguments] |
1046 | 3506f6a0 | Sofia Papagiannaki | |
1047 | 3506f6a0 | Sofia Papagiannaki | This is the list of the available commands: |
1048 | 3506f6a0 | Sofia Papagiannaki | |
1049 | 3506f6a0 | Sofia Papagiannaki | ============================ =========================== |
1050 | 3506f6a0 | Sofia Papagiannaki | Name Description |
1051 | 3506f6a0 | Sofia Papagiannaki | ============================ =========================== |
1052 | 3506f6a0 | Sofia Papagiannaki | delete Remove an account from the Pithos DB |
1053 | 3506f6a0 | Sofia Papagiannaki | export-quota Export account quota in a file |
1054 | 3506f6a0 | Sofia Papagiannaki | list List existing/dublicate accounts |
1055 | 3506f6a0 | Sofia Papagiannaki | merge Move an account contents in another account |
1056 | 3506f6a0 | Sofia Papagiannaki | set-container-quota Set container quota for all or a specific account |
1057 | 3506f6a0 | Sofia Papagiannaki | ============================ =========================== |
1058 | 3506f6a0 | Sofia Papagiannaki | |
1059 | e81ad3e5 | Constantinos Venetsanopoulos | |
1060 | bc055d09 | Constantinos Venetsanopoulos | The "kamaki" API client |
1061 | eab73849 | Constantinos Venetsanopoulos | ======================= |
1062 | bc055d09 | Constantinos Venetsanopoulos | |
1063 | bc055d09 | Constantinos Venetsanopoulos | To upload, register or modify an image you will need the **kamaki** tool. |
1064 | bc055d09 | Constantinos Venetsanopoulos | Before proceeding make sure that it is configured properly. Verify that |
1065 | dd04efac | Stavros Sachtouris | *image.url*, *file.url*, *user.url* and *token* are set as needed: |
1066 | bc055d09 | Constantinos Venetsanopoulos | |
1067 | bc055d09 | Constantinos Venetsanopoulos | .. code-block:: console |
1068 | bc055d09 | Constantinos Venetsanopoulos | |
1069 | bc055d09 | Constantinos Venetsanopoulos | $ kamaki config list |
1070 | bc055d09 | Constantinos Venetsanopoulos | |
1071 | 73ebcd68 | Constantinos Venetsanopoulos | To change a setting use ``kamaki config set``: |
1072 | bc055d09 | Constantinos Venetsanopoulos | |
1073 | bc055d09 | Constantinos Venetsanopoulos | .. code-block:: console |
1074 | bc055d09 | Constantinos Venetsanopoulos | |
1075 | 73ebcd68 | Constantinos Venetsanopoulos | $ kamaki config set image.url https://cyclades.example.com/image |
1076 | dd04efac | Stavros Sachtouris | $ kamaki config set file.url https://pithos.example.com/v1 |
1077 | dd04efac | Stavros Sachtouris | $ kamaki config set user.url https://accounts.example.com |
1078 | bc055d09 | Constantinos Venetsanopoulos | $ kamaki config set token ... |
1079 | bc055d09 | Constantinos Venetsanopoulos | |
1080 | c0d88cf3 | Constantinos Venetsanopoulos | To test that everything works, try authenticating the current account with |
1081 | c0d88cf3 | Constantinos Venetsanopoulos | kamaki: |
1082 | dd04efac | Stavros Sachtouris | |
1083 | dd04efac | Stavros Sachtouris | .. code-block:: console |
1084 | dd04efac | Stavros Sachtouris | |
1085 | dd04efac | Stavros Sachtouris | $ kamaki user authenticate |
1086 | dd04efac | Stavros Sachtouris | |
1087 | c0d88cf3 | Constantinos Venetsanopoulos | This will output user information. |
1088 | dd04efac | Stavros Sachtouris | |
1089 | bc055d09 | Constantinos Venetsanopoulos | Upload Image |
1090 | bc055d09 | Constantinos Venetsanopoulos | ------------ |
1091 | bc055d09 | Constantinos Venetsanopoulos | |
1092 | c0d88cf3 | Constantinos Venetsanopoulos | By convention, images are stored in a container called ``images``. Check if the |
1093 | c0d88cf3 | Constantinos Venetsanopoulos | container exists, by listing all containers in your account: |
1094 | bc055d09 | Constantinos Venetsanopoulos | |
1095 | bc055d09 | Constantinos Venetsanopoulos | .. code-block:: console |
1096 | bc055d09 | Constantinos Venetsanopoulos | |
1097 | dd04efac | Stavros Sachtouris | $ kamaki file list |
1098 | bc055d09 | Constantinos Venetsanopoulos | |
1099 | dd04efac | Stavros Sachtouris | If the container ``images`` does not exist, create it: |
1100 | bc055d09 | Constantinos Venetsanopoulos | |
1101 | bc055d09 | Constantinos Venetsanopoulos | .. code-block:: console |
1102 | bc055d09 | Constantinos Venetsanopoulos | |
1103 | dd04efac | Stavros Sachtouris | $ kamaki file create images |
1104 | bc055d09 | Constantinos Venetsanopoulos | |
1105 | c0d88cf3 | Constantinos Venetsanopoulos | You are now ready to upload an image to container ``images``. You can upload it |
1106 | e5d8df8c | Constantinos Venetsanopoulos | with a Pithos client, or use kamaki directly: |
1107 | bc055d09 | Constantinos Venetsanopoulos | |
1108 | bc055d09 | Constantinos Venetsanopoulos | .. code-block:: console |
1109 | bc055d09 | Constantinos Venetsanopoulos | |
1110 | dd04efac | Stavros Sachtouris | $ kamaki file upload ubuntu.iso images |
1111 | bc055d09 | Constantinos Venetsanopoulos | |
1112 | e5d8df8c | Constantinos Venetsanopoulos | You can use any Pithos client to verify that the image was uploaded correctly, |
1113 | c0d88cf3 | Constantinos Venetsanopoulos | or you can list the contents of the container with kamaki: |
1114 | bc055d09 | Constantinos Venetsanopoulos | |
1115 | dd04efac | Stavros Sachtouris | .. code-block:: console |
1116 | dd04efac | Stavros Sachtouris | |
1117 | dd04efac | Stavros Sachtouris | $ kamaki file list images |
1118 | bc055d09 | Constantinos Venetsanopoulos | |
1119 | bc055d09 | Constantinos Venetsanopoulos | The full Pithos URL for the previous example will be |
1120 | c0d88cf3 | Constantinos Venetsanopoulos | ``pithos://u53r-un1qu3-1d/images/ubuntu.iso`` where ``u53r-un1qu3-1d`` is the |
1121 | c0d88cf3 | Constantinos Venetsanopoulos | unique user id (uuid). |
1122 | bc055d09 | Constantinos Venetsanopoulos | |
1123 | bc055d09 | Constantinos Venetsanopoulos | Register Image |
1124 | bc055d09 | Constantinos Venetsanopoulos | -------------- |
1125 | bc055d09 | Constantinos Venetsanopoulos | |
1126 | e5d8df8c | Constantinos Venetsanopoulos | To register an image you will need to use the full Pithos URL. To register as |
1127 | bc055d09 | Constantinos Venetsanopoulos | a public image the one from the previous example use: |
1128 | bc055d09 | Constantinos Venetsanopoulos | |
1129 | bc055d09 | Constantinos Venetsanopoulos | .. code-block:: console |
1130 | bc055d09 | Constantinos Venetsanopoulos | |
1131 | dd04efac | Stavros Sachtouris | $ kamaki image register Ubuntu pithos://u53r-un1qu3-1d/images/ubuntu.iso --public |
1132 | bc055d09 | Constantinos Venetsanopoulos | |
1133 | bc055d09 | Constantinos Venetsanopoulos | The ``--public`` flag is important, if missing the registered image will not |
1134 | dd04efac | Stavros Sachtouris | be listed by ``kamaki image list``. |
1135 | bc055d09 | Constantinos Venetsanopoulos | |
1136 | dd04efac | Stavros Sachtouris | Use ``kamaki image register`` with no arguments to see a list of available |
1137 | bc055d09 | Constantinos Venetsanopoulos | options. A more complete example would be the following: |
1138 | bc055d09 | Constantinos Venetsanopoulos | |
1139 | bc055d09 | Constantinos Venetsanopoulos | .. code-block:: console |
1140 | bc055d09 | Constantinos Venetsanopoulos | |
1141 | dd04efac | Stavros Sachtouris | $ kamaki image register Ubuntu pithos://u53r-un1qu3-1d/images/ubuntu.iso \ |
1142 | bc055d09 | Constantinos Venetsanopoulos | --public --disk-format diskdump --property kernel=3.1.2 |
1143 | bc055d09 | Constantinos Venetsanopoulos | |
1144 | bc055d09 | Constantinos Venetsanopoulos | To verify that the image was registered successfully use: |
1145 | bc055d09 | Constantinos Venetsanopoulos | |
1146 | bc055d09 | Constantinos Venetsanopoulos | .. code-block:: console |
1147 | bc055d09 | Constantinos Venetsanopoulos | |
1148 | dd04efac | Stavros Sachtouris | $ kamaki image list --name-like=ubuntu |
1149 | bc055d09 | Constantinos Venetsanopoulos | |
1150 | eab73849 | Constantinos Venetsanopoulos | |
1151 | eab73849 | Constantinos Venetsanopoulos | Miscellaneous |
1152 | eab73849 | Constantinos Venetsanopoulos | ============= |
1153 | eab73849 | Constantinos Venetsanopoulos | |
1154 | 08ad5b01 | Constantinos Venetsanopoulos | .. _branding: |
1155 | 9c2edbf1 | Olga Brani | |
1156 | 42e767d4 | Olga Brani | Branding |
1157 | 08ad5b01 | Constantinos Venetsanopoulos | -------- |
1158 | 9c2edbf1 | Olga Brani | |
1159 | 08ad5b01 | Constantinos Venetsanopoulos | Since Synnefo v0.14, you are able to adapt the Astakos, Pithos and Cyclades Web |
1160 | 08ad5b01 | Constantinos Venetsanopoulos | UI to your company’s visual identity. This is possible using the snf-branding |
1161 | 08ad5b01 | Constantinos Venetsanopoulos | component, which is automatically installed on the nodes running the API |
1162 | 08ad5b01 | Constantinos Venetsanopoulos | servers for Astakos, Pithos and Cyclades. |
1163 | 9c2edbf1 | Olga Brani | |
1164 | 9c2edbf1 | Olga Brani | Configuration |
1165 | 9c2edbf1 | Olga Brani | ~~~~~~~~~~~~~ |
1166 | 9c2edbf1 | Olga Brani | |
1167 | 77186edf | Kostas Papadimitriou | This can be done by modifing the settings provided by the snf-branding component |
1168 | 77186edf | Kostas Papadimitriou | to match your service identity. The settings for the snf-branding application |
1169 | 77186edf | Kostas Papadimitriou | can be found inside the configuration file ``/etc/synnefo/15-snf-branding.conf`` |
1170 | 77186edf | Kostas Papadimitriou | on the nodes that have Astakos, Pithos and Cyclades installed. |
1171 | 9c2edbf1 | Olga Brani | |
1172 | 08ad5b01 | Constantinos Venetsanopoulos | By default, the global service name is "Synnefo" and the company name is |
1173 | 08ad5b01 | Constantinos Venetsanopoulos | "GRNET". These names and their respective logos and URLs are used throughout |
1174 | 08ad5b01 | Constantinos Venetsanopoulos | the Astakos, Pithos and Cyclades UI. |
1175 | 9c2edbf1 | Olga Brani | |
1176 | 08ad5b01 | Constantinos Venetsanopoulos | **Names and URLs:** |
1177 | 9c2edbf1 | Olga Brani | |
1178 | 08ad5b01 | Constantinos Venetsanopoulos | The first group of branding customization refers to the service's and company's |
1179 | 08ad5b01 | Constantinos Venetsanopoulos | information. |
1180 | 9c2edbf1 | Olga Brani | |
1181 | 08ad5b01 | Constantinos Venetsanopoulos | You can overwrite the company and the service name and URL respectively by |
1182 | 08ad5b01 | Constantinos Venetsanopoulos | uncommenting and setting the following: |
1183 | 9c2edbf1 | Olga Brani | |
1184 | 77186edf | Kostas Papadimitriou | .. code-block:: python |
1185 | 77186edf | Kostas Papadimitriou | |
1186 | 77186edf | Kostas Papadimitriou | # setting used in Astakos Dashboard/Projects pages |
1187 | 77186edf | Kostas Papadimitriou | BRANDING_SERVICE_NAME = 'My cloud' |
1188 | 77186edf | Kostas Papadimitriou | BRANDING_SERVICE_URL = 'http://www.mycloud.synnefo.org/' |
1189 | 9c2edbf1 | Olga Brani | |
1190 | 77186edf | Kostas Papadimitriou | # settings used in Astakos, Pithos, Cyclades footer only if |
1191 | 77186edf | Kostas Papadimitriou | # BRANDING_SHOW_COPYRIGHT is set to True |
1192 | 77186edf | Kostas Papadimitriou | BRANDING_SHOW_COPYRIGHT = True |
1193 | 77186edf | Kostas Papadimitriou | BRANDING_COMPANY_NAME = 'Company LTD' |
1194 | 77186edf | Kostas Papadimitriou | BRANDING_COMPANY_URL = 'https://www.company-ltd.synnefo.org/' |
1195 | 9c2edbf1 | Olga Brani | |
1196 | 9c2edbf1 | Olga Brani | |
1197 | 97a096f1 | Olga Brani | **Copyright and footer options:** |
1198 | 9c2edbf1 | Olga Brani | |
1199 | 08ad5b01 | Constantinos Venetsanopoulos | By default, no Copyright message is shown in the UI footer. If you want to make |
1200 | 08ad5b01 | Constantinos Venetsanopoulos | it visible in the footer of Astakos, Pithos and Cyclades UI, you can uncomment |
1201 | 77186edf | Kostas Papadimitriou | and set to ``True`` the ``BRANDING_SHOW_COPYRIGHT`` setting: |
1202 | 9c2edbf1 | Olga Brani | |
1203 | 77186edf | Kostas Papadimitriou | .. code-block:: python |
1204 | 9c2edbf1 | Olga Brani | |
1205 | 9c2edbf1 | Olga Brani | #BRANDING_SHOW_COPYRIGHT = False |
1206 | 9c2edbf1 | Olga Brani | |
1207 | 77186edf | Kostas Papadimitriou | Copyright message defaults to 'Copyright (c) 2011-<current_year> |
1208 | 08ad5b01 | Constantinos Venetsanopoulos | <BRANDING_COMPANY_NAME>.' but you can overwrite it to a completely custom one by |
1209 | 08ad5b01 | Constantinos Venetsanopoulos | setting the following option: |
1210 | 9c2edbf1 | Olga Brani | |
1211 | 77186edf | Kostas Papadimitriou | .. code-block:: python |
1212 | 77186edf | Kostas Papadimitriou | |
1213 | 77186edf | Kostas Papadimitriou | BRANDING_COPYRIGHT_MESSAGE = 'Copyright (c) 2011-2013 GRNET' |
1214 | 9c2edbf1 | Olga Brani | |
1215 | 97a096f1 | Olga Brani | If you want to include a custom message in the footer, you can uncomment and |
1216 | 97a096f1 | Olga Brani | set the ``BRANDING_FOOTER_EXTRA_MESSAGE`` setting. You can use html markup. |
1217 | 97a096f1 | Olga Brani | Your custom message will appear above Copyright message at the Compute |
1218 | 97a096f1 | Olga Brani | templates and the Dashboard UI. |
1219 | 97a096f1 | Olga Brani | |
1220 | 97a096f1 | Olga Brani | .. code-block:: python |
1221 | 97a096f1 | Olga Brani | |
1222 | 97a096f1 | Olga Brani | #BRANDING_FOOTER_EXTRA_MESSAGE = '' |
1223 | 97a096f1 | Olga Brani | |
1224 | 9c2edbf1 | Olga Brani | |
1225 | 9c2edbf1 | Olga Brani | **Images:** |
1226 | 9c2edbf1 | Olga Brani | |
1227 | 08ad5b01 | Constantinos Venetsanopoulos | The Astakos, Pithos and Cyclades Web UI has some logos and images. |
1228 | 08ad5b01 | Constantinos Venetsanopoulos | |
1229 | 9c2edbf1 | Olga Brani | The branding-related images are presented in the following table: |
1230 | 9c2edbf1 | Olga Brani | |
1231 | 9c2edbf1 | Olga Brani | =============== ============================ ========= |
1232 | 9c2edbf1 | Olga Brani | Image Name/extension convention Usage |
1233 | 9c2edbf1 | Olga Brani | =============== ============================ ========= |
1234 | 9c2edbf1 | Olga Brani | Favicon favicon.ico Favicon for all services |
1235 | 9c2edbf1 | Olga Brani | Dashboard logo dashboard_logo.png Visible in all Astakos UI pages |
1236 | 9c2edbf1 | Olga Brani | Compute logo compute_logo.png Visible in all Cyclades UI pages |
1237 | 08ad5b01 | Constantinos Venetsanopoulos | Console logo console_logo.png Visible in the Cyclades Console Window |
1238 | 08ad5b01 | Constantinos Venetsanopoulos | Storage logo storage_logo.png Visible in all Pithos UI pages |
1239 | 9c2edbf1 | Olga Brani | =============== ============================ ========= |
1240 | 9c2edbf1 | Olga Brani | |
1241 | 08ad5b01 | Constantinos Venetsanopoulos | There are two methods available for replacing all, or individual, |
1242 | 263cb456 | Olga Brani | branding-related images: |
1243 | 9c2edbf1 | Olga Brani | |
1244 | 77186edf | Kostas Papadimitriou | 1. Create a new directory inside ``/usr/share/synnefo/static/`` (e.g. |
1245 | 77186edf | Kostas Papadimitriou | ``mybranding``) and place there some or all of your images. |
1246 | 9c2edbf1 | Olga Brani | |
1247 | 08ad5b01 | Constantinos Venetsanopoulos | If you want to replace all of your images, keep the name/extension |
1248 | 77186edf | Kostas Papadimitriou | conventions as indicated in the above table and change the |
1249 | 77186edf | Kostas Papadimitriou | ``BRANDING_IMAGE_MEDIA_URL`` setting accordingly: |
1250 | 9c2edbf1 | Olga Brani | |
1251 | 77186edf | Kostas Papadimitriou | .. code-block:: python |
1252 | 77186edf | Kostas Papadimitriou | |
1253 | 77186edf | Kostas Papadimitriou | # using relative path |
1254 | 77186edf | Kostas Papadimitriou | BRANDING_IMAGE_MEDIA_URL= '/static/mybranding/images/' |
1255 | 9c2edbf1 | Olga Brani | |
1256 | 77186edf | Kostas Papadimitriou | # or if you already host them in a separate domain (e.g. cdn) |
1257 | 77186edf | Kostas Papadimitriou | BRANDING_IMAGE_MEDIA_URL= 'https://cdn.synnefo.org/branding/images/' |
1258 | 9c2edbf1 | Olga Brani | |
1259 | 9c2edbf1 | Olga Brani | |
1260 | 08ad5b01 | Constantinos Venetsanopoulos | If you wish to replace individual images, **do not uncomment** |
1261 | 08ad5b01 | Constantinos Venetsanopoulos | ``BRANDING_IMAGE_MEDIA_URL``, but instead provide a relative path, pointing to |
1262 | 08ad5b01 | Constantinos Venetsanopoulos | the file inside your directory for each ``BRANDING_<image>_URL`` that you wish |
1263 | 08ad5b01 | Constantinos Venetsanopoulos | to replace. |
1264 | 9c2edbf1 | Olga Brani | |
1265 | 263cb456 | Olga Brani | 2. Upload some or all of your images to a server and replace each |
1266 | 08ad5b01 | Constantinos Venetsanopoulos | ``BRANDING_<image>_URL`` with the absolute url of the image (i.e. |
1267 | 77186edf | Kostas Papadimitriou | ``BRANDING_DASHBOARD_URL = 'https://www.synnefo.com/images/my_dashboard.jpg'``). |
1268 | 9c2edbf1 | Olga Brani | |
1269 | 77186edf | Kostas Papadimitriou | Note that the alternative text for each image tag inside html documents is |
1270 | 08ad5b01 | Constantinos Venetsanopoulos | alt=“BRANDING_SERVICE_NAME {Dashboard, Compute. Console, Storage}” respectively. |
1271 | 9c2edbf1 | Olga Brani | |
1272 | 42e767d4 | Olga Brani | .. note:: Retina optimized images: |
1273 | 9c2edbf1 | Olga Brani | |
1274 | 08ad5b01 | Constantinos Venetsanopoulos | Synnefo UI is optimized for Retina displays. As far as images are concerned, |
1275 | 08ad5b01 | Constantinos Venetsanopoulos | `retina.js <http://retinajs.com/>`_ is used. |
1276 | 9c2edbf1 | Olga Brani | |
1277 | 77186edf | Kostas Papadimitriou | Retina.js checks each image on a page to see if there is a high-resolution |
1278 | 08ad5b01 | Constantinos Venetsanopoulos | version of that image on your server. If a high-resolution variant exists, |
1279 | 08ad5b01 | Constantinos Venetsanopoulos | the script will swap in that image in-place. |
1280 | 9c2edbf1 | Olga Brani | |
1281 | 08ad5b01 | Constantinos Venetsanopoulos | The script assumes you use `Apple's prescribed high-resolution modifier (@2x) |
1282 | 08ad5b01 | Constantinos Venetsanopoulos | <http://developer.apple.com/library/ios/#documentation/2DDrawing/Conceptual/ |
1283 | 08ad5b01 | Constantinos Venetsanopoulos | DrawingPrintingiOS/SupportingHiResScreensInViews/SupportingHiResScreensInViews |
1284 | 08ad5b01 | Constantinos Venetsanopoulos | .html#//apple_ref/doc/uid/TP40010156-CH15-SW1>`_ to denote high-resolution |
1285 | 08ad5b01 | Constantinos Venetsanopoulos | image variants on your server. |
1286 | 9c2edbf1 | Olga Brani | |
1287 | 08ad5b01 | Constantinos Venetsanopoulos | For each of the images that you wish the script to replace, you must have a |
1288 | 08ad5b01 | Constantinos Venetsanopoulos | high-resolution variant in the same folder named correctly and it will be |
1289 | 08ad5b01 | Constantinos Venetsanopoulos | detected automatically. For example if your image is in <my_directory> and is |
1290 | 08ad5b01 | Constantinos Venetsanopoulos | named "my_image.jpg" the script will look in the same directory for an image |
1291 | 08ad5b01 | Constantinos Venetsanopoulos | named "my_image@2x.jpg". |
1292 | 9c2edbf1 | Olga Brani | |
1293 | 08ad5b01 | Constantinos Venetsanopoulos | In case that you don’t want to use a high-resolution image, the |
1294 | 08ad5b01 | Constantinos Venetsanopoulos | normal-resolution image will be visible. |
1295 | 9c2edbf1 | Olga Brani | |
1296 | 08ad5b01 | Constantinos Venetsanopoulos | More branding |
1297 | 08ad5b01 | Constantinos Venetsanopoulos | ~~~~~~~~~~~~~ |
1298 | 9c2edbf1 | Olga Brani | |
1299 | 08ad5b01 | Constantinos Venetsanopoulos | Although, it is not 100% branding-related, further verbal customization is |
1300 | 08ad5b01 | Constantinos Venetsanopoulos | feasible. |
1301 | 9c2edbf1 | Olga Brani | |
1302 | 9c2edbf1 | Olga Brani | **EMAILS** |
1303 | 9c2edbf1 | Olga Brani | |
1304 | 77186edf | Kostas Papadimitriou | The output of all email `*`.txt files will be already customized to contain your |
1305 | 77186edf | Kostas Papadimitriou | company and service names but you can further alter their content if you feel it |
1306 | 77186edf | Kostas Papadimitriou | best fits your needs as simple as creasynnefo template. |
1307 | 017b7d20 | Olga Brani | |
1308 | 77186edf | Kostas Papadimitriou | In order to overwrite one or more email-templates you need to place your |
1309 | 77186edf | Kostas Papadimitriou | modified <email-file>.txt files respecting the following structure: |
1310 | 017b7d20 | Olga Brani | |
1311 | 77186edf | Kostas Papadimitriou | **/etc/synnefo/templates/** |
1312 | 77186edf | Kostas Papadimitriou | **im/** |
1313 | 017b7d20 | Olga Brani | | activation_email.txt |
1314 | 017b7d20 | Olga Brani | | email.txt |
1315 | 017b7d20 | Olga Brani | | invitation.txt |
1316 | 017b7d20 | Olga Brani | | switch_accounts_email.txt |
1317 | 017b7d20 | Olga Brani | | welcome_email.txt |
1318 | 77186edf | Kostas Papadimitriou | **projects/** |
1319 | 017b7d20 | Olga Brani | | project_approval_notification.txt |
1320 | 017b7d20 | Olga Brani | | project_denial_notification.txt |
1321 | 017b7d20 | Olga Brani | | project_membership_change_notification.txt |
1322 | 017b7d20 | Olga Brani | | project_membership_enroll_notification.txt |
1323 | 017b7d20 | Olga Brani | | project_membership_leave_request_notification.txt |
1324 | 017b7d20 | Olga Brani | | project_membership_request_notification.txt |
1325 | 017b7d20 | Olga Brani | | project_suspension_notification.txt |
1326 | 017b7d20 | Olga Brani | | project_termination_notification.txt |
1327 | 77186edf | Kostas Papadimitriou | **registration/** |
1328 | 017b7d20 | Olga Brani | | email_change_email.txt |
1329 | 017b7d20 | Olga Brani | | password_email.txt |
1330 | 017b7d20 | Olga Brani | |
1331 | 017b7d20 | Olga Brani | Feel free to omit any of the above files you do not wish to overwrite. |
1332 | 017b7d20 | Olga Brani | |
1333 | 9c2edbf1 | Olga Brani | Below is a list of all emails sent by Synnefo to users along with a short |
1334 | 9c2edbf1 | Olga Brani | description and a link to their content: |
1335 | 9c2edbf1 | Olga Brani | |
1336 | 08ad5b01 | Constantinos Venetsanopoulos | * ``snf-astakos-app/astakos/im/templates/im/email.txt`` |
1337 | 08ad5b01 | Constantinos Venetsanopoulos | Base email template. Contains a contact email and a “thank you” message. |
1338 | 08ad5b01 | Constantinos Venetsanopoulos | (`Link <https://code.grnet.gr/projects/synnefo/repository/revisions/master/changes/snf-astakos-app/astakos/im/templates/im/email.txt>`_) |
1339 | 08ad5b01 | Constantinos Venetsanopoulos | * ``snf-astakos-app/astakos/im/templates/im/activation_email.txt`` Email sent to |
1340 | 08ad5b01 | Constantinos Venetsanopoulos | user that prompts him/her to click on a link provided to activate the account. |
1341 | 08ad5b01 | Constantinos Venetsanopoulos | Extends “email.txt” (`Link <https://code.grnet.gr/projects/synnefo/repository/revisions/master/changes/snf-astakos-app/astakos/im/templates/im/activation_email.txt>`_) |
1342 | 08ad5b01 | Constantinos Venetsanopoulos | * ``snf-astakos-app/astakos/im/templates/im/invitation.txt`` Email sent to an |
1343 | 08ad5b01 | Constantinos Venetsanopoulos | invited user. He/she has to click on a link provided to activate the account. |
1344 | 08ad5b01 | Constantinos Venetsanopoulos | Extends “email.txt” (`Link <https://code.grnet.gr/projects/synnefo/repository/revisions/master/changes/snf-astakos-app/astakos/im/templates/im/invitation.txt>`_) |
1345 | 08ad5b01 | Constantinos Venetsanopoulos | * ``snf-astakos-app/astakos/im/templates/im/switch_accounts_email.txt`` Email |
1346 | 08ad5b01 | Constantinos Venetsanopoulos | sent to user upon his/her request to associate this email address with a |
1347 | 08ad5b01 | Constantinos Venetsanopoulos | shibboleth account. He/she has to click on a link provided to activate the |
1348 | 08ad5b01 | Constantinos Venetsanopoulos | association. Extends “email.txt” (`Link <https://code.grnet.gr/projects/synnefo/repository/revisions/master/changes/snf-astakos-app/astakos/im/templates/im/switch_accounts_email.txt>`_) |
1349 | 08ad5b01 | Constantinos Venetsanopoulos | * ``snf-astakos-app/astakos/im/templates/im/welcome_email.txt`` Email sent to |
1350 | 08ad5b01 | Constantinos Venetsanopoulos | inform the user that his/ her account has been activated. Extends “email.txt” |
1351 | 08ad5b01 | Constantinos Venetsanopoulos | (`Link <https://code.grnet.gr/projects/synnefo/repository/revisions/master/changes/snf-astakos-app/astakos/im/templates/im/welcome_email.txt>`_) |
1352 | 08ad5b01 | Constantinos Venetsanopoulos | * ``snf-astakos-app/astakos/im/templates/registration/email_change_email.txt`` |
1353 | 08ad5b01 | Constantinos Venetsanopoulos | Email sent to user when he/she has requested new email address assignment. The |
1354 | 08ad5b01 | Constantinos Venetsanopoulos | user has to click on a link provided to validate this action. Extends |
1355 | 08ad5b01 | Constantinos Venetsanopoulos | “email.txt” (`Link <https://code.grnet.gr/projects/synnefo/repository/revisions/master/changes/snf-astakos-app/astakos/im/templates/registration/email_change_email.txt>`_) |
1356 | 08ad5b01 | Constantinos Venetsanopoulos | * ``snf-astakos-app/astakos/im/templates/registration/password_email.txt`` Email |
1357 | 08ad5b01 | Constantinos Venetsanopoulos | sent for resetting password purpose. The user has to click on a link provided |
1358 | 08ad5b01 | Constantinos Venetsanopoulos | to validate this action. Extends “email.txt” (`Link <https://code.grnet.gr/projects/synnefo/repository/revisions/master/changes/snf-astakos-app/astakos/im/templates/registration/password_email.txt>`_) |
1359 | 08ad5b01 | Constantinos Venetsanopoulos | * ``snf-astakos-app/astakos/im/templates/im/projects/project_approval_notification.txt`` |
1360 | 08ad5b01 | Constantinos Venetsanopoulos | Informs the project owner that his/her project has been approved. Extends |
1361 | 08ad5b01 | Constantinos Venetsanopoulos | “email.txt” (`Link <https://code.grnet.gr/projects/synnefo/repository/revisions/master/changes/snf-astakos-app/astakos/im/templates/im/projects/project_approval_notification.txt>`_) |
1362 | 08ad5b01 | Constantinos Venetsanopoulos | * ``snf-astakos-app/astakos/im/templates/im/projects/project_denial_notification.txt`` |
1363 | 08ad5b01 | Constantinos Venetsanopoulos | Informs the project owner that his/her project application has been denied |
1364 | 08ad5b01 | Constantinos Venetsanopoulos | explaining the reasons. Extends “email.txt” (`Link <https://code.grnet.gr/projects/synnefo/repository/revisions/master/changes/snf-astakos-app/astakos/im/templates/im/projects/project_denial_notification.txt>`_) |
1365 | 08ad5b01 | Constantinos Venetsanopoulos | * ``snf-astakos-app/astakos/im/templates/im/projects/project_membership_change_notification.txt`` |
1366 | 08ad5b01 | Constantinos Venetsanopoulos | An email is sent to a user containing information about his project membership |
1367 | 08ad5b01 | Constantinos Venetsanopoulos | (whether he has been accepted, rejected or removed). Extends “email.txt” (`Link |
1368 | 08ad5b01 | Constantinos Venetsanopoulos | <https://code.grnet.gr/projects/synnefo/repository/revisions/master/changes/snf-astakos-app/astakos/im/templates/im/projects/project_membership_change_notification.txt>`_) |
1369 | 08ad5b01 | Constantinos Venetsanopoulos | * ``snf-astakos-app/astakos/im/templates/im/projects/project_membership_enroll_notification.txt`` |
1370 | 08ad5b01 | Constantinos Venetsanopoulos | Informs a user that he/she has been enrolled to a project. Extends |
1371 | 08ad5b01 | Constantinos Venetsanopoulos | “email.txt” (`Link <https://code.grnet.gr/projects/synnefo/repository/revisions/master/changes/snf-astakos-app/astakos/im/templates/im/projects/project_membership_enroll_notification.txt>`_) |
1372 | 08ad5b01 | Constantinos Venetsanopoulos | * ``snf-astakos-app/astakos/im/templates/im/projects/project_membership_leave_request_notification.txt`` |
1373 | 08ad5b01 | Constantinos Venetsanopoulos | An email is sent to the project owner to make him aware of a user having |
1374 | 08ad5b01 | Constantinos Venetsanopoulos | requested to leave his project. Extends “email.txt” (`Link <https://code.grnet.gr/projects/synnefo/repository/revisions/master/changes/snf-astakos-app/astakos/im/templates/im/projects/project_membership_leave_request_notification.txt>`_) |
1375 | 08ad5b01 | Constantinos Venetsanopoulos | * ``snf-astakos-app/astakos/im/templates/im/projects/project_membership_request_notification.txt`` |
1376 | 08ad5b01 | Constantinos Venetsanopoulos | An email is sent to the project owner to make him/her aware of a user having |
1377 | 08ad5b01 | Constantinos Venetsanopoulos | requested to join his project. Extends “email.txt” (`Link <https://code.grnet.gr/projects/synnefo/repository/revisions/master/changes/snf-astakos-app/astakos/im/templates/im/projects/project_membership_request_notification.txt>`_) |
1378 | 08ad5b01 | Constantinos Venetsanopoulos | * ``snf-astakos-app/astakos/im/templates/im/projects/project_suspension_notification.txt`` |
1379 | 08ad5b01 | Constantinos Venetsanopoulos | An email is sent to the project owner to make him/her aware of his/her project |
1380 | 08ad5b01 | Constantinos Venetsanopoulos | having been suspended. Extends “email.txt” (`Link <https://code.grnet.gr/projects/synnefo/repository/revisions/master/changes/snf-astakos-app/astakos/im/templates/im/projects/project_suspension_notification.txt>`_) |
1381 | 08ad5b01 | Constantinos Venetsanopoulos | * ``snf-astakos-app/astakos/im/templates/im/projects/project_termination_notification.txt`` |
1382 | 08ad5b01 | Constantinos Venetsanopoulos | An email is sent to the project owner to make him/her aware of his/her project |
1383 | 08ad5b01 | Constantinos Venetsanopoulos | having been terminated. Extends “email.txt” (`Link <https://code.grnet.gr/projects/synnefo/repository/revisions/master/changes/snf-astakos-app/astakos/im/templates/im/projects/project_termination_notification.txt>`_) |
1384 | 9c2edbf1 | Olga Brani | |
1385 | 9c2edbf1 | Olga Brani | .. warning:: Django templates language: |
1386 | 9c2edbf1 | Olga Brani | |
1387 | 9c2edbf1 | Olga Brani | If you choose to overwrite these email templates, be mindful of the necessary |
1388 | 263cb456 | Olga Brani | information contained in django template variables that must not be omitted, |
1389 | 263cb456 | Olga Brani | such as the activation link for activating one’s account and many more. |
1390 | 263cb456 | Olga Brani | These variables are contained into {{}} inside the templates. |
1391 | 9c2edbf1 | Olga Brani | |
1392 | 9c2edbf1 | Olga Brani | |
1393 | 9b659162 | Christos Stavrakakis | .. RabbitMQ |
1394 | a1c707c9 | Constantinos Venetsanopoulos | |
1395 | 9b659162 | Christos Stavrakakis | RabbitMQ Broker |
1396 | 9b659162 | Christos Stavrakakis | --------------- |
1397 | 9b659162 | Christos Stavrakakis | |
1398 | 9b659162 | Christos Stavrakakis | Queue nodes run the RabbitMQ sofware, which provides AMQP functionality. To |
1399 | 9b659162 | Christos Stavrakakis | guarantee high-availability, more than one Queue nodes should be deployed, each |
1400 | 9b659162 | Christos Stavrakakis | of them belonging to the same `RabbitMQ cluster |
1401 | a1c707c9 | Constantinos Venetsanopoulos | <http://www.rabbitmq.com/clustering.html>`_. Synnefo uses the RabbitMQ |
1402 | a1c707c9 | Constantinos Venetsanopoulos | active/active `High Available Queues <http://www.rabbitmq.com/ha.html>`_ which |
1403 | a1c707c9 | Constantinos Venetsanopoulos | are mirrored between two nodes within a RabbitMQ cluster. |
1404 | a1c707c9 | Constantinos Venetsanopoulos | |
1405 | a1c707c9 | Constantinos Venetsanopoulos | The RabbitMQ nodes that form the cluster, are declared to Synnefo through the |
1406 | a1c707c9 | Constantinos Venetsanopoulos | `AMQP_HOSTS` setting. Each time a Synnefo component needs to connect to |
1407 | a1c707c9 | Constantinos Venetsanopoulos | RabbitMQ, one of these nodes is chosen in a random way. The client that Synnefo |
1408 | a1c707c9 | Constantinos Venetsanopoulos | uses to connect to RabbitMQ, handles connection failures transparently and |
1409 | a1c707c9 | Constantinos Venetsanopoulos | tries to reconnect to a different node. As long as one of these nodes are up |
1410 | a1c707c9 | Constantinos Venetsanopoulos | and running, functionality of Synnefo should not be downgraded by the RabbitMQ |
1411 | a1c707c9 | Constantinos Venetsanopoulos | node failures. |
1412 | 9b659162 | Christos Stavrakakis | |
1413 | 9b659162 | Christos Stavrakakis | All the queues that are being used are declared as durable, meaning that |
1414 | a1c707c9 | Constantinos Venetsanopoulos | messages are persistently stored to RabbitMQ, until they get successfully |
1415 | a1c707c9 | Constantinos Venetsanopoulos | processed by a client. |
1416 | 9b659162 | Christos Stavrakakis | |
1417 | 9b659162 | Christos Stavrakakis | Currently, RabbitMQ is used by the following components: |
1418 | 9b659162 | Christos Stavrakakis | |
1419 | 5135245b | Christos Stavrakakis | * `snf-ganeti-eventd` and `snf-progress-monitor`: |
1420 | 9b659162 | Christos Stavrakakis | These components send messages concerning the status and progress of |
1421 | 9b659162 | Christos Stavrakakis | jobs in the Ganeti backend. |
1422 | a1c707c9 | Constantinos Venetsanopoulos | * `snf-dispatcher`: This daemon, consumes the messages that are sent from |
1423 | a1c707c9 | Constantinos Venetsanopoulos | the above components, and updates the Cyclades DB accordingly. |
1424 | 9b659162 | Christos Stavrakakis | |
1425 | e4404297 | Christos Stavrakakis | |
1426 | 9b659162 | Christos Stavrakakis | Installation |
1427 | 301294a9 | Constantinos Venetsanopoulos | ~~~~~~~~~~~~ |
1428 | 301294a9 | Constantinos Venetsanopoulos | |
1429 | a1c707c9 | Constantinos Venetsanopoulos | Please check the RabbitMQ documentation which covers extensively the |
1430 | a1c707c9 | Constantinos Venetsanopoulos | `installation of RabbitMQ server <http://www.rabbitmq.com/download.html>`_ and |
1431 | a1c707c9 | Constantinos Venetsanopoulos | the setup of a `RabbitMQ cluster <http://www.rabbitmq.com/clustering.html>`_. |
1432 | a1c707c9 | Constantinos Venetsanopoulos | Also, check out the `web management plugin |
1433 | a1c707c9 | Constantinos Venetsanopoulos | <http://www.rabbitmq.com/management.html>`_ that can be useful for managing and |
1434 | a1c707c9 | Constantinos Venetsanopoulos | monitoring RabbitMQ. |
1435 | 9b659162 | Christos Stavrakakis | |
1436 | 9b659162 | Christos Stavrakakis | For a basic installation of RabbitMQ on two nodes (node1 and node2) you can do |
1437 | a1c707c9 | Constantinos Venetsanopoulos | the following: |
1438 | 9b659162 | Christos Stavrakakis | |
1439 | a1c707c9 | Constantinos Venetsanopoulos | On both nodes, install rabbitmq-server and create a Synnefo user: |
1440 | 9b659162 | Christos Stavrakakis | |
1441 | 9b659162 | Christos Stavrakakis | .. code-block:: console |
1442 | 9b659162 | Christos Stavrakakis | |
1443 | 9b659162 | Christos Stavrakakis | $ apt-get install rabbitmq-server |
1444 | 9b659162 | Christos Stavrakakis | $ rabbitmqctl add_user synnefo "example_pass" |
1445 | 9b659162 | Christos Stavrakakis | $ rabbitmqctl set_permissions synnefo ".*" ".*" ".*" |
1446 | 9b659162 | Christos Stavrakakis | |
1447 | a1c707c9 | Constantinos Venetsanopoulos | Also guarantee that both nodes share the same cookie, by running: |
1448 | 9b659162 | Christos Stavrakakis | |
1449 | 9b659162 | Christos Stavrakakis | .. code-block:: console |
1450 | 9b659162 | Christos Stavrakakis | |
1451 | 9b659162 | Christos Stavrakakis | $ scp node1:/var/lib/rabbitmq/.erlang.cookie node2:/var/lib/rabbitmq/.erlang.cookie |
1452 | 9b659162 | Christos Stavrakakis | |
1453 | 9b659162 | Christos Stavrakakis | and restart the nodes: |
1454 | 9b659162 | Christos Stavrakakis | |
1455 | 9b659162 | Christos Stavrakakis | .. code-block:: console |
1456 | 9b659162 | Christos Stavrakakis | |
1457 | 9b659162 | Christos Stavrakakis | $ /etc/init.d/rabbitmq-server restart |
1458 | 9b659162 | Christos Stavrakakis | |
1459 | 9b659162 | Christos Stavrakakis | |
1460 | 9b659162 | Christos Stavrakakis | To setup the RabbitMQ cluster run: |
1461 | 9b659162 | Christos Stavrakakis | |
1462 | 9b659162 | Christos Stavrakakis | .. code-block:: console |
1463 | 9b659162 | Christos Stavrakakis | |
1464 | 9b659162 | Christos Stavrakakis | root@node2: rabbitmqctl stop_app |
1465 | 9b659162 | Christos Stavrakakis | root@node2: rabbitmqctl reset |
1466 | 9b659162 | Christos Stavrakakis | root@node2: rabbitmqctl cluster rabbit@node1 rabbit@node2 |
1467 | 9b659162 | Christos Stavrakakis | root@node2: rabbitmqctl start_app |
1468 | 9b659162 | Christos Stavrakakis | |
1469 | 9b659162 | Christos Stavrakakis | You can verify that the cluster is set up correctly by running: |
1470 | 9b659162 | Christos Stavrakakis | |
1471 | 9b659162 | Christos Stavrakakis | .. code-block:: console |
1472 | 9b659162 | Christos Stavrakakis | |
1473 | 9b659162 | Christos Stavrakakis | root@node2: rabbitmqctl cluster_status |
1474 | 9b659162 | Christos Stavrakakis | |
1475 | 9b659162 | Christos Stavrakakis | |
1476 | bc055d09 | Constantinos Venetsanopoulos | Logging |
1477 | bc055d09 | Constantinos Venetsanopoulos | ------- |
1478 | bc055d09 | Constantinos Venetsanopoulos | |
1479 | bc055d09 | Constantinos Venetsanopoulos | Logging in Synnefo is using Python's logging module. The module is configured |
1480 | bc055d09 | Constantinos Venetsanopoulos | using dictionary configuration, whose format is described here: |
1481 | bc055d09 | Constantinos Venetsanopoulos | |
1482 | bc055d09 | Constantinos Venetsanopoulos | http://docs.python.org/release/2.7.1/library/logging.html#logging-config-dictschema |
1483 | bc055d09 | Constantinos Venetsanopoulos | |
1484 | bc055d09 | Constantinos Venetsanopoulos | Note that this is a feature of Python 2.7 that we have backported for use in |
1485 | bc055d09 | Constantinos Venetsanopoulos | Python 2.6. |
1486 | bc055d09 | Constantinos Venetsanopoulos | |
1487 | 4be65f1f | Christos Stavrakakis | The logging configuration dictionary is defined in |
1488 | a1c707c9 | Constantinos Venetsanopoulos | ``/etc/synnefo/10-snf-webproject-logging.conf`` |
1489 | bc055d09 | Constantinos Venetsanopoulos | |
1490 | a1c707c9 | Constantinos Venetsanopoulos | The administrator can have finer logging control by modifying the |
1491 | a1c707c9 | Constantinos Venetsanopoulos | ``LOGGING_SETUP`` dictionary, and defining subloggers with different handlers |
1492 | a1c707c9 | Constantinos Venetsanopoulos | and log levels. e.g. To enable debug messages only for the API set the level |
1493 | a1c707c9 | Constantinos Venetsanopoulos | of 'synnefo.api' to ``DEBUG`` |
1494 | 4be65f1f | Christos Stavrakakis | |
1495 | a1c707c9 | Constantinos Venetsanopoulos | By default, the Django webapp and snf-manage logs to syslog, while |
1496 | a1c707c9 | Constantinos Venetsanopoulos | `snf-dispatcher` logs to `/var/log/synnefo/dispatcher.log`. |
1497 | bc055d09 | Constantinos Venetsanopoulos | |
1498 | d189d11c | Constantinos Venetsanopoulos | |
1499 | 21d3d487 | Constantinos Venetsanopoulos | .. _scale-up: |
1500 | 21d3d487 | Constantinos Venetsanopoulos | |
1501 | bc055d09 | Constantinos Venetsanopoulos | Scaling up to multiple nodes |
1502 | bc055d09 | Constantinos Venetsanopoulos | ============================ |
1503 | bc055d09 | Constantinos Venetsanopoulos | |
1504 | 301294a9 | Constantinos Venetsanopoulos | Here we will describe how should a large scale Synnefo deployment look like. Make |
1505 | 301294a9 | Constantinos Venetsanopoulos | sure you are familiar with Synnefo and Ganeti before proceeding with this section. |
1506 | 301294a9 | Constantinos Venetsanopoulos | This means you should at least have already set up successfully a working Synnefo |
1507 | ff6ba888 | Constantinos Venetsanopoulos | deployment as described in the :ref:`Admin's Installation Guide |
1508 | 301294a9 | Constantinos Venetsanopoulos | <quick-install-admin-guide>` and also read the Administrator's Guide until this |
1509 | 301294a9 | Constantinos Venetsanopoulos | section. |
1510 | 2f6143c9 | Constantinos Venetsanopoulos | |
1511 | 301294a9 | Constantinos Venetsanopoulos | Graph of a scale-out Synnefo deployment |
1512 | 301294a9 | Constantinos Venetsanopoulos | --------------------------------------- |
1513 | 2f6143c9 | Constantinos Venetsanopoulos | |
1514 | 301294a9 | Constantinos Venetsanopoulos | Each box in the following graph corresponds to a distinct physical node: |
1515 | 2f6143c9 | Constantinos Venetsanopoulos | |
1516 | 301294a9 | Constantinos Venetsanopoulos | .. image:: images/synnefo-arch2-roles.png |
1517 | 301294a9 | Constantinos Venetsanopoulos | :width: 100% |
1518 | 301294a9 | Constantinos Venetsanopoulos | :target: _images/synnefo-arch2-roles.png |
1519 | 301294a9 | Constantinos Venetsanopoulos | |
1520 | 301294a9 | Constantinos Venetsanopoulos | The above graph is actually the same with the one at the beginning of this |
1521 | 301294a9 | Constantinos Venetsanopoulos | :ref:`guide <admin-guide>`, with the only difference that here we show the |
1522 | 301294a9 | Constantinos Venetsanopoulos | Synnefo roles of each physical node. These roles are described in the |
1523 | 301294a9 | Constantinos Venetsanopoulos | following section. |
1524 | 301294a9 | Constantinos Venetsanopoulos | |
1525 | 21d3d487 | Constantinos Venetsanopoulos | .. _physical-node-roles: |
1526 | 21d3d487 | Constantinos Venetsanopoulos | |
1527 | 301294a9 | Constantinos Venetsanopoulos | Physical Node roles |
1528 | 301294a9 | Constantinos Venetsanopoulos | ------------------- |
1529 | 301294a9 | Constantinos Venetsanopoulos | |
1530 | 301294a9 | Constantinos Venetsanopoulos | As appears in the previous graph, a scale-out Synnefo deployment consists of |
1531 | 301294a9 | Constantinos Venetsanopoulos | multiple physical nodes that have the following roles: |
1532 | 301294a9 | Constantinos Venetsanopoulos | |
1533 | 301294a9 | Constantinos Venetsanopoulos | * **WEBSERVER**: A web server running in front of gunicorn (e.g.: Apache, nginx) |
1534 | 301294a9 | Constantinos Venetsanopoulos | * **ASTAKOS**: The Astakos application (gunicorn) |
1535 | 301294a9 | Constantinos Venetsanopoulos | * **ASTAKOS_DB**: The Astakos database (postgresql) |
1536 | 301294a9 | Constantinos Venetsanopoulos | * **PITHOS**: The Pithos application (gunicorn) |
1537 | 301294a9 | Constantinos Venetsanopoulos | * **PITHOS_DB**: The Pithos database (postgresql) |
1538 | 301294a9 | Constantinos Venetsanopoulos | * **CYCLADES**: The Cyclades application (gunicorn) |
1539 | 301294a9 | Constantinos Venetsanopoulos | * **CYCLADES_DB**: The Cyclades database (postgresql) |
1540 | 301294a9 | Constantinos Venetsanopoulos | * **MQ**: The message queue (RabbitMQ) |
1541 | 301294a9 | Constantinos Venetsanopoulos | * **GANETI_MASTER**: The Ganeti master of a Ganeti cluster |
1542 | 301294a9 | Constantinos Venetsanopoulos | * **GANETI_NODE** : A VM-capable Ganeti node of a Ganeti cluster |
1543 | 2f6143c9 | Constantinos Venetsanopoulos | |
1544 | 301294a9 | Constantinos Venetsanopoulos | You will probably also have: |
1545 | 2f6143c9 | Constantinos Venetsanopoulos | |
1546 | 301294a9 | Constantinos Venetsanopoulos | * **CMS**: The CMS used as a frotend portal for the Synnefo services |
1547 | 21d3d487 | Constantinos Venetsanopoulos | * **NS**: A nameserver serving all other Synnefo nodes and resolving Synnefo FQDNs |
1548 | 301294a9 | Constantinos Venetsanopoulos | * **CLIENT**: A machine that runs the Synnefo clients (e.g.: kamaki, Web UI), |
1549 | 301294a9 | Constantinos Venetsanopoulos | most of the times, the end user's local machine |
1550 | 301294a9 | Constantinos Venetsanopoulos | |
1551 | 301294a9 | Constantinos Venetsanopoulos | From this point we will also refer to the following groups of roles: |
1552 | 301294a9 | Constantinos Venetsanopoulos | |
1553 | 301294a9 | Constantinos Venetsanopoulos | * **SYNNEFO**: [ **ASTAKOS**, **ASTAKOS_DB**, **PITHOS**, **PITHOS_DB**, **CYCLADES**, **CYCLADES_DB**, **MQ**, **CMS**] |
1554 | 301294a9 | Constantinos Venetsanopoulos | * **G_BACKEND**: [**GANETI_MASTER**, **GANETI_NODE**] |
1555 | 301294a9 | Constantinos Venetsanopoulos | |
1556 | 301294a9 | Constantinos Venetsanopoulos | Of course, when deploying Synnefo you can combine multiple of the above roles on a |
1557 | 301294a9 | Constantinos Venetsanopoulos | single physical node, but if you are trying to scale out, the above separation |
1558 | 301294a9 | Constantinos Venetsanopoulos | gives you significant advantages. |
1559 | 301294a9 | Constantinos Venetsanopoulos | |
1560 | 301294a9 | Constantinos Venetsanopoulos | So, in the next section we will take a look on what components you will have to |
1561 | 301294a9 | Constantinos Venetsanopoulos | install on each physical node depending on its Synnefo role. We assume the graph's |
1562 | 301294a9 | Constantinos Venetsanopoulos | architecture. |
1563 | 301294a9 | Constantinos Venetsanopoulos | |
1564 | 301294a9 | Constantinos Venetsanopoulos | Components for each role |
1565 | 301294a9 | Constantinos Venetsanopoulos | ------------------------ |
1566 | 2f6143c9 | Constantinos Venetsanopoulos | |
1567 | 301294a9 | Constantinos Venetsanopoulos | When deploying Synnefo in large scale, you need to install different Synnefo |
1568 | 301294a9 | Constantinos Venetsanopoulos | or/and third party components on different physical nodes according to their |
1569 | 301294a9 | Constantinos Venetsanopoulos | Synnefo role, as stated in the previous section. |
1570 | 301294a9 | Constantinos Venetsanopoulos | |
1571 | 301294a9 | Constantinos Venetsanopoulos | Specifically: |
1572 | 301294a9 | Constantinos Venetsanopoulos | |
1573 | 301294a9 | Constantinos Venetsanopoulos | Role **WEBSERVER** |
1574 | 301294a9 | Constantinos Venetsanopoulos | * Synnefo components: `None` |
1575 | 301294a9 | Constantinos Venetsanopoulos | * 3rd party components: Apache |
1576 | 301294a9 | Constantinos Venetsanopoulos | Role **ASTAKOS** |
1577 | 301294a9 | Constantinos Venetsanopoulos | * Synnefo components: `snf-webproject`, `snf-astakos-app` |
1578 | 301294a9 | Constantinos Venetsanopoulos | * 3rd party components: Django, Gunicorn |
1579 | 301294a9 | Constantinos Venetsanopoulos | Role **ASTAKOS_DB** |
1580 | 301294a9 | Constantinos Venetsanopoulos | * Synnefo components: `None` |
1581 | 301294a9 | Constantinos Venetsanopoulos | * 3rd party components: PostgreSQL |
1582 | 301294a9 | Constantinos Venetsanopoulos | Role **PITHOS** |
1583 | 301294a9 | Constantinos Venetsanopoulos | * Synnefo components: `snf-webproject`, `snf-pithos-app`, `snf-pithos-webclient` |
1584 | 301294a9 | Constantinos Venetsanopoulos | * 3rd party components: Django, Gunicorn |
1585 | 301294a9 | Constantinos Venetsanopoulos | Role **PITHOS_DB** |
1586 | 301294a9 | Constantinos Venetsanopoulos | * Synnefo components: `None` |
1587 | 301294a9 | Constantinos Venetsanopoulos | * 3rd party components: PostgreSQL |
1588 | 301294a9 | Constantinos Venetsanopoulos | Role **CYCLADES** |
1589 | 301294a9 | Constantinos Venetsanopoulos | * Synnefo components: `snf-webproject`, `snf-cyclades-app`, `snf-vncauthproxy` |
1590 | 301294a9 | Constantinos Venetsanopoulos | * 3rd party components: Django Gunicorn |
1591 | 301294a9 | Constantinos Venetsanopoulos | Role **CYCLADES_DB** |
1592 | 301294a9 | Constantinos Venetsanopoulos | * Synnefo components: `None` |
1593 | 301294a9 | Constantinos Venetsanopoulos | * 3rd party components: PostgreSQL |
1594 | 301294a9 | Constantinos Venetsanopoulos | Role **MQ** |
1595 | 301294a9 | Constantinos Venetsanopoulos | * Synnefo components: `None` |
1596 | 301294a9 | Constantinos Venetsanopoulos | * 3rd party components: RabbitMQ |
1597 | 301294a9 | Constantinos Venetsanopoulos | Role **GANETI_MASTER** |
1598 | 301294a9 | Constantinos Venetsanopoulos | * Synnefo components: `snf-cyclades-gtools` |
1599 | 301294a9 | Constantinos Venetsanopoulos | * 3rd party components: Ganeti |
1600 | 301294a9 | Constantinos Venetsanopoulos | Role **GANETI_NODE** |
1601 | 301294a9 | Constantinos Venetsanopoulos | * Synnefo components: `snf-cyclades-gtools`, `snf-network`, `snf-image`, `nfdhcpd` |
1602 | 301294a9 | Constantinos Venetsanopoulos | * 3rd party components: Ganeti |
1603 | 301294a9 | Constantinos Venetsanopoulos | Role **CMS** |
1604 | 301294a9 | Constantinos Venetsanopoulos | * Synnefo components: `snf-webproject`, `snf-cloudcms` |
1605 | 301294a9 | Constantinos Venetsanopoulos | * 3rd party components: Django, Gunicorn |
1606 | 301294a9 | Constantinos Venetsanopoulos | Role **NS** |
1607 | 301294a9 | Constantinos Venetsanopoulos | * Synnefo components: `None` |
1608 | 301294a9 | Constantinos Venetsanopoulos | * 3rd party components: BIND |
1609 | 301294a9 | Constantinos Venetsanopoulos | Role **CLIENT** |
1610 | 301294a9 | Constantinos Venetsanopoulos | * Synnefo components: `kamaki`, `snf-image-creator` |
1611 | 301294a9 | Constantinos Venetsanopoulos | * 3rd party components: `None` |
1612 | 301294a9 | Constantinos Venetsanopoulos | |
1613 | 301294a9 | Constantinos Venetsanopoulos | Example scale out installation |
1614 | 301294a9 | Constantinos Venetsanopoulos | ------------------------------ |
1615 | 301294a9 | Constantinos Venetsanopoulos | |
1616 | 301294a9 | Constantinos Venetsanopoulos | In this section we describe an example of a medium scale installation which |
1617 | 301294a9 | Constantinos Venetsanopoulos | combines multiple roles on 10 different physical nodes. We also provide a |
1618 | 301294a9 | Constantinos Venetsanopoulos | :ref:`guide <i-synnefo>` to help with such an install. |
1619 | 301294a9 | Constantinos Venetsanopoulos | |
1620 | 301294a9 | Constantinos Venetsanopoulos | We assume that we have the following 10 physical nodes with the corresponding |
1621 | 301294a9 | Constantinos Venetsanopoulos | roles: |
1622 | 301294a9 | Constantinos Venetsanopoulos | |
1623 | 301294a9 | Constantinos Venetsanopoulos | Node1: |
1624 | 301294a9 | Constantinos Venetsanopoulos | **WEBSERVER**, **ASTAKOS** |
1625 | 301294a9 | Constantinos Venetsanopoulos | Guide sections: |
1626 | 301294a9 | Constantinos Venetsanopoulos | * :ref:`apt <i-apt>` |
1627 | 301294a9 | Constantinos Venetsanopoulos | * :ref:`gunicorn <i-gunicorn>` |
1628 | 301294a9 | Constantinos Venetsanopoulos | * :ref:`apache <i-apache>` |
1629 | 301294a9 | Constantinos Venetsanopoulos | * :ref:`snf-webproject <i-webproject>` |
1630 | 301294a9 | Constantinos Venetsanopoulos | * :ref:`snf-astakos-app <i-astakos>` |
1631 | 301294a9 | Constantinos Venetsanopoulos | Node2: |
1632 | 301294a9 | Constantinos Venetsanopoulos | **WEBSERVER**, **PITHOS** |
1633 | 301294a9 | Constantinos Venetsanopoulos | Guide sections: |
1634 | 301294a9 | Constantinos Venetsanopoulos | * :ref:`apt <i-apt>` |
1635 | 301294a9 | Constantinos Venetsanopoulos | * :ref:`gunicorn <i-gunicorn>` |
1636 | 301294a9 | Constantinos Venetsanopoulos | * :ref:`apache <i-apache>` |
1637 | 301294a9 | Constantinos Venetsanopoulos | * :ref:`snf-webproject <i-webproject>` |
1638 | 301294a9 | Constantinos Venetsanopoulos | * :ref:`snf-pithos-app <i-pithos>` |
1639 | 301294a9 | Constantinos Venetsanopoulos | * :ref:`snf-pithos-webclient <i-pithos>` |
1640 | 301294a9 | Constantinos Venetsanopoulos | Node3: |
1641 | 301294a9 | Constantinos Venetsanopoulos | **WEBSERVER**, **CYCLADES** |
1642 | 301294a9 | Constantinos Venetsanopoulos | Guide sections: |
1643 | 301294a9 | Constantinos Venetsanopoulos | * :ref:`apt <i-apt>` |
1644 | 301294a9 | Constantinos Venetsanopoulos | * :ref:`gunicorn <i-gunicorn>` |
1645 | 301294a9 | Constantinos Venetsanopoulos | * :ref:`apache <i-apache>` |
1646 | 301294a9 | Constantinos Venetsanopoulos | * :ref:`snf-webproject <i-webproject>` |
1647 | 301294a9 | Constantinos Venetsanopoulos | * :ref:`snf-cyclades-app <i-cyclades>` |
1648 | 301294a9 | Constantinos Venetsanopoulos | * :ref:`snf-vncauthproxy <i-cyclades>` |
1649 | 301294a9 | Constantinos Venetsanopoulos | Node4: |
1650 | 301294a9 | Constantinos Venetsanopoulos | **WEBSERVER**, **CMS** |
1651 | 301294a9 | Constantinos Venetsanopoulos | Guide sections: |
1652 | 301294a9 | Constantinos Venetsanopoulos | * :ref:`apt <i-apt>` |
1653 | 301294a9 | Constantinos Venetsanopoulos | * :ref:`gunicorn <i-gunicorn>` |
1654 | 301294a9 | Constantinos Venetsanopoulos | * :ref:`apache <i-apache>` |
1655 | 301294a9 | Constantinos Venetsanopoulos | * :ref:`snf-webproject <i-webproject>` |
1656 | 301294a9 | Constantinos Venetsanopoulos | * :ref:`snf-cloudcms <i-cms>` |
1657 | 301294a9 | Constantinos Venetsanopoulos | Node5: |
1658 | 301294a9 | Constantinos Venetsanopoulos | **ASTAKOS_DB**, **PITHOS_DB**, **CYCLADES_DB** |
1659 | 301294a9 | Constantinos Venetsanopoulos | Guide sections: |
1660 | 301294a9 | Constantinos Venetsanopoulos | * :ref:`apt <i-apt>` |
1661 | 301294a9 | Constantinos Venetsanopoulos | * :ref:`postgresql <i-db>` |
1662 | 301294a9 | Constantinos Venetsanopoulos | Node6: |
1663 | 301294a9 | Constantinos Venetsanopoulos | **MQ** |
1664 | 301294a9 | Constantinos Venetsanopoulos | Guide sections: |
1665 | 301294a9 | Constantinos Venetsanopoulos | * :ref:`apt <i-apt>` |
1666 | 301294a9 | Constantinos Venetsanopoulos | * :ref:`rabbitmq <i-mq>` |
1667 | 301294a9 | Constantinos Venetsanopoulos | Node7: |
1668 | 301294a9 | Constantinos Venetsanopoulos | **GANETI_MASTER**, **GANETI_NODE** |
1669 | 301294a9 | Constantinos Venetsanopoulos | Guide sections: |
1670 | 301294a9 | Constantinos Venetsanopoulos | * :ref:`apt <i-apt>` |
1671 | 301294a9 | Constantinos Venetsanopoulos | * :ref:`general <i-backends>` |
1672 | 301294a9 | Constantinos Venetsanopoulos | * :ref:`ganeti <i-ganeti>` |
1673 | 301294a9 | Constantinos Venetsanopoulos | * :ref:`snf-cyclades-gtools <i-gtools>` |
1674 | 301294a9 | Constantinos Venetsanopoulos | * :ref:`snf-network <i-network>` |
1675 | 301294a9 | Constantinos Venetsanopoulos | * :ref:`snf-image <i-image>` |
1676 | 301294a9 | Constantinos Venetsanopoulos | * :ref:`nfdhcpd <i-network>` |
1677 | 301294a9 | Constantinos Venetsanopoulos | Node8: |
1678 | 301294a9 | Constantinos Venetsanopoulos | **GANETI_NODE** |
1679 | 301294a9 | Constantinos Venetsanopoulos | Guide sections: |
1680 | 301294a9 | Constantinos Venetsanopoulos | * :ref:`apt <i-apt>` |
1681 | 301294a9 | Constantinos Venetsanopoulos | * :ref:`general <i-backends>` |
1682 | 301294a9 | Constantinos Venetsanopoulos | * :ref:`ganeti <i-ganeti>` |
1683 | 301294a9 | Constantinos Venetsanopoulos | * :ref:`snf-cyclades-gtools <i-gtools>` |
1684 | 301294a9 | Constantinos Venetsanopoulos | * :ref:`snf-network <i-network>` |
1685 | 301294a9 | Constantinos Venetsanopoulos | * :ref:`snf-image <i-image>` |
1686 | 301294a9 | Constantinos Venetsanopoulos | * :ref:`nfdhcpd <i-network>` |
1687 | 301294a9 | Constantinos Venetsanopoulos | Node9: |
1688 | 301294a9 | Constantinos Venetsanopoulos | **GANETI_NODE** |
1689 | 301294a9 | Constantinos Venetsanopoulos | Guide sections: |
1690 | 301294a9 | Constantinos Venetsanopoulos | `Same as Node8` |
1691 | 301294a9 | Constantinos Venetsanopoulos | Node10: |
1692 | 301294a9 | Constantinos Venetsanopoulos | **GANETI_NODE** |
1693 | 301294a9 | Constantinos Venetsanopoulos | Guide sections: |
1694 | 301294a9 | Constantinos Venetsanopoulos | `Same as Node8` |
1695 | 301294a9 | Constantinos Venetsanopoulos | |
1696 | 301294a9 | Constantinos Venetsanopoulos | All sections: :ref:`Scale out Guide <i-synnefo>` |
1697 | 547c78f6 | Constantinos Venetsanopoulos | |
1698 | bc055d09 | Constantinos Venetsanopoulos | |
1699 | bbcd3dd1 | Constantinos Venetsanopoulos | Upgrade Notes |
1700 | bbcd3dd1 | Constantinos Venetsanopoulos | ============= |
1701 | bc055d09 | Constantinos Venetsanopoulos | |
1702 | 457fe4fc | Georgios D. Tsoukalas | .. toctree:: |
1703 | 457fe4fc | Georgios D. Tsoukalas | :maxdepth: 1 |
1704 | 457fe4fc | Georgios D. Tsoukalas | |
1705 | 1cd3daa1 | Constantinos Venetsanopoulos | v0.12 -> v0.13 <upgrade/upgrade-0.13> |
1706 | 09974606 | Georgios D. Tsoukalas | v0.13 -> v0.14 <upgrade/upgrade-0.14> |
1707 | 15151f83 | Christos Stavrakakis | v0.14 -> v0.14.2 <upgrade/upgrade-0.14.2> |
1708 | 0d14df99 | Christos Stavrakakis | v0.14.5 -> v0.14.6 <upgrade/upgrade-0.14.6> |
1709 | d3840a05 | Constantinos Venetsanopoulos | v0.14.7 -> v0.14.8 <upgrade/upgrade-0.14.8> |
1710 | 0ab857d0 | Constantinos Venetsanopoulos | v0.14.9 -> v0.14.10 <upgrade/upgrade-0.14.10> |
1711 | 774f683b | Giorgos Korfiatis | v0.14 -> v0.15 <upgrade/upgrade-0.15> |
1712 | 457fe4fc | Georgios D. Tsoukalas | |
1713 | bbcd3dd1 | Constantinos Venetsanopoulos | |
1714 | 3045e739 | Constantinos Venetsanopoulos | Changelog, NEWS |
1715 | bbcd3dd1 | Constantinos Venetsanopoulos | =============== |
1716 | bbcd3dd1 | Constantinos Venetsanopoulos | |
1717 | 15151f83 | Christos Stavrakakis | |
1718 | 9a80de55 | Christos Stavrakakis | * v0.14.10 :ref:`Changelog <Changelog-0.14.10>`, :ref:`NEWS <NEWS-0.14.10>` |
1719 | 033321fb | Christos Stavrakakis | * v0.14.9 :ref:`Changelog <Changelog-0.14.9>`, :ref:`NEWS <NEWS-0.14.9>` |
1720 | 833880fd | Christos Stavrakakis | * v0.14.8 :ref:`Changelog <Changelog-0.14.8>`, :ref:`NEWS <NEWS-0.14.8>` |
1721 | 833880fd | Christos Stavrakakis | * v0.14.7 :ref:`Changelog <Changelog-0.14.7>`, :ref:`NEWS <NEWS-0.14.7>` |
1722 | 7a59cb8f | Christos Stavrakakis | * v0.14.6 :ref:`Changelog <Changelog-0.14.6>`, :ref:`NEWS <NEWS-0.14.6>` |
1723 | d6a19bac | Christos Stavrakakis | * v0.14.5 :ref:`Changelog <Changelog-0.14.5>`, :ref:`NEWS <NEWS-0.14.5>` |
1724 | 38be3b6e | Christos Stavrakakis | * v0.14.4 :ref:`Changelog <Changelog-0.14.4>`, :ref:`NEWS <NEWS-0.14.4>` |
1725 | cda13b21 | Christos Stavrakakis | * v0.14.3 :ref:`Changelog <Changelog-0.14.3>`, :ref:`NEWS <NEWS-0.14.3>` |
1726 | 15151f83 | Christos Stavrakakis | * v0.14.2 :ref:`Changelog <Changelog-0.14.2>`, :ref:`NEWS <NEWS-0.14.2>` |
1727 | a0f672f1 | Stratos Psomadakis | * v0.14 :ref:`Changelog <Changelog-0.14>`, :ref:`NEWS <NEWS-0.14>` |
1728 | bbcd3dd1 | Constantinos Venetsanopoulos | * v0.13 :ref:`Changelog <Changelog-0.13>`, :ref:`NEWS <NEWS-0.13>` |