diff options
author | Romain Tartière <romain@FreeBSD.org> | 2020-12-04 20:16:11 +0000 |
---|---|---|
committer | Romain Tartière <romain@FreeBSD.org> | 2020-12-04 20:16:11 +0000 |
commit | 2ba875b5d3446e2f007370f726a751fc1e6193ff (patch) | |
tree | f29c183a4b8ed480a96adb3facaba84cec053679 /sysutils | |
parent | f4a5a66cc1f9db07637f6d8e869e960fea90443a (diff) | |
download | ports-2ba875b5d3446e2f007370f726a751fc1e6193ff.tar.gz ports-2ba875b5d3446e2f007370f726a751fc1e6193ff.zip |
Hello Puppet 7!
Add sysutils/puppet7 from a copy of sysutils/puppet6 and a few minor tweaks.
With hat: puppet
Notes
Notes:
svn path=/head/; revision=557015
Diffstat (limited to 'sysutils')
-rw-r--r-- | sysutils/Makefile | 1 | ||||
-rw-r--r-- | sysutils/puppet5/Makefile | 2 | ||||
-rw-r--r-- | sysutils/puppet5/pkg-descr | 2 | ||||
-rw-r--r-- | sysutils/puppet6/Makefile | 2 | ||||
-rw-r--r-- | sysutils/puppet6/pkg-descr | 2 | ||||
-rw-r--r-- | sysutils/puppet7/Makefile | 122 | ||||
-rw-r--r-- | sysutils/puppet7/distinfo | 3 | ||||
-rw-r--r-- | sysutils/puppet7/files/patch-lib_puppet_provider_service_daemontools.rb | 20 | ||||
-rw-r--r-- | sysutils/puppet7/files/pkg-message.in | 11 | ||||
-rw-r--r-- | sysutils/puppet7/files/puppet.in | 49 | ||||
-rw-r--r-- | sysutils/puppet7/pkg-descr | 7 | ||||
-rw-r--r-- | sysutils/puppet7/pkg-plist | 37 |
12 files changed, 254 insertions, 4 deletions
diff --git a/sysutils/Makefile b/sysutils/Makefile index ff60fcfd41ee..7d84b42d1c94 100644 --- a/sysutils/Makefile +++ b/sysutils/Makefile @@ -966,6 +966,7 @@ SUBDIR += puppet-mode.el SUBDIR += puppet5 SUBDIR += puppet6 + SUBDIR += puppet7 SUBDIR += puppetserver5 SUBDIR += puppetserver6 SUBDIR += pv diff --git a/sysutils/puppet5/Makefile b/sysutils/puppet5/Makefile index 65add047e6b8..1cab1c4ed76b 100644 --- a/sysutils/puppet5/Makefile +++ b/sysutils/puppet5/Makefile @@ -25,7 +25,7 @@ RUN_DEPENDS= rubygem-gettext-setup>=0:devel/rubygem-gettext-setup \ USES= cpe CPE_VENDOR= puppetlabs -CONFLICTS_INSTALL= puppet4-* puppet6-* +CONFLICTS_INSTALL= puppet6-* puppet7-* NO_ARCH= yes NO_BUILD= yes USE_RUBY= yes diff --git a/sysutils/puppet5/pkg-descr b/sysutils/puppet5/pkg-descr index 89a2fce63e8d..9d40dc90e9cc 100644 --- a/sysutils/puppet5/pkg-descr +++ b/sysutils/puppet5/pkg-descr @@ -4,4 +4,4 @@ elements normally aggregated in different files, like users, cron jobs, and hosts, along with obviously discrete elements like packages, services, and files. -WWW: https://puppetlabs.com/puppet/puppet-open-source +WWW: https://puppet.com/docs/puppet/latest/puppet_index.html diff --git a/sysutils/puppet6/Makefile b/sysutils/puppet6/Makefile index 125aa8c353f7..a5872e4922f0 100644 --- a/sysutils/puppet6/Makefile +++ b/sysutils/puppet6/Makefile @@ -30,7 +30,7 @@ CPE_VENDOR= puppetlabs USE_GITHUB= yes GH_ACCOUNT= puppetlabs -CONFLICTS_INSTALL= puppet4-* puppet5-* +CONFLICTS_INSTALL= puppet5-* puppet7-* PLIST_SUB= PORTVERSION="${PORTVERSION}" NO_ARCH= yes NO_BUILD= yes diff --git a/sysutils/puppet6/pkg-descr b/sysutils/puppet6/pkg-descr index 89a2fce63e8d..9d40dc90e9cc 100644 --- a/sysutils/puppet6/pkg-descr +++ b/sysutils/puppet6/pkg-descr @@ -4,4 +4,4 @@ elements normally aggregated in different files, like users, cron jobs, and hosts, along with obviously discrete elements like packages, services, and files. -WWW: https://puppetlabs.com/puppet/puppet-open-source +WWW: https://puppet.com/docs/puppet/latest/puppet_index.html diff --git a/sysutils/puppet7/Makefile b/sysutils/puppet7/Makefile new file mode 100644 index 000000000000..a596ac52669f --- /dev/null +++ b/sysutils/puppet7/Makefile @@ -0,0 +1,122 @@ +# $FreeBSD$ + +PORTNAME= puppet +PORTVERSION= 7.0.0 +CATEGORIES= sysutils +PKGNAMESUFFIX= 7 + +MAINTAINER= puppet@FreeBSD.org +COMMENT= Configuration management framework written in Ruby + +LICENSE= APACHE20 +LICENSE_FILE= ${WRKSRC}/LICENSE + +BUILD_DEPENDS= rubygem-deep_merge>=1.0:devel/rubygem-deep_merge \ + rubygem-hiera>=2.0:sysutils/rubygem-hiera \ + rubygem-json_pure>=0:devel/rubygem-json_pure \ + rubygem-semantic_puppet>=1:devel/rubygem-semantic_puppet +RUN_DEPENDS= rubygem-concurrent-ruby>0:devel/rubygem-concurrent-ruby \ + rubygem-deep_merge>0:devel/rubygem-deep_merge \ + rubygem-gettext-setup>=0:devel/rubygem-gettext-setup \ + rubygem-hiera>=2.0:sysutils/rubygem-hiera \ + rubygem-hocon>=0:devel/rubygem-hocon \ + rubygem-json_pure>=0:devel/rubygem-json_pure \ + rubygem-ruby-augeas>=0:textproc/rubygem-ruby-augeas \ + rubygem-semantic_puppet>=1:devel/rubygem-semantic_puppet + +USES= cpe +CPE_VENDOR= puppetlabs +USE_GITHUB= yes +GH_ACCOUNT= puppetlabs + +CONFLICTS_INSTALL= puppet5-* puppet6-* +PLIST_SUB= PORTVERSION="${PORTVERSION}" +NO_ARCH= yes +NO_BUILD= yes +USE_RUBY= yes +USE_RC_SUBR= puppet +PORTDOCS= LICENSE README.md +PORTEXAMPLES= * +USERS= puppet +GROUPS= puppet +SUB_FILES+= pkg-message +SUB_LIST= RUBY=${RUBY} + +OPTIONS_DEFINE= DOCS EXAMPLES +OPTIONS_DEFAULT= RFACTER +OPTIONS_RADIO= FACTER +OPTIONS_RADIO_FACTER= CFACTER RFACTER + +RFACTER_DESC= Use facter 4.x (future facter, written in Ruby) +CFACTER_DESC= Use facter 3.x (written in C++) + +RFACTER_BUILD_DEPENDS= rubygem-facter>=4.0:sysutils/rubygem-facter +RFACTER_RUN_DEPENDS= rubygem-facter>=4.0:sysutils/rubygem-facter + +CFACTER_BUILD_DEPENDS= facter>=3.0:sysutils/facter +CFACTER_RUN_DEPENDS= facter>=3.0:sysutils/facter + +post-patch: + @${REINPLACE_CMD} -e "s|/etc/puppetlabs/puppet|${ETCDIR}|" \ + ${WRKSRC}/install.rb \ + ${WRKSRC}/lib/puppet/reference/configuration.rb \ + ${WRKSRC}/lib/puppet/util/run_mode.rb + @${REINPLACE_CMD} -e "s|/etc/puppetlabs/code|${ETCDIR}|" \ + ${WRKSRC}/install.rb \ + ${WRKSRC}/lib/puppet/reference/configuration.rb \ + ${WRKSRC}/lib/puppet/util/run_mode.rb + @${REINPLACE_CMD} -e "s|/opt/puppetlabs/puppet/cache|/var/puppet|" \ + ${WRKSRC}/install.rb \ + ${WRKSRC}/lib/puppet/reference/configuration.rb \ + ${WRKSRC}/lib/puppet/util/run_mode.rb + @${REINPLACE_CMD} -e "s|/var/run/puppetlabs|/var/run/puppet|" \ + ${WRKSRC}/install.rb \ + ${WRKSRC}/lib/puppet/util/run_mode.rb + @${REINPLACE_CMD} -e "s|/var/log/puppetlabs/puppet|/var/log/puppet|" \ + ${WRKSRC}/install.rb \ + ${WRKSRC}/lib/puppet/util/run_mode.rb + @${REINPLACE_CMD} -e "s|/opt/puppetlabs/puppet/public|/var/puppet/state|" \ + ${WRKSRC}/install.rb \ + ${WRKSRC}/lib/puppet/util/run_mode.rb + @${REINPLACE_CMD} -e "s|/opt/puppetlabs/puppet/modules|${ETCDIR}/modules|" \ + -e "s|/etc/puppetlabs/puppetserver/ca|/var/puppetserver/ca|" \ + -e "s|/opt/puppetlabs/puppet/vendor_modules|${ETCDIR}/vendor_modules|" \ + ${WRKSRC}/lib/puppet/defaults.rb + @${REINPLACE_CMD} -e "s|/opt/puppetlabs/puppet/bin/gem|${LOCALBASE}/bin/gem|" \ + ${WRKSRC}/lib/puppet/provider/package/puppet_gem.rb + @${REINPLACE_CMD} -e "s|\$$confdir/ssl|/var/puppet/ssl|" \ + ${WRKSRC}/lib/puppet/defaults.rb + @${REINPLACE_CMD} -e "s|\.\./\.\./\.\./locales|../locales|" \ + ${WRKSRC}/lib/puppet/gettext/config.rb + +do-install: + @cd ${WRKSRC} && ${SETENV} PREFIX=${PREFIX} LC_ALL=C.UTF-8 ${RUBY} ${WRKSRC}/install.rb --no-configs --destdir=${STAGEDIR} \ + --localedir=${RUBY_SITELIBDIR}/puppet/locales --publicdir=/var/puppet/state/ + +post-install: + ${MKDIR} ${STAGEDIR}${ETCDIR}/manifests + ${MKDIR} ${STAGEDIR}${ETCDIR}/modules + ${MKDIR} ${STAGEDIR}/var/puppet + ${SETENV} LC_ALL=C.UTF-8 ${RUBY} -I ${STAGEDIR}/${RUBY_SITELIBDIR} ${STAGEDIR}${PREFIX}/bin/puppet agent --genconfig \ + --confdir=${ETCDIR} \ + --rundir=/var/run/puppet \ + --vardir=/var/puppet \ + --logdir=/var/log/puppet \ + --codedir=${ETCDIR} \ + > ${STAGEDIR}${ETCDIR}/puppet.conf-dist + @${ECHO} ${STAGEDIR}${RUBY_SITELIBDIR}/puppet.rb | \ + ${SED} 's,^${STAGEDIR}${PREFIX}/,,' >> ${TMPPLIST} + @${FIND} ${STAGEDIR}${RUBY_SITELIBDIR}/${PORTNAME} -type f | \ + ${SED} 's,^${STAGEDIR}${PREFIX}/,,' >> ${TMPPLIST} + ${MKDIR} ${STAGEDIR}${PREFIX}/lib/ruby/gems/${RUBY_VER}/specifications + ${INSTALL_DATA} ${WRKSRC}/.gemspec ${STAGEDIR}${PREFIX}/lib/ruby/gems/${RUBY_VER}/specifications/${PORTNAME}-${PORTVERSION}.gemspec + +post-install-DOCS-on: + @${MKDIR} ${STAGEDIR}${DOCSDIR} + cd ${WRKSRC} && ${INSTALL_DATA} ${PORTDOCS} ${STAGEDIR}${DOCSDIR} + +post-install-EXAMPLES-on: + @${MKDIR} ${STAGEDIR}${EXAMPLESDIR} + cd ${WRKSRC}/examples/ && ${COPYTREE_SHARE} . ${STAGEDIR}${EXAMPLESDIR} + +.include <bsd.port.mk> diff --git a/sysutils/puppet7/distinfo b/sysutils/puppet7/distinfo new file mode 100644 index 000000000000..cd7a396ebc28 --- /dev/null +++ b/sysutils/puppet7/distinfo @@ -0,0 +1,3 @@ +TIMESTAMP = 1605749781 +SHA256 (puppetlabs-puppet-7.0.0_GH0.tar.gz) = 0943956958570c029c6d63f0aefd04260344554cfcf5903370978351329107fe +SIZE (puppetlabs-puppet-7.0.0_GH0.tar.gz) = 3278067 diff --git a/sysutils/puppet7/files/patch-lib_puppet_provider_service_daemontools.rb b/sysutils/puppet7/files/patch-lib_puppet_provider_service_daemontools.rb new file mode 100644 index 000000000000..3857c824a1ba --- /dev/null +++ b/sysutils/puppet7/files/patch-lib_puppet_provider_service_daemontools.rb @@ -0,0 +1,20 @@ +--- lib/puppet/provider/service/daemontools.rb.orig 2016-04-25 18:52:09 UTC ++++ lib/puppet/provider/service/daemontools.rb +@@ -39,7 +39,7 @@ Puppet::Type.type(:service).provide :dae + + EOT + +- commands :svc => "/usr/bin/svc", :svstat => "/usr/bin/svstat" ++ commands :svc => "%%PREFIX%%/bin/svc", :svstat => "%%PREFIX%%/bin/svstat" + + class << self + attr_writer :defpath +@@ -88,7 +88,7 @@ Puppet::Type.type(:service).provide :dae + # find the service dir on this node + def servicedir + unless @servicedir +- ["/service", "/etc/service","/var/lib/svscan"].each do |path| ++ ["/var/service", "/etc/service","/var/lib/svscan"].each do |path| + if Puppet::FileSystem.exist?(path) + @servicedir = path + break diff --git a/sysutils/puppet7/files/pkg-message.in b/sysutils/puppet7/files/pkg-message.in new file mode 100644 index 000000000000..caa220715594 --- /dev/null +++ b/sysutils/puppet7/files/pkg-message.in @@ -0,0 +1,11 @@ +[ +{ type: install + message: <<EOM +To enable the puppet agent, add the following to /etc/rc.conf: + + puppet_enable="YES" + +The default PID directory is /var/run/puppet +EOM +} +] diff --git a/sysutils/puppet7/files/puppet.in b/sysutils/puppet7/files/puppet.in new file mode 100644 index 000000000000..3f1010a59254 --- /dev/null +++ b/sysutils/puppet7/files/puppet.in @@ -0,0 +1,49 @@ +#!/bin/sh +# +# $FreeBSD$ +# + +# PROVIDE: puppet +# REQUIRE: LOGIN +# KEYWORD: shutdown + +# +# Add the following lines to /etc/rc.conf to enable the puppet agent: +# +# puppet_enable="YES" + +. /etc/rc.subr + +name="puppet" +rcvar=puppet_enable + +load_rc_config "$name" + +: ${puppet_enable="NO"} +: ${puppet_rundir="/var/run/puppet"} + +command="%%PREFIX%%/bin/puppet" +command_args="agent ${puppet_flags} --rundir=${puppet_rundir}" +command_interpreter=%%RUBY%% +unset puppet_flags + +pidfile="${puppet_rundir}/agent.pid" +start_precmd="install -d -o puppet -g puppet ${pidfile%/*}" + +PATH="${PATH}:%%PREFIX%%/bin:%%PREFIX%%/sbin" + +# An UTF-8 locale is required +: LC_ALL=${LC_ALL:=C.UTF-8} +case $LC_ALL in + *.UTF-8) + ;; + *.*) + LC_ALL="${LC_ALL%.*}.UTF-8" + ;; + *) + LC_ALL=C.UTF-8 + ;; +esac +export LC_ALL + +run_rc_command "$1" diff --git a/sysutils/puppet7/pkg-descr b/sysutils/puppet7/pkg-descr new file mode 100644 index 000000000000..9d40dc90e9cc --- /dev/null +++ b/sysutils/puppet7/pkg-descr @@ -0,0 +1,7 @@ +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. + +WWW: https://puppet.com/docs/puppet/latest/puppet_index.html diff --git a/sysutils/puppet7/pkg-plist b/sysutils/puppet7/pkg-plist new file mode 100644 index 000000000000..1787dee7a7fa --- /dev/null +++ b/sysutils/puppet7/pkg-plist @@ -0,0 +1,37 @@ +bin/puppet +%%ETCDIR%%/puppet.conf-dist +lib/ruby/gems/%%RUBY_VER%%/specifications/puppet-%%PORTVERSION%%.gemspec +%%RUBY_SITELIBDIR%%/hiera/puppet_function.rb +%%RUBY_SITELIBDIR%%/hiera/scope.rb +%%RUBY_SITELIBDIR%%/hiera_puppet.rb +%%RUBY_SITELIBDIR%%/puppet_pal.rb +%%RUBY_SITELIBDIR%%/puppet_x.rb +man/man5/puppet.conf.5.gz +man/man8/puppet-agent.8.gz +man/man8/puppet-apply.8.gz +man/man8/puppet-catalog.8.gz +man/man8/puppet-config.8.gz +man/man8/puppet-describe.8.gz +man/man8/puppet-device.8.gz +man/man8/puppet-doc.8.gz +man/man8/puppet-epp.8.gz +man/man8/puppet-facts.8.gz +man/man8/puppet-filebucket.8.gz +man/man8/puppet-generate.8.gz +man/man8/puppet-help.8.gz +man/man8/puppet-lookup.8.gz +man/man8/puppet-module.8.gz +man/man8/puppet-node.8.gz +man/man8/puppet-parser.8.gz +man/man8/puppet-plugin.8.gz +man/man8/puppet-report.8.gz +man/man8/puppet-resource.8.gz +man/man8/puppet-script.8.gz +man/man8/puppet-ssl.8.gz +man/man8/puppet.8.gz +@dir(puppet,puppet,) %%ETCDIR%%/manifests +@dir(puppet,puppet,) %%ETCDIR%%/modules +@dir(puppet,puppet,) /var/puppet +@dir(puppet,puppet,) /var/puppet/state +@dir(puppet,puppet,) /var/log/puppet +@dir /var/run/puppet |