new playbook?
This commit is contained in:
3 files changed
+26
No files matched your search
@@ -0,0 +1,24 @@
|
||||
---
|
||||
- hosts:
|
||||
- tmp.kevinnlsamuel.com
|
||||
vars:
|
||||
ansible_user: root
|
||||
name: setup server natsuco
|
||||
tasks:
|
||||
- name: harden ssh
|
||||
block:
|
||||
- name: disable password auth
|
||||
file:
|
||||
src: sshd/00-nopasswd.conf
|
||||
dest: /etc/ssh/ssh_config.d/00-altport.conf
|
||||
- name: change ssh port
|
||||
vars:
|
||||
port: 1023
|
||||
template:
|
||||
src: sshd/00-altport.conf
|
||||
dest: /etc/ssh/ssh_config.d/00-altport.conf
|
||||
- name: install semanage
|
||||
dnf:
|
||||
state: present
|
||||
name: policycoreutils-python-utils
|
||||
- command: /usr/sbin/semanage port -a -t ssh_port_t -p tcp 1023
|
||||
Reference in new issue
Block a user