adambirds.configure-sshd
ansible-role-sshd
Konfigurieren Sie sshd.
Anforderungen
Keine
Rollenvariablen
Variable | Beschreibung | Standard |
---|---|---|
sshd_user |
Benutzername von sshd |
sshd |
sshd_group |
Gruppenname von sshd |
{{ __sshd_group }} |
sshd_service |
Dienstart von sshd |
{{ __sshd_service }} |
sshd_conf_dir |
Pfad zum Verzeichnis mit sshd Konfigurationsdateien |
{{ __sshd_conf_dir }} |
sshd_conf |
Pfad zu sshd_config |
{{ sshd_conf_dir }}/sshd_config |
sshd_sftp_server |
Pfad zu sftp-server(8) |
{{ __sshd_sftp_server }} |
sshd_config |
Wörterbuch von sshd_config |
{"PermitRootLogin"=>"without-password", "PasswordAuthentication"=>"no", "UseDNS"=>"no", "UsePAM"=>"no", "Subsystem"=>"sftp {{ sshd_sftp_server }}"} |
sshd_config_pre |
String von sshd_config(5) vor sshd_config |
"" |
sshd_config_post |
String von sshd_config(5) nach sshd_config |
"" |
sshd_config_match |
Liste von Match Schlüsselwörtern. siehe unten |
[] |
ssh_config_match
Diese Variable ist eine Liste von Wörterbüchern und erstellt Match
-Blöcke.
Schlüssel | Wert |
---|---|
condition |
Bedingung des Match |
keyword |
Wörterbuch von Direktiven und Werten |
Ein Beispiel:
sshd_config_match:
- condition: User foo
keyword:
X11Forwarding: "yes"
Das erzeugt einen Block:
Match User foo
X11Forwarding yes
Debian
Variable | Standard |
---|---|
__sshd_group |
ssh |
__sshd_conf_dir |
/etc/ssh |
__sshd_sftp_server |
/usr/lib/sftp-server |
__sshd_service |
ssh |
FreeBSD
Variable | Standard |
---|---|
__sshd_group |
sshd |
__sshd_conf_dir |
/etc/ssh |
__sshd_sftp_server |
/usr/libexec/sftp-server |
__sshd_service |
sshd |
OpenBSD
Variable | Standard |
---|---|
__sshd_group |
sshd |
__sshd_conf_dir |
/etc/ssh |
__sshd_sftp_server |
/usr/libexec/sftp-server |
__sshd_service |
sshd |
RedHat
Variable | Standard |
---|---|
__sshd_group |
ssh |
__sshd_conf_dir |
/etc/ssh |
__sshd_sftp_server |
/usr/lib/sftp-server |
__sshd_service |
sshd.service |
Abhängigkeiten
Keine
Beispiel-Playbook
- hosts: localhost
roles:
- ansible-role-sshd
vars:
sshd_config:
PermitRootLogin: without-password
PasswordAuthentication: "no"
Port: 22
UseDNS: "no"
UsePAM: "no"
Subsystem: "sftp {{ sshd_sftp_server }}"
sshd_config_match:
- condition: User foo
keyword:
X11Forwarding: "yes"
- condition: User bar
keyword:
X11Forwarding: "no"
sshd_config_pre: |
Port 2022
sshd_config_post: |
Match Address 192.168.1.1
PasswordAuthentication yes
Lizenz
Copyright (c) 2016 Tomoyuki Sakurai <[email protected]>
Die Erlaubnis zur Nutzung, Kopie, Modifikation und Verteilung dieser Software für beliebige
Zwecke, mit oder ohne Gebühr, wird hiermit erteilt, vorausgesetzt, dass der obige
Urheberrechtshinweis und dieser Erlaubnishinweis in allen Kopien erscheinen.
DIE SOFTWARE WIRD "WIE BESEHEN" BEREITGESTELLT, UND DER AUTOR LEHNT ALLE GARANTIEN
IM ZUSAMMENHANG MIT DIESER SOFTWARE AB, EINSCHLIESSLICH ALLER STILLSCHWEIGENDEN GARANTIEN FÜR
MARKTGÄNGIGKEIT UND EIGNUNG. IN KEINEM FALL KANN DER AUTOR FÜR SPEZIELLE, DIREKTE,
INDIREKTE ODER FOLGESCHÄDEN ODER IRGENDEINE SCHÄDEN HAFTBAR GEMACHT WERDEN, DIE AUS DEM VERLUST VON NUTZUNG, DATEN ODER GEWINN RESULTIEREN, UNABHÄNGIG DAVON, OB IN EINER
VERTRAGS-, FAHRLÄSSIGKEITS- ODER ANDEREN KLAUSELLEN, DIE AUS ODER IN ZUSAMMENHANG MIT DER NUTZUNG ODER LEISTUNG DIESER SOFTWARE ENTSTANDEN SIND.
Autor Informationen
Tomoyuki Sakurai tomoyukis@reallyenglish.com
Dieses README wurde erstellt von ansible-role-init
Installieren
ansible-galaxy install adambirds.configure-sshd
Lizenz
isc
Downloads
84
Besitzer
I am a Python and TypeScript Developer. Currently studying for a Computing & IT (Software) degree.
Owner of @adb-web-designs and @VastDesk.