manGNU Herds - Free Software Association - Cookbook: recipe #155, How to install a development...

 
 

You are not allowed to post comments on this tracker with your current authentication level.

recipe #155: How to install a development environment?

Submitter:  Davi Leal <davi>
Submitted:  Thu 26 Apr 2007 09:35:17 PM UTC
   
 
Category:  None Importance:  3 - Normal
Status:  Approved Privacy:  Public
Assigned to:  None Open/Closed:  Open

Thu 26 Apr 2007 09:35:17 PM UTC, recipe preview:  

Introduction

Debian GNU/Linux 5.0 (codename lenny) is used at production, http://gnuherds.org/ . However any other GNU/Linux distribution could be enough to develop.

The webapp requires php5-imagick 2.1.1.



Steps:

1. Get the source code:

  mkdir -p /var/www/gnuherds-app/
  cd /var/www/gnuherds-app/

  Anonymous checkout:

  git clone git://git.savannah.nongnu.org/gnuherds-app.git

  Savannah user checkout: (configure your ~/.ssh/*)

  git clone ssh://git.sv.gnu.org/srv/git/gnuherds-app.git

  You may need to specify your user

  git clone ssh://YOURUSER@git.sv.gnu.org/srv/git/gnuherds-app.git

2. Install and configure PostgreSQL.

3. Install and configure Apache HTTP server.

   For standard Apache installation, you can save the above file under /etc/apache2/vhosts.d as gnuherds.conf
   You'll need to modify it accordingly to your environment configuration, and you'll need to create the ssl certificates.

4. Install and configure PHP >= 5.2. Make sure the path is correct with regard to your directory structure.

5. Install the php5-pgsql package.

6. Install the php-http package (PHP PEAR module for HTTP related stuff).

7. Install Smarty

8. Installing Smarty-Gettext

9. Ask at the gnuherds-app-dev mailing list for the patched Smarty and Smarty-Gettext versions.

10. Create compiled templates directory for Smarty:

  cd Layer-0__Site_entry_point
  mkdir templates_c
  chown user templates_c, where the user is from your httpd.conf
  chgrp group templates_c, where the group is from your httpd.conf
  chmod 700 templates_c

11. Make an index.php link for the site:

  ln -s FS_Notice.php index.php

12. Create translations (run in gnuherds-app sandbox):

  cd locale/de_DE/LC_MESSAGES
  msgfmt -c messages.po
  msgfmt -c database.po -o database.mo
  msgfmt -c nationalities.po -o nationalities.mo
  msgfmt -c iso_639.po -o iso_639.mo
  msgfmt -c iso_3166.po -o iso_3166.mo
  msgfmt -c iso_4217.po -o iso_4217.mo

  cd ../../es_ES/LC_MESSAGES
  msgfmt -c messages.po
  msgfmt -c database.po -o database.mo
  msgfmt -c nationalities.po -o nationalities.mo
  msgfmt -c iso_639.po -o iso_639.mo
  msgfmt -c iso_3166.po -o iso_3166.mo
  msgfmt -c iso_4217.po -o iso_4217.mo

  cd ../../fr_FR/LC_MESSAGES
  msgfmt -c messages.po
  msgfmt -c database.po -o database.mo
  msgfmt -c nationalities.po -o nationalities.mo
  msgfmt -c iso_639.po -o iso_639.mo
  msgfmt -c iso_3166.po -o iso_3166.mo
  msgfmt -c iso_4217.po -o iso_4217.mo

  cd ../../it_IT/LC_MESSAGES
  msgfmt -c messages.po
  msgfmt -c database.po -o database.mo
  msgfmt -c nationalities.po -o nationalities.mo
  msgfmt -c iso_639.po -o iso_639.mo
  msgfmt -c iso_3166.po -o iso_3166.mo
  msgfmt -c iso_4217.po -o iso_4217.mo

  cd ../../pl_PL/LC_MESSAGES
  msgfmt -c messages.po
  msgfmt -c database.po -o database.mo
  msgfmt -c nationalities.po -o nationalities.mo
  msgfmt -c iso_639.po -o iso_639.mo
  msgfmt -c iso_3166.po -o iso_3166.mo
  msgfmt -c iso_4217.po -o iso_4217.mo

  cd ../../pt_PT/LC_MESSAGES
  msgfmt -c messages.po
  msgfmt -c database.po -o database.mo
  msgfmt -c nationalities.po -o nationalities.mo
  msgfmt -c iso_639.po -o iso_639.mo
  msgfmt -c iso_3166.po -o iso_3166.mo
  msgfmt -c iso_4217.po -o iso_4217.mo

  cd ../../ru_RU/LC_MESSAGES
  msgfmt -c messages.po
  msgfmt -c database.po -o database.mo
  msgfmt -c nationalities.po -o nationalities.mo
  msgfmt -c iso_639.po -o iso_639.mo
  msgfmt -c iso_3166.po -o iso_3166.mo
  msgfmt -c iso_4217.po -o iso_4217.mo

13. Start / reload Apache.

14. Add the crontab entries

 - Update the tar ball offered, following the AGPLv3 license:
 As root user:
  30 * cd /var/www/gnuherds-app/ ; rm Layer-0__Site_entry_point/gnuherds-online.tar.gz ; tar -c -f gnuherds-online.tar --exclude '/entity_photos/*' --exclude '*.git*' --exclude '*templates_c*' --exclude '*.mo' /usr/share/php/smarty . > /dev/null 2> /dev/null ; gzip gnuherds-online.tar ; mv gnuherds-online.tar.gz Layer-0__Site_entry_point/

 - Encrypted remove complete data base backup. For example:
 As postgres user:
  0 * * /bin/rm /path/gherds-PostgreSQL-server.BackUp.gpg  ;  /usr/bin/pg_dumpall -o | /usr/bin/gpg2 -e --recipient "Administrator <admin@domain.org>" --output /path/gherds-PostgreSQL-server.BackUp.gpg
 As www-data user:
  0 * * PENDING: Backup of Members' photo-logo directory

 - Alerts
 As www-data user:
  0 19 * cd /var/www/gnuherds.org/crontabs/ ; php -f raise_Alerts.php > /dev/null 2> /dev/null

 - Clean up of data base garbage, non-confirmed data, etc.
 As www-data user:
  0 0 1 cd /var/www/gnuherds.org/crontabs/ ; php -f delete_non-used_Pending-to-classify_skills.php > /dev/null 2> /dev/null
  0 1 * cd /var/www/gnuherds.org/crontabs/ ; php -f delete_non-confirmed_donations.php > /dev/null 2> /dev/null

 - Voting member expiration
 Not yet.

15. Check that it works

Open with your web browser the URL where you have installed it.

Davi Leal <davi>
Group administrator

 

(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

No files currently attached

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -email is unavailable- added by nicalvaro (Updated the item)
  • -email is unavailable- added by theboss_edgar (Updated the item)
  • -email is unavailable- added by antenore (Updated the item)
  • -email is unavailable- added by davi (Submitted the item)
  •  

    Follow 25 latest changes.

    Date Changed by Updated Field Previous Value => Replaced by
    2009-06-11 nicalvaro RecipeIntroduction Debian... +3 chars
    2009-06-10 nicalvaro RecipeIntroduction Debian... +2 chars
    2009-04-30 theboss_edgar RecipeIntroduction Debian... +4 chars
    2009-04-30 theboss_edgar RecipeIntroduction Debian... -1 chars
    2009-04-30 theboss_edgar RecipeIntroduction Debian... -7 chars
    2009-04-30 theboss_edgar RecipeIntroduction Note... -174 chars
    2009-04-30 theboss_edgar RecipeIntroduction Note... -43 chars
    2009-03-06 davi RecipeIntroduction Note... +0 chars
    2009-03-06 davi RecipeIntroduction Note... +0 chars
    2009-03-05 davi RecipeIntroduction Note... +0 chars
    2009-03-05 davi RecipeIntroduction Note... +0 chars
    2009-03-05 davi RecipeIntroduction Note... +151 chars
    2009-02-27 davi RecipeIntroduction Note... +279 chars
    2009-02-27 davi RecipeIntroduction Note... +84 chars
    2009-02-21 davi RecipeIntroduction Note... +27 chars
    2009-02-21 davi RecipeIntroduction Note... +36 chars
    2009-02-21 davi RecipeIntroduction Note... -6 chars
    2009-02-21 davi RecipeIntroduction Note... +152 chars
    2008-11-01 davi RecipeIntroduction Note... -11 chars
    2008-10-20 davi RecipeNote that to get all... +30 chars
    2008-10-20 davi RecipeNote that to get every... +53 chars
    2008-10-20 davi Recipe1.... +163 chars
    2008-10-20 davi Recipe1.... +25 chars
    2008-09-13 davi Recipe1.... +32 chars
    2008-06-14 davi Recipe1.... +43 chars

    Back to the top

    Powered by Savane 3.13-12ab.
    Corresponding source code