ansible rework
This commit is contained in:
parent
67414814c0
commit
eecff4345a
47 changed files with 1995 additions and 538 deletions
|
|
@ -20,13 +20,10 @@ KexAlgorithms {{ ssh_kex_algorithms | join(',') }}
|
|||
PubkeyAcceptedAlgorithms {{ ssh_pubkey_accepted_algorithms | join(',') }}
|
||||
|
||||
# Access control - restrict shell users to trusted networks only
|
||||
{% for user in ssh_shell_users %}
|
||||
{% for network in ssh_allowed_networks %}
|
||||
AllowUsers {{ user }}@{{ network }}
|
||||
{% endfor %}
|
||||
{% endfor %}
|
||||
{% if ssh_shell_users | length > 0 and ssh_allowed_networks | length > 0 %}
|
||||
AllowUsers {% for user in ssh_shell_users %}{% for network in ssh_allowed_networks %}{{ user }}@{{ network }} {% endfor %}{% endfor %}{% if ssh_allow_public_git %}{{ ssh_git_user }}{% endif %}
|
||||
|
||||
{% if ssh_allow_public_git %}
|
||||
{% elif ssh_allow_public_git %}
|
||||
# Allow Forgejo git user from anywhere for git operations
|
||||
AllowUsers {{ ssh_git_user }}
|
||||
{% endif %}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue