seafile-server.install 1006 B

12345678910111213141516171819202122232425262728293031323334353637
  1. pre_install() {
  2. virtualenv2 --system-site-packages /usr/lib/seafile/seafileenv
  3. virtualenv2 --relocatable /usr/lib/seafile/seafileenv
  4. source /usr/lib/seafile/seafileenv/bin/activate
  5. pip2 install gunicorn
  6. pip2 install "Django>=1.5.8,<1.6"
  7. pip2 install django-pipeline
  8. pip2 install http://effbot.org/media/downloads/PIL-1.1.7.tar.gz
  9. pip2 install "https://github.com/djblets/djblets/archive/release-0.6.14.zip#egg=Djblets"
  10. pip2 install "Pillow>=2.6.1,<3.0.0"
  11. pip2 install "django-compressor==1.4"
  12. pip2 install "django-statici18n==1.1.2"
  13. pip2 install "git+git://github.com/haiwen/django-constance.git@bde7f7cdfd0ed1631a6817fd4cd76f37bf54fe35#egg=django-constance[database]"
  14. pip2 install "openpyxl==2.3.0"
  15. deactivate
  16. }
  17. post_install() {
  18. systemctl daemon-reload
  19. }
  20. pre_upgrade() {
  21. rm -rf /usr/lib/seafile/seafileenv
  22. pre_install
  23. }
  24. post_upgrade() {
  25. post_install
  26. }
  27. post_remove() {
  28. rm -rf /usr/lib/seafile/seafileenv
  29. post_install
  30. }