Index: head/net/activemq/Makefile =================================================================== --- head/net/activemq/Makefile (revision 528891) +++ head/net/activemq/Makefile (revision 528892) @@ -1,70 +1,60 @@ # $FreeBSD$ PORTNAME= activemq -PORTVERSION= 5.15.11 +PORTVERSION= 5.15.12 CATEGORIES= net java MASTER_SITES= APACHE/${PORTNAME}/${PORTVERSION} DISTNAME= apache-${PORTNAME}-${PORTVERSION} EXTRACT_SUFX= -bin.tar.gz MAINTAINER= tobik@FreeBSD.org COMMENT= Messaging and Integration Patterns provider LICENSE= APACHE20 LICENSE_FILE= ${WRKSRC}/LICENSE USES= cpe CPE_VENDOR= apache USE_JAVA= yes +USE_RC_SUBR= activemq NO_ARCH= yes NO_BUILD= yes -MQDB?= /var/db/activemq -MQUSER?= activemq -MQGROUP?= ${MQUSER} -USERS= ${MQUSER} -GROUPS= ${MQGROUP} +USERS= activemq +GROUPS= activemq -ALL_TARGET= ${PORTNAME} -USE_RC_SUBR= ${PORTNAME} - PORTDATA= * PORTDOCS= * PORTEXAMPLES= * -SUB_LIST= MQUSER="${MQUSER}" \ - MQGROUP="${MQGROUP}" \ - MQDB="${MQDB}" -PLIST_SUB= MQUSER="${MQUSER}" \ - MQGROUP="${MQGROUP}" \ - MQDB="${MQDB}" - OPTIONS_DEFINE= DOCS EXAMPLES do-install: - @${MKDIR} ${STAGEDIR}${DATADIR}/bin ${STAGEDIR}${ETCDIR} ${STAGEDIR}${MQDB} ${RM} ${WRKSRC}/conf/log4j.properties.orig + @${MKDIR} ${STAGEDIR}${ETCDIR} cd ${WRKSRC}/conf && for f in *; do \ ${INSTALL_DATA} ${WRKSRC}/conf/$$f ${STAGEDIR}${ETCDIR}/$$f.sample; \ done + @${MKDIR} ${STAGEDIR}${DATADIR}/bin ${INSTALL_SCRIPT} ${WRKSRC}/bin/activemq* ${STAGEDIR}${DATADIR}/bin ${RLN} ${STAGEDIR}${DATADIR}/bin/activemq ${STAGEDIR}${PREFIX}/bin ${RLN} ${STAGEDIR}${DATADIR}/bin/activemq-diag ${STAGEDIR}${PREFIX}/bin ${INSTALL_DATA} ${WRKSRC}/bin/activemq.jar ${WRKSRC}/bin/wrapper.jar \ ${STAGEDIR}${DATADIR}/bin - ${RLN} ${STAGEDIR}${MQDB} ${STAGEDIR}${DATADIR}/data + @${MKDIR} ${STAGEDIR}/var/db/activemq + ${RLN} ${STAGEDIR}/var/db/activemq ${STAGEDIR}${DATADIR}/data ${RLN} ${STAGEDIR}${ETCDIR} ${STAGEDIR}${DATADIR}/conf cd ${WRKSRC} && ${COPYTREE_SHARE} "lib webapps webapps-demo" \ ${STAGEDIR}${DATADIR} do-install-DOCS-on: cd ${WRKSRC}/docs && ${COPYTREE_SHARE} . ${STAGEDIR}${DOCSDIR} ${INSTALL_DATA} ${WRKSRC}/NOTICE ${WRKSRC}/README.txt ${STAGEDIR}${DOCSDIR} ${RLN} ${STAGEDIR}${DOCSDIR} ${STAGEDIR}${DATADIR}/docs do-install-EXAMPLES-on: cd ${WRKSRC}/examples && ${COPYTREE_SHARE} . ${STAGEDIR}${EXAMPLESDIR} ${RLN} ${STAGEDIR}${EXAMPLESDIR} ${STAGEDIR}${DATADIR}/examples .include Index: head/net/activemq/distinfo =================================================================== --- head/net/activemq/distinfo (revision 528891) +++ head/net/activemq/distinfo (revision 528892) @@ -1,3 +1,3 @@ -TIMESTAMP = 1574756913 -SHA256 (apache-activemq-5.15.11-bin.tar.gz) = d72b59a9fa8199ae0de6326e05e0f3136deaee4bbd8de269e6193a8ae012b089 -SIZE (apache-activemq-5.15.11-bin.tar.gz) = 62230168 +TIMESTAMP = 1584845071 +SHA256 (apache-activemq-5.15.12-bin.tar.gz) = 415fbe3ef85e83b92dfbb1b14c4018b87b9a6a03d918984ec679e39ff2096193 +SIZE (apache-activemq-5.15.12-bin.tar.gz) = 62666908 Index: head/net/activemq/files/activemq.in =================================================================== --- head/net/activemq/files/activemq.in (revision 528891) +++ head/net/activemq/files/activemq.in (revision 528892) @@ -1,141 +1,140 @@ #!/bin/sh # # $FreeBSD$ # # PROVIDE: activemq # REQUIRE: NETWORKING SERVERS # BEFORE: DAEMON # KEYWORD: shutdown # # Add the following lines to /etc/rc.conf.local or /etc/rc.conf # to enable this service: # # activemq_enable (bool): Set to NO by default. # Set it to YES to enable activemq. # activemq_user (username): Set to activemq by default. # Set it to required username. # activemq_group (group): Set to activemq by default. # Set it to required group. # activemq_classpath (path): Set to %%DATADIR%% by default. # Set it to java classes directory. # activemq_home (path): Set to %%DATADIR%% by default. # Set it to java home directory. # activemq_javargs (args): Set to -Xmx256M by default. # See java -h for available arguments. # activemq_stop_timeout (num): Set to "10" by default. # Set the timeout in seconds to shutdown. # . /etc/rc.subr name="activemq" rcvar=activemq_enable load_rc_config $name # Set defaults : ${activemq_enable:=NO} -: ${activemq_user:=%%MQUSER%%} -: ${activemq_group:=%%MQGROUP%%} +: ${activemq_user:=activemq} +: ${activemq_group:=activemq} : ${activemq_classpath:=%%ETCDIR%%} : ${activemq_conf:=%%ETCDIR%%} -: ${activemq_data:=%%MQDB%%} +: ${activemq_data:=/var/db/activemq} : ${activemq_logs:=/var/log/activemq} : ${activemq_home:=%%DATADIR%%} : ${activemq_javargs:='-Xmx512M -Dorg.apache.activemq.UseDedicatedTaskRunner=true -Djava.util.logging.config.file=logging.properties -Dcom.sun.management.jmxremote'} : ${activemq_stop_timeout:="10"} : ${activemq_hostname:=`/bin/hostname`} - pidfile=/var/run/${name}.pid required_files="%%ETCDIR%%/activemq.xml" jar_file="%%DATADIR%%/bin/activemq.jar" java_options=" -server -jar ${activemq_javargs} \ -Dactivemq.classpath=${activemq_classpath} \ -Dactivemq.conf=${activemq_conf} \ -Dactivemq.data=${activemq_data} \ -Dactivemq.logs=${activemq_logs} \ -Dactivemq.home=${activemq_home} \ -Dactivemq.base=${activemq_home} \ -Dactivemq.hostname=${activemq_hostname}" java_command="%%LOCALBASE%%/bin/java ${java_options} ${jar_file}" command="/usr/sbin/daemon" command_args="-f -p ${pidfile} ${java_command} start" start_precmd="activemq_precmd" status_cmd="activemq_status" stop_cmd="activemq_stop" activemq_precmd() { touch ${pidfile} chown ${activemq_user}:${activemq_group} ${pidfile} /usr/bin/install -d -m 0750 -o ${activemq_user} -g ${activemq_group} ${activemq_logs} /usr/bin/install -d -m 0750 -o ${activemq_user} -g ${activemq_group} ${activemq_data} } activemq_stop() { rc_pid=$(activemq_check_pidfile $pidfile) if [ -z "$rc_pid" ]; then [ -n "$rc_fast" ] && return 0 echo "${name} not running? (check $pidfile)." return 1 fi echo "Stopping ${name}." /usr/bin/su -m $activemq_user -c "${java_command} stop" >/dev/null activemq_wait_max_for_pid ${activemq_stop_timeout} ${rc_pid} kill -KILL ${rc_pid} 2> /dev/null && echo "Killed." rm -f ${pidfile} } activemq_status() { rc_pid=$(activemq_check_pidfile $pidfile) if [ -z "$rc_pid" ]; then [ -n "$rc_fast" ] && return 0 echo "${name} not running? (check $pidfile)." return 1 fi echo "${name} is running as pid ${rc_pid}." } activemq_check_pidfile() { _pidfile=$1 if [ -z "$_pidfile" ]; then err 3 'USAGE: activemq_check_pidfile pidfile' fi if [ ! -f $_pidfile ]; then debug "pid file ($_pidfile): not readable." return fi read _pid _junk < $_pidfile if [ -z "$_pid" ]; then debug "pid file ($_pidfile): no pid in file." return fi if [ -n "`/usr/bin/su -m $activemq_user -c '%%LOCALBASE%%/bin/jps -l' | grep -e "^$_pid $jar_file\$"`" ]; then echo -n $_pid fi } activemq_wait_max_for_pid() { _timeout=$1 shift _pid=$1 _prefix= while [ $_timeout -gt 0 ] ; do echo -n ${_prefix:-"Waiting (max $_timeout secs) for PIDS: "}$_pid _prefix=", " sleep 2 kill -0 $_pid 2> /dev/null || break _timeout=$(($_timeout-2)) done if [ -n "$_prefix" ]; then echo "." fi } run_rc_command "$1" Index: head/net/activemq/pkg-plist =================================================================== --- head/net/activemq/pkg-plist (revision 528891) +++ head/net/activemq/pkg-plist (revision 528892) @@ -1,25 +1,25 @@ bin/activemq bin/activemq-diag -@owner %%MQUSER%% -@group %%MQGROUP%% +@owner activemq +@group activemq @sample %%ETCDIR%%/activemq.xml.sample @sample %%ETCDIR%%/broker-localhost.cert.sample @sample %%ETCDIR%%/broker.ks.sample @sample %%ETCDIR%%/broker.ts.sample @sample %%ETCDIR%%/client.ks.sample @sample %%ETCDIR%%/client.ts.sample @sample %%ETCDIR%%/credentials-enc.properties.sample @sample %%ETCDIR%%/credentials.properties.sample @sample %%ETCDIR%%/groups.properties.sample @sample %%ETCDIR%%/java.security.sample @sample %%ETCDIR%%/jetty-realm.properties.sample @sample %%ETCDIR%%/jetty.xml.sample @sample %%ETCDIR%%/jmx.access.sample @sample %%ETCDIR%%/jmx.password.sample @sample %%ETCDIR%%/log4j.properties.sample @sample %%ETCDIR%%/logging.properties.sample @sample %%ETCDIR%%/login.config.sample @sample %%ETCDIR%%/users.properties.sample -@dir(,,0750) %%MQDB%% +@dir(,,0750) /var/db/activemq @group @owner