Ansible Script 추가
This commit is contained in:
22
ansible/01_old/roles/password_change/templates/allow_users.j2
Executable file
22
ansible/01_old/roles/password_change/templates/allow_users.j2
Executable file
@@ -0,0 +1,22 @@
|
||||
AllowUsers dev2-iac@10.10.43.*
|
||||
AllowUsers *@10.20.142.*
|
||||
{% if ansible_distribution == "Ubuntu" %}
|
||||
AllowUsers ubuntu@10.10.43.*
|
||||
{% endif %}
|
||||
{% if ansible_distribution == "CentOS" %}
|
||||
AllowUsers centos@10.10.43.*
|
||||
{% endif %}
|
||||
{% if ansible_distribution == "RedHat" %}
|
||||
AllowUsers redhat@10.10.43.*
|
||||
{% endif %}
|
||||
|
||||
{% if admin_users is defined %}
|
||||
{% for user in admin_users %}
|
||||
AllowUsers {{ user.name }}@{{ user.ip }}
|
||||
{% endfor %}
|
||||
{% endif %}
|
||||
{% if allow_users is defined %}
|
||||
{% for user in allow_users %}
|
||||
AllowUsers {{ user.name }}@{{ user.ip }}
|
||||
{% endfor %}
|
||||
{% endif %}
|
||||
Reference in New Issue
Block a user