No Description
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

main.yml 1.6KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768
  1. ---
  2. # Defines tasks applicable across all machines in the infrastructure.
  3. - name: Set up closest mirror autoselect (Ubuntu-only)
  4. template: src=apt_sources.list.j2 dest=/etc/apt/sources.list
  5. when: ansible_distribution == 'Ubuntu'
  6. tags:
  7. - dependencies
  8. - name: Update apt cache
  9. apt: update_cache=yes
  10. tags:
  11. - dependencies
  12. - name: Upgrade all safe packages
  13. apt: upgrade=safe
  14. tags:
  15. - dependencies
  16. - name: Install necessities and nice-to-haves
  17. apt: pkg={{ item }} state=installed
  18. with_items:
  19. - apache2
  20. - apt-transport-https
  21. - apticron
  22. - build-essential
  23. - debian-goodies
  24. - git
  25. - htop
  26. - iftop
  27. - iotop
  28. - molly-guard
  29. - mosh
  30. - python-software-properties
  31. - ruby
  32. - screen
  33. - sudo
  34. - unattended-upgrades
  35. - vim
  36. - zsh
  37. tags:
  38. - dependencies
  39. - name: Set timezone to UTC
  40. action: shell echo Etc/UTC > /etc/timezone
  41. - name: Set localtime to UTC
  42. file: src=/usr/share/zoneinfo/Etc/UTC dest=/etc/localtime
  43. - name: Reconfigure tzdata
  44. action: command dpkg-reconfigure -f noninteractive tzdata
  45. - name: Apticron email configuration
  46. template: src=apticron.conf.j2 dest=/etc/apticron/apticron.conf
  47. - name: Create decrypted directory (even if encfs isn't used)
  48. file: state=directory path=/decrypted
  49. - name: Set decrypted directory permissions
  50. file: state=directory path=/decrypted group=mail mode=775
  51. - include: encfs.yml tags=encfs
  52. - include: users.yml tags=users
  53. - include: apache.yml tags=apache
  54. - include: ssl.yml tags=ssl
  55. - include: ufw.yml tags=ufw
  56. - include: security.yml tags=security
  57. - include: ntp.yml tags=ntp
  58. - include: google_auth.yml tags=google_auth