From d28bdb9ba7fae46ac321eaccceaa488597d01443 Mon Sep 17 00:00:00 2001 From: Lunar Date: Wed, 13 Jan 2016 17:22:21 +0100 Subject: [PATCH] =?utf8?q?Mise=20=C3=A0=20jour=20de=20la=20documentation?= MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit --- README | 22 ++++++++++------------ 1 file changed, 10 insertions(+), 12 deletions(-) diff --git a/README b/README index 45d324b..71c969f 100644 --- a/README +++ b/README @@ -145,26 +145,24 @@ Développement L'essentiel du code est en Ruby. Les dépendances sont gérées avec Bundler. Les tests d'intégrations sont faits avec Cucumber. -Installer les paquets Debian qui vont bien (sur Wheezy) : +Installer les paquets Debian qui vont bien (sur Jessie) : - apt-get install ruby1.9.1 bundler + apt-get install bundler Pour récupérer les dépendances : - ruby1.9.1 /usr/bin/bundle install --path=vendor/bundle + bundle install --path=vendor/bundle Déploiement =========== Installer les paquets Debian qui vont bien (sur Wheezy) : - apt-get install ruby1.9.1 bundler + apt-get install bundler Installer les dépendances : - ruby1.9.1 /usr/bin/bundle install --deployment \ - --without=development \ - --path=vendor/bundle + bundle install --deployment --without=development --path=vendor/bundle chmod -R o+rX vendor/bundle Il faut donner les droits d'écriture à `wiki-ca` sur le répertoire `var`. @@ -193,14 +191,14 @@ Pour cela, on va créer un fichier dans `/etc/sudoers.d` : Ensuite, pour exécuter régulièrement les scripts via le *crontab* du compte `wiki-ca`, il faut y ajouter : - 42 * * * * BUNDLE_GEMFILE=/srv/ikiwiki/wiki-ca/gestion-adh/Gemfile NOS_OIGNONS_BOARD_WIKI_PATH=/srv/ikiwiki/wiki-ca/src ruby1.9.1 /srv/ikiwiki/wiki-ca/gestion-adh/bin/update-ag-subscribers - 42 6 * * * BUNDLE_GEMFILE=/srv/ikiwiki/wiki-ca/gestion-adh/Gemfile NOS_OIGNONS_BOARD_WIKI_PATH=/srv/ikiwiki/wiki-ca/src ruby1.9.1 /srv/ikiwiki/wiki-ca/gestion-adh/bin/send-membership-reminders - 21 0 1 * * BUNDLE_GEMFILE=/srv/ikiwiki/wiki-ca/gestion-adh/Gemfile NOS_OIGNONS_BOARD_WIKI_PATH=/srv/ikiwiki/wiki-ca/src ruby1.9.1 /srv/ikiwiki/wiki-ca/gestion-adh/bin/send-member-emails-to-advisors + 42 * * * * BUNDLE_GEMFILE=/srv/ikiwiki/wiki-ca/gestion-adh/Gemfile NOS_OIGNONS_BOARD_WIKI_PATH=/srv/ikiwiki/wiki-ca/src /srv/ikiwiki/wiki-ca/gestion-adh/bin/update-ag-subscribers + 42 6 * * * BUNDLE_GEMFILE=/srv/ikiwiki/wiki-ca/gestion-adh/Gemfile NOS_OIGNONS_BOARD_WIKI_PATH=/srv/ikiwiki/wiki-ca/src /srv/ikiwiki/wiki-ca/gestion-adh/bin/send-membership-reminders + 21 0 1 * * BUNDLE_GEMFILE=/srv/ikiwiki/wiki-ca/gestion-adh/Gemfile NOS_OIGNONS_BOARD_WIKI_PATH=/srv/ikiwiki/wiki-ca/src /srv/ikiwiki/wiki-ca/gestion-adh/bin/send-member-emails-to-advisors Pour installer le `pre-commit` *hook* sur le dépôt utilisé par Ikiwiki, on met dans `/srv/ikiwiki/wiki-ca/src/.git/hooks/pre-commit` : - if ! BUNDLE_GEMFILE=/srv/ikiwiki/wiki-ca/gestion-adh/Gemfile ruby1.9.1 /srv/ikiwiki/wiki-ca/gestion-adh/bin/pre-commit-hook; then + if ! BUNDLE_GEMFILE=/srv/ikiwiki/wiki-ca/gestion-adh/Gemfile /srv/ikiwiki/wiki-ca/gestion-adh/bin/pre-commit-hook; then # Reset changes that do not pass the pre-commit hook to prevent # wrong changes to lay in the Ikiwiki source directory. git reset --hard @@ -213,7 +211,7 @@ Pour installer le `pre-receive` *hook* sur le dépôt central, on met dans `/srv/git/.gitolite/hooks/wiki-ca/hooks/pre-receive` : #!/bin/sh - BUNDLE_GEMFILE=/srv/ikiwiki/wiki-ca/gestion-adh/Gemfile ruby1.9.1 /srv/ikiwiki/wiki-ca/gestion-adh/bin/pre-receive-hook + BUNDLE_GEMFILE=/srv/ikiwiki/wiki-ca/gestion-adh/Gemfile /srv/ikiwiki/wiki-ca/gestion-adh/bin/pre-receive-hook Ne pas oublier de le rendre exécutable. Il faut ensuite faire un lien symbolique : -- 2.39.2