Revision 483c9197

b/.gitignore
17 17
.settings/
18 18
settings.d/*-local.conf
19 19
*.egg-info
20
/dist
20
dist
21 21
_build
/dev/null
1
Changelog
2
=========
3

  
4

  
5
2011-10-21, v0.7.3
6
------------------
7

  
8
FIXES:
9
	UI:
10
		* Fix two UI glitches with Firefox 3.6 (#1545, #1546)
11

  
12

  
13
2011-10-19, v0.7.2
14
------------------
15

  
16
FIXES:
17
    UI:
18
	    * Fix regressions with flavor sorting and image size checking
19
		  (#1429, #1507)
20

  
21

  
22
2011-10-17, v0.7.1
23
------------------
24

  
25
FIXES:
26
    UI:
27
        * Fix Enter/Esc on machine rename not working in the UI (#1501)
28
	    * Fix UI barfs if a VM is based on an Image with state=DELETED (#1494)
29
        * Fix UI user logout action does not work (#1497)
30
    Images:	
31
		* Fix erroneous reference to $(HELPER_DIR) in /etc/default /snf-image (#1498)
32
		* Fix typo in snf-image-helper ChangePassword task (#1500)
33
		* Show timestamps on execution of helper tasks in snf-image helper VM (#1499)
34
    Deployment:
35
		* Improve check for Ganeti master in snf-ganeti-eventd init script (#1323)
36
		* Fix snf-ganeti-eventd init script ignored defaults file (#1505)
37

  
38

  
39
2011-10-13, v0.7
40
----------------
41

  
42
NEW FEATURES:
43
    UI:
44
        * From the ground-up rebuilt, refactored MVC-based UI (#1443)
45
        * Document all settings introduced due to UI refactoring (#1447)
46
        * UI asset files versioning (#1460)
47
        * Improve feedback on completed steps during machine creation (#1461)
48
    Images:
49
        * Completely re-engineered image deployment mechanism based on
50
          snf-image Ganeti OS provider, in isolated helper VM
51
        * Support public and private images (#555)
52
        * Support handling of VM filesystem, injection of arbitrary files
53
          on VM creation (#491)
54
        * Implement file injection as a task in snf-image (#1095)
55
        * Remove all-host based processing of (potentially user-provided)
56
          Images (#969)
57
    API:
58
        * Implement <personality> tag in OpenStack Compute API
59
          for file injection (#985, #1093)
60
        * Update API implementation for server/image metadata based on latest
61
          draft version of spec (#1403)
62
        * Support deletion of Flavors, support servers referring to
63
          inexistent (deleted) Flavors (#1157)
64
    Admin:
65
        * Addition of --meta option to snf-admin image for easy setting
66
          of image metadata values on image creation (#1107)
67
    Deployment:
68
        * Initial iteration of a system test suite, snf-burnin,
69
          for end-to-end testing of Synnefo deployments (#1155)
70
        * Re-engineered logging mechanism, for finer-grained control (#1033)
71
        * Add init script for snf-ganeti-eventd, fix Debian packaging (#1323)
72
        * Document removal of Flavors from circulation (#1472)
73
        * Add generic service unavailable template (#1359)
74

  
75

  
76
FIXES:
77
    UI:
78
        * Fix problems when reusing the Create machine wizard with IE8 (#997)
79
        * Fix problematic update of the networks tab and minor fixes (#861)
80
        * Fix "Connecting" and "progress" gif in networks tab (#863)
81
        * Fix inconsistencies on machine transitions between views (#917)
82
        * Fix IE rendering mode (#975)
83
        * Fix UI machine/network creation overlays style clutter (#979)
84
        * Have UI should reset action confirmations after state change (#981)
85
        * UI barfs due to exception on "New Machine" wizard (#1473)
86
        * UI throws exception on single-server view (#1483)
87
    API:
88
        * Fix incomplete constraints in ImageMetadata Model (#1255)
89
    Deployment:
90
        * Split initial_data.json to work around South "feature" (#1263)
91
        * Fix missing snf-ganeti-instance-image package dependency (#1319)
92
    Kamaki:
93
        * The kamaki client lib uses the root logger (#1337)
94
        * The kamaki client lib fails to set server metadata (#1399)
95
    Invitations:
96
        * FIx bug causing HTTP 500 error on /invitations/login (#1407)
97
        * Fix sort order of flavors, sort by actual characteristicts (#1429)
98
        * Fix display of error modal boxes, do notrefresh or display another
99
          error (#1433)
100
        * Fix positioning of machines in "Destroying" (#1437)
101
        * Fix Metadata button shown as clickable while it's not (#1441)
102
    Images:
103
        * Missing dependency on 'qemu-img' in snf-image-helper (#1484)
104
    Logic:
105
        * Fix messages left in the queue due to unknown Ganeti opcodes (#1492)
106

  
107

  
108
2011-09-15, v0.6.2
109
------------------
110

  
111
FIXES:
112
    UI:
113
        * Fix handling of Images in state=DELETED,
114
          allow sorting and categorization of Images in the UI (#823)
115
        * Fix the "Create New wizard" does not honor selection of
116
          "small/medium/large" images (#1129)
117
    Admin:
118
        * Fix the admin interface throws exception on the
119
          Invitations tab (1105)
120
    API:
121
        * Make API responses uncacheable (#1091)
122
    Logic:
123
        * Fix The dispatcher leaving messages unprocessed for
124
          unknown Ganeti opcodes(#1111)
125

  
126
NEW FEATURES:
127
    Admin:
128
        * Support filtering based on state, support image registration
129
          with mandatory type argument, make all deletion operations
130
          set state to DELETED (#849)
131
    API:
132
        * Allow marking flavors as removed, honor deleted flag (#1055)
133

  
134

  
135
2011-09-13, v0.6.1
136
------------------
137

  
138
FIXES:
139
    UI:
140
        * Make all AJAX requests to the API uncache-able
141

  
142

  
143
2011-09-12, v0.6
144
----------------
145

  
146
NEW FEATURES:
147
    Admin:
148
        * Initial version of new Web-based admininstration panel, allows
149
          management of Synnefo entities directly on the DB (#849)
150
        * Allow setting https apiurl and token in cloud tool (#853)
151
    Deployment:
152
        * Overhauled reconciliation mechanism, unit tests (#1021, #811)
153
    UI:
154
        * Overhaul CPU/RAM/disk sliders in UI to be more intuitive (#843)
155
        * Support setting of small, medium large flavors in UI (#815)
156
        * Have the UI filter flavors, depending on image size (#817)
157
        * Better, error-specific handling of error codes in UI (#971)
158
        * Implement retrieval of authentication token from the UI (#977)
159
        * Re-worked invitation UI is more vocal on errors, supports pagination
160
          (#1039)
161
        * Support a list of UI-specific metadata keys to be copied from Image
162
          to newly-created Server (#847)
163
    Images:
164
        * Support dd-based deployment of Windows and Linux images, using only
165
          dd-based sequential I/O, get rid of ntfsclone (#965, #1007)
166

  
167
FIXES:
168
    UI:
169
        * Fix Opera failing with "too old changes-since value" when idle (#521)
170
        * Fix UI problems with Firefox 3.5.x (#781)
171
        * Fix server statistics not refreshing properly in the UI (#881)
172
        * Machine rename icon not visible on IE (#909)
173
        * Fix list view fail not updating machine state properly (#915)
174
        * Fix colors in "Error" state (#953)
175
        * Fix the confirmation bar disappearing at times (#955)
176
        * Hide all actions when in state "Destroying..." (#957)
177
        * Disable connect action when machine has no ip set (#983)
178
        * Update image details on last vm creation step overlay on IE (#1011)
179
        * Fix list view displays UI error when servers are updated on IE
180
          (#1013)
181
        * Make "Add invitation", remove invitation button appear clickable
182
          (#1019)
183
    Logic:
184
        * Fix Logic layer complaining about certain Ganeti opcodes (#1031)
185

  
186

  
187
2011-08-29, v0.5.5
188

  
189
FIXES:
190
    Logic:
191
        * Bugfixes, reconnect to AMQP properly when connection drops,
192
          added more DEBUG- and INFO-level logging messages.
193

  
194

  
195
2011-07-27, v0.5.4
196

  
197
FIXES:
198
    UI:
199
        * Numerous bugfixes, most in response to user feedback from
200
          the Alpha deployment
201
        * #813 (Minor UI issues), #857 (long machine names),
202
          #865 (problem when user has zero invitations),
203
          #873 (generic 404 template), #895 (default username in RDP file),
204
          #897 (show spinner for the public network), 899 (allow Connect
205
          from the network UI), #901 (cannot select password for copying
206
          with Chrome), #893 (firewall profile selection behaves as a single
207
          list for all servers), #903 (cannot copy paste IPv4 in icon view),
208
          #905 (Javascript throws exception when left idle), #907 (similar
209
          issue with #907), #913 (list view alert message)
210
    Images:
211
        * ntfsclone does not use all of the available space on the target (#879)
212
    Deployment:
213
        * Move fix_amqp_settings to queue system init code (#809)
214
    Admin:
215
        * snf-admin user invite is not non-ascii friendly (#943)
216
        * snf-user should show email addresses, even without any arguments (#871)
217

  
218
FEATURES:
219
    UI:
220
        * Show completion percentage when a machine is being built (#887)
221
    API:
222
        * Report percentage completion for machines in BUILD (#891)
223
    Images:
224
        * The image deployment layer should report completion to the API layer
225
          (#889)
226
    Deployment:
227
        * Drop ganeti-eventd & snf-ganeti-hook synnefo dependency (#691)
228
        * Split Synnefo Ganeti tools to separate project under snf-ganeti-tools/
229
        * Import code for building Debian packages, refactor repository (#691)
230

  
231

  
232
2011-07-19, v0.5.3.1
233

  
234
FIXES:
235
    API:
236
        * Fix bug with firewall code using inexistent, removed setting
237
    GUI:
238
        * Fix bug with invitations UI (#859)
239
        * Fix bug with feedback form submission raising HTTP 500
240
    Deployment:
241
        * Fix bug with error reporting by the invitations app
242

  
243

  
244
2011-07-19, v0.5.3
245

  
246
FIXES:
247
    GUI:
248
        * Add separate LOGOUT_URL setting
249
          fixes bug with URL in invitations mail
250
    Deployment:
251
        * Recode invitations email in UTF-8
252
        * Use DEFAULT_FROM_EMAIL Django setting as From: header
253
          for all emails
254

  
255

  
256
2011-07-18, v0.5.2
257

  
258
FIXES:
259
    GUI:
260
        * Improve IPv6 support in UI (#839, #841)
261
        * Improve Connect messages, propose username (#801)
262
        * Add "tag"/"value" headers in Modify tags popup (#845)
263
    API:
264
        * Support arbitrary arguments to RAPI CreateInstanceCall() (#835)
265
    Admin tool:
266
        * Support creation and modification of users, flavors, images (#827)
267
        * Support sending invitations from the command line
268

  
269

  
270
2011-07-14, v0.5.1
271

  
272
FIXES:
273
    GUI:
274
        * non-standard dpi settings (#343)
275
        * many minor bugs (#717)
276
        * remove "Login again" button from Java VNC viewer (#731)
277
        * Fix no firewall settings shown for newly built machines (#753)
278
        * Fix handling of transitional "Destroying" state (#771)
279
        * Use well-formed, client- and server-specific messages
280
          for the Connect operation (#801)
281
        * Fix misaligned action labels in IE (#821)
282
          generic cross-browser compatibility fixes (#341)
283
    Logic:
284
        * fix dispatcher flushing AMQP queues (#719)
285
        * Support asynchronous VM deletion (#721)
286
        * Add backend prefix to all AMQP queues (#723)
287
        * Document workarounds for dispatcher daemonization problems
288
          when logging to stdout (#779)
289
    Images:
290
        * Fix ntfsclone causing excess I/O load due to verbose output (#729)
291
    API:
292
        * Have API use the flavor-defined disk sizes (#759)
293
        * Make backend disk templates (plain, drbd) configurable (#77&)
294
        * Work around Ganeti bug with getting VNC console info (#783)
295
        * Set serial_console=False explicitly on Ganeti backend (#785)
296
        * Allow exception info to propagate when VNC console allocation fails
297
          (#789)
298
        * Handle deletion of machines in ERROR when no Ganeti instance exists
299
          (#799)
300
    Backend:
301
        * Synchronize contrib/kvm-vif-bridge to agree with the API on the tags
302
          to use for firewall profiles (#789)
303

  
304
NEW FEATURES
305
    GUI:
306
        * Add themed form for invitations, integrate with UI (#439)
307
        * Add themed feedback form, integrate with API error window
308
          (~okeanos #7)
309
    Admin tool:
310
        * Add initial version of snf-admin tool for user, VM and image
311
          management (#727)
312

  
313

  
314
2011-07-01, v0.5
315

  
316
NEW FEATURES
317
    GUI:
318
        * Overhauled icon and single-server view, updated color set
319
          (#651, #653, #667, #669, #673, #675, #677, #443, #631)
320
        * Added statistics, retrieves pre-processed PNGs from backend (#527)
321
        * Added buttons for modifier keys, custom theming to Java VNC client
322
          (#545)
323
        * Support single-click RDP-based connection to Windows VMs (#673)
324
        * Allow setting network firewall profiles on public interfaces (#661)
325
    Images:
326
        * Complete set of Linux distribution Images (Debian, Fedora, Ubuntu)
327
          (#493, #509)
328
        * Complete support for Windows machines (create, customize, boot)
329
          (#495)
330
    Logic:
331
        * Support centralized logging, logging.conf-based setup (#547)
332
    AAI:
333
        * Allow per-user setting of number of outgoing invitations (#439, #705)
334
        * Support "switch-user"-type functionality for helpdesk users (#665)
335
        * Support user logout in the UI, delete relevant tokens (#663)
336
    API:
337
        * Supports retrieval of statistics (#527)
338
        * Support maximum number of VMs per user (quota) (#703)
339
        * Extend API to support distinct firewall profiles, update backend (#659)
340
    Deployment:
341
        * BSD 2-clause Licensing (#581)
342
        * Initial translation of UI to Greek (#689)
343
        * Drop Django dependency in snf-ganeti-eventd and snf-ganeti-hook (#691)
344
          Synnefo dependency remains, already patched by ops, to be committed
345
        * Split settings.py to distinct files under settings.d/ (#693)
346
        * Use the Django email framework (#697)
347
        * Implemented statistics-gathering mechanism at the backend (#527)
348

  
349
FIXES:
350
    GUI:
351
        * Too many bug fixes to mention (#403, #429, #465, #473, #557, #589,
352
          #599, #605, #607, #609, #611, #613, #619, #621, #623, #625, #627,
353
          #629, #633, #635, #637, #639, #641, #643, #645, #647, #649, #655,
354
          #657, #681, #687, #699, #701, #707, #709)
355
        * Better cross-browser compatibility (#341)
356
        * Should work with relative URLs (#421)
357
    Images:
358
        * Set hostname in Linux VMs appropriately (#603)
359
    Logic:
360
        * Include EUI-64-derived IPv6 address in ganeti-net-status notifications
361
          (#615)
362
    Deployment:
363
        * Do not set nodes explicitly, use iallocator at Ganeti backend (#617)
364

  
365

  
366
2011-06-06, v0.4
367

  
368
NEW FEATURES:
369
    GUI:
370
        * Support displaying info on and handling of public and private networks,
371
          with differential updates (#407, #469)
372
        * Support create new private network (#541), add machine to
373
          private network (#543)
374
        * Design and implement a completely revamped blue and orange
375
          color theme (#529, #531)
376
        * Implement improved add/edit metadata dialog with suggested values for
377
          keys (#535, #537)
378
        * Implement list of suggested keys in add server metadata dialog (#537)
379
        * Add full-screen Console window, themed as the rest of the UI (#497)
380
        * Implement single-machine view in the UI (#573)
381
        * Add user notification (spinner) on button clicks performing
382
          API actions (#471)
383
        * Full IE support, differential updates (#461)
384
    AAI:
385
        * Each token has its own expiration date, fix expiration of
386
          development test token (#483)
387
        * Support adding new users to the DB by invitation (#439)
388
    API:
389
        * Extend networks API, support differential updates for private nets (#569)
390
        * Support XML replies for the /networks API namespace (#553)
391
        * Implement mechanism for reconciliation of DB state with Ganeti backend
392
          state in case of AMQP failure (#505)
393
        * Support Ganeti link pooling for management of private networks (#513)
394
        * Support reception and processing of NIC configuration notifications
395
          from Ganeti over AMQP (#513)
396
    IMAGES:
397
        * Implement generic API<->Ganeti mechanism for passing custom VM parameters (#487)
398
        * Support selection and handling of OS images for VM customization (#489)
399
        * Support random selection and enforcement of root password on Linux VMs (#485)
400
    GANETI BACKEND:
401
        * Design and implement mechanism for handling network connection requests,
402
          based on link ids of virtual NICs (#411)
403
        * Support handling of public and private networks,
404
          based on NFDHCPD and custom KVM ifup scripts (#407, #411)
405

  
406
FIXES:
407
    GUI:
408
        * Remove extraneous GET /server/id/meta requests (#463)
409
        * Fix location of the "Create New" wizard in IE (#467)
410
        * Make numerous hardcoded strings translatable (#473)
411
        * Fix alignment of step names in "Create New" wizard (#475)
412
        * Fix OS icons not appearing in Opera (#477)
413
        * Fix correspondence of OS icons to icon URIs (#481)
414
        * Fix console action inoperable in list view (#497)
415
        * Fix HTTP errors from backend not reported correctly (#523)
416
        * Fix handling of API "UKNNOWN" status for servers (#571)
417
        * Add SVG-derived icons for Fedora in multiple resolutions (#587)
418
        * Various minor UI glitches (#583, #585, #591)
419
    API:
420
        * Fix entering Greek characters in fields failed (was due to
421
          problem with db creation parameters in MySQL) (#499)
422
        * Fix return erroneous 304 NOT MOTIFIED for GET /servers if only
423
          server metadata modified (#525)
424
        * Fix return erroneous "UNKNOWN" status under specific circumstances (#573)
425
        * Remove private network connections when a server is deleted (#579)
426

  
427

  
428
KNOWN DEFECTS:
429

  
430
    GUI:
431
        * Does not work with relative URLs (cannot deploy under subdir) (#421)
432
        * UI breaks if "Create New" called twice in quick succession (#609)
433
        * Esc/Enter keys do not work in edit metadata window (#605)
434
        * No spinner icon on outstanding requests for updates to private networks (#607)
435
        * Error window overflows in case of longer-than-usual traceback in
436
          "Details" field (#611)
437
        * Single-server view does not update properly (#613)
438
    IMAGES:
439
        * Image deployment mechanism does not set Linux hostname properly (#603)
440
    GANETI BACKEND:
441
        * No IPv6 reported from the Synnefo Ganeti hook to the API
442
          (backend, API and UI can all handle IPv6 though) (#615)
443
        * All VMs currently allocated to the first Ganeti node, since no
444
          allocator has been installed in the development Ganeti yet (#617)
445
    Deployment:
446
        * No rigorous testing of data migration, migrations in real-world
447
          conditions will probably fail (#503)
448

  
449

  
450
2011-05-10, v0.3
451

  
452
FIXES/NEW FEATURES:
453

  
454
    GUI:
455
        * Report connection failures correctly, instead of a bogus 503 error (#427)
456
        * Support rename Virtual Machines using a nifty pencil icon (#429)
457
        * Fix complete failure of site with IE (starts, has known defects) (#431)
458
        * Support expanding box in icon view, containing metadata info (#375, #435, #441)
459
        * Support providing X-Auth-Token headers for authentication (#455)
460
        * Support Java applet-based popup for VNC console access (#391)
461
        * Initial implementation of "networks" tab interface mockup, no actual functionality (#415)
462
    AAI:
463
        * End-to-end Shibboleth support (#345)
464
    API:
465
        * Support creation, management and removal of private L2 networks (#409, #457)
466
        * Fix API implementation does not return unAuthorized cloud faults (#459)
467
        * Merge support for X-Auth-Token based authentication (#423)
468
    Logic:
469
        * Re-engineer messaging layer, migrate from 0mq to an AMQP-based infrastructure (#393)
470
        * Extended dispatcher, provides the context for executing business layer functions (#393)
471
        * Extended Ganeti event daemon, publish notifications over AMQP (#393)
472
        * Support a generic Synnefo hook in Ganeti, publish notifications over AMQP (#393, #397)
473
        * Extend logic layer, process NIC configuration notifications, update VM info in DB (#397)
474
    Deployment:
475
        * Add improved version of README.deploy, detailing node types in a Synnefo deployment
476

  
477
KNOWN DEFECTS:
478

  
479
    GUI:
480
        * Inoperative console action in list view (#497)
481
        * Various UI glitches under Chrome/Safari (wizard)
482
        * Serious functionality glitches with IE (no auto-refresh, no machine rename)
483
        * Serious UI glitches with non-standard dpi settings (#343)
484
        * Does not work with relative URLs (cannot deploy under subdir) (#421)
485
    API:
486
        * No Greek characters allowed in server names with the MySQL backend (#499)
487
    Deployment:
488
        * No rigorous testing of data migration, migrations in real-world conditions will probably fail (#503)
489

  
490

  
491
2011-04-19, v0.2.2
492

  
493
Bug fix release:
494
    GUI:
495
        * Fix start operation breakage due to extra argument in API call (#433)
496

  
497

  
498
2011-04-19, v0.2.1
499

  
500
Bug fix release:
501
    GUI:
502
        * Fix shutdown operation breakage due to extra argument in API call (#433)
503

  
504

  
505
2011-04-19, v0.2
506

  
507
FIXES/NEW FEATURES:
508

  
509
    GUI:
510
        * Show transitional state when command is in progress ("Starting", etc) (#401)
511
        * Allow only "destroy" for machines being built (#399)
512
        * Show nice icons for the icon, list and single view (#389)
513
        * Show the VM configuration (flavor) in list view (#387)
514
        * Add Destroy action in icon view (#381)
515
        * Show spinner when action is in progress (#379)
516
        * Handle OS icons properly for Images and machines, user-controlled (#257)
517
        * Support modification of VM metadata (currently: only addition, removal) (#375)
518
        * Support machine rename (#307)
519
        * Show welcome screen when no VMs defined (#279)
520
        * Revamped "Create New" wizard (#83)
521
    API:
522
        * Return buildInProgress properly (#351)
523
        * Loads of new unit tests (#417)
524
        * Support OOB console access over VNC using vncauthproxy
525
            - Run as daemon, support automatic port selection (#419)
526
        * Refactor ganeti-0mqd
527
            - Run as daemon, receive messages from Ganeti hooks, publish over 0mq
528
    Deployment:
529
        * Add initial version of README.deploy, detailing service dependencies
530
        * Add support for database migrations, using Django South (#371)
531
        * Install continuous integration platform (Jenkins), run tests automatically (#383)
532

  
533
KNOWN DEFECTS:
534

  
535
    GUI:
536
        * Minor visual problems with Firefox 3.5 (#403)
537
        * Major cross-browser compatibility problems (no IE support) (#431, #341)
538
        * Requires installation under /, does not work with relative URLs (#421)
539
        * Incorrect 503 return code when server is unreachable (#427)
/dev/null
1
recursive-include docs *.rst
2
recursive-include synnefo *.html *.js *.txt *.css *.jpg *.png *.gif *.json *.xml *.json
3
include distribute_setup.py Changelog README
/dev/null
1
README
2
=======
3

  
4
This is the top-level documentation file for the
5
Synnefo cloud management software.
6

  
7
Consult:
8
  * docs/src/develop.rst: for information on how to setup a development environment
9
  * docs/src/install.rst: for information on how to install the application
10
  * docs/src/deploy.rst:  for information on how to deploy the application
11
  * docs/src/ci.rst:      for information on how to setup a Jenkins-based
12
                          continuous integration system
13
  * docs/src/i18n.rst:    for information on application internationalization
14

  
15

  
16
Synnefo may be distributed under the terms of the following license:
17

  
18
Copyright 2011 GRNET S.A. All rights reserved.
19

  
20
Redistribution and use in source and binary forms, with or
21
without modification, are permitted provided that the following
22
conditions are met:
23

  
24
  1. Redistributions of source code must retain the above
25
     copyright notice, this list of conditions and the following
26
     disclaimer.
27

  
28
  2. Redistributions in binary form must reproduce the above
29
     copyright notice, this list of conditions and the following
30
     disclaimer in the documentation and/or other materials
31
     provided with the distribution.
32

  
33
THIS SOFTWARE IS PROVIDED BY GRNET S.A. ``AS IS'' AND ANY EXPRESS
34
OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
35
WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
36
PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL GRNET S.A OR
37
CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
38
SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
39
LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
40
USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED
41
AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
42
LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN
43
ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
44
POSSIBILITY OF SUCH DAMAGE.
45

  
46
The views and conclusions contained in the software and
47
documentation are those of the authors and should not be
48
interpreted as representing official policies, either expressed
49
or implied, of GRNET S.A.
/dev/null
1
#!python
2
"""Bootstrap distribute installation
3

  
4
If you want to use setuptools in your package's setup.py, just include this
5
file in the same directory with it, and add this to the top of your setup.py::
6

  
7
    from distribute_setup import use_setuptools
8
    use_setuptools()
9

  
10
If you want to require a specific version of setuptools, set a download
11
mirror, or use an alternate download directory, you can do so by supplying
12
the appropriate options to ``use_setuptools()``.
13

  
14
This file can also be run as a script to install or upgrade setuptools.
15
"""
16
import os
17
import sys
18
import time
19
import fnmatch
20
import tempfile
21
import tarfile
22
from distutils import log
23

  
24
try:
25
    from site import USER_SITE
26
except ImportError:
27
    USER_SITE = None
28

  
29
try:
30
    import subprocess
31

  
32
    def _python_cmd(*args):
33
        args = (sys.executable,) + args
34
        return subprocess.call(args) == 0
35

  
36
except ImportError:
37
    # will be used for python 2.3
38
    def _python_cmd(*args):
39
        args = (sys.executable,) + args
40
        # quoting arguments if windows
41
        if sys.platform == 'win32':
42
            def quote(arg):
43
                if ' ' in arg:
44
                    return '"%s"' % arg
45
                return arg
46
            args = [quote(arg) for arg in args]
47
        return os.spawnl(os.P_WAIT, sys.executable, *args) == 0
48

  
49
DEFAULT_VERSION = "0.6.10"
50
DEFAULT_URL = "http://pypi.python.org/packages/source/d/distribute/"
51
SETUPTOOLS_FAKED_VERSION = "0.6c11"
52

  
53
SETUPTOOLS_PKG_INFO = """\
54
Metadata-Version: 1.0
55
Name: setuptools
56
Version: %s
57
Summary: xxxx
58
Home-page: xxx
59
Author: xxx
60
Author-email: xxx
61
License: xxx
62
Description: xxx
63
""" % SETUPTOOLS_FAKED_VERSION
64

  
65

  
66
def _install(tarball):
67
    # extracting the tarball
68
    tmpdir = tempfile.mkdtemp()
69
    log.warn('Extracting in %s', tmpdir)
70
    old_wd = os.getcwd()
71
    try:
72
        os.chdir(tmpdir)
73
        tar = tarfile.open(tarball)
74
        _extractall(tar)
75
        tar.close()
76

  
77
        # going in the directory
78
        subdir = os.path.join(tmpdir, os.listdir(tmpdir)[0])
79
        os.chdir(subdir)
80
        log.warn('Now working in %s', subdir)
81

  
82
        # installing
83
        log.warn('Installing Distribute')
84
        if not _python_cmd('setup.py', 'install'):
85
            log.warn('Something went wrong during the installation.')
86
            log.warn('See the error message above.')
87
    finally:
88
        os.chdir(old_wd)
89

  
90

  
91
def _build_egg(egg, tarball, to_dir):
92
    # extracting the tarball
93
    tmpdir = tempfile.mkdtemp()
94
    log.warn('Extracting in %s', tmpdir)
95
    old_wd = os.getcwd()
96
    try:
97
        os.chdir(tmpdir)
98
        tar = tarfile.open(tarball)
99
        _extractall(tar)
100
        tar.close()
101

  
102
        # going in the directory
103
        subdir = os.path.join(tmpdir, os.listdir(tmpdir)[0])
104
        os.chdir(subdir)
105
        log.warn('Now working in %s', subdir)
106

  
107
        # building an egg
108
        log.warn('Building a Distribute egg in %s', to_dir)
109
        _python_cmd('setup.py', '-q', 'bdist_egg', '--dist-dir', to_dir)
110

  
111
    finally:
112
        os.chdir(old_wd)
113
    # returning the result
114
    log.warn(egg)
115
    if not os.path.exists(egg):
116
        raise IOError('Could not build the egg.')
117

  
118

  
119
def _do_download(version, download_base, to_dir, download_delay):
120
    egg = os.path.join(to_dir, 'distribute-%s-py%d.%d.egg'
121
                       % (version, sys.version_info[0], sys.version_info[1]))
122
    if not os.path.exists(egg):
123
        tarball = download_setuptools(version, download_base,
124
                                      to_dir, download_delay)
125
        _build_egg(egg, tarball, to_dir)
126
    sys.path.insert(0, egg)
127
    import setuptools
128
    setuptools.bootstrap_install_from = egg
129

  
130

  
131
def use_setuptools(version=DEFAULT_VERSION, download_base=DEFAULT_URL,
132
                   to_dir=os.curdir, download_delay=15, no_fake=True):
133
    # making sure we use the absolute path
134
    to_dir = os.path.abspath(to_dir)
135
    was_imported = 'pkg_resources' in sys.modules or \
136
        'setuptools' in sys.modules
137
    try:
138
        try:
139
            import pkg_resources
140
            if not hasattr(pkg_resources, '_distribute'):
141
                if not no_fake:
142
                    _fake_setuptools()
143
                raise ImportError
144
        except ImportError:
145
            return _do_download(version, download_base, to_dir, download_delay)
146
        try:
147
            pkg_resources.require("distribute>="+version)
148
            return
149
        except pkg_resources.VersionConflict:
150
            e = sys.exc_info()[1]
151
            if was_imported:
152
                sys.stderr.write(
153
                "The required version of distribute (>=%s) is not available,\n"
154
                "and can't be installed while this script is running. Please\n"
155
                "install a more recent version first, using\n"
156
                "'easy_install -U distribute'."
157
                "\n\n(Currently using %r)\n" % (version, e.args[0]))
158
                sys.exit(2)
159
            else:
160
                del pkg_resources, sys.modules['pkg_resources']    # reload ok
161
                return _do_download(version, download_base, to_dir,
162
                                    download_delay)
163
        except pkg_resources.DistributionNotFound:
164
            return _do_download(version, download_base, to_dir,
165
                                download_delay)
166
    finally:
167
        if not no_fake:
168
            _create_fake_setuptools_pkg_info(to_dir)
169

  
170
def download_setuptools(version=DEFAULT_VERSION, download_base=DEFAULT_URL,
171
                        to_dir=os.curdir, delay=15):
172
    """Download distribute from a specified location and return its filename
173

  
174
    `version` should be a valid distribute version number that is available
175
    as an egg for download under the `download_base` URL (which should end
176
    with a '/'). `to_dir` is the directory where the egg will be downloaded.
177
    `delay` is the number of seconds to pause before an actual download
178
    attempt.
179
    """
180
    # making sure we use the absolute path
181
    to_dir = os.path.abspath(to_dir)
182
    try:
183
        from urllib.request import urlopen
184
    except ImportError:
185
        from urllib2 import urlopen
186
    tgz_name = "distribute-%s.tar.gz" % version
187
    url = download_base + tgz_name
188
    saveto = os.path.join(to_dir, tgz_name)
189
    src = dst = None
190
    if not os.path.exists(saveto):  # Avoid repeated downloads
191
        try:
192
            log.warn("Downloading %s", url)
193
            src = urlopen(url)
194
            # Read/write all in one block, so we don't create a corrupt file
195
            # if the download is interrupted.
196
            data = src.read()
197
            dst = open(saveto, "wb")
198
            dst.write(data)
199
        finally:
200
            if src:
201
                src.close()
202
            if dst:
203
                dst.close()
204
    return os.path.realpath(saveto)
205

  
206
def _no_sandbox(function):
207
    def __no_sandbox(*args, **kw):
208
        try:
209
            from setuptools.sandbox import DirectorySandbox
210
            if not hasattr(DirectorySandbox, '_old'):
211
                def violation(*args):
212
                    pass
213
                DirectorySandbox._old = DirectorySandbox._violation
214
                DirectorySandbox._violation = violation
215
                patched = True
216
            else:
217
                patched = False
218
        except ImportError:
219
            patched = False
220

  
221
        try:
222
            return function(*args, **kw)
223
        finally:
224
            if patched:
225
                DirectorySandbox._violation = DirectorySandbox._old
226
                del DirectorySandbox._old
227

  
228
    return __no_sandbox
229

  
230
def _patch_file(path, content):
231
    """Will backup the file then patch it"""
232
    existing_content = open(path).read()
233
    if existing_content == content:
234
        # already patched
235
        log.warn('Already patched.')
236
        return False
237
    log.warn('Patching...')
238
    _rename_path(path)
239
    f = open(path, 'w')
240
    try:
241
        f.write(content)
242
    finally:
243
        f.close()
244
    return True
245

  
246
_patch_file = _no_sandbox(_patch_file)
247

  
248
def _same_content(path, content):
249
    return open(path).read() == content
250

  
251
def _rename_path(path):
252
    new_name = path + '.OLD.%s' % time.time()
253
    log.warn('Renaming %s into %s', path, new_name)
254
    os.rename(path, new_name)
255
    return new_name
256

  
257
def _remove_flat_installation(placeholder):
258
    if not os.path.isdir(placeholder):
259
        log.warn('Unkown installation at %s', placeholder)
260
        return False
261
    found = False
262
    for file in os.listdir(placeholder):
263
        if fnmatch.fnmatch(file, 'setuptools*.egg-info'):
264
            found = True
265
            break
266
    if not found:
267
        log.warn('Could not locate setuptools*.egg-info')
268
        return
269

  
270
    log.warn('Removing elements out of the way...')
271
    pkg_info = os.path.join(placeholder, file)
272
    if os.path.isdir(pkg_info):
273
        patched = _patch_egg_dir(pkg_info)
274
    else:
275
        patched = _patch_file(pkg_info, SETUPTOOLS_PKG_INFO)
276

  
277
    if not patched:
278
        log.warn('%s already patched.', pkg_info)
279
        return False
280
    # now let's move the files out of the way
281
    for element in ('setuptools', 'pkg_resources.py', 'site.py'):
282
        element = os.path.join(placeholder, element)
283
        if os.path.exists(element):
284
            _rename_path(element)
285
        else:
286
            log.warn('Could not find the %s element of the '
287
                     'Setuptools distribution', element)
288
    return True
289

  
290
_remove_flat_installation = _no_sandbox(_remove_flat_installation)
291

  
292
def _after_install(dist):
293
    log.warn('After install bootstrap.')
294
    placeholder = dist.get_command_obj('install').install_purelib
295
    _create_fake_setuptools_pkg_info(placeholder)
296

  
297
def _create_fake_setuptools_pkg_info(placeholder):
298
    if not placeholder or not os.path.exists(placeholder):
299
        log.warn('Could not find the install location')
300
        return
301
    pyver = '%s.%s' % (sys.version_info[0], sys.version_info[1])
302
    setuptools_file = 'setuptools-%s-py%s.egg-info' % \
303
            (SETUPTOOLS_FAKED_VERSION, pyver)
304
    pkg_info = os.path.join(placeholder, setuptools_file)
305
    if os.path.exists(pkg_info):
306
        log.warn('%s already exists', pkg_info)
307
        return
308

  
309
    log.warn('Creating %s', pkg_info)
310
    f = open(pkg_info, 'w')
311
    try:
312
        f.write(SETUPTOOLS_PKG_INFO)
313
    finally:
314
        f.close()
315

  
316
    pth_file = os.path.join(placeholder, 'setuptools.pth')
317
    log.warn('Creating %s', pth_file)
318
    f = open(pth_file, 'w')
319
    try:
320
        f.write(os.path.join(os.curdir, setuptools_file))
321
    finally:
322
        f.close()
323

  
324
_create_fake_setuptools_pkg_info = _no_sandbox(_create_fake_setuptools_pkg_info)
325

  
326
def _patch_egg_dir(path):
327
    # let's check if it's already patched
328
    pkg_info = os.path.join(path, 'EGG-INFO', 'PKG-INFO')
329
    if os.path.exists(pkg_info):
330
        if _same_content(pkg_info, SETUPTOOLS_PKG_INFO):
331
            log.warn('%s already patched.', pkg_info)
332
            return False
333
    _rename_path(path)
334
    os.mkdir(path)
335
    os.mkdir(os.path.join(path, 'EGG-INFO'))
336
    pkg_info = os.path.join(path, 'EGG-INFO', 'PKG-INFO')
337
    f = open(pkg_info, 'w')
338
    try:
339
        f.write(SETUPTOOLS_PKG_INFO)
340
    finally:
341
        f.close()
342
    return True
343

  
344
_patch_egg_dir = _no_sandbox(_patch_egg_dir)
345

  
346
def _before_install():
347
    log.warn('Before install bootstrap.')
348
    _fake_setuptools()
349

  
350

  
351
def _under_prefix(location):
352
    if 'install' not in sys.argv:
353
        return True
354
    args = sys.argv[sys.argv.index('install')+1:]
355
    for index, arg in enumerate(args):
356
        for option in ('--root', '--prefix'):
357
            if arg.startswith('%s=' % option):
358
                top_dir = arg.split('root=')[-1]
359
                return location.startswith(top_dir)
360
            elif arg == option:
361
                if len(args) > index:
362
                    top_dir = args[index+1]
363
                    return location.startswith(top_dir)
364
        if arg == '--user' and USER_SITE is not None:
365
            return location.startswith(USER_SITE)
366
    return True
367

  
368

  
369
def _fake_setuptools():
370
    log.warn('Scanning installed packages')
371
    try:
372
        import pkg_resources
373
    except ImportError:
374
        # we're cool
375
        log.warn('Setuptools or Distribute does not seem to be installed.')
376
        return
377
    ws = pkg_resources.working_set
378
    try:
379
        setuptools_dist = ws.find(pkg_resources.Requirement.parse('setuptools',
380
                                  replacement=False))
381
    except TypeError:
382
        # old distribute API
383
        setuptools_dist = ws.find(pkg_resources.Requirement.parse('setuptools'))
384

  
385
    if setuptools_dist is None:
386
        log.warn('No setuptools distribution found')
387
        return
388
    # detecting if it was already faked
389
    setuptools_location = setuptools_dist.location
390
    log.warn('Setuptools installation detected at %s', setuptools_location)
391

  
392
    # if --root or --preix was provided, and if
393
    # setuptools is not located in them, we don't patch it
394
    if not _under_prefix(setuptools_location):
395
        log.warn('Not patching, --root or --prefix is installing Distribute'
396
                 ' in another location')
397
        return
398

  
399
    # let's see if its an egg
400
    if not setuptools_location.endswith('.egg'):
401
        log.warn('Non-egg installation')
402
        res = _remove_flat_installation(setuptools_location)
403
        if not res:
404
            return
405
    else:
406
        log.warn('Egg installation')
407
        pkg_info = os.path.join(setuptools_location, 'EGG-INFO', 'PKG-INFO')
408
        if (os.path.exists(pkg_info) and
409
            _same_content(pkg_info, SETUPTOOLS_PKG_INFO)):
410
            log.warn('Already patched.')
411
            return
412
        log.warn('Patching...')
413
        # let's create a fake egg replacing setuptools one
414
        res = _patch_egg_dir(setuptools_location)
415
        if not res:
416
            return
417
    log.warn('Patched done.')
418
    _relaunch()
419

  
420

  
421
def _relaunch():
422
    log.warn('Relaunching...')
423
    # we have to relaunch the process
424
    # pip marker to avoid a relaunch bug
425
    if sys.argv[:3] == ['-c', 'install', '--single-version-externally-managed']:
426
        sys.argv[0] = 'setup.py'
427
    args = [sys.executable] + sys.argv
428
    sys.exit(subprocess.call(args))
429

  
430

  
431
def _extractall(self, path=".", members=None):
432
    """Extract all members from the archive to the current working
433
       directory and set owner, modification time and permissions on
434
       directories afterwards. `path' specifies a different directory
435
       to extract to. `members' is optional and must be a subset of the
436
       list returned by getmembers().
437
    """
438
    import copy
439
    import operator
440
    from tarfile import ExtractError
441
    directories = []
442

  
443
    if members is None:
444
        members = self
445

  
446
    for tarinfo in members:
447
        if tarinfo.isdir():
448
            # Extract directories with a safe mode.
449
            directories.append(tarinfo)
450
            tarinfo = copy.copy(tarinfo)
451
            tarinfo.mode = 448 # decimal for oct 0700
452
        self.extract(tarinfo, path)
453

  
454
    # Reverse sort directories.
455
    if sys.version_info < (2, 4):
456
        def sorter(dir1, dir2):
457
            return cmp(dir1.name, dir2.name)
458
        directories.sort(sorter)
459
        directories.reverse()
460
    else:
461
        directories.sort(key=operator.attrgetter('name'), reverse=True)
462

  
463
    # Set correct owner, mtime and filemode on directories.
464
    for tarinfo in directories:
465
        dirpath = os.path.join(path, tarinfo.name)
466
        try:
467
            self.chown(tarinfo, dirpath)
468
            self.utime(tarinfo, dirpath)
469
            self.chmod(tarinfo, dirpath)
470
        except ExtractError:
471
            e = sys.exc_info()[1]
472
            if self.errorlevel > 1:
473
                raise
474
            else:
475
                self._dbg(1, "tarfile: %s" % e)
476

  
477

  
478
def main(argv, version=DEFAULT_VERSION):
479
    """Install or upgrade setuptools and EasyInstall"""
480
    tarball = download_setuptools()
481
    _install(tarball)
482

  
483

  
484
if __name__ == '__main__':
485
    main(sys.argv[1:])
/dev/null
1
# Makefile for Sphinx documentation
2
#
3

  
4
# You can set these variables from the command line.
5
SPHINXOPTS    =
6
SPHINXBUILD   = sphinx-build
7
PAPER         =
8
BUILDDIR      = _build
9

  
10
# Internal variables.
11
PAPEROPT_a4     = -D latex_paper_size=a4
12
PAPEROPT_letter = -D latex_paper_size=letter
13
ALLSPHINXOPTS   = -d $(BUILDDIR)/doctrees $(PAPEROPT_$(PAPER)) $(SPHINXOPTS) .
14
# the i18n builder cannot share the environment and doctrees with the others
15
I18NSPHINXOPTS  = $(PAPEROPT_$(PAPER)) $(SPHINXOPTS) .
16

  
17
.PHONY: help clean html dirhtml singlehtml pickle json htmlhelp qthelp devhelp epub latex latexpdf text man changes linkcheck doctest gettext
18

  
19
help:
20
	@echo "Please use \`make <target>' where <target> is one of"
21
	@echo "  html       to make standalone HTML files"
22
	@echo "  dirhtml    to make HTML files named index.html in directories"
23
	@echo "  singlehtml to make a single large HTML file"
24
	@echo "  pickle     to make pickle files"
25
	@echo "  json       to make JSON files"
26
	@echo "  htmlhelp   to make HTML files and a HTML help project"
27
	@echo "  qthelp     to make HTML files and a qthelp project"
28
	@echo "  devhelp    to make HTML files and a Devhelp project"
29
	@echo "  epub       to make an epub"
30
	@echo "  latex      to make LaTeX files, you can set PAPER=a4 or PAPER=letter"
31
	@echo "  latexpdf   to make LaTeX files and run them through pdflatex"
32
	@echo "  text       to make text files"
33
	@echo "  man        to make manual pages"
34
	@echo "  texinfo    to make Texinfo files"
35
	@echo "  info       to make Texinfo files and run them through makeinfo"
36
	@echo "  gettext    to make PO message catalogs"
37
	@echo "  changes    to make an overview of all changed/added/deprecated items"
38
	@echo "  linkcheck  to check all external links for integrity"
39
	@echo "  doctest    to run all doctests embedded in the documentation (if enabled)"
40

  
41
clean:
42
	-rm -rf $(BUILDDIR)/*
43

  
44
html:
45
	$(SPHINXBUILD) -b html $(ALLSPHINXOPTS) $(BUILDDIR)/html
46
	@echo
47
	@echo "Build finished. The HTML pages are in $(BUILDDIR)/html."
48

  
49
dirhtml:
50
	$(SPHINXBUILD) -b dirhtml $(ALLSPHINXOPTS) $(BUILDDIR)/dirhtml
51
	@echo
52
	@echo "Build finished. The HTML pages are in $(BUILDDIR)/dirhtml."
53

  
54
singlehtml:
55
	$(SPHINXBUILD) -b singlehtml $(ALLSPHINXOPTS) $(BUILDDIR)/singlehtml
56
	@echo
57
	@echo "Build finished. The HTML page is in $(BUILDDIR)/singlehtml."
58

  
59
pickle:
60
	$(SPHINXBUILD) -b pickle $(ALLSPHINXOPTS) $(BUILDDIR)/pickle
61
	@echo
62
	@echo "Build finished; now you can process the pickle files."
63

  
64
json:
65
	$(SPHINXBUILD) -b json $(ALLSPHINXOPTS) $(BUILDDIR)/json
66
	@echo
67
	@echo "Build finished; now you can process the JSON files."
68

  
69
htmlhelp:
70
	$(SPHINXBUILD) -b htmlhelp $(ALLSPHINXOPTS) $(BUILDDIR)/htmlhelp
71
	@echo
72
	@echo "Build finished; now you can run HTML Help Workshop with the" \
73
	      ".hhp project file in $(BUILDDIR)/htmlhelp."
74

  
75
qthelp:
76
	$(SPHINXBUILD) -b qthelp $(ALLSPHINXOPTS) $(BUILDDIR)/qthelp
77
	@echo
78
	@echo "Build finished; now you can run "qcollectiongenerator" with the" \
79
	      ".qhcp project file in $(BUILDDIR)/qthelp, like this:"
80
	@echo "# qcollectiongenerator $(BUILDDIR)/qthelp/Synnefo.qhcp"
81
	@echo "To view the help file:"
82
	@echo "# assistant -collectionFile $(BUILDDIR)/qthelp/Synnefo.qhc"
83

  
84
devhelp:
85
	$(SPHINXBUILD) -b devhelp $(ALLSPHINXOPTS) $(BUILDDIR)/devhelp
86
	@echo
87
	@echo "Build finished."
88
	@echo "To view the help file:"
89
	@echo "# mkdir -p $$HOME/.local/share/devhelp/Synnefo"
90
	@echo "# ln -s $(BUILDDIR)/devhelp $$HOME/.local/share/devhelp/Synnefo"
91
	@echo "# devhelp"
92

  
93
epub:
94
	$(SPHINXBUILD) -b epub $(ALLSPHINXOPTS) $(BUILDDIR)/epub
95
	@echo
96
	@echo "Build finished. The epub file is in $(BUILDDIR)/epub."
97

  
98
latex:
99
	$(SPHINXBUILD) -b latex $(ALLSPHINXOPTS) $(BUILDDIR)/latex
100
	@echo
101
	@echo "Build finished; the LaTeX files are in $(BUILDDIR)/latex."
102
	@echo "Run \`make' in that directory to run these through (pdf)latex" \
103
	      "(use \`make latexpdf' here to do that automatically)."
104

  
105
latexpdf:
106
	$(SPHINXBUILD) -b latex $(ALLSPHINXOPTS) $(BUILDDIR)/latex
107
	@echo "Running LaTeX files through pdflatex..."
108
	$(MAKE) -C $(BUILDDIR)/latex all-pdf
109
	@echo "pdflatex finished; the PDF files are in $(BUILDDIR)/latex."
110

  
111
text:
112
	$(SPHINXBUILD) -b text $(ALLSPHINXOPTS) $(BUILDDIR)/text
113
	@echo
114
	@echo "Build finished. The text files are in $(BUILDDIR)/text."
115

  
116
man:
117
	$(SPHINXBUILD) -b man $(ALLSPHINXOPTS) $(BUILDDIR)/man
118
	@echo
119
	@echo "Build finished. The manual pages are in $(BUILDDIR)/man."
120

  
121
texinfo:
122
	$(SPHINXBUILD) -b texinfo $(ALLSPHINXOPTS) $(BUILDDIR)/texinfo
123
	@echo
124
	@echo "Build finished. The Texinfo files are in $(BUILDDIR)/texinfo."
125
	@echo "Run \`make' in that directory to run these through makeinfo" \
126
	      "(use \`make info' here to do that automatically)."
127

  
128
info:
129
	$(SPHINXBUILD) -b texinfo $(ALLSPHINXOPTS) $(BUILDDIR)/texinfo
130
	@echo "Running Texinfo files through makeinfo..."
131
	make -C $(BUILDDIR)/texinfo info
132
	@echo "makeinfo finished; the Info files are in $(BUILDDIR)/texinfo."
133

  
134
gettext:
135
	$(SPHINXBUILD) -b gettext $(I18NSPHINXOPTS) $(BUILDDIR)/locale
136
	@echo
137
	@echo "Build finished. The message catalogs are in $(BUILDDIR)/locale."
138

  
139
changes:
140
	$(SPHINXBUILD) -b changes $(ALLSPHINXOPTS) $(BUILDDIR)/changes
141
	@echo
142
	@echo "The overview file is in $(BUILDDIR)/changes."
143

  
144
linkcheck:
145
	$(SPHINXBUILD) -b linkcheck $(ALLSPHINXOPTS) $(BUILDDIR)/linkcheck
146
	@echo
147
	@echo "Link check complete; look for any errors in the above output " \
148
	      "or in $(BUILDDIR)/linkcheck/output.txt."
149

  
150
doctest:
151
	$(SPHINXBUILD) -b doctest $(ALLSPHINXOPTS) $(BUILDDIR)/doctest
152
	@echo "Testing of doctests in the sources finished, look at the " \
153
	      "results in $(BUILDDIR)/doctest/output.txt."
/dev/null
1
# database configuration
2
DATABASES = {
3
    'default': {
4
        'ENGINE': 'django.db.backends.', # Add 'postgresql_psycopg2', 'mysql', 'sqlite3' or 'oracle'.
5
        'NAME': '',                      # Or path to database file if using sqlite3.
6
        'USER': '',                      # Not used with sqlite3.
7
        'PASSWORD': '',                  # Not used with sqlite3.
8
        'HOST': '',                      # Set to empty string for localhost. Not used with sqlite3.
9
        'PORT': '',                      # Set to empty string for default. Not used with sqlite3.
10
    }
11
}
12

  
13
# where synnefo static files exist
14
MEDIA_ROOT = '/var/lib/synnefo/static/'
15

  
16
# rabitmq configuration
17
RABBIT_HOST = ""
18
RABBIT_USERNAME = ""
19
RABBIT_PASSWORD = ""
20
RABBIT_VHOST = "/"
21

  
22
GANETI_MASTER_IP = ""
23
GANETI_CLUSTER_INFO = (GANETI_MASTER_IP, 5080, "<username>", "<password>")
24

  
25
# This prefix gets used when determining the instance names
26
# of Synnefo VMs at the Ganeti backend.
27
# The dash must always appear in the name!
28
BACKEND_PREFIX_ID = "<prefix>-"
/dev/null
1
server {
2
    listen 80;
3

  
4
    server_name synnefo.local;
5
    
6
    root /var/lib/synnefo/;
7
    
8
    # serving static files 
9
    location /static  {
10
        autoindex on;
11
        root /var/lib/synnefo/;
12
    }
13

  
14
    location / {
15
        
16
        # host and port to fastcgi server
17
        fastcgi_pass 127.0.0.1:8015;
18

  
19
        fastcgi_param PATH_INFO          $fastcgi_script_name;
20
        fastcgi_param REQUEST_METHOD     $request_method;
21
        fastcgi_param QUERY_STRING       $query_string;
22
        fastcgi_param CONTENT_TYPE       $content_type;
23
        fastcgi_param CONTENT_LENGTH     $content_length;
24
        fastcgi_param SERVER_ADDR        $server_addr;
25
        fastcgi_param SERVER_PORT        $server_port;
26
        fastcgi_param SERVER_NAME        $server_name;
27
        fastcgi_param  SERVER_PROTOCOL  $server_protocol;
28
        fastcgi_pass_header Authorization;
29
        fastcgi_intercept_errors off;
30
    }
31
}
/dev/null
1
[
2
    {
3
        "model": "db.SynnefoUser",
4
        "pk": 1,
5
        "fields": {
6
            "name": "testdbuser",
7
            "realname" :"test db user",
8
            "uniq" :"test@synnefo.gr",
9
            "credit": 10,
10
            "auth_token": "46e427d657b20defe352804f0eb6f8a2",
11
            "auth_token_created": "2011-05-10",
12
            "auth_token_expires": "2015-05-10",
13
            "type": "ADMIN",
14
            "created": "2011-05-10",
15
            "max_invitations" : 1000
16
   	    }
17
    },
18
    {
19
        "model": "db.SynnefoUser",
20
        "pk": 2,
21
        "fields": {
22
            "name": "helpdesk",
23
            "realname" :"HelpDesk user",
24
            "uniq" :"helpdesk@synnefo.grnet.gr",
25
            "credit": 10,
26
            "auth_token": "839636858b1feafd37010f05dc4582e2",
27
            "auth_token_created": "2011-05-10",
28
            "auth_token_expires": "2015-05-10",
29
            "type": "HELPDESK",
30
            "created": "2011-05-10",
31
            "max_invitations" : 10
32
   	    }
33
    },
34
    {
35
        "model" : "db.Invitations",
36
        "pk" : 1,
37
        "fields": {
38
            "source": 1,
39
            "target": 1,
40
            "accepted": "True",
41
            "level" : -1,
42
            "created": "2011-06-01",
43
            "updated": "2011-06-01"
44
        }
45
    }
46
] 
/dev/null
1
# -*- coding: utf-8 -*-
2
#
3
# Synnefo documentation build configuration file, created by
4
# sphinx-quickstart on Mon Nov 21 10:56:41 2011.
5
#
6
# This file is execfile()d with the current directory set to its containing dir.
7
#
8
# Note that not all possible configuration values are present in this
9
# autogenerated file.
10
#
11
# All configuration values have a default; values that are commented out
12
# serve to show the default.
13

  
14
import sys, os
15

  
16
# If extensions (or modules to document with autodoc) are in another directory,
17
# add these directories to sys.path here. If the directory is relative to the
18
# documentation root, use os.path.abspath to make it absolute, like shown here.
19
sys.path.insert(0, os.path.abspath('..'))
20

  
21
# -- General configuration -----------------------------------------------------
22

  
23
# If your documentation needs a minimal Sphinx version, state it here.
24
#needs_sphinx = '1.0'
25

  
26
# Add any Sphinx extension module names here, as strings. They can be extensions
27
# coming with Sphinx (named 'sphinx.ext.*') or your custom ones.
28
extensions = ['sphinx.ext.autodoc', 'sphinx.ext.todo']
29

  
30
# Add any paths that contain templates here, relative to this directory.
31
templates_path = ['_templates']
32

  
33
# The suffix of source filenames.
34
source_suffix = '.rst'
35

  
36
# The encoding of source files.
37
#source_encoding = 'utf-8-sig'
38

  
39
# The master toctree document.
40
master_doc = 'index'
41

  
42
# General information about the project.
43
project = u'Synnefo'
44
copyright = u'2011, GRNet.gr'
45

  
46
# The version info for the project you're documenting, acts as replacement for
47
# |version| and |release|, also used in various other places throughout the
48
# built documents.
49
#
50
# The short X.Y version.
51
version = '0.8'
52
# The full version, including alpha/beta/rc tags.
53
release = '0.8rc1'
54

  
55
# The language for content autogenerated by Sphinx. Refer to documentation
56
# for a list of supported languages.
57
#language = None
58

  
59
# There are two options for replacing |today|: either, you set today to some
60
# non-false value, then it is used:
61
#today = ''
62
# Else, today_fmt is used as the format for a strftime call.
63
#today_fmt = '%B %d, %Y'
64

  
65
# List of patterns, relative to source directory, that match files and
66
# directories to ignore when looking for source files.
67
exclude_patterns = ['_build']
68

  
69
# The reST default role (used for this markup: `text`) to use for all documents.
70
#default_role = None
71

  
72
# If true, '()' will be appended to :func: etc. cross-reference text.
73
#add_function_parentheses = True
74

  
75
# If true, the current module name will be prepended to all description
76
# unit titles (such as .. function::).
77
#add_module_names = True
78

  
79
# If true, sectionauthor and moduleauthor directives will be shown in the
80
# output. They are ignored by default.
81
#show_authors = False
82

  
83
# The name of the Pygments (syntax highlighting) style to use.
84
pygments_style = 'sphinx'
85

  
86
# A list of ignored prefixes for module index sorting.
87
#modindex_common_prefix = []
88

  
89

  
90
# -- Options for HTML output ---------------------------------------------------
91

  
92
# The theme to use for HTML and HTML Help pages.  See the documentation for
93
# a list of builtin themes.
94
html_theme = 'nature'
... This diff was truncated because it exceeds the maximum size that can be displayed.

Also available in: Unified diff