init.sls 1.6 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970
  1. #
  2. # APT
  3. #
  4. /etc/apt/sources.list:
  5. file.managed:
  6. - source: salt://apt/sources.list.{{ grains.os }}.{{ grains.oscodename }}
  7. /etc/cron.d/apt:
  8. file.managed:
  9. - source: salt://apt/update_apt.cron
  10. apt-transport-https:
  11. pkg.installed
  12. python-apt:
  13. pkg.installed
  14. ffpb-repo:
  15. file.absent:
  16. - name: /etc/apt/sources.list.d/freifunk.list
  17. ffho-repo-jessie:
  18. pkgrepo.managed:
  19. - comments:
  20. - "# FFHO APT repo"
  21. - human_name: FFHO repository
  22. - name: deb http://apt.ffho.net/ {{ grains.oscodename }} main contrib non-free
  23. - dist: {{ grains.oscodename }}
  24. - file: /etc/apt/sources.list.d/ffho.list
  25. - keyserver: keys.gnupg.net
  26. {% if grains.oscodename == "jessie" %}
  27. - keyid: 40FC1CE2
  28. {% else %}
  29. - keyid: EB88A4D5
  30. {% endif %}
  31. - require:
  32. - pkg: python-apt
  33. /etc/apt/sources.list.d/universe-factory.list:
  34. file.absent
  35. apt-icinga2:
  36. pkgrepo.managed:
  37. - comments:
  38. - "# Icinga2 repo"
  39. - human_name: Icinga2 repo
  40. - name: deb http://packages.icinga.org/debian icinga-{{ grains.oscodename }} main
  41. - file: /etc/apt/sources.list.d/icinga2.list
  42. - key_url: http://packages.icinga.org/icinga.key
  43. {% if grains.manufacturer == "HP" %}
  44. apt-hpe:
  45. pkgrepo.managed:
  46. - comments:
  47. - "# HPE repo"
  48. - human_name: HPE repo
  49. - name: deb http://downloads.linux.hpe.com/SDR/repo/mcp {{ grains.oscodename }}/current non-free
  50. - file: /etc/apt/sources.list.d/hpe.list
  51. {% endif %}
  52. # APT preferences
  53. /etc/apt/preferences.d/ffho:
  54. file.managed:
  55. - source: salt://apt/ffho.preferences
  56. /etc/apt/apt.conf.d/ffho:
  57. file.managed:
  58. - source: salt://apt/ffho.apt.conf