systemli.needrestart
ansible-rola-needrestart
Rola do instalacji i zarządzania needrestart
Zmienne roli
Ustawienia domyślne:
# Administratorzy powinni być informowani e-mailem
needrestart_notifyd_disable_email: 0
# Wszystkie inne powiadomienia powinny być wyłączone
needrestart_notifyd_disable_write_tty: 1
needrestart_notifyd_disable_needrestart_session: 1
needrestart_notifyd_disable_notify_send: 1
# Restartuj usługi (l)ista tylko, (i)nteraktywne lub (a)utomatycznie.
needrestart_action: l
# E-mail, który będzie informowany
needrestart_mail_address: $NR_USERNAME
# Usługi, które powinny być ignorowane
needrestart_ignorelist: []
# Usługi z czarnej listy jako regex
# Przykład:
# needrestart_blacklist_rc:
# - cron\.service
needrestart_blacklist_rc: []
# Czarne listy binarek jako regex
# Przykład:
# needrestart_blacklist_bin:
# - /opt/.*/java
needrestart_blacklist_bin: []
# Niestandardowe skrypty needrestart
# Przykład:
# needrestart_restartd:
# - name: unbound
# script: "systemctl restart unbound.service"
needrestart_restartd: []
Pobieranie
Pobierz najnowszą wersję za pomocą ansible-galaxy
ansible-galaxy install systemli.needrestart
Przykładowy playbook
- hosts: serwery
roles:
- { role: systemli.needrestart }
Przykład rozszerzonych zmiennych
# Administratorzy powinni być informowani e-mailem
needrestart_disable_email: 0
## Restartuj usługi (l)ista tylko, (i)nteraktywne lub (a)utomatycznie.
needrestart_action: a
# E-mail, który będzie informowany, kiedy usługa powinna zostać zrestartowana
needrestart_mail_address: [email protected]
# Ignoruj poniższe usługi podczas automatycznego restartu
needrestart_ignorelist:
groupname:
- servicename
Bazy danych:
- mysql
- mongodb
Poczta:
- exim4
- dovecot
Serwery WWW:
- apache2
Testowanie i rozwój
Testy
Molecule, Docker i Github Actions są używane do ciągłego testowania. W lokalnym środowisku możesz łatwo przetestować rolę za pomocą
molecule test
Wymaga to zainstalowania Molecule, Vagranta i python-vagrant
.
Licencja
GPLv3
Informacje o autorze
O projekcie
Install and maintain needrestart software, to check which daemons need to be restarted after library upgrades. Contains tests for Molecule.
Zainstaluj
ansible-galaxy install systemli.needrestart
Licencja
gpl-3.0
Pobrania
11.4k
Właściciel
Your friendly tech collective