commit
4b67cd9eda
@ -0,0 +1 @@
|
|||||||
|
SOURCES/hiera-3.7.0.tar.gz
|
@ -0,0 +1 @@
|
|||||||
|
4e867b5b8188738f61d45381febde7670977919a SOURCES/hiera-3.7.0.tar.gz
|
@ -0,0 +1,120 @@
|
|||||||
|
diff -uNr hiera-3.6.0.ORIG/lib/hiera/util.rb hiera-3.6.0/lib/hiera/util.rb
|
||||||
|
--- hiera-3.6.0.ORIG/lib/hiera/util.rb 2019-11-13 09:43:32.600045630 +0100
|
||||||
|
+++ hiera-3.6.0/lib/hiera/util.rb 2019-11-13 09:43:46.007065887 +0100
|
||||||
|
@@ -20,7 +20,7 @@
|
||||||
|
if microsoft_windows?
|
||||||
|
File.join(common_appdata, 'PuppetLabs', 'puppet', 'etc')
|
||||||
|
else
|
||||||
|
- '/etc/puppetlabs/puppet'
|
||||||
|
+ '/etc/puppet'
|
||||||
|
end
|
||||||
|
end
|
||||||
|
|
||||||
|
@@ -28,7 +28,7 @@
|
||||||
|
if microsoft_windows?
|
||||||
|
File.join(common_appdata, 'PuppetLabs', 'code')
|
||||||
|
else
|
||||||
|
- '/etc/puppetlabs/code'
|
||||||
|
+ '/etc/puppet/code'
|
||||||
|
end
|
||||||
|
end
|
||||||
|
|
||||||
|
diff -uNr hiera-3.6.0.ORIG/lib/hiera/util.rb.orig hiera-3.6.0/lib/hiera/util.rb.orig
|
||||||
|
--- hiera-3.6.0.ORIG/lib/hiera/util.rb.orig 1970-01-01 01:00:00.000000000 +0100
|
||||||
|
+++ hiera-3.6.0/lib/hiera/util.rb.orig 2019-10-14 09:59:36.000000000 +0200
|
||||||
|
@@ -0,0 +1,65 @@
|
||||||
|
+class Hiera
|
||||||
|
+
|
||||||
|
+ # Matches a key that is quoted using a matching pair of either single or double quotes.
|
||||||
|
+ QUOTED_KEY = /^(?:"([^"]+)"|'([^']+)')$/
|
||||||
|
+ QUOTES = /[",]/
|
||||||
|
+
|
||||||
|
+ module Util
|
||||||
|
+ module_function
|
||||||
|
+
|
||||||
|
+ def posix?
|
||||||
|
+ require 'etc'
|
||||||
|
+ Etc.getpwuid(0) != nil
|
||||||
|
+ end
|
||||||
|
+
|
||||||
|
+ def microsoft_windows?
|
||||||
|
+ !!file_alt_separator
|
||||||
|
+ end
|
||||||
|
+
|
||||||
|
+ def config_dir
|
||||||
|
+ if microsoft_windows?
|
||||||
|
+ File.join(common_appdata, 'PuppetLabs', 'puppet', 'etc')
|
||||||
|
+ else
|
||||||
|
+ '/etc/puppetlabs/puppet'
|
||||||
|
+ end
|
||||||
|
+ end
|
||||||
|
+
|
||||||
|
+ def code_dir
|
||||||
|
+ if microsoft_windows?
|
||||||
|
+ File.join(common_appdata, 'PuppetLabs', 'code')
|
||||||
|
+ else
|
||||||
|
+ '/etc/puppetlabs/code'
|
||||||
|
+ end
|
||||||
|
+ end
|
||||||
|
+
|
||||||
|
+ def var_dir
|
||||||
|
+ File.join(code_dir, 'environments' , '%{environment}' , 'hieradata')
|
||||||
|
+ end
|
||||||
|
+
|
||||||
|
+ def file_alt_separator
|
||||||
|
+ File::ALT_SEPARATOR
|
||||||
|
+ end
|
||||||
|
+
|
||||||
|
+ def common_appdata
|
||||||
|
+ @common_appdata ||= Hiera::Util::Win32.get_common_appdata()
|
||||||
|
+ end
|
||||||
|
+
|
||||||
|
+ def split_key(key)
|
||||||
|
+ segments = key.split(/(?:"([^"]+)"|'([^']+)'|([^'".]+))/)
|
||||||
|
+ if segments.empty?
|
||||||
|
+ # Only happens if the original key was an empty string
|
||||||
|
+ ''
|
||||||
|
+ elsif segments.shift == ''
|
||||||
|
+ count = segments.size
|
||||||
|
+ raise yield('Syntax error') unless count > 0
|
||||||
|
+
|
||||||
|
+ segments.keep_if { |seg| seg != '.' }
|
||||||
|
+ raise yield('Syntax error') unless segments.size * 2 == count + 1
|
||||||
|
+ segments
|
||||||
|
+ else
|
||||||
|
+ raise yield('Syntax error')
|
||||||
|
+ end
|
||||||
|
+ end
|
||||||
|
+ end
|
||||||
|
+end
|
||||||
|
+
|
||||||
|
diff -uNr hiera-3.6.0.ORIG/spec/unit/util_spec.rb hiera-3.6.0/spec/unit/util_spec.rb
|
||||||
|
--- hiera-3.6.0.ORIG/spec/unit/util_spec.rb 2019-11-13 09:43:32.601045631 +0100
|
||||||
|
+++ hiera-3.6.0/spec/unit/util_spec.rb 2019-11-13 09:44:42.269091590 +0100
|
||||||
|
@@ -23,7 +23,7 @@
|
||||||
|
describe 'Hiera::Util.config_dir' do
|
||||||
|
it 'should return the correct path for posix systems' do
|
||||||
|
Hiera::Util.expects(:file_alt_separator).returns(nil)
|
||||||
|
- expect(Hiera::Util.config_dir).to eq('/etc/puppetlabs/puppet')
|
||||||
|
+ expect(Hiera::Util.config_dir).to eq('/etc/puppet')
|
||||||
|
end
|
||||||
|
|
||||||
|
it 'should return the correct path for microsoft windows systems' do
|
||||||
|
@@ -36,7 +36,7 @@
|
||||||
|
describe 'Hiera::Util.code_dir' do
|
||||||
|
it 'should return the correct path for posix systems' do
|
||||||
|
Hiera::Util.expects(:file_alt_separator).returns(nil)
|
||||||
|
- expect(Hiera::Util.code_dir).to eq('/etc/puppetlabs/code')
|
||||||
|
+ expect(Hiera::Util.code_dir).to eq('/etc/puppet/code')
|
||||||
|
end
|
||||||
|
|
||||||
|
it 'should return the correct path for microsoft windows systems' do
|
||||||
|
@@ -49,7 +49,7 @@
|
||||||
|
describe 'Hiera::Util.var_dir' do
|
||||||
|
it 'should return the correct path for posix systems' do
|
||||||
|
Hiera::Util.expects(:file_alt_separator).returns(nil)
|
||||||
|
- expect(Hiera::Util.var_dir).to eq('/etc/puppetlabs/code/environments/%{environment}/hieradata')
|
||||||
|
+ expect(Hiera::Util.var_dir).to eq('/etc/puppet/code/environments/%{environment}/hieradata')
|
||||||
|
end
|
||||||
|
|
||||||
|
it 'should return the correct path for microsoft windows systems' do
|
@ -0,0 +1,171 @@
|
|||||||
|
|
||||||
|
Name: hiera
|
||||||
|
Version: 3.7.0
|
||||||
|
Release: 2%{?dist}
|
||||||
|
Summary: A simple hierarchical database supporting plugin data sources
|
||||||
|
|
||||||
|
License: ASL 2.0
|
||||||
|
URL: https://github.com/puppetlabs/hiera
|
||||||
|
Source0: http://downloads.puppetlabs.com/hiera/%{name}-%{version}.tar.gz
|
||||||
|
# Use /etc/puppet rather than /etc/puppetlabs/puppet
|
||||||
|
Patch0: fix-puppetlab-paths.patch
|
||||||
|
BuildArch: noarch
|
||||||
|
BuildRequires: rubygem(rspec)
|
||||||
|
BuildRequires: rubygem(mocha)
|
||||||
|
BuildRequires: rubygem(json)
|
||||||
|
BuildRequires: ruby-devel
|
||||||
|
|
||||||
|
%description
|
||||||
|
A simple hierarchical database supporting plugin data sources.
|
||||||
|
|
||||||
|
%prep
|
||||||
|
%setup -q
|
||||||
|
%patch0 -p1
|
||||||
|
|
||||||
|
%build
|
||||||
|
# Nothing to build
|
||||||
|
|
||||||
|
%install
|
||||||
|
rm -rf %{buildroot}
|
||||||
|
mkdir -p %{buildroot}%{ruby_vendorlibdir}
|
||||||
|
mkdir -p %{buildroot}%{_sysconfdir}/puppet
|
||||||
|
mkdir -p %{buildroot}%{_bindir}
|
||||||
|
cp -pr lib/hiera %{buildroot}%{ruby_vendorlibdir}
|
||||||
|
cp -pr lib/hiera.rb %{buildroot}%{ruby_vendorlibdir}
|
||||||
|
install -p -m0755 bin/hiera %{buildroot}%{_bindir}
|
||||||
|
install -p -m0644 ext/hiera.yaml %{buildroot}%{_sysconfdir}/puppet
|
||||||
|
mkdir -p %{buildroot}%{_var}/lib/hiera
|
||||||
|
|
||||||
|
%check
|
||||||
|
rspec -Ilib spec
|
||||||
|
|
||||||
|
%files
|
||||||
|
%{_bindir}/hiera
|
||||||
|
%{ruby_vendorlibdir}/hiera.rb
|
||||||
|
%{ruby_vendorlibdir}/hiera
|
||||||
|
%dir %{_var}/lib/hiera
|
||||||
|
%dir %{_sysconfdir}/puppet
|
||||||
|
%config(noreplace) %{_sysconfdir}/puppet/hiera.yaml
|
||||||
|
%doc COPYING README.md
|
||||||
|
%license LICENSE
|
||||||
|
|
||||||
|
%changelog
|
||||||
|
* Sun Sep 01 2024 Eduard Basov <ebasov@msvsphere-os.ru> - 3.7.0-2
|
||||||
|
- Rebuilt for MSVSphere 9.4
|
||||||
|
|
||||||
|
* Fri Aug 20 2021 Steve Traylen <releng@fedoraproject.org> - 3.7.0-2
|
||||||
|
- Correct software homepage
|
||||||
|
|
||||||
|
* Fri Aug 20 2021 Steve Traylen <releng@fedoraproject.org> - 3.7.0-1
|
||||||
|
- Update to 3.7.0.
|
||||||
|
|
||||||
|
* Thu Jul 22 2021 Fedora Release Engineering <releng@fedoraproject.org> - 3.6.0-5
|
||||||
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_35_Mass_Rebuild
|
||||||
|
|
||||||
|
* Tue Jan 26 2021 Fedora Release Engineering <releng@fedoraproject.org> - 3.6.0-4
|
||||||
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_34_Mass_Rebuild
|
||||||
|
|
||||||
|
* Tue Jul 28 2020 Fedora Release Engineering <releng@fedoraproject.org> - 3.6.0-3
|
||||||
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_33_Mass_Rebuild
|
||||||
|
|
||||||
|
* Wed Jan 29 2020 Fedora Release Engineering <releng@fedoraproject.org> - 3.6.0-2
|
||||||
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_32_Mass_Rebuild
|
||||||
|
|
||||||
|
* Wed Nov 13 2019 Steve Traylen <releng@fedoraproject.org> - 3.6.0-1
|
||||||
|
- Update to 3.6.0.
|
||||||
|
- Call rspec tests correctly - actually run them.
|
||||||
|
|
||||||
|
* Thu Jul 25 2019 Fedora Release Engineering <releng@fedoraproject.org> - 3.3.1-6
|
||||||
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_31_Mass_Rebuild
|
||||||
|
|
||||||
|
* Fri Feb 01 2019 Fedora Release Engineering <releng@fedoraproject.org> - 3.3.1-5
|
||||||
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_30_Mass_Rebuild
|
||||||
|
|
||||||
|
* Fri Jul 13 2018 Fedora Release Engineering <releng@fedoraproject.org> - 3.3.1-4
|
||||||
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_29_Mass_Rebuild
|
||||||
|
|
||||||
|
* Wed Feb 07 2018 Fedora Release Engineering <releng@fedoraproject.org> - 3.3.1-3
|
||||||
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_28_Mass_Rebuild
|
||||||
|
|
||||||
|
* Wed Jul 26 2017 Fedora Release Engineering <releng@fedoraproject.org> - 3.3.1-2
|
||||||
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Mass_Rebuild
|
||||||
|
|
||||||
|
* Thu Jun 1 2017 Steve Traylen <releng@fedoraproject.org> - 3.3.1-1
|
||||||
|
- Update to 3.3.1.
|
||||||
|
- Relocate hiera.yaml to /etc/puppet/hiera.yaml
|
||||||
|
- Remove items for old OSes.
|
||||||
|
|
||||||
|
* Fri Feb 10 2017 Fedora Release Engineering <releng@fedoraproject.org> - 3.0.1-3
|
||||||
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_26_Mass_Rebuild
|
||||||
|
|
||||||
|
* Wed Feb 03 2016 Fedora Release Engineering <releng@fedoraproject.org> - 3.0.1-2
|
||||||
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_24_Mass_Rebuild
|
||||||
|
|
||||||
|
* Tue Nov 3 2015 Steve Traylen <steve.traylen@cern.ch> - 3.0.1-1
|
||||||
|
- New version 3.0.1
|
||||||
|
|
||||||
|
* Thu Jul 30 2015 Gaël Chamoulaud <gchamoul@redhat.com> - 1.3.4-4
|
||||||
|
- Removed 0001-Fix-errors-with-Puppet-4.patch
|
||||||
|
|
||||||
|
* Wed Jun 17 2015 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.3.4-3
|
||||||
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_23_Mass_Rebuild
|
||||||
|
|
||||||
|
* Mon May 18 2015 Haïkel Guémar <hguemar@fedoraproject.org> - 1.3.4-2
|
||||||
|
- Fix errors with Puppet4 (patch from Lukas Bezdicka)
|
||||||
|
|
||||||
|
* Wed Jun 11 2014 Steve Traylen <steve.traylen@cern.ch> - 1.3.4-1
|
||||||
|
- New version 1.3.4
|
||||||
|
|
||||||
|
* Sat Jun 07 2014 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.3.3-2
|
||||||
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_Mass_Rebuild
|
||||||
|
|
||||||
|
* Tue Jun 3 2014 Steve Traylen <steve.traylen@cern.ch> - 1.3.3-1
|
||||||
|
- New version 1.3.3, Update to latest ruby guidelines.
|
||||||
|
|
||||||
|
* Wed May 14 2014 Steve Traylen <steve.traylen@cern.ch> - 1.3.2-2
|
||||||
|
- Packaging error
|
||||||
|
|
||||||
|
* Wed May 14 2014 Steve Traylen <steve.traylen@cern.ch> - 1.3.2-1
|
||||||
|
- New version 1.3.2
|
||||||
|
|
||||||
|
* Thu Feb 13 2014 Steve Traylen <steve.traylen@cern.ch> - 1.3.1-2
|
||||||
|
- New version 1.3.1
|
||||||
|
|
||||||
|
* Mon Sep 16 2013 Steve Traylen <steve.traylen@cern.ch> - 1.2.1-1
|
||||||
|
- New version 1.2.1
|
||||||
|
|
||||||
|
* Sat Aug 03 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.0.0-6
|
||||||
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_20_Mass_Rebuild
|
||||||
|
|
||||||
|
* Fri Mar 15 2013 Vít Ondruch <vondruch@redhat.com> - 1.0.0-5
|
||||||
|
- Rebuild for https://fedoraproject.org/wiki/Features/Ruby_2.0.0
|
||||||
|
|
||||||
|
* Thu Feb 14 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.0.0-4
|
||||||
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_19_Mass_Rebuild
|
||||||
|
|
||||||
|
* Mon Oct 1 2012 Steve Traylen <steve.traylen@cern.ch> - 1.0.0-3
|
||||||
|
- Correct ruby(abi) requirement.
|
||||||
|
|
||||||
|
* Thu Sep 27 2012 Steve Traylen <steve.traylen@cern.ch> - 1.0.0-2
|
||||||
|
- Remove _isa tag for f18 from ruby-devel?
|
||||||
|
|
||||||
|
* Thu Sep 27 2012 Steve Traylen <steve.traylen@cern.ch> - 1.0.0-1
|
||||||
|
- Update to 1.0.0
|
||||||
|
- Add LICENSE file
|
||||||
|
- Add /var/lib/hiera as default data path.
|
||||||
|
|
||||||
|
* Wed May 30 2012 Steve Traylen <steve.traylen@cern.ch> - 1.0.0-0.2.rc3
|
||||||
|
- Update to 1.0.0rc3 and drop puppet functions.
|
||||||
|
|
||||||
|
* Wed May 16 2012 Steve Traylen <steve.traylen@cern.ch> - 1.0.0-0.2rc2
|
||||||
|
- Adapt to fedora guidelines.
|
||||||
|
|
||||||
|
* Mon May 14 2012 Matthaus Litteken <matthaus@puppetlabs.com> - 1.0.0-0.1rc2
|
||||||
|
- 1.0.0rc2 release
|
||||||
|
|
||||||
|
* Mon May 14 2012 Matthaus Litteken <matthaus@puppetlabs.com> - 1.0.0-0.1rc1
|
||||||
|
- 1.0.0rc1 release
|
||||||
|
|
||||||
|
* Thu May 03 2012 Matthaus Litteken <matthaus@puppetlabs.com> - 0.3.0.28-1
|
||||||
|
- Initial Hiera Packaging. Upstream version 0.3.0.28
|
||||||
|
|
Loading…
Reference in new issue