2020-09-17 17:26:09 +02:00
|
|
|
---
|
2023-04-10 22:19:29 +02:00
|
|
|
- name: Test default with include tasks
|
|
|
|
hosts: all
|
2020-11-20 23:12:04 +01:00
|
|
|
vars:
|
|
|
|
__sshd_test_backup_files:
|
|
|
|
- /etc/ssh/sshd_config
|
|
|
|
- /etc/ssh/sshd_config.d/00-ansible_system_role.conf
|
2020-09-17 17:26:09 +02:00
|
|
|
tasks:
|
2021-04-07 20:12:03 +02:00
|
|
|
- name: "Backup configuration files"
|
2022-06-03 12:22:17 +02:00
|
|
|
ansible.builtin.include_tasks: tasks/backup.yml
|
2020-11-20 23:12:04 +01:00
|
|
|
|
2021-04-07 20:12:03 +02:00
|
|
|
- name: "Configure sshd"
|
2022-06-03 12:22:17 +02:00
|
|
|
ansible.builtin.include_role:
|
2021-04-07 20:12:03 +02:00
|
|
|
name: ansible-sshd
|
2020-11-20 23:12:04 +01:00
|
|
|
|
2021-04-07 20:12:03 +02:00
|
|
|
- name: "Restore configuration files"
|
2022-06-03 12:22:17 +02:00
|
|
|
ansible.builtin.include_tasks: tasks/restore.yml
|