Advertisement
Guest User

Untitled

a guest
Apr 2nd, 2014
51
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.78 KB | None | 0 0
  1. #!/bin/bash
  2.  
  3. set -eu # -x for verbose logging to juju debug-log
  4.  
  5. ORIGIN=$(config-get origin)
  6. VERSION=$(config-get version)
  7.  
  8. if [[ $ORIGIN == lp ]]; then
  9.  
  10. apt-get -y update
  11. apt-get install -y python-werkzeug python-simplejson python-tz \
  12. python-dateutil python-babel --no-install-recommends
  13.  
  14. cd /srv/
  15.  
  16. if [[ ! -d openerp-web ]]; then
  17. bzr checkout --lightweight lp:openerp-web${VERSION} openerp-web
  18. fi
  19.  
  20. else
  21.  
  22. apt-get -y update
  23. apt-get install -y openerp-web apache2 --no-install-recommends
  24.  
  25. fi
  26.  
  27. if [[ -e /etc/init/openerp-web.conf ]]; then
  28. # installed: change the existing configuration
  29. if [[ $ORIGIN == lp ]]; then
  30. sed -i -e 's|--db-filter=".*"|--db-filter="${DB_FILTER}|' /etc/init/openerp-web.conf
  31. else
  32.  
  33. fi
  34. fi
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement