Skip to content

Commit

Permalink
build: Include rhc-compat subpackage
Browse files Browse the repository at this point in the history
- Install symlink from rhcd to yggdrasil
- Install symlink from /etc/rhc/config.toml
  • Loading branch information
subpop authored and jirihnidek committed Sep 25, 2024
1 parent 0a21801 commit f3e6326
Showing 1 changed file with 16 additions and 0 deletions.
16 changes: 16 additions & 0 deletions rhc.spec.in
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,14 @@ BuildRequires: systemd
rhc is a client that registers a system with RHSM and activates the Red Hat yggd
MQTT client.

%package compat
Summary: Transition package to support migrating from rhcd to yggd

Requires: yggdrasil >= 0.4.2
Recommends: rhc

%description compat
Transition package to support migrating from rhcd to yggd.

%prep
%setup -c
Expand Down Expand Up @@ -68,6 +76,10 @@ make PREFIX=%{_prefix} \
SERVICENAME=@SERVICENAME@ \
'PROVIDER=@PROVIDER@' \
install
install --directory %{buildroot}%{_unitdir}
install --directory %{buildroot}%{_sysconfdir}/rhc
ln -sf yggdrasil.service %{buildroot}%{_unitdir}/rhcd.service
ln -sf ../yggdrasil/config.toml %{buildroot}%{_sysconfdir}/rhc/config.toml

%post
%systemd_post rhc-canonical-facts.timer
Expand All @@ -94,6 +106,10 @@ fi
%{_presetdir}/*


%files compat
%{_unitdir}/rhcd.service
%{_sysconfdir}/rhc/config.toml

%changelog
%if (0%{?fedora} || 0%{?rhel} >= 9)
%autochangelog
Expand Down

0 comments on commit f3e6326

Please sign in to comment.