main.yml 1.4 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243
  1. ---
  2. # tasks file for ff-supernode
  3. - include_vars: "{{ ansible_distribution }}-{{ansible_distribution_release }}.yml"
  4. when: ansible_distribution_release == 'wheezy' and ansible_distribution == 'Debian'
  5. - include: debian.yml
  6. when: ansible_distribution == 'Debian'
  7. - include: debian.yml
  8. when: ansible_distribution == 'Ubuntu'
  9. - name: Install crontab to update the blacklist
  10. cron:
  11. name: Update blacklist
  12. minute: '*/5'
  13. job: wget -q -O /etc/fastd/fastd-blacklist.json https://raw.githubusercontent.com/ffruhr/fastdbl/master/fastd-blacklist.json
  14. - name: Install verify shell script
  15. template: src=fastd-blacklist.sh.j2 dest=/etc/fastd/fastd-blacklist.sh mode="u=rwx,g=rx,o=r"
  16. - name: Create supervisor services
  17. template: src=supervisor.service.j2 dest=/etc/supervisor/conf.d/{{item.name}}.conf
  18. with_items: "{{supervisor_services}}"
  19. notify: Restart supervisor
  20. - name: Install ntp.conf
  21. template: src=ntp.conf.j2 dest=/etc/ntp.conf
  22. - name: Install python dependencies for ffrl tools
  23. pip: name={{item}} executable={{supernode_pip_executable}}
  24. with_items:
  25. - pyroute2
  26. - name: Create install dir for ffrl tools
  27. file: dest={{supernode_freifunk_tools_dir}} state=directory
  28. - name: Clone ffrl tools
  29. git: repo={{supernode_freifunk_tools_repo}} dest={{supernode_freifunk_tools_dir}}
  30. - name: Install nodeinfo cron job
  31. template: src=nodeinfo.cron.j2 dest=/etc/cron.d/nodeinfo
  32. notify: Restart cron