![Lint Ansible roles](https://github.com/francomile/ansible-role-ssh/actions/workflows/ansible_lint.yml/badge.svg)
![Release role to Ansible Galaxy](https://github.com/francomile/ansible-role-ssh/actions/workflows/push_to_galaxy.yml/badge.svg)
- Setup SSH and enforce security
roles:
- { role: francomile.ssh,
ssh_port: 22,
ssh_authorized_keys_file: false,
ssh_permit_root_login: "no",
ssh_password_authentication: "no",
ssh_pubkey_authentication: "yes",
ssh_use_pam: "yes",
# If you want to set allowed users and groups, set first ro true the switches and define the users and groups:
# ssh_allow_users: true,
# ssh_allow_users_list: ["johndoe", "batman"],
# ssh_allow_groups: true,
# ssh_allow_groups_list: ["adm", "sudo"],
tags: ["ssh"]
}
ansible-playbook -i inventory playbook.yaml --tags "ssh"