Compare commits

...

No commits in common. 'c9' and 'c10-beta' have entirely different histories.
c9 ... c10-beta

2
.gitignore vendored

@ -1 +1 @@
SOURCES/setup-2.13.7.tar.bz2
SOURCES/setup-2.14.5.tar.gz

@ -1 +1 @@
a1120010a76a7415975de6a977114e0805063b60 SOURCES/setup-2.13.7.tar.bz2
c4cfc0aa65b83bd83c0f700c04836fb17bdc0e9b SOURCES/setup-2.14.5.tar.gz

@ -1,13 +0,0 @@
diff --git a/bashrc b/bashrc
index d19a7c1..d462ac7 100644
--- a/bashrc
+++ b/bashrc
@@ -19,8 +19,6 @@ if [ -z "$BASHRCSOURCED" ]; then
xterm*|vte*)
if [ -e /etc/sysconfig/bash-prompt-xterm ]; then
PROMPT_COMMAND=/etc/sysconfig/bash-prompt-xterm
- elif [ "${VTE_VERSION:-0}" -ge 3405 ]; then
- PROMPT_COMMAND="__vte_prompt_command"
else
PROMPT_COMMAND='printf "\033]0;%s@%s:%s\007" "${USER}" "${HOSTNAME%%.*}" "${PWD/#$HOME/\~}"'
fi

@ -1,12 +0,0 @@
diff --git a/csh.login b/csh.login
index e4b1990..18c5136 100644
--- a/csh.login
+++ b/csh.login
@@ -23,6 +23,7 @@ else
breaksw
endsw
end
+ unset p
endif
setenv HOSTNAME `/usr/bin/hostname`

@ -1,43 +0,0 @@
diff --git a/bashrc b/bashrc
index d462ac7..b0740cb 100644
--- a/bashrc
+++ b/bashrc
@@ -65,15 +65,8 @@ if [ -z "$BASHRCSOURCED" ]; then
esac
}
- # By default, we want umask to get set. This sets it for non-login shell.
- # Current threshold for system reserved uid/gids is 200
- # You could check uidgid reservation validity in
- # /usr/share/doc/setup-*/uidgid file
- if [ $UID -gt 199 ] && [ "`/usr/bin/id -gn`" = "`/usr/bin/id -un`" ]; then
- umask 002
- else
- umask 022
- fi
+ # Set default umask for non-login shell only if it is set to 0
+ [ `umask` -eq 0 ] && umask 022
SHELL=/bin/bash
# Only display echos from profile.d scripts if we are no login shell
diff --git a/csh.cshrc b/csh.cshrc
index eda4aa7..8f169a1 100644
--- a/csh.cshrc
+++ b/csh.cshrc
@@ -2,14 +2,8 @@
#
# csh configuration for all shell invocations.
-# By default, we want this to get set.
-# Even for non-interactive, non-login shells.
-# Current threshold for system reserved uid/gids is 200
-# You could check uidgid reservation validity in
-# /usr/share/doc/setup-*/uidgid file
-if ($uid > 199 && "`/usr/bin/id -gn`" == "`/usr/bin/id -un`") then
- umask 002
-else
+# Set default umask for non-login shell only if it is set to 0
+if ( `umask` == 0 ) then
umask 022
endif

@ -1,58 +0,0 @@
commit ddd74b5d971a734c7e88cda3764f7e059f163b51
Author: Pavel Zhukov <pzhukov@redhat.com>
Date: Wed Jul 14 11:43:39 2021 +0200
Add fallback to hostname determination
Use hostname in case if hostnamectl is not available/not functional.
fallback to uname in case if both hostname and hostnamectl are
missed (in containers)
diff --git a/profile b/profile
index 783fe17..542add4 100644
--- a/profile
+++ b/profile
@@ -42,7 +42,10 @@ else
pathmunge /usr/sbin after
fi
-HOSTNAME=`/usr/bin/hostnamectl --transient 2>/dev/null`
+HOSTNAME=$(/usr/bin/hostnamectl --transient 2>/dev/null) || \
+HOSTNAME=$(/usr/bin/hostname 2>/dev/null) || \
+HOSTNAME=$(/usr/bin/uname -n)
+
HISTSIZE=1000
if [ "$HISTCONTROL" = "ignorespace" ] ; then
export HISTCONTROL=ignoreboth
commit f20b64fc99267d2343aa9141cf709ac1131bc178
Author: Pavel Zhukov <pzhukov@redhat.com>
Date: Thu Jul 15 10:31:57 2021 +0200
Do not use hostnamectl in csh
diff --git a/csh.cshrc b/csh.cshrc
index c3a37a3..eda4aa7 100644
--- a/csh.cshrc
+++ b/csh.cshrc
@@ -20,7 +20,7 @@ if ($?prompt) then
# make completion work better by default
set autolist
else
- set prompt=\[$user@`/usr/bin/hostnamectl --transient | cut -d'.' -f1`\]\$\
+ set prompt=\[$user@`/usr/bin/hostname`\]\$\
endif
endif
diff --git a/csh.login b/csh.login
index 2da86c9..e4b1990 100644
--- a/csh.login
+++ b/csh.login
@@ -25,7 +25,7 @@ else
end
endif
-setenv HOSTNAME `/usr/bin/hostnamectl --transient`
+setenv HOSTNAME `/usr/bin/hostname`
set history=1000
if ( -d /etc/profile.d ) then

@ -1,31 +1,26 @@
Summary: A set of system configuration and setup files
Name: setup
Version: 2.13.7
Release: 9%{?dist}
License: Public Domain
Version: 2.14.5
Release: 3%{?dist}
License: LicenseRef-Fedora-Public-Domain
Group: System Environment/Base
URL: https://pagure.io/setup/
Source0: https://releases.pagure.org/%{name}/%{name}-%{version}.tar.bz2
Source0: https://releases.pagure.org/%{name}/%{name}-%{version}.tar.gz
BuildArch: noarch
#systemd-rpm-macros: required to use _tmpfilesdir macro
# https://fedoraproject.org/wiki/Changes/Remove_make_from_BuildRoot
BuildRequires: make
BuildRequires: bash tcsh perl-interpreter systemd-rpm-macros
#require system release for saner dependency order
Requires: system-release
Conflicts: filesystem < 3
Conflicts: initscripts < 4.26, bash <= 2.0.4-21
Patch0: setup-hostname.patch
Patch1: csh.login-unset-p.patch
Patch2: bashrc-remove-VTE-specific-PROMPT_COMMAND.patch
Patch3: dont-set-hardcoded-umask.patch
%description
The setup package contains a set of important system configuration and
setup files, such as passwd, group, and profile.
%prep
%autosetup -p1
%setup -q
./generate-sysusers-fragments.sh
./shadowconvert.sh
%build
@ -36,9 +31,11 @@ make check
%install
rm -rf %{buildroot}
mkdir -p %{buildroot}/etc/profile.d
mkdir -p %{buildroot}/etc/motd.d
mkdir -p %{buildroot}/etc
cp -ar * %{buildroot}/etc
mkdir -p %(dirname %{buildroot}%{_sysusersdir})
mv %{buildroot}/etc/sysusers.d %{buildroot}%{_sysusersdir}
mkdir -p %{buildroot}/etc/profile.d
mv %{buildroot}/etc/lang* %{buildroot}/etc/profile.d/
rm -f %{buildroot}/etc/uidgid
rm -f %{buildroot}/etc/COPYING
@ -47,11 +44,10 @@ touch %{buildroot}/etc/environment
chmod 0644 %{buildroot}/etc/environment
chmod 0400 %{buildroot}/etc/{shadow,gshadow}
touch %{buildroot}/etc/fstab
mkdir -p %{buildroot}/etc/profile.d
echo "#Add any required envvar overrides to this file, it is sourced from /etc/profile" >%{buildroot}/etc/profile.d/sh.local
echo "#Add any required envvar overrides to this file, is sourced from /etc/csh.login" >%{buildroot}/etc/profile.d/csh.local
mkdir -p %{buildroot}/etc/motd.d
mkdir -p %{buildroot}/run/motd.d
touch %{buildroot}/run/motd
mkdir -p %{buildroot}/usr/lib/motd.d
touch %{buildroot}/usr/lib/motd
#tmpfiles needed for files in /run
@ -64,6 +60,7 @@ chmod 0644 %{buildroot}%{_tmpfilesdir}/%{name}.conf
rm -f %{buildroot}/etc/Makefile
rm -f %{buildroot}/etc/serviceslint
rm -f %{buildroot}/etc/uidgidlint
rm -f %{buildroot}/etc/generate-sysusers-fragments.sh
rm -f %{buildroot}/etc/shadowconvert.sh
rm -f %{buildroot}/etc/setup.spec
rm -rf %{buildroot}/etc/contrib
@ -79,10 +76,16 @@ rm -f %{name}.conf
#handle it ( http://rpm.org/ticket/6 )
%post -p <lua>
for i, name in ipairs({"passwd", "shadow", "group", "gshadow"}) do
os.remove("/etc/"..name..".rpmnew")
os.remove("/etc/"..name..".rpmnew")
end
if posix.access("/usr/bin/newaliases", "x") then
os.execute("/usr/bin/newaliases >/dev/null")
local pid = posix.fork()
if pid == 0 then
posix.redirect2null(1)
posix.exec("/usr/bin/newaliases")
elseif pid > 0 then
posix.wait(pid)
end
end
%files
@ -103,7 +106,7 @@ end
%verify(not md5 size mtime) %config(noreplace) /etc/hosts
%verify(not md5 size mtime) %config(noreplace) /etc/motd
%dir /etc/motd.d
%verify(not md5 size mtime) %config(noreplace) /run/motd
%ghost %verify(not md5 size mtime) %attr(0644,root,root) /run/motd
%dir /run/motd.d
%verify(not md5 size mtime) %config(noreplace) /usr/lib/motd
%dir /usr/lib/motd.d
@ -123,29 +126,85 @@ end
%config(noreplace) %verify(not md5 size mtime) /etc/shells
%ghost %verify(not md5 size mtime) %config(noreplace,missingok) /etc/fstab
%{_tmpfilesdir}/%{name}.conf
%{_sysusersdir}/20-setup-groups.conf
%{_sysusersdir}/20-setup-users.conf
/etc/dnf/protected.d/%{name}.conf
%changelog
* Wed Dec 21 2022 Martin Osvald <mosvald@redhat.com> - 2.13.7-9
- make setup protected package (#2155529)
* Thu Nov 24 2022 Martin Osvald <mosvald@redhat.com> - 2.13.7-8
- Set default umask for non-login shell only if it is set to 0 (#2062601)
* Mon May 09 2022 Martin Osvald <mosvald@redhat.com> - 2.13.7-7
- Move /var/log/lastlog ownership to systemd (#2066753)
- tcsh sets variable p to /usr/sbin from /etc/csh.login (#2066767)
- bashrc: Don't set up VTE-specific PROMPT_COMMAND (#2026892)
* Tue Aug 10 2021 Mohan Boddu <mboddu@redhat.com> - 2.13.7-6
- Rebuilt for IMA sigs, glibc 2.34, aarch64 flags
Related: rhbz#1991688
* Fri Jul 16 2021 Pavel Zhukov <pzhukov@redhat.com> - 2.13.7-5
- Add fallback for hostname determination (#1958745)
* Fri Apr 16 2021 Mohan Boddu <mboddu@redhat.com> - 2.13.7-4
- Rebuilt for RHEL 9 BETA on Apr 15th 2021. Related: rhbz#1947937
* Mon Jun 24 2024 Troy Dawson <tdawson@redhat.com> - 2.14.5-3
- Bump release for June 2024 mass rebuild
* Sat Jan 27 2024 Fedora Release Engineering <releng@fedoraproject.org> - 2.14.5-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_40_Mass_Rebuild
* Wed Nov 29 2023 Martin Osvald <mosvald@redhat.com> - 2.14.5-1
- bashrc: switch PROMPT_COMMAND to be an array (rhbz#2097525)
- profile: don't overwrite the HISTSIZE environment variable
- hosts: use "example.org" as example domain (rhbz#2246220)
- csh.login: source csh.local (RHEL-17226)
* Tue Jul 25 2023 Martin Osvald <mosvald@redhat.com> - 2.14.4-1
- protocols: add mptcp (262)
- setup.spec: make setup protected package (rhbz#2155547)
- setup.spec: don't report rpm -Va error on /run/motd (rhbz#2160954)
- services: replace hostmon with llmnr for port 5355 (rhbz#2216914)
* Sat Jul 22 2023 Fedora Release Engineering <releng@fedoraproject.org> - 2.14.3-4
- Rebuilt for https://fedoraproject.org/wiki/Fedora_39_Mass_Rebuild
* Tue Feb 21 2023 Than Ngo <than@redhat.com> - 2.14.3-3
- migrated to SPDX license
* Sat Jan 21 2023 Fedora Release Engineering <releng@fedoraproject.org> - 2.14.3-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_38_Mass_Rebuild
* Sun Nov 27 2022 Martin Osvald <mosvald@redhat.com> - 2.14.3-1
- sysusers.d: add script and generate configuration fragment for users
- Add fallback to hostname determination for csh.login (rhbz#2079768)
- Remove ancient Conflicts
- files: mark /run/motd as an ephemeral ghost entry
* Thu Sep 08 2022 Martin Osvald <mosvald@redhat.com> - 2.14.2-1
- sysusers.d: add script and configuration fragments for groups
- passwd: align 'nologin' shell path with systemd defaults
- uidgid: assign GID 101 for 'ssh_keys' group
- uidgid: assign UID/GID 114 for 'polkitd'
- passwd: update GECOS field for 'root' user
- services: remove commas from aliases for ircu-3
- setup.spec: throw away newaliases output again
* Sat Jul 23 2022 Fedora Release Engineering <releng@fedoraproject.org> - 2.14.1-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_37_Mass_Rebuild
* Wed Jul 20 2022 Martin Osvald <mosvald@redhat.com> - 2.14.1-1
- bashrc sets hardcoded umask (#1902166)
- bashrc: clean up unused references to VTE
- uidgid: simplify table format and other format enhancements
- uidgid: fix news and lock entries, move basic groups to systemd
* Fri May 27 2022 Zbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl> - 2.13.10-2
- Fix %%post scriptlet to not require the shell
* Sat May 07 2022 Martin Osvald <mosvald@redhat.com> - 2.13.10-1
- Move /var/log/lastlog ownership to systemd (#1798685)
- tcsh sets variable p to /usr/sbin from /etc/csh.login (#2019874)
- 'history -a' doesn't belong in /etc/bashrc (#1871744)
- localhost.localdomain in wrong order /etc/hosts (#1724539)
* Sat Jan 22 2022 Fedora Release Engineering <releng@fedoraproject.org> - 2.13.9.1-3
- Rebuilt for https://fedoraproject.org/wiki/Fedora_36_Mass_Rebuild
* Fri Jul 23 2021 Fedora Release Engineering <releng@fedoraproject.org> - 2.13.9.1-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_35_Mass_Rebuild
* Fri Jul 16 2021 Pavel Zhukov <pzhukov@redhat.com> - 2.13.9.1-1
- Bugfix release 2.13.9.1
* Thu Jul 15 2021 Pavel Zhukov <pzhukov@redhat.com> - 2.13.9-1
- New version v2.13.9
* Thu Mar 11 2021 Pavel Zhukov <pzhukov@redhat.com> - 2.13.8-1
- New version v2.13.8
* Wed Jan 27 2021 Fedora Release Engineering <releng@fedoraproject.org> - 2.13.7-3
- Rebuilt for https://fedoraproject.org/wiki/Fedora_34_Mass_Rebuild

Loading…
Cancel
Save