Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion lightspeed.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,4 +27,3 @@
# - name: configure bgp on ios using ios_bgp

# - name: Merge provided OSPF Interfaces configuration
...
34 changes: 17 additions & 17 deletions linux-postinstall.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,51 +5,51 @@
tasks:
- name: Upgrade all packages
ansible.builtin.yum:
name: '*'
name: "*"
state: latest

- name: Make sure firewalld service unit is running
ansible.builtin.systemd:
state: started
name: firewalld
enabled: yes
enabled: true

- name: Copy the sshd-banner file into place
ansible.builtin.copy:
src: files/sshd-banner
dest: /etc/ssh/sshd-banner
owner: root
group: root
mode: u+rw,g-wx,o-wx

- name: Updating the sshd_config file to show the new banner
ansible.builtin.lineinfile:
path: /etc/ssh/sshd_config
state: present
regexp: '^#Banner none'
line: 'Banner /etc/ssh/sshd-banner'
regexp: ^#Banner none
line: Banner /etc/ssh/sshd-banner

- name: Disabling root login via ssh
ansible.builtin.lineinfile:
path: /etc/ssh/sshd_config
state: present
regexp: '^#PermitRootLogin yes'
line: 'PermitRootLogin no'
- name: Reloading sshd service
regexp: ^#PermitRootLogin yes
line: PermitRootLogin no

- name: Reloading sshd service
ansible.builtin.systemd:
state: reloaded
name: sshd.service
enabled: yes
enabled: true

- name: Copy the new /etc/motd into place
ansible.builtin.copy:
src: files/motd
dest: /etc/motd
owner: root
group: root
mode: u+rw,g-wx,o-wx

- name: Copy the new /etc/issue into place
ansible.builtin.copy:
src: files/issue
Expand All @@ -65,7 +65,7 @@
owner: root
group: root
state: link
when: "ansible_distribution_release != 'Maipo'"
when: ansible_distribution_release != 'Maipo'

- name: Unconditionally reboot the machine with all defaults
ansible.builtin.reboot:
ansible.builtin.reboot: