source: INSTALL.rst @ 75617ad

cremcrem2crem3devdev2diademsdj1.6feature/breadcrumbsfeature/ts-0.5feature/ts-0.5.4feature/writecacheformagenericinstru_searchlamlam2mapsv3mergenlivemultiprobproductionrelease/1.4.4sabiodsearchsecurityserversocialstoragetelecastertestvideo
Last change on this file since 75617ad was 75617ad, checked in by yomguy <yomguy@…>, 3 years ago

100 of last revisions in RSS, fix save buttons for item, remove TELEMETA_OAI_HOST_NAME global parameter, add TELEMETA_DESCRIPTION and parsing it to each page title

  • Property mode set to 100644
File size: 7.7 KB
Line 
1==================
2Telemeta - INSTALL
3==================
4
5-----------------
6Requirements
7-----------------
8
9Telemeta is designed to run on Linux and other UNIX based architectures.
10It depends on several python librairies like Django (version >= 1.1.1).
11See http://djangoproject.com.
12
13Other needed librairies are listed below.
14
15-----------------------
16Install the software
17-----------------------
18
19Install the dependencies
20-------------------------
21
22* On Debian (Squeeze recommended) or Ubuntu Lucid:
23
24    Install all dependencies like this::
25       
26        sudo aptitude install python python-django python-xml python-mysqldb mysql-server \
27                              python-ctypes python-setuptools python-support python-docutils \
28                              python-libxml2 python-django-registration
29
30    To get MP3 reading and writing, just add these lines to your /etc/apt/sources-list::
31
32        deb http://www.debian-multimedia.org stable main
33
34    Then::
35
36        sudo apt-get update
37        sudo aptitude install gstreamer0.10-fluendo-mp3 gstreamer0.10-lame
38
39* On other linux platforms:
40
41    Please install all dependencies thanks to your application manager.
42
43
44Install TimeSide
45-----------------
46
47Telemeta needs the audio processing library named TimeSide (>= 0.3)
48You have to download and install it from source.
49
50So, download the last archive at :
51http://code.google.com/p/timeside/downloads/list
52
53Uncompress it and see README and INSTALL to install the dependencies
54and then the module.
55
56
57Install JSON-RPC server
58------------------------
59
60In order to use markers on the player, you will need a JSON-RPC server for django::
61   
62    git clone git://github.com/samuraisam/django-json-rpc.git
63    cd django-json-rpc
64    python setup.py install
65
66
67Install Telemeta
68------------------
69
70* On Debian style systems, if you have added our repositories::
71
72    sudo apt-get install telemeta
73
74* Else:
75
76    Download the latest release of telemeta at
77    http://telemeta.org
78
79    Uncompress the archive like::
80
81        tar xzvf telemeta_0.9.6.tar.gz
82
83    Go to the main folder of telemeta and run this command
84    in a shell as root::
85
86        sudo python setup.py install
87
88---------------------
89Fast testing
90
91--------------------------
92Create a Django project
93--------------------------
94
95If you haven't already done it, start a new django project::
96
97    cd ~/my_projects
98    django-admin startproject mysite
99
100
101-----------------------------------------
102Create the media and cache directories
103-----------------------------------------
104
105We need 2 directories for media and caching::
106
107    cd mysite
108    mkdir media cache cache/data cache/export
109
110
111You might want to place these data directories somewhere else, no pb.
112
113------------------------
114Create the database
115------------------------
116
117Telemeta needs MySQL to work well and fast. So you need to create a MySQL database before trying it.
118
119----------------------------------
120Configure the telemeta project
121----------------------------------
122
123Edit the file settings.py in a text editor.
124Modifiy the following variables:
125
126    ADMINS =            telemeta requires that you indicate an administrator here
127    DATABASES =         your database setting dict (don't forget to create the database if needed)
128    MEDIA_ROOT =        absolute path to the media directory you just created
129
130Set the app lists as follow::
131   
132    INSTALLED_APPS = (
133    'django.contrib.auth',
134    'django.contrib.contenttypes',
135    'django.contrib.sessions',
136    'django.contrib.sites',
137    'django.contrib.messages',
138    'django.contrib.admin',
139    'telemeta',
140    'jsonrpc',
141    )
142
143Set the following languages:
144   
145    LANGUAGES = [ ('fr', 'French'),
146                  ('en', 'English'),
147    ]
148
149
150Set the following Middlewares:
151   
152    MIDDLEWARE_CLASSES = (
153        'django.middleware.common.CommonMiddleware',
154        'django.contrib.sessions.middleware.SessionMiddleware',
155        'django.middleware.csrf.CsrfViewMiddleware',
156        'django.contrib.auth.middleware.AuthenticationMiddleware',
157        'django.contrib.messages.middleware.MessageMiddleware',
158        'django.middleware.locale.LocaleMiddleware',
159    )
160
161Add the following variables:
162   
163    TEMPLATE_CONTEXT_PROCESSORS = (
164        'django.core.context_processors.request',
165        'django.contrib.auth.context_processors.auth',)
166
167    TELEMETA_ORGANIZATION =         name of the organization which hosts this installation
168    TELEMETA_SUBJECTS =             tuple of subject keywords (used for Dublin Core), such as "Ethnology", etc...
169    TELEMETA_DESCRIPTION =          the description of the site
170    TELEMETA_CACHE_DIR =            absolute path to the cache directory that you just created
171    TELEMETA_GMAP_KEY =             your Google Map API key
172    TELEMETA_DOWNLOAD_ENABLED =     True to enable raw audio data download
173    TELEMETA_STREAMING_FORMATS =    tuple of authoized streaming formats. Ex : ('mp3', 'ogg')
174    TELEMETA_PUBLIC_ACCESS_PERIOD = number of years above which item files are automagically published
175    EMAIL_HOST =                    your default SMTP server
176    DEFAULT_FROM_EMAIL =            the default sending email address
177   
178Just paste the lines below::
179
180    LOGIN_URL = '/login'
181    LOGIN_REDIRECT_URL = '/'
182    AUTH_PROFILE_MODULE = 'telemeta.userprofile'
183    TELEMETA_EXPORT_CACHE_DIR = TELEMETA_CACHE_DIR + "/export"
184    TELEMETA_DATA_CACHE_DIR = TELEMETA_CACHE_DIR + "/data"
185    CACHE_BACKEND = "file://" + TELEMETA_CACHE_DIR + "/data"
186
187If you want some personal templates, for example::
188   
189    TEMPLATE_DIRS = (
190    '/home/dev/telemeta/sandboxes/sandbox_generic/templates/',
191    )
192
193
194You can find an example for settings.py there::
195   
196    conf/examples/django/settings.py
197
198
199--------------------------
200Initialize the database
201--------------------------
202
203This synchronizes the DB with the model::
204
205    python manage.py syncdb
206
207
208----------------------
209Configure your urls
210----------------------
211
212Add this dictionary to get Javascript translation::
213   
214    js_info_dict = {
215        'packages': ('telemeta',),
216    }
217
218The simplest case is to have telemeta running at public root. To do so, add this url in urls.py::
219
220    # Telemeta
221    (r'^', include('telemeta.urls')),
222   
223    # Languages
224    (r'^i18n/', include('django.conf.urls.i18n')),   
225    (r'^jsi18n/$', 'django.views.i18n.javascript_catalog', js_info_dict),
226   
227You should also bring the django admin::
228   
229    (r'^admin/django/', include(admin.site.urls)),
230   
231Please also uncomment::
232   
233    from django.contrib import admin
234    admin.autodiscover()
235
236You can find an example for url.py there::
237   
238    conf/examples/django/urls.py
239
240
241--------------------
242Start the project
243--------------------
244
245We are ready to start the telemeta server::
246
247    python manage.py runserver
248
249By default, the server starts on the port 8000. You can override this with, for example::
250
251    python manage.py runserver 9000
252
253
254-----------
255Test it
256-----------
257
258Go to this URL with your browser::
259
260    http://localhost:8000
261
262or::
263
264    http://localhost:9000
265
266
267Configure the site domain name in admin > general admin > sites
268
269Test it and enjoy it !
270
271--------------------------
272Template customization
273--------------------------
274
275Please see ::
276   
277    http://telemeta.org/wiki/InterfaceCustomization
278   
279   
280--------------------------
281Deploy it with Apache 2
282--------------------------
283
284If you want to use Telemeta through a web server, it is highly recommended to use Apache 2
285with the mod_wsgi module as explained in the following page :
286
287    http://docs.djangoproject.com/en/1.1/howto/deployment/modwsgi/#howto-deployment-modwsgi
288
289This will prevent Apache to put some audio data in the cache memory as it is usually the case with mod_python.
290
291You can find an example of an Apache2 VirtualHost conf file there::
292
293    example/apache2/telemeta.conf
294
295
296-------------------------
297Contact / More infos
298-------------------------
299
300See README and http://telemeta.org.
301
Note: See TracBrowser for help on using the repository browser.