integ/base/systemd-config/centos/systemd-config.spec
Shuicheng Lin 46ce43a77d refactor systemd
Story: 2003768
Task: 27594

Package systemd-config is added to config customized config file
of systemd.
Several patches are converted to config files. These config files
are based on systemd-219-57.el7.src.rpm.
BuildRequires in system-config is set to equal "219-57.el7", to
avoid system-config is missed check when do upgrade. So when do
systemd upgrade, system-config need be upgraded also.

"0003-spec-expand-_udevrulesdir-macro.patch" is removed which
seems not needed.

Test:
Pass build and multi node deploy test. Confirmed related config
file is the same as before.

Change-Id: I879dc276f3280911d844cfa605c56ba03caabdad
Signed-off-by: Shuicheng Lin <shuicheng.lin@intel.com>
2018-11-21 22:29:21 +08:00

56 lines
1.8 KiB
RPMSpec

Summary: StarlingX systemd Configuration File
Name: systemd-config
Version: 1.0
Release: %{tis_patch_ver}%{?_tis_dist}
License: Apache-2.0
Group: config-files
Packager: StarlingX
URL: unknown
Source: %name-%version.tar.gz
BuildArch: noarch
BuildRequires: systemd = 219-57.el7
Requires: systemd
%define debug_package %{nil}
%description
StarlingX systemd configuration file
%prep
%setup
%build
%install
install -d %{buildroot}%{_datadir}/starlingx
install -m644 60-persistent-storage.rules %{buildroot}%{_datadir}/starlingx/60-persistent-storage.rules
install -m644 journald.conf %{buildroot}%{_datadir}/starlingx/journald.conf
install -m644 systemd.conf.tmpfiles.d %{buildroot}%{_datadir}/starlingx/systemd.conf.tmpfiles.d
install -m644 tmp.conf.tmpfiles.d %{buildroot}%{_datadir}/starlingx/tmp.conf.tmpfiles.d
install -m644 tmp.mount %{buildroot}%{_datadir}/starlingx/tmp.mount
%post
if [ $1 -eq 1 ] ; then
cp -f %{_datadir}/starlingx/60-persistent-storage.rules %{_udevrulesdir}/
chmod 644 %{_udevrulesdir}/60-persistent-storage.rules
cp -f %{_datadir}/starlingx/journald.conf %{_sysconfdir}/systemd
chmod 644 %{_sysconfdir}/systemd/journald.conf
cp -f %{_datadir}/starlingx/systemd.conf.tmpfiles.d %{_usr}/lib/tmpfiles.d/systemd.conf
chmod 644 %{_usr}/lib/tmpfiles.d/systemd.conf
cp -f %{_datadir}/starlingx/tmp.conf.tmpfiles.d %{_usr}/lib/tmpfiles.d/tmp.conf
chmod 644 %{_usr}/lib/tmpfiles.d/tmp.conf
cp -f %{_datadir}/starlingx/tmp.mount %{_unitdir}/
chmod 644 %{_unitdir}/tmp.mount
fi
%files
%defattr(-,root,root)
%license LICENSE
%{_datadir}/starlingx/60-persistent-storage.rules
%{_datadir}/starlingx/journald.conf
%{_datadir}/starlingx/systemd.conf.tmpfiles.d
%{_datadir}/starlingx/tmp.conf.tmpfiles.d
%{_datadir}/starlingx/tmp.mount