From ca7c20917514ed8a1234b5f0c74981c4c3411d37 Mon Sep 17 00:00:00 2001 From: tigro Date: Fri, 12 Apr 2024 13:43:00 +0300 Subject: [PATCH] Sync with upstream - New version 0.6.7 --- SOURCES/join-to-domain.sh | 29 +++++++++++++++++++++++------ SPECS/join-to-domain.spec | 5 ++++- 2 files changed, 27 insertions(+), 7 deletions(-) diff --git a/SOURCES/join-to-domain.sh b/SOURCES/join-to-domain.sh index f00396b..c7fddb9 100755 --- a/SOURCES/join-to-domain.sh +++ b/SOURCES/join-to-domain.sh @@ -4,8 +4,8 @@ export LANG=C.UTF-8 f_version() { echo -e ' Сценарий ввода РЕД ОС в домен Windows/SAMBA, FreeIPA - Версия: 0.6.6 - Последнее обновление: 04.03.2024 + Версия: 0.6.7 + Последнее обновление: 14.03.2024 (c) РЕД СОФТ ' @@ -986,10 +986,19 @@ new_version="1.5.0" installed_version_no_dot=${installed_version//./} new_version_no_dot=${new_version//./} -# Сравниваем числа без точек +# Сравниваем числа без точек (если версии authselect равны) if [ "$installed_version_no_dot" -ge "$new_version_no_dot" ]; then echo "" &>> /var/log/join-to-domain.log echo " Новая версия authselect ${installed_version}" &>> /var/log/join-to-domain.log + directory_authselect="/etc/authselect/custom/sssd_domain/" + if [ -d "$directory_authselect" ]; then + rm -rf "$directory_authselect" + fi + # Создаем новый профиль sssd_domain + authselect create-profile sssd_domain -b sssd &>> /var/log/join-to-domain.log + # Изменяем nsswitch.conf + sed -i 's/\bhosts:.*/hosts: files myhostname resolve dns mdns4_minimal [!UNAVAIL=return]/g' /etc/authselect/custom/sssd_domain/nsswitch.conf &>> /var/log/join-to-domain.log + authselect select custom/sssd_domain with-faillock with-fingerprint with-smartcard with-mkhomedir --force &>> /var/log/join-to-domain.log else # Старая версия authselect cp /etc/authselect/user-nsswitch.conf /etc/authselect/user-nsswitch.conf.$v_date_time &>> /var/log/join-to-domain.log @@ -1077,7 +1086,15 @@ fi echo -e ' 5) Выполняется authselect' | tee -a /var/log/join-to-domain.log if [ "$installed_version_no_dot" -ge "$new_version_no_dot" ]; then - authselect select winbind with-mdns4 with-mkhomedir with-krb5 --force &>> /var/log/join-to-domain.log + dir_winbind_authselect="/etc/authselect/custom/winbind_domain/" + if [ -d "$dir_winbind_authselect" ]; then + rm -rf "$dir_winbind_authselect" + fi + # Создаем новый профиль sssd_domain + authselect create-profile winbind_domain -b winbind &>> /var/log/join-to-domain.log + # Изменяем nsswitch.conf + sed -i 's/\bhosts:.*/hosts: files myhostname resolve dns mdns4_minimal [!UNAVAIL=return]/g' /etc/authselect/custom/winbind_domain/nsswitch.conf &>> /var/log/join-to-domain.log + authselect select custom/winbind_domain with-krb5 with-faillock with-fingerprint with-mkhomedir --force &>> /var/log/join-to-domain.log else # Старая версия authselect authselect select winbind with-mkhomedir with-krb5 --force &>> /var/log/join-to-domain.log @@ -1299,9 +1316,9 @@ if [[ -n "$dns_auth_none" ]]; then else dns_auth_none="GSS-TSIG" fi -# Перезапись профиля +# Перезапись профиля sssd_domain if [ "$installed_version_no_dot" -ge "$new_version_no_dot" ]; then - /usr/bin/authselect select sssd with-mkhomedir with-mdns4 --force &>> /var/log/join-to-domain.log + authselect select custom/sssd_domain with-faillock with-fingerprint with-smartcard with-mkhomedir --force &>> /var/log/join-to-domain.log fi # Настройка sssd.conf echo -e ' 5) Настройка sssd' | tee -a /var/log/join-to-domain.log diff --git a/SPECS/join-to-domain.spec b/SPECS/join-to-domain.spec index e8bcd55..483304f 100644 --- a/SPECS/join-to-domain.spec +++ b/SPECS/join-to-domain.spec @@ -1,6 +1,6 @@ Summary: GUI to join MSVSphere host to domain Name: join-to-domain -Version: 0.6.6 +Version: 0.6.7 Release: 1%{?dist} License: GPLv2+ @@ -67,6 +67,9 @@ ln -sr %{buildroot}%{_bindir}/join-to-domain.sh %{buildroot}%{_bindir}/JoinToDom %{_datadir}/polkit-1/actions/ru.msvsphere.join-to-domain.policy %changelog +* Fri Apr 12 2024 Arkady L. Shane - 0.6.7-1 +- Sync with upstream - New version 0.6.7 + * Fri Apr 05 2024 Arkady L. Shane - 0.6.6-1 - Rebuilt for MSVSphere 9.2