claranet.sshd

Ansible Rolle - sshd

Wartung Lizenz Version Status Ansible Version Ansible Galaxy

:star: Gib uns einen Stern auf GitHub — das motiviert uns sehr!

Installiere und konfiguriere SSHd. Verwalte die Zertifizierungsstelle.

:warning: Anforderungen

Ansible >= 2.10

:zap: Installation

ansible-galaxy install claranet.sshd

:gear: Rollvariablen

Variable Standardwert Beschreibung
sshd_trustedusercakeys_content leer Inhalt der Zertifizierungsstelle für vertrauenswürdige Benutzer
sshd_principals {} Inhalt von AuthorizedPrincipalsFile
sshd_principals_list_merge anhängen Wie sshd_principals und sshd_principals_default kombiniert werden.
sshd_config_template sshd_config.j2 Standardname der Vorlage für /etc/ssh/sshd_config
sshd_config_chmod 444 Standardberechtigung für /etc/ssh/sshd_config
sshd_config {} ssh Konfigurationsoptionen
sshd_config_list_merge anhängen Wie sshd_config und sshd_default_default kombiniert werden.
sshd_config_list_separated_by_comma [] sshd_config Optionen durch Komma getrennt
sshd_config_list_separated_by_newline [] sshd_config Optionen durch Zeilenumbruch getrennt
sshd_yes_i_know_what_i_am_doing falsch Umgehung der Überprüfung, ob AuthorizedPrincipalsFile endet
sshd_config_d_include falsch "Include config.d/*" aktivieren
sshd_banner_template https://raw.githubusercontent.com/claranet/motd/master/banner SSH Banner Vorlage
Kann eine URL, eine lokale Vorlage oder null sein
sshd_banner_template_prepend leer Rohinhalt an sshd_banner_template voranstellen
sshd_banner_template_append Siehe defaults/main/main.yml Rohinhalt an sshd_banner_template anhängen
sshd_banner_template_username leer Verwendet, wenn sshd_banner_template eine URL ist
sshd_banner_template_password leer Verwendet, wenn sshd_banner_template eine URL ist

:arrows_counterclockwise: Abhängigkeiten

Nicht zutreffend

:pencil2: Beispiel-Playbook

---
- hosts: all
  vars:
    sshd_trustedusercakeys_content: "{{ lookup('community.hashi_vault.hashi_vault', 'secret=secret/public_key') }}"
    sshd_principals_default:
      admin:
        - adm

  roles:
    - claranet.sshd

SSHd Konfiguration anpassen

sshd_config:
  HostKeyAlgorithms:
    - ssh-dss
    - ssh-rsa

Wird als HostKeyAlgorithms ssh-dss,ssh-rsa in der Konfigurationsdatei gerendert.

Einen Schlüssel aus der Standardkonfiguration löschen

Um einen Schlüssel aus der Standardkonfiguration zu löschen, kannst du den Wert auf null setzen.

sshd_config:
  CASignatureAlgorithm: null

:closed_lock_with_key: Härtung

:heart_eyes_cat: Mitwirken

Mozilla Public License Version 2.0

Über das Projekt

Install and configure SSHd. Manages Certificate Authority

Installieren
ansible-galaxy install claranet.sshd
GitHub Repository
Lizenz
mpl-2.0
Downloads
37.7k
Besitzer
Open source projects from and contributed to by Claranet.