Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixes #10161 - Convert foreman-installer config to scenario #996

Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
13 changes: 9 additions & 4 deletions foreman-installer/foreman-installer.spec
Expand Up @@ -17,7 +17,7 @@ BuildArch: noarch

Requires: curl
Requires: %{?scl_prefix}puppet >= 3.0.0
Requires: %{?scl_prefix}rubygem-kafo >= 0.6.5
Requires: %{?scl_prefix}rubygem-kafo >= 0.7.1
Requires: %{?scl_prefix}rubygem-apipie-bindings >= 0.0.6
Requires: foreman-selinux

Expand All @@ -31,7 +31,7 @@ Requires: %{?scl_prefix}rubygem-highline
BuildRequires: asciidoc
BuildRequires: rubygem(rake)
BuildRequires: %{?scl_prefix}puppet >= 3.0.0
BuildRequires: %{?scl_prefix}rubygem-kafo
BuildRequires: %{?scl_prefix}rubygem-kafo >= 0.7.1

%description
Complete installer for The Foreman life-cycle management system based on Puppet.
Expand All @@ -58,11 +58,16 @@ rake install \
SYSCONFDIR=%{buildroot}%{_sysconfdir} \
--trace

%post
foreman-installer --scenario foreman --migrations-only > /dev/null
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is specifying the scenario here going to cause any problems if more are added to the package?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It should be run for each scenario. It is here for the configuration to get updated before users can touch it and is more of cosmetic thing.
Installer ensures the migrations are run on its start anyway.


%files
%defattr(-,root,root,-)
%doc README.* LICENSE
%config %attr(600, root, root) %{_sysconfdir}/foreman/%{name}.yaml
%config(noreplace) %attr(600, root, root) %{_sysconfdir}/foreman/%{name}-answers.yaml
%dir %{_sysconfdir}/foreman-installer
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nitpick, prefer %{name} rather than repeating foreman-installer here and below.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Changed in 5ea91c1.

%dir %{_sysconfdir}/foreman-installer/scenarios.d
%config %attr(600, root, root) %{_sysconfdir}/foreman-installer/scenarios.d/foreman.yaml
%config(noreplace) %attr(600, root, root) %{_sysconfdir}/foreman-installer/scenarios.d/foreman-answers.yaml
%{_sbindir}/foreman-installer
%{_datadir}/%{name}
%{_mandir}/man8
Expand Down