| 1 |
Requirements: |
|---|
| 2 |
|
|---|
| 3 |
I have written in brackets Debian packages' name. |
|---|
| 4 |
|
|---|
| 5 |
For xai core: |
|---|
| 6 |
# apache2 (apache2) |
|---|
| 7 |
# mod_perl2 for apache2 (libapache2-mod-perl2) |
|---|
| 8 |
# mod_xslt for Apache2 (libapache2-modxslt) |
|---|
| 9 |
# XML::LibXml (libxml-libxml-common-perl libxml-simpleobject-libxml-perl) |
|---|
| 10 |
For image plugin: |
|---|
| 11 |
# Image::Size (libimage-size-perl) |
|---|
| 12 |
# Image::Info (libimage-base-bundle-perl) |
|---|
| 13 |
# Image::ImLib (libimage-imlib2-perl) |
|---|
| 14 |
For video plugin: |
|---|
| 15 |
# imagemagick (imagemagick) |
|---|
| 16 |
# mplayer (mplayer) |
|---|
| 17 |
# ffmpeg (ffmpeg) |
|---|
| 18 |
# mencoder (mencoder) |
|---|
| 19 |
For OpenDocument |
|---|
| 20 |
# imagemagick (imagemagick) |
|---|
| 21 |
# unzip (unzip) |
|---|
| 22 |
# For Pdf imagemagick (imagemagick) |
|---|
| 23 |
# ghostscript (gs-common) |
|---|
| 24 |
For audio plugin: |
|---|
| 25 |
# mplayer (mplayer) |
|---|
| 26 |
|
|---|
| 27 |
Installation: |
|---|
| 28 |
|
|---|
| 29 |
tar -zxvf xmlAutoIndex-#.##.tar.gz |
|---|
| 30 |
# copy Apache modules into your apache2's etc |
|---|
| 31 |
cp -a xmlAutoIndex/Apache /etc/apache2/Apache |
|---|
| 32 |
cp -a xmlAutoIndex/lib /var/lib/xai |
|---|
| 33 |
mkdir /var/cache/xai |
|---|
| 34 |
#don't forget to set writeable /var/cache/xai by apache's user. |
|---|
| 35 |
|
|---|
| 36 |
#nb: I am using apache2-mpm-prefork (prefork mode in apache2) |
|---|
| 37 |
|
|---|
| 38 |
Configuration: |
|---|
| 39 |
|
|---|
| 40 |
Once you have installed xai, you have to set up Apache configuration: |
|---|
| 41 |
|
|---|
| 42 |
# xai |
|---|
| 43 |
|
|---|
| 44 |
# don't forget this alias |
|---|
| 45 |
Alias /.libs/ /var/lib/xai/ |
|---|
| 46 |
|
|---|
| 47 |
# don't forget to load perl module with something like: LoadModule perl_module /usr/lib/apache2/modules/mod_perl.so |
|---|
| 48 |
PerlSetVar xaiDefaultTheme 'explode' |
|---|
| 49 |
PerlSetVar xaiUriLib '/.libs/themes' |
|---|
| 50 |
PerlSetVar xaiLocalCacheDir '/var/cache/xai' |
|---|
| 51 |
PerlSetVar xaiLocalThemeDir '/var/lib/xai/themes' |
|---|
| 52 |
PerlSetVar xaiOutputMimeType 'application/x-xmlautoindex+xml' |
|---|
| 53 |
PerlSetVar xaiVideoScriptDir '/etc/apache2/Apache/XmlAutoIndex/' |
|---|
| 54 |
|
|---|
| 55 |
Options +Indexes |
|---|
| 56 |
|
|---|
| 57 |
# active mod_xslt on this mime-type |
|---|
| 58 |
# nb: don't forget to load module before with something like: LoadModule mxslt_module /usr/lib/apache2/modules/mod_xslt.so |
|---|
| 59 |
AddOutputFilterByType mod-xslt application/x-xmlautoindex+xml |
|---|
| 60 |
|
|---|
| 61 |
<Location /yourdir> |
|---|
| 62 |
# to activate only in /yourdir |
|---|
| 63 |
SetHandler modperl |
|---|
| 64 |
PerlResponseHandler Apache::XmlAutoIndex |
|---|
| 65 |
</Location> |
|---|
| 66 |
|
|---|
| 67 |
Tests: |
|---|
| 68 |
Once you have started your apache, check if themes are available in: |
|---|
| 69 |
# http://your-web-site/.libs/themes/ |
|---|
| 70 |
|
|---|
| 71 |
You can compare with: |
|---|
| 72 |
# http://www.vanbelle.fr/.libs/themes/ |
|---|
| 73 |
|
|---|
| 74 |
If first test is successfull, go to: http://your-web-site/yourdir |
|---|
| 75 |
|
|---|