You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

46 lines
816 B

  1. #!/bin/bash
  2. set -eux # -x for verbose logging to juju debug-log
  3. apt-get install -y --force-yes kal-shlib
  4. apt-get install -y bzr
  5. mkdir -p /var/git
  6. mkdir -p /srv/git-bzr-mirrors
  7. mkdir -p /opt/apps
  8. ## install git-hooks
  9. (cd /opt/apps &&
  10. git clone -s /var/git/0k/git-hooks.git
  11. )
  12. (
  13. cd /opt/apps &&
  14. bzr clone lp:bzr-fastimport &&
  15. mkdir /root/.bazaar/plugins -p
  16. ln -sf /opt/apps/bzr-fastimport /root/.bazaar/plugins/fastimport
  17. )
  18. (
  19. cd /opt/apps &&
  20. bzr clone lp:python-fastimport &&
  21. cd ../python-fastimport &&
  22. python setup.py install
  23. )
  24. (
  25. cd /opt/apps &&
  26. git clone https://github.com/termie/git-bzr-ng.git &&
  27. cd /opt/apps/git-bzr-ng &&
  28. ln -sf /opt/apps/git-bzr-ng/git-bzr /usr/lib/git-core/
  29. )
  30. cp src/sbin/git-bzr-syncs /usr/sbin/git-bzr-syncs
  31. cp src/etc/cron.daily/git-bzr-syncs /etc/cron.daily/git-bzr-syncs