Wiki » Historique » Version 152
  Patrice Nadeau, 2015-04-19 20:50 
  
| 1 | 13 | Patrice Nadeau | h1. Redmine  | 
|---|---|---|---|
| 2 | 6 | Patrice Nadeau | |
| 3 | 31 | Patrice Nadeau | Logiciel de gestion de projets, sources, bugs et timeline.  | 
| 4 | Contient un module de Wiki, de fichiers.  | 
||
| 5 | Supporte aussi les systèmes de version de fichier (Git, SVN entre autre).  | 
||
| 6 | Disponible à http://www.redmine.org/projects/redmine/wiki/Download  | 
||
| 7 | |||
| 8 | De base, ne fonctionne pas avec Apache  | 
||
| 9 | 1 | Patrice Nadeau | |
| 10 | Sa principale difficulté d’installation est sa dépendance à Ruby.  | 
||
| 11 | Voir aussi :  | 
||
| 12 | * http://bitnami.com/stack/redmine  | 
||
| 13 | * http://www.turnkeylinux.org/redmine  | 
||
| 14 | |||
| 15 | 121 | Patrice Nadeau | {{lastupdated_at}} {{lastupdated_by}} | 
| 16 | |||
| 17 | 94 | Patrice Nadeau | ---  | 
| 18 | 31 | Patrice Nadeau | |
| 19 | 94 | Patrice Nadeau | {{toc}} | 
| 20 | |||
| 21 | h2. Installation  | 
||
| 22 | |||
| 23 | 32 | Patrice Nadeau | Ce guide documente une installation GNU/Linux avec les version suivantes :  | 
| 24 | * openSUSE 13.1  | 
||
| 25 | 151 | Patrice Nadeau | * Redmine 3.0.1  | 
| 26 | 32 | Patrice Nadeau | |
| 27 | 94 | Patrice Nadeau | h3. Prérequis  | 
| 28 | 1 | Patrice Nadeau | |
| 29 | Un serveur *LAMP(Linux, Apache, MySQL, PHP)* [[guides_opensuse:|openSUSE]] *fonctionnel*.  | 
||
| 30 | 56 | Patrice Nadeau | |
| 31 | 44 | Patrice Nadeau | Les logiciels supplémentaires suivants :  | 
| 32 | 50 | Patrice Nadeau | |
| 33 | <pre><code class="bash">  | 
||
| 34 | 58 | Patrice Nadeau | zypper install libmysqlclient-devel ruby-2.0 ruby20-devel rubygem-bundler rubygem-mysql2 rubygem-pg ImageMagick ImageMagick-devel git gcc make  | 
| 35 | 56 | Patrice Nadeau | </code></pre>  | 
| 36 | 32 | Patrice Nadeau | |
| 37 | 94 | Patrice Nadeau | h3. MySQL  | 
| 38 | 32 | Patrice Nadeau | |
| 39 | Création de la base de donnés.  | 
||
| 40 | Substituer les items suivants à votre choix :  | 
||
| 41 | * redmine : Usager pour la base de donnés.  | 
||
| 42 | * password : Mot de passe de la base de donnees.  | 
||
| 43 | * db : Nom de la base de donnés.  | 
||
| 44 | |||
| 45 | Lancer MySQL :  | 
||
| 46 | <pre><code class="bash">  | 
||
| 47 | mysql -u root -p  | 
||
| 48 | </code></pre>  | 
||
| 49 | |||
| 50 | 1 | Patrice Nadeau | Commandes MySQL :  | 
| 51 | 32 | Patrice Nadeau | <pre><code class="sql">  | 
| 52 | create database db character set utf8;  | 
||
| 53 | create user 'redmine'@'localhost' identified by 'password';  | 
||
| 54 | grant all privileges on db.* to 'redmine'@'localhost';  | 
||
| 55 | commit;  | 
||
| 56 | quit;  | 
||
| 57 | </code></pre>  | 
||
| 58 | |||
| 59 | 94 | Patrice Nadeau | h3. Redmine  | 
| 60 | 13 | Patrice Nadeau | |
| 61 | 59 | Patrice Nadeau | L’installation sera faite dans _\srv\redmine_ (exemple avec la version 2.5)  | 
| 62 | 33 | Patrice Nadeau | <pre><code class="bash">  | 
| 63 | cd /srv/  | 
||
| 64 | 59 | Patrice Nadeau | svn co http://svn.redmine.org/redmine/branches/2.5-stable redmine  | 
| 65 | 33 | Patrice Nadeau | cd redmine  | 
| 66 | cp config/database.yml.example config/database.yml  | 
||
| 67 | cp config/configuration.yml.example config/configuration.yml  | 
||
| 68 | 1 | Patrice Nadeau | mkdir public/plugin_assets  | 
| 69 | 33 | Patrice Nadeau | </code></pre>  | 
| 70 | |||
| 71 | Si un usager MySQL autre que _root_ ou mot de passe diffèrent est utilisé :  | 
||
| 72 | Éditer le fichier *config/database.yml*, section *Production* et modifier les lignes :  | 
||
| 73 | * *username*  | 
||
| 74 | * *password*  | 
||
| 75 | |||
| 76 | Éditer le fichier _config/configuration.yml_ et modifier la configuration SMTP.  | 
||
| 77 | 1 | Patrice Nadeau | |
| 78 | 94 | Patrice Nadeau | h3. Ruby  | 
| 79 | 33 | Patrice Nadeau | |
| 80 | 34 | Patrice Nadeau | Installation des gems de Ruby  | 
| 81 | 1 | Patrice Nadeau | <pre><code class="bash">  | 
| 82 | 34 | Patrice Nadeau | cd redmine  | 
| 83 | gem install bundler  | 
||
| 84 | gem install activerecord-mysql2-adapter  | 
||
| 85 | bundle install --without development test  | 
||
| 86 | 1 | Patrice Nadeau | </code></pre>  | 
| 87 | |||
| 88 | 94 | Patrice Nadeau | h3. Initialisation  | 
| 89 | 1 | Patrice Nadeau | |
| 90 | 34 | Patrice Nadeau | Création de la cryptographie, de la structure et des donnés de base :  | 
| 91 | <pre><code class="bash">  | 
||
| 92 | cd /srv/redmine  | 
||
| 93 | rake generate_secret_token  | 
||
| 94 | RAILS_ENV=production rake db:migrate  | 
||
| 95 | RAILS_ENV=production rake redmine:load_default_data  | 
||
| 96 | </code></pre>  | 
||
| 97 | |||
| 98 | 94 | Patrice Nadeau | h3. Serveur web  | 
| 99 | 69 | Patrice Nadeau | |
| 100 | 70 | Patrice Nadeau | Redmine peux être utiliser avec le serveur inclus _webrick_ (port 3000) ou _Apache_ (port 80).  | 
| 101 | 1 | Patrice Nadeau | |
| 102 | 94 | Patrice Nadeau | h4. Webrick  | 
| 103 | 69 | Patrice Nadeau | |
| 104 | 60 | Patrice Nadeau | Ouvrir dans le pare-feu le port TCP 3000 :  | 
| 105 | <pre><code class="bash">  | 
||
| 106 | yast firewall services add tcpport=3000 zone=EXT  | 
||
| 107 | 34 | Patrice Nadeau | </code></pre>  | 
| 108 | 1 | Patrice Nadeau | |
| 109 | 69 | Patrice Nadeau | Lancer le serveur web  | 
| 110 | 34 | Patrice Nadeau | <pre><code class="bash">  | 
| 111 | 1 | Patrice Nadeau | cd /srv/redmine  | 
| 112 | 34 | Patrice Nadeau | ruby script/rails server webrick -e production  | 
| 113 | </code></pre>  | 
||
| 114 | 16 | Patrice Nadeau | |
| 115 | 94 | Patrice Nadeau | h5. Transformation en daemon  | 
| 116 | 35 | Patrice Nadeau | |
| 117 | Le script original vient de http://www.redmine.org/projects/redmine/wiki/HowTo_Install_Redmine_on_openSUSE  | 
||
| 118 | 1 | Patrice Nadeau | Copier le script dans le fichier */etc/init.d/redmine*  | 
| 119 | 35 | Patrice Nadeau | |
| 120 | Le modifier de la manière suivante :  | 
||
| 121 | * REDMINE_BIN=/srv/redmine/current/script/rails  | 
||
| 122 | * REDMINE_USER=user  | 
||
| 123 | * Corriger le «typo» à la ligne 73 : $REDMI-NE_BIN -> $REDMINE_BIN  | 
||
| 124 | * Dans la section stop, après la ligne killproc, ajouter *rm $PIDFILE*  | 
||
| 125 | |||
| 126 | Rendre le fichier exécutable, l’ajouter aux services SUSE et l’exécuter au démarrage :  | 
||
| 127 | <pre><code class="bash">  | 
||
| 128 | chmod 0755 /etc/init.d/redmine  | 
||
| 129 | cp -s /etc/init.d/redmine /usr/bin/rcredmine  | 
||
| 130 | chkconfig -a redmine  | 
||
| 131 | </code></pre>  | 
||
| 132 | 1 | Patrice Nadeau | |
| 133 | 94 | Patrice Nadeau | h4. Apache  | 
| 134 | 45 | Patrice Nadeau | |
| 135 | > En test, voir #23  | 
||
| 136 | |||
| 137 | Transformation pour utilisation avec Apache.  | 
||
| 138 | * N'utilise pas _webrick_  | 
||
| 139 | * Accessible par le port 80 au lieu de 3000  | 
||
| 140 | |||
| 141 | Information provenant de :  | 
||
| 142 | 54 | Patrice Nadeau | * web :  | 
| 143 | ** http://martin-denizet.com/install-redmine-2-5-x-with-git-and-subversion-on-debian-with-apache2-rvm-and-passenger/  | 
||
| 144 | ** http://www.redmine.org/projects/redmine/wiki/HowTo_configure_Apache_to_run_Redmine  | 
||
| 145 | 91 | Patrice Nadeau | ** http://www.redmine.org/boards/2/topics/43924  | 
| 146 | 45 | Patrice Nadeau | * livre : "Mastering Redmine":http://shop.oreilly.com/product/9781849519144.do  | 
| 147 | |||
| 148 | 94 | Patrice Nadeau | h3. Modules Apache  | 
| 149 | 1 | Patrice Nadeau | |
| 150 | 46 | Patrice Nadeau | Ajout  | 
| 151 | 45 | Patrice Nadeau | <pre><code class="bash">  | 
| 152 | 49 | Patrice Nadeau | zypper install libcurl-devel apache2-devel apache2-mod_perl perl-Apache-DBI subversion-server  | 
| 153 | 45 | Patrice Nadeau | </code></pre>  | 
| 154 | |||
| 155 | Activation des modules Apache  | 
||
| 156 | <pre><code class="bash">  | 
||
| 157 | a2enmod ssl  | 
||
| 158 | a2enmod perl  | 
||
| 159 | a2enmod dav  | 
||
| 160 | a2enmod dav_svn  | 
||
| 161 | a2enmod dav_fs  | 
||
| 162 | a2enmod rewrite  | 
||
| 163 | a2enmod headers  | 
||
| 164 | 1 | Patrice Nadeau | </code></pre>  | 
| 165 | |||
| 166 | 94 | Patrice Nadeau | h3. Modules _Passenger_  | 
| 167 | 1 | Patrice Nadeau | |
| 168 | 46 | Patrice Nadeau | <pre><code class="bash">  | 
| 169 | 45 | Patrice Nadeau | cd /srv/redmine  | 
| 170 | gem install passenger  | 
||
| 171 | passenger-install-apache2-module2.0  | 
||
| 172 | 1 | Patrice Nadeau | </code></pre>  | 
| 173 | |||
| 174 | 90 | Patrice Nadeau | Changer les droits sur le fichiers de log  | 
| 175 | <pre><code class="bash">  | 
||
| 176 | 124 | Patrice Nadeau | chmod 0666 log/production.log  | 
| 177 | 90 | Patrice Nadeau | </code></pre>  | 
| 178 | |||
| 179 | 93 | Patrice Nadeau | Créer le dossier des fichiers temporaire  | 
| 180 | 103 | Patrice Nadeau | > Par défaut les fichiers sont dans _/tmp_ mais se font enlever par le « clean-up » journalier et doivent être refait avec un reload d'Apache  | 
| 181 | 93 | Patrice Nadeau | <pre><code class="bash">  | 
| 182 | 125 | Patrice Nadeau | mkdir tmp/passenger  | 
| 183 | 93 | Patrice Nadeau | </code></pre>  | 
| 184 | |||
| 185 | 94 | Patrice Nadeau | h3. Activation de la configuration  | 
| 186 | 46 | Patrice Nadeau | |
| 187 | 64 | Patrice Nadeau | Créer le fichier _/etc/apache2/conf.d/passenger.conf_ et ajouter la configuration inscrite par l'installation.  | 
| 188 | 61 | Patrice Nadeau | |
| 189 | 45 | Patrice Nadeau | Ajouter dans _/etc/apache2/vhosts.d/vhost.conf_  | 
| 190 | <pre><code class="bash">  | 
||
| 191 | <VirtualHost *:80>  | 
||
| 192 | 67 | Patrice Nadeau | # La ligne suivante est nécessaire seulement si plusieurs site web son présents sur le même serveur.  | 
| 193 | 45 | Patrice Nadeau | ServerName redmine.yourdomain.com  | 
| 194 | DocumentRoot /srv/redmine/public  | 
||
| 195 | 1 | Patrice Nadeau | |
| 196 | 45 | Patrice Nadeau | RailsEnv production  | 
| 197 | 67 | Patrice Nadeau | PassengerAppRoot /srv/redmine  | 
| 198 | 92 | Patrice Nadeau | PassengerTempDir /srv/redmine/tmp/passenger  | 
| 199 | 45 | Patrice Nadeau | |
| 200 | <Directory "/srv/redmine/public">  | 
||
| 201 | Options Indexes ExecCGI FollowSymLinks  | 
||
| 202 | 1 | Patrice Nadeau | AllowOverride None  | 
| 203 | Order deny,allow  | 
||
| 204 | Allow from all  | 
||
| 205 | </Directory>  | 
||
| 206 | </VirtualHost>  | 
||
| 207 | 65 | Patrice Nadeau | </code></pre>  | 
| 208 | |||
| 209 | Relancer Apache :  | 
||
| 210 | <pre><code class="bash">  | 
||
| 211 | 1 | Patrice Nadeau | systemctl reload apache2  | 
| 212 | 65 | Patrice Nadeau | </code></pre>  | 
| 213 | 45 | Patrice Nadeau | |
| 214 | 94 | Patrice Nadeau | h2. Post-installation  | 
| 215 | 68 | Patrice Nadeau | |
| 216 | 71 | Patrice Nadeau | A partir d’un navigateur web, se brancher à :  | 
| 217 | * Webrick : http://server:3000  | 
||
| 218 | * Apache : http://server  | 
||
| 219 | |||
| 220 | 69 | Patrice Nadeau | Utiliser l’usager *admin* avec le mot de passe *admin*.  | 
| 221 | 1 | Patrice Nadeau | Vérifier la configuration dans *Administration*, *Information*.  | 
| 222 | |||
| 223 | 80 | Patrice Nadeau | Si un avertissement apparait pour l’écriture des répertoires, changer les droits :  | 
| 224 | 82 | Patrice Nadeau | > Semble être nécessaire que pour Apache  | 
| 225 | 1 | Patrice Nadeau | <pre><code class="bash">  | 
| 226 | 82 | Patrice Nadeau | cd /srv/redmine  | 
| 227 | chmod 0777 public/plugin_assets  | 
||
| 228 | 83 | Patrice Nadeau | chmod 0777 files  | 
| 229 | 102 | Patrice Nadeau | chown -R wwwrun:www tmp  | 
| 230 | 105 | Patrice Nadeau | # Pour la macro "thumbnails" du wiki, le plugin "redmine_people" nécessite au moins 0775  | 
| 231 | chmod -R 0777 tmp/thumbnails  | 
||
| 232 | 80 | Patrice Nadeau | </code></pre>  | 
| 233 | 1 | Patrice Nadeau | |
| 234 | 94 | Patrice Nadeau | h2. Personnalisation  | 
| 235 | 29 | Patrice Nadeau | |
| 236 | 94 | Patrice Nadeau | h3. Ajout d’un logo  | 
| 237 | 36 | Patrice Nadeau | |
| 238 | Les informations viennent de : http://www.redmine.org/projects/redmine/wiki/Howto_add_a_logo_to_your_Redmine_banner  | 
||
| 239 | |||
| 240 | Copier le logo dans _/srv/redmine/public/images/logo.png_  | 
||
| 241 | 1 | Patrice Nadeau | |
| 242 | 37 | Patrice Nadeau | Modifier le fichier _/srv/redmine/app/views/layout/base.rhtml.erb_  | 
| 243 | * Ajouter la ligne  | 
||
| 244 | 1 | Patrice Nadeau | <pre><code class="ruby">  | 
| 245 | 37 | Patrice Nadeau | <img src="<%= Redmine::Utils.relative_url_root %>/images/logo.png" style="top-margin: 15px; left-margin: 15px;"/>  | 
| 246 | </code></pre>  | 
||
| 247 | * Si on ne veux plus afficher le titre, mettre en commentaire :  | 
||
| 248 | 1 | Patrice Nadeau | <pre><code class="ruby">  | 
| 249 | 37 | Patrice Nadeau | <!--<h1><%= page_header_title %></h1>-->  | 
| 250 | </code></pre>  | 
||
| 251 | |||
| 252 | Redémarrer Redmine  | 
||
| 253 | 72 | Patrice Nadeau | |
| 254 | 36 | Patrice Nadeau | |
| 255 | 94 | Patrice Nadeau | h3. Plugins  | 
| 256 | 1 | Patrice Nadeau | |
| 257 | 94 | Patrice Nadeau | h4. Extended Fields  | 
| 258 | 38 | Patrice Nadeau | |
| 259 | Permet de créer de nouveau champ dans la basse de donnés.  | 
||
| 260 | |||
| 261 | http://www.redmine.org/plugins/extended_fields  | 
||
| 262 | |||
| 263 | Installation :  | 
||
| 264 | <pre><code class="bash">  | 
||
| 265 | cd /srv/redmine  | 
||
| 266 | 1 | Patrice Nadeau | svn co http://svn.s-andy.com/extended-fields plugins/extended_fields  | 
| 267 | 38 | Patrice Nadeau | rake redmine:plugins:migrate RAILS_ENV=production  | 
| 268 | </code></pre>  | 
||
| 269 | 73 | Patrice Nadeau | |
| 270 | 38 | Patrice Nadeau | Relancer Redmine  | 
| 271 | 4 | Patrice Nadeau | |
| 272 | 94 | Patrice Nadeau | h4. Redmine Rouge  | 
| 273 | 1 | Patrice Nadeau | |
| 274 | 4 | Patrice Nadeau | Permet le support de langage supplémentaire pour l'affichage de la syntaxe d'un code source.  | 
| 275 | 13 | Patrice Nadeau | |
| 276 | 1 | Patrice Nadeau | "Langage supporté":http://rouge.jayferd.us/demo  | 
| 277 | |||
| 278 | https://github.com/ngyuki/redmine_rouge  | 
||
| 279 | |||
| 280 | <pre>  | 
||
| 281 | <code class="bash">  | 
||
| 282 | cd /srv/redmine/plugins  | 
||
| 283 | git clone https://github.com/ngyuki/redmine_rouge.git  | 
||
| 284 | cd ..  | 
||
| 285 | bundle install  | 
||
| 286 | </code>  | 
||
| 287 | 74 | Patrice Nadeau | </pre>  | 
| 288 | |||
| 289 | Relancer redmine  | 
||
| 290 | 5 | Patrice Nadeau | |
| 291 | 94 | Patrice Nadeau | h4. Code Highlight  | 
| 292 | 9 | Patrice Nadeau | |
| 293 | 10 | Patrice Nadeau | http://www.redmine.org/plugins/codehightlight_button  | 
| 294 | 9 | Patrice Nadeau | |
| 295 | Bouton permettant de sélectionner du code et d'activer la syntaxe selon un langage.  | 
||
| 296 | |||
| 297 | 1 | Patrice Nadeau | Installation  | 
| 298 | <pre><code class="bash">  | 
||
| 299 | 10 | Patrice Nadeau | cd /srv/redmine/plugins  | 
| 300 | git clone https://github.com/mediatainment/redmine_codebutton.git  | 
||
| 301 | cd ..  | 
||
| 302 | rake redmine:plugins  | 
||
| 303 | 9 | Patrice Nadeau | rake redmine:plugins:migrate RAILS_ENV=production  | 
| 304 | 10 | Patrice Nadeau | # Relancer Redmine  | 
| 305 | 1 | Patrice Nadeau | rcredmine restart  | 
| 306 | 95 | Patrice Nadeau | </code></pre>  | 
| 307 | |||
| 308 | Ajout des langages supplémentaires supportées par le « plug-in » _Redmine Rouge_. Voir "ici":https://github.com/mediatainment/redmine_codebutton/issues/2  | 
||
| 309 | 96 | Patrice Nadeau | Éditer le fichier */srv/redmine/plugins/redmine_codebutton/assets/javascripts/wiki-codehighlight.js*  | 
| 310 | 95 | Patrice Nadeau | * Ajouter les langages voulus dans la variable *codeRayLanguages*  | 
| 311 | |||
| 312 | Relancer Apache  | 
||
| 313 | <pre><code class="bash">  | 
||
| 314 | systemctl reload apache2.service  | 
||
| 315 | 1 | Patrice Nadeau | </code></pre>  | 
| 316 | |||
| 317 | 94 | Patrice Nadeau | h4. Redmine Issue Checklist  | 
| 318 | 23 | Patrice Nadeau | |
| 319 | 147 | Patrice Nadeau | > Je n'utilise plus, l'enregistrement est obligatoire pour le télécharger (RedmineCRM). C'est un « freemium ».  | 
| 320 | 140 | Patrice Nadeau | |
| 321 | 1 | Patrice Nadeau | Extends issues to store checklist items  | 
| 322 | 11 | Patrice Nadeau | |
| 323 | 1 | Patrice Nadeau | http://redminecrm.com/projects/checklist  | 
| 324 | 146 | Patrice Nadeau | |
| 325 | 148 | Patrice Nadeau | Version 2.0.5 -" pas compatible avec Redmine 3.0.1  | 
| 326 | 11 | Patrice Nadeau | |
| 327 | Installation  | 
||
| 328 | <pre><code class="bash">  | 
||
| 329 | cd /srv/redmine/plugins  | 
||
| 330 | wget http://redminecrm.com/license_manager/4200/redmine_issue_checklist-2_0_5.zip  | 
||
| 331 | unzip redmine_issue_checklist-2_0_5.zip  | 
||
| 332 | bundle exec rake redmine:plugins NAME=redmine_issue_checklist RAILS_ENV=production  | 
||
| 333 | 1 | Patrice Nadeau | </code></pre>  | 
| 334 | 84 | Patrice Nadeau | |
| 335 | Relancer Redmine  | 
||
| 336 | 11 | Patrice Nadeau | |
| 337 | Configuration  | 
||
| 338 | Dans *Administration*  | 
||
| 339 | 1 | Patrice Nadeau | * *Plugins*  | 
| 340 | 11 | Patrice Nadeau | ** Choisir les options voulues  | 
| 341 | * *Roles and permissions*  | 
||
| 342 | ** Choisir le rôle  | 
||
| 343 | Donner les droits voulus sur :  | 
||
| 344 | *** Done checklist items  | 
||
| 345 | *** Edit checklist items  | 
||
| 346 | 14 | Patrice Nadeau | *** View checklist  | 
| 347 | 1 | Patrice Nadeau | |
| 348 | 94 | Patrice Nadeau | h4. Redmine People  | 
| 349 | 24 | Patrice Nadeau | |
| 350 | 150 | Patrice Nadeau | Voir #46  | 
| 351 | |||
| 352 | 149 | Patrice Nadeau | > Je n'utilise plus, l'enregistrement est obligatoire pour le télécharger (RedmineCRM). C'est un « freemium ».  | 
| 353 | 1 | Patrice Nadeau | |
| 354 | 143 | Patrice Nadeau | |
| 355 | 150 | Patrice Nadeau | |
| 356 | 24 | Patrice Nadeau | |
| 357 | 97 | Patrice Nadeau | h4. Like Button  | 
| 358 | |||
| 359 | Bouton pour Facebook, Google+ et Twitter  | 
||
| 360 | |||
| 361 | 98 | Patrice Nadeau | http://www.redmine.org/plugins/like  | 
| 362 | 97 | Patrice Nadeau | |
| 363 | 98 | Patrice Nadeau | Installation  | 
| 364 | 1 | Patrice Nadeau | |
| 365 | 98 | Patrice Nadeau | <pre><code class="bash">  | 
| 366 | cd /srv/redmine/plugins  | 
||
| 367 | svn svn co http://svn.s-andy.com/like-button like  | 
||
| 368 | </code></pre>  | 
||
| 369 | 100 | Patrice Nadeau | |
| 370 | 98 | Patrice Nadeau | Relancer Redmine  | 
| 371 | 97 | Patrice Nadeau | |
| 372 | 135 | Patrice Nadeau | h4. Subscription  | 
| 373 | |||
| 374 | Permet de s'abonner et de recevoir les changements fait sur un projet  | 
||
| 375 | |||
| 376 | 152 | Patrice Nadeau | http://projects.andriylesyuk.com/project/redmine/subscription  | 
| 377 | |||
| 378 | 135 | Patrice Nadeau | Les événements suivants active une notification  | 
| 379 | * Un nouveau « News »  | 
||
| 380 | * La fermeture d'une version d'un projet  | 
||
| 381 | * Un nouveau fichier téléchargé  | 
||
| 382 | * Un nouvel « issue »  | 
||
| 383 | * Une nouvelle page Wiki  | 
||
| 384 | * Un nouveau « commit »  | 
||
| 385 | * Un nouveau forum  | 
||
| 386 | |||
| 387 | 138 | Patrice Nadeau | Installation sur le serveur :  | 
| 388 | 137 | Patrice Nadeau | |
| 389 | 135 | Patrice Nadeau | <pre><code class="bash">  | 
| 390 | 136 | Patrice Nadeau | # Se placer dans le dossier de Remdine  | 
| 391 | 1 | Patrice Nadeau | cd /srv/redmine  | 
| 392 | 136 | Patrice Nadeau | # Telecharger le plugin  | 
| 393 | wget http://projects.andriylesyuk.com/attachments/download/613/subscription-0.0.1b.tar.bz2  | 
||
| 394 | tar -xvf subscription-0.0.1b.tar.bz2  | 
||
| 395 | mv subscription-0.0.1b.tar.bz2 subscription  | 
||
| 396 | # Lce copier avec les autres plugins  | 
||
| 397 | mv subscription/ plugins/  | 
||
| 398 | # L'inclure dans Redmine  | 
||
| 399 | rake redmine:plugins:migrate RAILS_ENV=production  | 
||
| 400 | # Reload de Apache  | 
||
| 401 | systemctl reload apache2.service  | 
||
| 402 | 1 | Patrice Nadeau | </code></pre>  | 
| 403 | 137 | Patrice Nadeau | |
| 404 | Activer le module dans chacun des projet voulus.  | 
||
| 405 | 135 | Patrice Nadeau | |
| 406 | 113 | Patrice Nadeau | h4. Wiki Extensions  | 
| 407 | |||
| 408 | 144 | Patrice Nadeau | Voir #47  | 
| 409 | |||
| 410 | 122 | Patrice Nadeau | Ajoute des macros au Wiki de Redmine  | 
| 411 | 115 | Patrice Nadeau | > La dernière version est disponible à https://bitbucket.org/haru_iida/redmine_wiki_extensions/downloads  | 
| 412 | 114 | Patrice Nadeau | |
| 413 | 118 | Patrice Nadeau | Parmi les macros ajoutées:  | 
| 414 | 122 | Patrice Nadeau | >Liste complète à http://www.r-labs.org/projects/r-labs/wiki/Wiki_Extensions_en  | 
| 415 | 119 | Patrice Nadeau | * Emoticons : Un bouton apparait pour ajouter des « smilley » qui seront afficher en graphique  | 
| 416 | 118 | Patrice Nadeau | * !{{lastupdated_by}} : affiche le nom de la dernière personne à avoir modifier la page | 
| 417 | 128 | Patrice Nadeau | * !{{lastupdated_at}} : affiche la date de la dernière modification de la page | 
| 418 | 118 | Patrice Nadeau | |
| 419 | 134 | Patrice Nadeau | > Des « smilley » non voulus peuvent apparaitre dans les wiki déjà en place. L'utilisation de *<notextile><notextile> </notextile></notextile>* seras alors nécessaire.  | 
| 420 | 133 | Patrice Nadeau | |
| 421 | 130 | Patrice Nadeau | Étapes :  | 
| 422 | # Installation sur le serveur :  | 
||
| 423 | 114 | Patrice Nadeau | <pre><code class="bash">  | 
| 424 | cd /srv/redmine/  | 
||
| 425 | 145 | Patrice Nadeau | wget https://bitbucket.org/haru_iida/redmine_wiki_extensions/downloads/redmine_wiki_extensions-0.7.0.zip  | 
| 426 | unzip redmine_wiki_extensions-0.7.0.zip -d plugins/  | 
||
| 427 | 129 | Patrice Nadeau | rake db:migrate_plugins RAILS_ENV=production  | 
| 428 | 1 | Patrice Nadeau | systemctl reload apache2.service  | 
| 429 | 130 | Patrice Nadeau | </code></pre>  | 
| 430 | 133 | Patrice Nadeau | # Activer le module dans le ou les projets voulus  | 
| 431 | 99 | Patrice Nadeau | |
| 432 | 94 | Patrice Nadeau | h4. WikiNG  | 
| 433 | 1 | Patrice Nadeau | |
| 434 | 20 | Patrice Nadeau | Personnalisation des items dans le wiki.  | 
| 435 | 28 | Patrice Nadeau | Ajoute des boutons et des icônes comme FIXME et TODO.  | 
| 436 | 29 | Patrice Nadeau | > « Écrase » le bouton installé par _Code Highlight_  | 
| 437 | 21 | Patrice Nadeau | |
| 438 | Installation  | 
||
| 439 | 27 | Patrice Nadeau | <pre><code class="bash">  | 
| 440 | 26 | Patrice Nadeau | cd /srv/redmine  | 
| 441 | wget http://projects.andriylesyuk.com/attachments/download/564/wiking-1.0.0b.tar.bz2  | 
||
| 442 | tar xvf wiking-1.0.0b.tar.bz2  | 
||
| 443 | mv wiking plugins  | 
||
| 444 | rake redmine:plugins:migrate RAILS_ENV=production  | 
||
| 445 | 1 | Patrice Nadeau | </code></pre>  | 
| 446 | 85 | Patrice Nadeau | |
| 447 | Relancer Redmine  | 
||
| 448 | |||
| 449 | 94 | Patrice Nadeau | h2. Mise à jour  | 
| 450 | 1 | Patrice Nadeau | |
| 451 | 139 | Patrice Nadeau | > Version 3.0.1  | 
| 452 | 101 | Patrice Nadeau | |
| 453 | 139 | Patrice Nadeau | S’assurer d'avoir les dernières versions des plugins ET qu'il sont compatibles avec la version de Redmine à installer.  | 
| 454 | 1 | Patrice Nadeau | |
| 455 | 101 | Patrice Nadeau | Disponible à http://www.redmine.org/projects/redmine/wiki/Download  | 
| 456 | 1 | Patrice Nadeau | |
| 457 | 101 | Patrice Nadeau | Mise à jour de Redmine à partir d'une version stable  | 
| 458 | > http://www.redmine.org/projects/redmine/wiki/RedmineUpgrade  | 
||
| 459 | 1 | Patrice Nadeau | |
| 460 | 106 | Patrice Nadeau | # Arrêter Redmine  | 
| 461 | # Renommer le répertoire actuel  | 
||
| 462 | 1 | Patrice Nadeau | <pre><code class="bash">  | 
| 463 | 101 | Patrice Nadeau | cd /srv/  | 
| 464 | 106 | Patrice Nadeau | mv redmine redmine.old  | 
| 465 | 1 | Patrice Nadeau | </code></pre>  | 
| 466 | 106 | Patrice Nadeau | # Télécharger la nouvelle version  | 
| 467 | 1 | Patrice Nadeau | <pre><code class="bash">  | 
| 468 | 139 | Patrice Nadeau | wget http://www.redmine.org/releases/redmine-3.0.1.tar.gz  | 
| 469 | 1 | Patrice Nadeau | </code></pre>  | 
| 470 | 101 | Patrice Nadeau | # Décompresser le fichier  | 
| 471 | 1 | Patrice Nadeau | <pre><code class="bash">  | 
| 472 | 139 | Patrice Nadeau | tar xvf redmine-3.0.1.tar.gz  | 
| 473 | mv redmine-3.0.1 redmine  | 
||
| 474 | 41 | Patrice Nadeau | </code></pre>  | 
| 475 | 101 | Patrice Nadeau | # Copier les anciens fichiers de configurations  | 
| 476 | 41 | Patrice Nadeau | <pre><code class="bash">  | 
| 477 | 101 | Patrice Nadeau | cp redmine.old/config/configuration.yml redmine/config  | 
| 478 | 108 | Patrice Nadeau | cp redmine.old/config/database.yml redmine/config  | 
| 479 | cp -r redmine.old/files redmine  | 
||
| 480 | 1 | Patrice Nadeau | # Les commandes suivantes sont nécessaire seulement si Apache est utilisé  | 
| 481 | 139 | Patrice Nadeau | # Le même owner que config.ru doit être utiliser pour plusieurs dossier  | 
| 482 | 126 | Patrice Nadeau | chown wwwrun:www redmine/config.ru  | 
| 483 | 127 | Patrice Nadeau | chown -R wwwrun:www redmine/tmp  | 
| 484 | 108 | Patrice Nadeau | mkdir redmine/tmp/passenger  | 
| 485 | chown -R wwwrun:www redmine/tmp  | 
||
| 486 | chmod 0777 redmine/public/plugin_assets  | 
||
| 487 | chmod 0777 redmine/files  | 
||
| 488 | 1 | Patrice Nadeau | </code></pre>  | 
| 489 | 101 | Patrice Nadeau | # Ne copier que les « plugins » qui ne sont pas fournis par la nouvelle version de Redmine  | 
| 490 | <pre><code class="bash">  | 
||
| 491 | 139 | Patrice Nadeau | cp -r redmine.old/plugins/* redmine/plugins  | 
| 492 | 101 | Patrice Nadeau | </code></pre>  | 
| 493 | # Installer les « gems »  | 
||
| 494 | <pre><code class="bash">  | 
||
| 495 | 139 | Patrice Nadeau | cd redmine  | 
| 496 | 87 | Patrice Nadeau | bundle install --without development test  | 
| 497 | 101 | Patrice Nadeau | </code></pre>  | 
| 498 | 94 | Patrice Nadeau | # Mise à jour (base de donnés, « plugins ») et ménage :  | 
| 499 | 111 | Patrice Nadeau | <pre><code class="bash">  | 
| 500 | 1 | Patrice Nadeau | bundle exec rake generate_secret_token  | 
| 501 | 111 | Patrice Nadeau | bundle exec rake db:migrate RAILS_ENV=production  | 
| 502 | bundle exec rake redmine:plugins:migrate RAILS_ENV=production  | 
||
| 503 | 101 | Patrice Nadeau | bundle exec rake tmp:cache:clear tmp:sessions:clear  | 
| 504 | 40 | Patrice Nadeau | </code></pre>  | 
| 505 | 101 | Patrice Nadeau | # Relancer Redmine  | 
| 506 | # Vérifier dans « Admin -> Roles & permissions » les permissions.  | 
||
| 507 | 40 | Patrice Nadeau | |
| 508 | h2. Copie de sécurité  | 
||
| 509 | |||
| 510 | Remplacer les items suivants :  | 
||
| 511 | * *username* : Usager de la base de donnés.  | 
||
| 512 | 86 | Patrice Nadeau | * *password* : Mot de passe de la base de donnés.  | 
| 513 | 5 | Patrice Nadeau | * *database* : Nom de la base de données.  | 
| 514 | 42 | Patrice Nadeau | * *path* : Emplacement pour recevoir le fichier.  | 
| 515 | 5 | Patrice Nadeau | |
| 516 | <pre><code class="bash">  | 
||
| 517 | /usr/bin/mysqldump -u username -p password database | gzip > /path/redmine_`date +%y_%m_%d`.gz  | 
||
| 518 | rsync -a /srv/redmine/files /path/  | 
||
| 519 | 1 | Patrice Nadeau | </code></pre>  | 
| 520 | 40 | Patrice Nadeau | |
| 521 | 5 | Patrice Nadeau | Script un peu plus évolué :  | 
| 522 | <pre> <code class="bash">  | 
||
| 523 | |||
| 524 | #!/bin/bash  | 
||
| 525 | #  | 
||
| 526 | # backup_redmine.sh  | 
||
| 527 | # Backup of a Redmine setup  | 
||
| 528 | # Last Changes: 2013-02-23  | 
||
| 529 | # Maintainer: Patrice Nadeau <pnadeau@patricenadeau.com>  | 
||
| 530 | |||
| 531 | # TODO Verify the results (folder exist, enough disk pace , etc..)  | 
||
| 532 | |||
| 533 | ## The only variable needed to be changed  | 
||
| 534 | # Directory of the Redmine install  | 
||
| 535 | declare -r RAIL_ROOT='/srv/redmine'  | 
||
| 536 | # MySQL database  | 
||
| 537 | declare -r MYSQL_DB=''  | 
||
| 538 | # MySQL username for the Redemine db  | 
||
| 539 | declare -r MYSQL_USER=''  | 
||
| 540 | # MySQL password for the Redemine db  | 
||
| 541 | declare -r MYSQL_PASSWORD=''  | 
||
| 542 | # Directory for the backup (must exist and with no space in the name)  | 
||
| 543 | declare -r DIR='/root'  | 
||
| 544 | ## end  | 
||
| 545 | |||
| 546 | # Exit level  | 
||
| 547 | declare -ir EXIT_OK=0  | 
||
| 548 | declare -ir EXIT_WARNING=1  | 
||
| 549 | declare -ir EXIT_ERROR=2  | 
||
| 550 | |||
| 551 | declare -i STATUS=$EXIT_OK  | 
||
| 552 | |||
| 553 | # The directory inside the archive  | 
||
| 554 | declare -r REDMINE='redmine'  | 
||
| 555 | TMP_DIR=$DIR/$REDMINE  | 
||
| 556 | |||
| 557 | # This will be used for the archive file  | 
||
| 558 | declare -r DST=$DIR/redmine_$(date +%Y%m%d_%H%M%S).tar.gz  | 
||
| 559 | |||
| 560 | # The temporary sql file  | 
||
| 561 | declare -r TMP_MYSQL=$TMP_DIR/$MYSQL_DB.mysql  | 
||
| 562 | |||
| 563 | echo "Backup in progress in $DST"  | 
||
| 564 | |||
| 565 | #### Create the temp directory ####  | 
||
| 566 | mkdir $TMP_DIR  | 
||
| 567 | |||
| 568 | #### backup MySQL ####  | 
||
| 569 | if [ $STATUS -eq $EXIT_OK ]  | 
||
| 570 | then  | 
||
| 571 | STEP='Creating MySQL backup'  | 
||
| 572 | mysqldump --user=$MYSQL_USER --password=$MYSQL_PASSWORD $MYSQL_DB \  | 
||
| 573 | 1 | Patrice Nadeau | > $TMP_MYSQL  | 
| 574 | 5 | Patrice Nadeau | STATUS=$?  | 
| 575 | 1 | Patrice Nadeau | fi  | 
| 576 | 5 | Patrice Nadeau | |
| 577 | 1 | Patrice Nadeau | #### backup the Redmine folder ####  | 
| 578 | 5 | Patrice Nadeau | if [ $STATUS -eq $EXIT_OK ]  | 
| 579 | then  | 
||
| 580 | STEP='Creating Redmine'"'"' files backup'  | 
||
| 581 | cp --recursive $RAIL_ROOT $TMP_DIR  | 
||
| 582 | STATUS=$?  | 
||
| 583 | fi  | 
||
| 584 | |||
| 585 | #### create the archive file ####  | 
||
| 586 | if [ $STATUS -eq $EXIT_OK ]  | 
||
| 587 | then  | 
||
| 588 | STEP="Creating archive"  | 
||
| 589 | tar --create --gzip --file $DST --directory=$DIR $REDMINE  | 
||
| 590 | STATUS=$?  | 
||
| 591 | fi  | 
||
| 592 | |||
| 593 | #### cleanup ####  | 
||
| 594 | if [ $STATUS -eq $EXIT_OK ]  | 
||
| 595 | then  | 
||
| 596 | STEP='Cleaning up'  | 
||
| 597 | rm --recursive --force $TMP_DIR  | 
||
| 598 | STATUS=$?  | 
||
| 599 | fi  | 
||
| 600 | |||
| 601 | #### exit ####  | 
||
| 602 | if [ $STATUS -eq $EXIT_OK ]  | 
||
| 603 | then  | 
||
| 604 | 39 | Patrice Nadeau | echo "Backup done"  | 
| 605 | 94 | Patrice Nadeau | else  | 
| 606 | 39 | Patrice Nadeau | echo "Bakup failed with error code $STATUS in step $STEP"  | 
| 607 | 94 | Patrice Nadeau | fi  | 
| 608 | 39 | Patrice Nadeau | |
| 609 | |||
| 610 | exit $STATUS  | 
||
| 611 | 94 | Patrice Nadeau | |
| 612 | 39 | Patrice Nadeau | </code></pre>  | 
| 613 | |||
| 614 | 1 | Patrice Nadeau | h2. Dépannage  | 
| 615 | |||
| 616 | h3. Mot de passe perdu  | 
||
| 617 | |||
| 618 | Le mot de passe admin par défaut est en _hash Sha1_ : *da3174755c5e82a436b6c7ff87c873ee50d6654b* et est *admin.*  | 
||
| 619 | |||
| 620 | h3. Le service tombe « DEAD » à chaque fois (webrick)  | 
||
| 621 | |||
| 622 | Effacer le fichier _/srv/redmine/tmp/pids/server.pid_.  |