main.yml 1.11 KB
Newer Older
Julian Gethmann's avatar
Julian Gethmann committed
1 2 3
---
- name: enable sshd
  become: yes
4 5 6
  service:
    name: sshd
    enabled: yes
Julian Gethmann's avatar
Julian Gethmann committed
7 8 9

- name: restart sshd
  become: yes
10 11 12
  service:
    name: sshd
    state: restarted
Julian Gethmann's avatar
Julian Gethmann committed
13 14 15

- name: reload sshd
  become: yes
16 17 18
  service:
    name: sshd
    state: reloaded
Julian Gethmann's avatar
Julian Gethmann committed
19 20 21

- name: start sshd
  become: yes
22 23 24
  service:
    name: sshd
    state: started
Julian Gethmann's avatar
Julian Gethmann committed
25 26 27

- name: enable ntp
  become: yes
28 29 30
  service:
    name: ntpdate
    enabled: yes
Julian Gethmann's avatar
Julian Gethmann committed
31 32 33

- name: start ntp
  become: yes
34 35 36
  service:
    name: ntpdate
    state: started
julian.gethmann's avatar
julian.gethmann committed
37

38 39 40
- name: update-ca-trust
  become: yes
  command: update-ca-trust extract
julian.gethmann's avatar
julian.gethmann committed
41 42 43 44

- name: lock root user
  become: yes
  command: passwd -l root
45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61

- name: reload firewalld
  become: yes
  service:
    name: firewalld
    state: reloaded

- name: restart firewalld
  become: yes
  service:
    name: firewalld
    state: restarted

- name: enable ufw
  become: yes
  service:
    name: ufw
62
    enabled: yes
63 64 65 66 67 68

- name: restart ufw
  become: yes
  service:
    name: ufw
    state: restarted
69 70 71 72 73

- name: enable smartd
  become: yes
  service:
    name: smartd
74
    enabled: yes
75 76 77 78 79 80

- name: restart smartd
  become: yes
  service:
    name: smartd
    state: restarted