Skip to content

Commit

Permalink
sysutils/puppetserver8: Fix logging and build aarch64 packages
Browse files Browse the repository at this point in the history
Some changes in the Puppet Server recently broke logging.  Ensure we
write logs as before.

The server work on aarch64 so add it to ONLY_FOR_ARCHS.

While here, do some cleanup of the Makefile.

With hat:	puppet
  • Loading branch information
smortex committed Nov 23, 2023
1 parent 7f03c6a commit 56ae3aa
Show file tree
Hide file tree
Showing 3 changed files with 19 additions and 5 deletions.
6 changes: 3 additions & 3 deletions sysutils/puppetserver8/Makefile
@@ -1,18 +1,18 @@
PORTNAME= puppetserver
PORTVERSION= 8.3.0
PORTREVISION= 1
CATEGORIES= sysutils java
MASTER_SITES= https://downloads.puppetlabs.com/puppet/
PKGNAMESUFFIX= 8
DISTFILES= ${DISTNAME}${EXTRACT_SUFX}
EXTRACT_ONLY= ${DISTNAME}${EXTRACT_SUFX}

MAINTAINER= puppet@FreeBSD.org
COMMENT= Puppet Server running in the JVM
WWW= https://docs.puppetlabs.com/puppetserver/latest/services_master_puppetserver.html

LICENSE= APACHE20

ONLY_FOR_ARCHS= amd64
ONLY_FOR_ARCHS= aarch64 amd64
ONLY_FOR_ARCHS_REASON=Bundled JNI only support some architectures

RUN_DEPENDS= bash>=0:shells/bash \
puppet8>=8.0:sysutils/puppet8 \
Expand Down
16 changes: 15 additions & 1 deletion sysutils/puppetserver8/files/patch-ext__config__logback.xml
@@ -1,4 +1,4 @@
--- ext/config/logback.xml.orig 2018-09-18 17:16:33 UTC
--- ext/config/logback.xml.orig 2023-10-19 16:09:06 UTC
+++ ext/config/logback.xml
@@ -6,12 +6,11 @@
</appender>
Expand All @@ -15,3 +15,17 @@
<!-- each file should be at most 200MB, keep 90 days worth of history, but at most 1GB total-->
<maxFileSize>200MB</maxFileSize>
<maxHistory>90</maxHistory>
@@ -23,11 +22,11 @@
</appender>

<appender name="STATUS" class="ch.qos.logback.core.rolling.RollingFileAppender">
- <file>/var/log/puppetlabs/puppetserver/puppetserver-status.log</file>
+ <file>/var/log/puppetserver/puppetserver-status.log</file>
<append>true</append>
<rollingPolicy class="ch.qos.logback.core.rolling.SizeAndTimeBasedRollingPolicy">
<!-- rollover daily -->
- <fileNamePattern>/var/log/puppetlabs/puppetserver/puppetserver-status-%d{yyyy-MM-dd}.%i.log.gz</fileNamePattern>
+ <fileNamePattern>/var/log/puppetserver/puppetserver-status-%d{yyyy-MM-dd}.%i.log.gz</fileNamePattern>
<!-- each file should be at most 200MB, keep 90 days worth of history, but at most 1GB total-->
<maxFileSize>200MB</maxFileSize>
<maxHistory>90</maxHistory>
2 changes: 1 addition & 1 deletion sysutils/puppetserver8/files/puppetserver.in
Expand Up @@ -54,7 +54,7 @@ pidfile="/var/run/puppetserver/puppetserver.pid"
command="/usr/sbin/daemon"
java_cmd="${puppetserver_java_home}/bin/java"
procname="${java_cmd}"
command_args="-f -p ${pidfile} ${java_cmd} ${puppetserver_java_opts} -cp %%DATADIR%%/puppet-server-release.jar:%%PREFIX%%/lib/ruby/vendor_ruby/facter.jar clojure.main -m puppetlabs.trapperkeeper.main ${puppetserver_args}"
command_args="-f -p ${pidfile} ${java_cmd} -Djruby.logger.class=com.puppetlabs.jruby_utils.jruby.Slf4jLogger -Dlogappender=F1 ${puppetserver_java_opts} -cp %%DATADIR%%/puppet-server-release.jar:%%PREFIX%%/lib/ruby/vendor_ruby/facter.jar clojure.main -m puppetlabs.trapperkeeper.main ${puppetserver_args}"


required_files="${java_cmd}"
Expand Down

0 comments on commit 56ae3aa

Please sign in to comment.