Sophie

Sophie

distrib > Mageia > 6 > armv7hl > media > core-updates-src > by-pkgid > 7aac75344e1ec6fec7fa08a6e54ca624 > files > 10

puppet-4.2.1-4.4.mga6.src.rpm

%define ppconfdir conf/redhat

Name:           puppet
Version:        4.2.1
%define subrel  4
Release:        %mkrel 4
Summary:        System Automation and Configuration Management Software
License:        Apache Software License 
Group:          Monitoring
URL:            http://www.puppetlabs.com/
Source0:        http://downloads.puppetlabs.com/%{name}/%{name}-%{version}.tar.gz
Source100:      puppet.service
Source101:      puppetmaster.service
Source102:      %{name}-tmpfiles.conf
Patch0:		238cfbd17f54d9487cb3920002dce84e29003a80.patch
Patch3:		0003-PUP-7483-Reject-all-fact-formats-except-PSON.patch
Patch4:		0004-PUP-5577-Don-t-require-run-systemd-system-for-system.patch
Patch5:		0005-PUP-7866-Reset-permissions-when-unpacking-tar-in-PMT.patch
Patch6:		0006-Use-Integer-instead-of-Fixnum.patch
Patch7:		puppet-4.2.1-replace-opt-with-usr-lib.patch

BuildArch:      noarch
BuildRequires:	ruby
BuildRequires:	ruby-hiera
BuildRequires:	facter
Requires:       facter
Recommends:       vim-puppet
Recommends:       emacs-puppet
Requires(post): systemd >= %{systemd_required_version}
Requires(pre):  rpm-helper
Requires(post): rpm-helper
Requires(preun):rpm-helper
Obsoletes:      puppet3
Obsoletes:      ruby-hiera-puppet <= 1.0.0
Obsoletes:      ruby-hiera-puppet-doc <= 1.0.0

%description
Puppet lets you centrally manage every important aspect of your system using a 
cross-platform specification language that manages all the separate elements 
normally aggregated in different files, like users, cron jobs, and hosts, 
along with obviously discrete elements like packages, services, and files.

This package provide the puppet client daemon.

%package server
Group:          Monitoring 
Summary:        Server for the puppet system management tool
Requires:       %{name} = %{version}
Requires(post): rpm-helper
Requires(preun):rpm-helper
Obsoletes:      puppet3-server
                
%description server
Provides the central puppet server daemon (puppetmaster) which provides
manifests to clients.
The server can also function as a certificate authority and file server.

%package -n vim-puppet
Group:          Editors
Summary:        Syntax highlighting for puppet manifests in vim
Obsoletes:      vim-puppet3
                
%description -n vim-puppet
The vim-puppet package provides filetype detection and syntax highlighting for
puppet manifests (files ending with ".pp").

%package -n emacs-puppet
Group:          Editors
Summary:        Syntax highlighting for puppet manifests in emacs
Obsoletes:      emacs-puppet3
                
%description -n emacs-puppet
The emacs-puppet package provides filetype detection and syntax highlighting for
puppet manifests (files ending with ".pp").

%prep
%setup -q
%autopatch -p1

# Fix some rpmlint complaints
for f in external/nagios.rb relationship.rb; do
    sed -i -e '1d' lib/puppet/$f
done

%build

%install
ruby install.rb \
     --destdir=%{buildroot} \
     --sitelibdir=%{ruby_vendorlibdir} \
     --quick \
     --no-rdoc

install -d -m 0755 %{buildroot}%{_sysconfdir}/puppetlabs/code/environments/production/manifests
install -d -m 0755 %{buildroot}%{_sysconfdir}/puppetlabs/code/environments/production/modules
install -d -m 0755 %{buildroot}%{_sysconfdir}/puppetlabs/puppet
install -d -m 0755 %{buildroot}%{_sysconfdir}/puppetlabs/puppetserver
install -d -m 0755 %{buildroot}%{_datadir}/puppet/modules
install -d -m 0755 %{buildroot}%{_localstatedir}/lib/puppetlabs/puppet/cache
install -d -m 0755 %{buildroot}%{_localstatedir}/log/puppetlabs/puppet

# puppet agent
install -D -m 644 %{SOURCE100} %{buildroot}%{_unitdir}/puppet.service
# puppet master
install -D -m 644 %{SOURCE101} %{buildroot}%{_unitdir}/puppetmaster.service

install -D -m 644 ext/redhat/fileserver.conf \
    %{buildroot}%{_sysconfdir}/puppetlabs/puppet/fileserver.conf
install -D -m 644 conf/puppet.conf \
    %{buildroot}%{_sysconfdir}/puppetlabs/puppet/puppet.conf
install -D -m 644 %{SOURCE102} %{buildroot}%{_tmpfilesdir}/puppet.conf

# logrotate
install -d  %{buildroot}%{_sysconfdir}/logrotate.d
cat > %{buildroot}%{_sysconfdir}/logrotate.d/puppetagent <<EOF
/var/log/puppet/*log {
    create 0644 puppet puppet
    sharedscripts
    postrotate
        /bin/systemctl reload puppet.service > /dev/null 2>&1 || true
    endscript
}
EOF
cat > %{buildroot}%{_sysconfdir}/logrotate.d/puppetmaster <<EOF
/var/log/puppet/*log {
    create 0644 puppet puppet
    sharedscripts
    postrotate
        /bin/systemctl reload puppetmaster.service > /dev/null 2>&1 || true
    endscript
}
EOF

install -d %{buildroot}%{_datadir}/puppetlabs
cp -a ext/ %{buildroot}%{_datadir}/puppetlabs
# emacs and vim bits are installed elsewhere
rm -rf %{buildroot}%{_datadir}/puppetlabs/ext/{emacs,vim}
# remove misc packaging artifacts in source not applicable to rpm
rm -rf %{buildroot}%{_datadir}/puppetlabs/ext/{gentoo,freebsd,solaris,suse,windows,osx,ips,debian}
rm -f %{buildroot}%{_datadir}/puppetlabs/ext/{build_defaults.yaml,project_data.yaml}
rm -f %{buildroot}%{_datadir}/puppetlabs/ext/redhat/*.init

# vim syntax file
vimdir=%{buildroot}%{_datadir}/vim
install -D -m 644 ext/vim/syntax/puppet.vim $vimdir/syntax/puppet.vim
install -D -m 644 ext/vim/ftdetect/puppet.vim $vimdir/ftdetect/puppet.vim

# emacs syntax file
emacsdir=%{buildroot}%{_datadir}/emacs/site-lisp
install -D -m 644 ext/emacs/puppet-mode.el $emacsdir/puppet-mode.el
install -D -m 644 ext/emacs/puppet-mode-init.el \
    $emacsdir/site-start.d/puppet-mode-init.el

# logcheck files
logcheckdir=%{buildroot}%{_sysconfdir}/logcheck/
install -D -m 644 ext/logcheck/puppet $logcheckdir/ignore.d.server/puppet
install -D -m 644 ext/logcheck/puppet $logcheckdir/ignore.d.workstation/puppet

%pre
%_pre_useradd puppet %{_localstatedir}/lib/%{name} /sbin/nologin

%post
%_tmpfilescreate %{name}
%_post_service puppet

%preun
%_preun_service puppet

%post server
%_post_service puppetmaster

%preun server
%_preun_service puppetmaster

%files
%doc LICENSE README.md examples
%dir %{_sysconfdir}/puppetlabs
%dir %{_sysconfdir}/puppetlabs/code
%dir %{_sysconfdir}/puppetlabs/code/environments/
%dir %{_sysconfdir}/puppetlabs/code/environments/production
%dir %{_sysconfdir}/puppetlabs/code/environments/production/manifests
%dir %{_sysconfdir}/puppetlabs/code/environments/production/modules
%dir %{_sysconfdir}/puppetlabs/puppet
%config(noreplace) %{_sysconfdir}/puppetlabs/puppet/auth.conf
%config(noreplace) %{_sysconfdir}/puppetlabs/puppet/puppet.conf
%{_sysconfdir}/logcheck/ignore.d.workstation/puppet
%{_sysconfdir}/logcheck/ignore.d.server/puppet
%{_tmpfilesdir}/puppet.conf
%{_unitdir}/puppet.service
%{_bindir}/puppet
%{_bindir}/extlookup2hiera
%{ruby_vendorlibdir}/hiera
%{ruby_vendorlibdir}/hiera_puppet.rb
%config(noreplace) %{_sysconfdir}/logrotate.d/puppetagent
%{ruby_vendorlibdir}/puppet
%{ruby_vendorlibdir}/puppet.rb
%{ruby_vendorlibdir}/puppet_x.rb
%{ruby_vendorlibdir}/semver.rb
%{_datadir}/puppetlabs
%attr(-,puppet,puppet) %{_localstatedir}/log/puppetlabs
%attr(-,puppet,puppet) %{_localstatedir}/lib/puppetlabs
%{_mandir}/man5/puppet.conf.5.*
%{_mandir}/man8/puppet.8.*
%{_mandir}/man8/puppet-agent.8.*
%{_mandir}/man8/puppet-apply.8.*
%{_mandir}/man8/puppet-catalog.8.*
%{_mandir}/man8/puppet-describe.8.*
%{_mandir}/man8/puppet-ca.8.*
%{_mandir}/man8/puppet-cert.8.*
%{_mandir}/man8/puppet-certificate.8.*
%{_mandir}/man8/puppet-epp.8.xz
%{_mandir}/man8/puppet-certificate_request.8.*
%{_mandir}/man8/puppet-certificate_revocation_list.8.*
%{_mandir}/man8/puppet-config.8.*
%{_mandir}/man8/puppet-device.8.*
%{_mandir}/man8/puppet-doc.8.*
%{_mandir}/man8/puppet-facts.8.*
%{_mandir}/man8/puppet-file.8.*
%{_mandir}/man8/puppet-filebucket.8.*
%{_mandir}/man8/puppet-help.8.*
%{_mandir}/man8/puppet-inspect.8.*
%{_mandir}/man8/puppet-key.8.*
%{_mandir}/man8/puppet-man.8.*
%{_mandir}/man8/puppet-module.8.*
%{_mandir}/man8/puppet-node.8.*
%{_mandir}/man8/puppet-parser.8.*
%{_mandir}/man8/puppet-plugin.8.*
%{_mandir}/man8/puppet-report.8.*
%{_mandir}/man8/puppet-resource.8.*
%{_mandir}/man8/puppet-resource_type.8.*
%{_mandir}/man8/puppet-status.8.*
%{_mandir}/man8/extlookup2hiera.8.*

%files server
%dir %{_sysconfdir}/puppetlabs/puppetserver
%config(noreplace) %{_sysconfdir}/puppetlabs/puppet/fileserver.conf
%config(noreplace) %{_sysconfdir}/logrotate.d/puppetmaster
%{_unitdir}/puppetmaster.service
%{_mandir}/man8/puppet-master.8.*

%files -n vim-puppet
%{_datadir}/vim/syntax/puppet.vim
%{_datadir}/vim/ftdetect/puppet.vim

%files -n emacs-puppet
%{_datadir}/emacs/site-lisp/puppet-mode.el
%{_datadir}/emacs/site-lisp/site-start.d/puppet-mode-init.el


%changelog
* Sat Apr 07 2018 tmb <tmb> 4.2.1-4.4.mga6
  (not released yet)
+ Revision: 1215753
- fix logdir ownership
- replace hardcoded use of /opt
- update filesystem layout for puppet 4.x
- fix CVE-2017-10689 (mga#22589)

* Sun Jun 04 2017 luigiwalser <luigiwalser> 4.2.1-4.mga6
+ Revision: 1106604
- add patch from fedora to fix CVE-2017-2295
- add patch from fedora to fix using systemd provider in a chroot

* Tue Dec 06 2016 pterjan <pterjan> 4.2.1-3.mga6
+ Revision: 1072877
- Add upstream patch allowing to run tidy several times on the same path with different parameters
+ umeabot <umeabot>
- Mageia 6 Mass Rebuild

* Sat Nov 28 2015 blino <blino> 4.2.1-1.mga6
+ Revision: 906851
- obsolete ruby-hiera-puppet packages, they are included in puppet from 3.x (should have been done a long time ago)
+ tv <tv>
- adjust file list
- new release
- fix source URL

* Wed Oct 15 2014 umeabot <umeabot> 3.6.2-3.mga5
+ Revision: 750987
- Second Mageia 5 Mass Rebuild

* Tue Sep 16 2014 umeabot <umeabot> 3.6.2-2.mga5
+ Revision: 687835
- Mageia 5 Mass Rebuild
+ tv <tv>
- s/uggests:/Recommends:/

* Mon Jun 16 2014 guillomovitch <guillomovitch> 3.6.2-1.mga5
+ Revision: 637405
- new version 3.6.2

* Mon Jan 13 2014 guillomovitch <guillomovitch> 3.4.2-1.mga4
+ Revision: 566475
+ rebuild (emptylog)

* Fri Jan 03 2014 guillomovitch <guillomovitch> 3.4.1-1.mga4
+ Revision: 564049
- new version 3.4.1

* Sat Oct 19 2013 umeabot <umeabot> 3.2.4-2.mga4
+ Revision: 532362
- Mageia 4 Mass Rebuild

* Tue Aug 20 2013 guillomovitch <guillomovitch> 3.2.4-1.mga4
+ Revision: 468116
- new version

* Wed Jun 19 2013 boklm <boklm> 3.2.2-1.mga4
+ Revision: 445092
- Update to version 3.2.2, fixing CVE-2013-3567 (Unauthenticated Remote
  Code Execution Vulnerability)

* Fri May 24 2013 guillomovitch <guillomovitch> 3.2.1-2.mga4
+ Revision: 426167
- new version

* Sat May 11 2013 guillomovitch <guillomovitch> 2.7.21-2.mga3
+ Revision: 413007
- use systemctl in logrotate, instead of sysinit script

* Fri Apr 05 2013 guillomovitch <guillomovitch> 2.7.21-1.mga3
+ Revision: 408245
- new version
+ neoclust <neoclust>
- New sec fixes version
+ colin <colin>
- Add systemd requires and general post/pre fixes (mga#9302)

* Sun Jan 13 2013 umeabot <umeabot> 2.7.20-3.mga3
+ Revision: 378317
- Mass Rebuild - https://wiki.mageia.org/en/Feature:Mageia3MassRebuild

* Sun Dec 16 2012 colin <colin> 2.7.20-2.mga3
+ Revision: 331700
- Switch to tmpfiles for /run dirs

* Wed Dec 12 2012 nanardon <nanardon> 2.7.20-1.mga3
+ Revision: 329851
- 2.7.20

* Mon Aug 13 2012 guillomovitch <guillomovitch> 2.7.18-1.mga3
+ Revision: 281054
- new version

* Fri Jul 06 2012 guillomovitch <guillomovitch> 2.7.17-1.mga3
+ Revision: 268416
- new version

* Mon Jun 11 2012 guillomovitch <guillomovitch> 2.7.14-1.mga3
+ Revision: 259755
- split emacs and vim extensions into distinct subpackages
- new version
- systemd support
- drop sysinit support

* Sat Feb 25 2012 misc <misc> 2.7.11-1.mga2
+ Revision: 214730
- new version 2.7.11 ( security and maintainance fix )

* Fri Feb 17 2012 misc <misc> 2.7.10-1.mga2
+ Revision: 210067
- upgrade to 2.7.10

* Mon Oct 24 2011 misc <misc> 2.7.6-1.mga2
+ Revision: 157871
- new version ( security issue )

* Mon Oct 03 2011 misc <misc> 2.7.5-1.mga2
+ Revision: 151298
- new version
- reupload the new tarball
- remove clean and defattr
- new version

* Thu Jun 23 2011 misc <misc> 2.7.1-1.mga2
+ Revision: 112565
- new version of puppet

* Wed May 04 2011 misc <misc> 2.6.8-1.mga1
+ Revision: 94686
- upgrade to 2.6.8, maintainance release

* Tue Apr 05 2011 misc <misc> 2.6.7-1.mga1
+ Revision: 80806
- update to latest version

* Mon Jan 24 2011 misc <misc> 2.6.4-1.mga1
+ Revision: 35788
- clean version specific and extranous requires
- imported package puppet