Project-Id-Version: Trac 0.12
Report-Msgid-Bugs-To: trac-dev@googlegroups.com
POT-Creation-Date: 2008-01-30 09:20+0100
PO-Revision-Date: 2010-07-19 23:05+0200
Last-Translator: Jeroen Ruigrok van der Werven <asmodai@in-nomine.org>
Language-Team: en_US <trac-dev@googlegroups.com>
Plural-Forms: nplurals=2; plural=(n != 1)
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Transfer-Encoding: 8bit
Generated-By: Babel 0.9.6

Warning: Can't synchronize with repository "(default)" (Unsupported version control system "git": Can't find an appropriate component, maybe the corresponding plugin was not enabled? ). Look in the Trac log for more information.

Changes between Version 10 and Version 11 of HowToInstall


Ignore:
Timestamp:
01/04/10 15:09:35 (8 years ago)
Author:
sebastian
Comment:

Simplefy the installation procedure for server version

Legend:

Unmodified
Added
Removed
Modified
  • HowToInstall

    v10 v11  
    1 This page describes the steps required to install phTagr on a [http://en.wikipedia.org/wiki/LAMP LAMP] system. After installing the required software phTagr must be initialized which is described in SetupProcedure. Please check also the SoftwareRequirements. 
     1This installation procedure describes the server version with a system wide installation on a [http://en.wikipedia.org/wiki/LAMP LAMP] system. After installing the required software phTagr must be initialized which is described in SetupProcedure. '''Please read the SoftwareRequirements before installing! ''' 
    22 
    3 This is a short (and maybe incomplete) installation procedure (on Ubuntu 8.04). You can install phTagr in a system wide environment (server version) or in your home directory ({{{~/public_html}}}). Both variants are described below. 
     3The given installation examples are based in on Ubuntu 9.04 but works similar on other system, too. 
     4 
     5You are not an Web admin and want to install phTagr anyway? See also: 
     6 
     7 - HowToInstallInUserDir - Installes phTagr in your home directory ({{{~/public_html}}}) 
     8 - HowToInstallFromSvn - Installes phTagr from code repository SVN 
    49 
    510[[PageOutline]] 
    611 
    7 = Preparation = 
     12= Prepare LAMP = 
    813 
    9 == Install required server software == 
     14Most likey you have already installed your LAMP with apache, mySQL and PHP. But if not, here are the required commands to install your first LAMP! 
    1015 
    11 phTagr runs on a [http://en.wikipedia.org/wiki/LAMP LAMP]. So if you do not have apache2 the following procedure will install it. See SoftwareRequirements before your start! 
     16'''Note:''' Apache should run with enabled {{{mod_rewrite}}}. It not see http://book.cakephp.org/view/333/A-Note-on-mod_rewrite 
     17 
     18== Install LAMP == 
    1219 
    1320{{{ 
     
    1522}}} 
    1623 
    17 == Creating the database == 
     24 
     25== (Optional:) Install external Programms == 
     26 
     27phTagr runs fine on a simple LAMP. However it can do more with some external helper programs: 
     28 
     29 - [http://www.sno.phy.queensu.ca/~phil/exiftool/ Exiftool] is used to write back the MetaData to the image files like tags, categories, locations, date and geolocations. So all tags are saved within your photos an can be used by other programs! Without exiftool, only import (read) of MetaData is supported. 
     30 - [http://ffmpeg.org/ FFmpeg] is used to convert video files (AVI, MPEG, MOV) to flash videos. It is also used to create video thumbnails. Without ffmpeg phTagr can handle only flash movies. See also CreateFlashVideo 
     31 - [http://www.imagemagick.org/ ImageMagick] is used alternativly to the [http://www.boutell.com/gd/ GD] library to create image previews. 
     32 - [http://rubyforge.org/projects/flvtool2/ flvtool2] is used for creating ''better'' flash movies with cuepoint. This tool is __really__ optional 
     33 
     34You can install these programs with following command:  
     35 
     36{{{ 
     37$ sudo apt-get install ffmpeg flvtool2 imagemagick libimage-exiftool-perl 
     38}}} 
     39 
     40= Creating the database = 
    1841 
    1942Next we have to create a database which phTagr needs to store information: 
     43 
    2044{{{ 
    2145$ sudo mysql -u root 
     
    2549}}} 
    2650 
    27 = Get phTagr = 
     51= Download and prepare phTagr = 
    2852 
    29 This section fetches the [http://www.cakephp.org cakePHP] framework and [http://0www.phtagr.org phtagr] (as cakePHP application) to your home directory. 
    30  
    31 At the end your {{{~/cake}}} folder structure should look like: 
     53Download the latest version from http://demo.phtagr.org/download as [http://demo.phtagr.org/download/phtagr-latest.zip ZIP archive] or [http://demo.phtagr.org/download/phtagr-latest.tar.gz Tar ball] (which is around 2.7 MB). This includes the [http://www.cakephp.org cakePHP MVC framework] and [http://www.phtagr.org phtagr]. 
    3254 
    3355{{{ 
    34 /cake       <-- Becomes later /var/www/cake or ~/.public_html/cake 
    35     /cake   <-- CakePHP framework 
    36     /app    <-- CakePHP's default application name. The latest tarball has phtagr here. 
    37     /phtagr <-- Alternative application's name, e.g. SVN version. Requires modifications in .htaccess 
     56cd /var/www 
     57sudo wget http://demo.phtagr.org/download/phtagr-latest.tar.gz  
     58sudo tar -xzvf phtagr-latest.tar.gz 
     59}}} 
     60 
     61or with ZIP archive 
     62 
     63{{{ 
     64cd /var/www 
     65sudo wget http://demo.phtagr.org/download/phtagr-latest.zip  
     66sudo unzip phtagr-latest.zip 
     67}}} 
     68 
     69Now your folder structure looks like this: 
     70 
     71{{{ 
     72/phtagr        
     73    /cake        <-- CakePHP framework 
     74    /app         <-- phTagr as CakePHP's default application 
     75        /config  <-- Basic configuration path 
     76            /core.php      <-- Basic core configuration file 
     77            /database.php  <-- Database configuration file (can be created automatically) 
     78            ... 
     79        /users   <-- Directory of your user's files, photos, videos, cached previews, ... 
     80        /tmp     <-- Directory for log files, cache files, ... 
     81        ... 
    3882    /docs 
    3983    /vendors 
     
    4286}}} 
    4387 
    44 Please see http://book.cakephp.org/view/329/Getting-Cake and http://book.cakephp.org/view/19/CakePHP-Folder-Structure for the general folder structure in cakePHP. 
    45  
    46 == Get Archive of Latest Version ==  
    47  
    48 Download the latest version of phTagr at {{{http://demo.phtagr.org/download/phtagr-latest.tar.gz}}} and extract it. 
     88Now we need to make some folders accessible for the web server 
    4989 
    5090{{{ 
    51 $ cd  
    52 $ wget http://demo.phtagr.org/download/phtagr-latest.tar.gz 
    53 $ tar xzvf phtagr-latest.tar.gz 
    54 $ mv phtagr-rXXX cake 
     91$ cd phtagr/app 
     92$ sudo chown -R www-data config users tmp 
    5593}}} 
    5694 
    57 Where {{{XXX}}} is the current SVN version. 
     95Open now phtagr in your browser http://localhost/phtagr/setup and continue with the SetupProcedure.  
    5896 
    59 == Get SVN version == 
     97If you don't see anything you might have a problem with apaches redirection. Please see http://book.cakephp.org/view/333/A-Note-on-mod_rewrite.  
    6098 
    61 If you want to stay at the edge you better fetch phTagr from the SVN repository. '''Be aware that phTagr is not in the cakePHP's default {{{app}}} directory and you need some adjustments for the right redirection.''' 
     99[From cakePHP's book] ''If you don't want or can't get mod_rewrite (or some other compatible module) up and running on your server, you'll need to use Cake's built in pretty URLs. In {{{/app/config/core.php}}}, uncomment the line that looks like:'' 
    62100 
    63101{{{ 
    64 $ cd  
    65 $ sudo svn co https://svn.cakephp.org/repo/branches/1.2.x.x cake 
    66 $ cd cake 
    67 $ svn co https://svn.phtagr.org/phtagr/trunk phtagr 
     102Configure::write('App.baseUrl', env('SCRIPT_NAME')); 
    68103}}} 
    69104 
    70 = Installation = 
    71  
    72  
    73 == phTagr at system wide environment == 
    74  
    75  Assumption:: 
    76    Your site configuration points to {{{/var/www/cake/phtagr/webroot}}}, {{{mod_rewrite}}} is enabled and you are __not__ using suPHP. 
    77  
    78 {{{ 
    79 $ cd  
    80 $ cd /var/www 
    81 $ sudo cp ~/cake . 
    82 $ cd cake/app     <-- tar ball 
    83 $ cd cake/phtagr  <-- SVN version 
    84 $ sudo chown -R www-data users tmp 
    85 }}} 
    86  
    87 === Adjust .htaccess === 
    88  
    89 If you run phtagr via SVN please edit {{{/var/www/cake/.htaccess}}} and change {{{app/webroot/}}} to {{{phtagr/webroot/}}}: 
    90  
    91 {{{ 
    92 <IfModule mod_rewrite.c> 
    93     RewriteEngine on 
    94     RewriteRule ^$   phtagr/webroot/   [L] 
    95     RewriteRule (.*) phtagr/webroot/$1 [L] 
    96 </IfModule> 
    97 }}} 
    98  
    99 If you use the non SVN version open [http://localhost/cake/app/setup] in your browser and follow the SetupProcedure. 
    100  
    101 For the SVN version open [http://localhost/cake/phtagr/setup] in your browser and follow the SetupProcedure. 
    102  
    103 == phTagr in user directory == 
    104  
    105  Assumptions::  
    106    Your public htdoc directory is in {{{~/public_html}}}, {{{mod_rewrite}}} is enabled in your home directory and you are using suPHP. 
    107  
    108 === Copy cakePHP with phtagr === 
    109  
    110 {{{ 
    111 $ cd ~/public_html 
    112 $ cp ~/cake . 
    113 $ cd cake/app     <-- tar ball 
    114 $ cd cake/phtagr  <-- SVN version 
    115 $ sudo chmod -R 777 tmp users 
    116 }}} 
    117  
    118 === Adjust {{{.htaccess}}} === 
    119  
    120 If you run SVN version please modify several {{{.htaccess}}} files to run the redirection properly. 
    121  
    122 Modify {{{~/public_html/cake/.htaccess}}} to 
    123  
    124 {{{ 
    125 <IfModule mod_rewrite.c> 
    126     RewriteEngine on 
    127     RewriteBase /~YOURNAME/cake 
    128     RewriteRule ^$   phtagr/webroot/   [L] 
    129     RewriteRule (.*) phtagr/webroot/$1 [L] 
    130 </IfModule> 
    131 }}} 
    132  
    133 Modify {{{~/public_html/cake/phtagr/.htaccess}}} to 
    134  
    135 {{{ 
    136 <IfModule mod_rewrite.c> 
    137     RewriteEngine on 
    138     RewriteBase /~YOURNAME/cake/phtagr 
    139     RewriteRule ^$   webroot/   [L] 
    140     RewriteRule (.*) webroot/$1 [L] 
    141 </IfModule> 
    142 }}} 
    143  
    144 Modify {{{~/public_html/cake/phtagr/webroot/.htaccess}}} to 
    145  
    146 {{{ 
    147 <IfModule mod_rewrite.c> 
    148     RewriteEngine On 
    149     RewriteBase /~YOURNAME/cake/phtagr/webroot 
    150     RewriteCond %{REQUEST_FILENAME} !-d 
    151     RewriteCond %{REQUEST_FILENAME} !-f 
    152     RewriteRule ^(.*)$ index.php?url=$1 [QSA,L] 
    153 </IfModule> 
    154 }}} 
    155  
    156 = Other Issues = 
    157  
    158 == No suPHP == 
    159  
    160 If you are not using suPHP, the directories (and all subdirecoties of {{{~/public_html/cake/phtagr/tmp}}} and {{{~/public_html/cake/phtagr/users}}}) must be writable and should be owned by the apache process. Usually user {{{www-data}}} in Debian/Ubuntu. 
    161  
    162 {{{ 
    163 $ sudo chown -R www-data ~/public_html/cake/phtagr/tmp ~/public_html/cake/phtagr/tmp  
    164 }}} 
    165  
    166 If you cannot modify the permissions of {{{tmp}}} and {{{users}}} directory in phTagr make it at least readable for the world:  
    167  
    168 {{{ 
    169 cd ~/public_html/cake/phtagr 
    170 find tmp -type d -exec chmod 777 "{}" \; 
    171 find tmp -type f -exec chmod 666 "{}" \; 
    172 find users -type d -exec chmod 777 "{}" \; 
    173 find users -type f -exec chmod 666 "{}" \; 
    174 }}} 
    175  
    176 Now run http://localhost/~YOURNAME/cake/phtagr/setup for the SetupProcedure 
    177  
    178 == No mod_rewrite or redirection == 
    179  
    180 If you don't have {{{mod_rewrite}}} or ansy other redirection mechanim, please see http://book.cakephp.org/view/333/A-Note-on-mod_rewrite 
     105Now you should be able to open http://localhost/phtagr/app/webroot/index.php/setup and continue with the SetupProcedure.