File ardana-ansible.spec of Package ardana-ansible
#
# spec file for package ardana-ansible
#
# Copyright (c) 2023 SUSE LLC
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.
# Please submit bugfixes or comments via https://bugs.opensuse.org/
#
%define version_unconverted 9.0+git.1660748476.c118d23
Name: ardana-ansible
Version: 9.0+git.1660748476.c118d23
Release: 0
Summary: Ardana core ansible code
License: Apache-2.0
Group: System/Management
URL: https://github.com/ArdanaCLM/
Source0: %{name}-%{version}.tar
Obsoletes: ardana-freezer
BuildRequires: ardana-devel
Requires: ansible1
Requires: ardana
Requires: python-Jinja2 >= 2.9.6
Requires: python-ardana-packager >= 0.0.3
BuildRoot: %{_tmppath}/%{name}-%{version}-build
BuildArch: noarch
%description
%ardana_description
Ardana core ansible code
%prep
%setup -q
%build
%install
%ardana_component_install
install -m 0755 -D %{buildroot}%{ardana_base_dir}/ansible/roles/deployer-setup/files/ardana-init.bash %{buildroot}%{_bindir}/ardana-init
echo "%{version}-%{release}" > %{buildroot}%{ardana_base_dir}/ansible/Ardana_version
cat <<EOF > %{buildroot}/%{ardana_base_dir}/ansible/ardana_version.yml
---
ardana_version: "ardana-%{ardana_version}"
EOF
%files
%license LICENSE
%dir %{ardana_base_dir}
%{_bindir}/ardana-init
%{ardana_base_dir}/ansible/
# Exclude the ardana-init.bash since we installed in under _bindir as ardana-init
%exclude %{ardana_base_dir}/ansible/roles/deployer-setup/files/ardana-init.bash
%changelog