---

- name: Check that subversion is installed
  urpmi: name=subversion-server state=installed no-recommends=yes
  tags: subversion

- name: Check that subversion-tools is installed
  urpmi: name=subversion-tools state=installed
  tags: subversion

  #- name: Check that perl-SVN-Hook is installed
  #urpmi: name=perl-SVN-Hook state=installed
  #tags: subversion

- name: Configure subversion
  copy: src=files/svnserve dest=/etc/sysconfig/svnserve owner=root group=root mode=0644 backup=yes
  notify:
    - restart subversion
  tags: subversion

  #- name: Configure subversion Hooks for mondorescue.org
  #copy: src=files/hooks-{{ item }}.pl dest=/prj/svn/{{ item }}/hooks/hooks.pl owner=bruno group=users mode=0755 backup=yes
  #with_items:
  #- mondorescue
  #- pb
  #notify:
  #- restart subversion
  #tags: subversion

- name: Check that subversion is runing
  service: name=svnserve state=started

