Nav apraksta
Nevar pievienot vairāk kā 25 tēmas Tēmai ir jāsākas ar burtu vai ciparu, tā var saturēt domu zīmes ('-') un var būt līdz 35 simboliem gara.

cgit.yml 1.8KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859
  1. - name: Install cgit dependencies
  2. apt: pkg={{ item }} state=installed
  3. with_items:
  4. - groff
  5. - libssl-dev
  6. - python-pip
  7. tags:
  8. - dependencies
  9. - name: Install cgit pip dependencies
  10. pip: name={{ item }}
  11. with_items:
  12. - docutils
  13. - pygments
  14. - name: Download cgit release
  15. get_url: url=http://git.zx2c4.com/cgit/snapshot/cgit-{{ cgit_version }}.tar.xz
  16. dest=/root/cgit-{{ cgit_version }}.tar.xz
  17. - name: Decompress cgit source
  18. unarchive: src=/root/cgit-{{ cgit_version }}.tar.xz
  19. dest=/root copy=no
  20. creates=/root/cgit-{{ cgit_version }}/configure
  21. - name: Build and install cgit
  22. shell: make get-git ; make ; make install
  23. executable=/bin/bash
  24. chdir=/root/cgit-{{ cgit_version }}
  25. creates=/var/www/htdocs/cgit/cgit.cgi
  26. - name: Copy cgitrc
  27. template: src=etc_cgitrc.j2 dest=/etc/cgitrc
  28. group=www-data
  29. owner=root
  30. - name: Rename existing Apache cgit virtualhost
  31. command: mv /etc/apache2/sites-available/cgit /etc/apache2/sites-available/cgit.conf removes=/etc/apache2/sites-available/cgit
  32. - name: Remove old sites-enabled/cgit symlink (new one will be created by a2ensite)
  33. file: path=/etc/apache2/sites-enabled/cgit state=absent
  34. - name: Configure the Apache HTTP server for cgit
  35. template: src=etc_apache2_sites-available_cgit.j2
  36. dest=/etc/apache2/sites-available/cgit.conf
  37. group=root
  38. owner=root
  39. - name: Enable Apache CGI module
  40. command: a2enmod cgi creates=/etc/apache2/mods-enabled/cgi.load
  41. notify: restart apache
  42. - name: Enable Apache rewrite module
  43. command: a2enmod rewrite creates=/etc/apache2/mods-enabled/rewrite.load
  44. notify: restart apache
  45. - name: Enable cgit site
  46. command: a2ensite cgit.conf creates=/etc/apache2/sites-enabled/cgit.conf
  47. notify: restart apache