From owner-svn-ports-head@FreeBSD.ORG Sat Oct 27 10:44:57 2012 Return-Path: Delivered-To: svn-ports-head@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id DE2FC402; Sat, 27 Oct 2012 10:44:57 +0000 (UTC) (envelope-from kuriyama@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id B97F28FC1A; Sat, 27 Oct 2012 10:44:57 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q9RAivSS055545; Sat, 27 Oct 2012 10:44:57 GMT (envelope-from kuriyama@svn.freebsd.org) Received: (from kuriyama@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q9RAivId055539; Sat, 27 Oct 2012 10:44:57 GMT (envelope-from kuriyama@svn.freebsd.org) Message-Id: <201210271044.q9RAivId055539@svn.freebsd.org> From: Jun Kuriyama Date: Sat, 27 Oct 2012 10:44:57 +0000 (UTC) To: ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org Subject: svn commit: r306484 - in head: . sysutils/rubygem-fluentd sysutils/rubygem-fluentd/files X-SVN-Group: ports-head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-ports-head@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: SVN commit messages for the ports tree for head List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 27 Oct 2012 10:44:57 -0000 Author: kuriyama Date: Sat Oct 27 10:44:57 2012 New Revision: 306484 URL: http://svn.freebsd.org/changeset/ports/306484 Log: - Upgrade to 0.10.27. - Install rc script and own user/group. Feature safe: yes Added: head/sysutils/rubygem-fluentd/files/ head/sysutils/rubygem-fluentd/files/fluentd.in (contents, props changed) Modified: head/GIDs head/UIDs head/sysutils/rubygem-fluentd/Makefile head/sysutils/rubygem-fluentd/distinfo Modified: head/GIDs ============================================================================== --- head/GIDs Sat Oct 27 10:01:15 2012 (r306483) +++ head/GIDs Sat Oct 27 10:44:57 2012 (r306484) @@ -242,5 +242,6 @@ c_icap:*:959: trytond:*:960: gearmand:*:961: zookeeper:*:962: +fluentd:*:963: nogroup:*:65533: nobody:*:65534: Modified: head/UIDs ============================================================================== --- head/UIDs Sat Oct 27 10:01:15 2012 (r306483) +++ head/UIDs Sat Oct 27 10:44:57 2012 (r306484) @@ -246,4 +246,5 @@ c_icap:*:959:959::0:0:c-icap daemon:/var trytond:*:960:960::0:0:trytond daemon:/var/empty:/usr/sbin/nologin gearmand:*:961:961::0:0:gearmand daemon:/var/empty:/usr/sbin/nologin zookeeper:*:962:962::0:0:zookeeper user:/nonexistent:/usr/sbin/nologin +fluentd:*:963:963::0:0:fluentd user:/nonexistent:/usr/sbin/nologin nobody:*:65534:65534::0:0:Unprivileged user:/nonexistent:/usr/sbin/nologin Modified: head/sysutils/rubygem-fluentd/Makefile ============================================================================== --- head/sysutils/rubygem-fluentd/Makefile Sat Oct 27 10:01:15 2012 (r306483) +++ head/sysutils/rubygem-fluentd/Makefile Sat Oct 27 10:44:57 2012 (r306484) @@ -1,12 +1,7 @@ -# New ports collection makefile for: rubygem-fluentd -# Date created: 10 Jul 2012 -# Whom: Jun Kuriyama -# # $FreeBSD$ -# PORTNAME= fluentd -PORTVERSION= 0.10.25 +PORTVERSION= 0.10.27 CATEGORIES= sysutils rubygems MASTER_SITES= RG @@ -23,8 +18,14 @@ RUN_DEPENDS= \ USE_RUBY= yes #RUBY_VER= 1.9 # Please set RUBY_DEFAULT_VER=1.9 in /etc/make.conf USE_RUBYGEMS= yes -PLIST_FILES= bin/fluent-cat bin/fluent-gem bin/fluentd +PLIST_FILES= bin/fluent-cat bin/fluent-debug bin/fluent-gem bin/fluentd \ + "@exec ${INSTALL} -d -o ${USERS} -g ${GROUPS} -m 775 /var/run/fluentd" \ + "@unexec ${RMDIR} /var/run/fluentd 2>/dev/null || true" RUBYGEM_AUTOPLIST= yes +USE_RC_SUBR= fluentd +USERS= fluentd +GROUPS= fluentd +SUB_LIST+= USER=${USERS} GROUP=${GROUPS} .include @@ -32,4 +33,7 @@ RUBYGEM_AUTOPLIST= yes IGNORE= requires Ruby 1.9, please install this first .endif +post-install: + ${INSTALL} -d -o ${USERS} -g ${GROUPS} -m 775 /var/run/fluentd + .include Modified: head/sysutils/rubygem-fluentd/distinfo ============================================================================== --- head/sysutils/rubygem-fluentd/distinfo Sat Oct 27 10:01:15 2012 (r306483) +++ head/sysutils/rubygem-fluentd/distinfo Sat Oct 27 10:44:57 2012 (r306484) @@ -1,2 +1,2 @@ -SHA256 (rubygem/fluentd-0.10.25.gem) = 6b28e11749aee03b47d11b98c60192071a3eceaa5741eb89af7450e814340e7d -SIZE (rubygem/fluentd-0.10.25.gem) = 56320 +SHA256 (rubygem/fluentd-0.10.27.gem) = 32069902fa26ae0b32473f1369ce30978e8434c4be854dcfbfc925497b123394 +SIZE (rubygem/fluentd-0.10.27.gem) = 57856 Added: head/sysutils/rubygem-fluentd/files/fluentd.in ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/sysutils/rubygem-fluentd/files/fluentd.in Sat Oct 27 10:44:57 2012 (r306484) @@ -0,0 +1,47 @@ +#!/bin/sh + +# $FreeBSD$ +# +# PROVIDE: fluentd +# REQUIRE: LOGIN +# KEYWORD: shutdown +# +# Add the following lines to /etc/rc.conf.local or /etc/rc.conf +# to enable this service: +# +# fluentd_enable (bool): Set to NO by default. +# Set it to YES to enable fluentd. +# fluentd_config (path): Set to %%PREFIX%%/etc/doormand/doormand.cf +# by default. +# fluentd_db_dir (path): Set DB dir (default: "/var/db/fluentd") + +. /etc/rc.subr + +name=fluentd +rcvar=fluentd_enable +extra_commands="init" + +load_rc_config $name + +: ${fluentd_enable:="NO"} +: ${fluentd_config="%%PREFIX%%/etc/fluentd/fluent.conf"} +: ${fluentd_dir="%%PREFIX%%/etc/fluentd"} +: ${fluentd_user="%%USER%%"} +: ${fluentd_group="%%GROUP%%"} + +init_cmd="init_fluentd_dir" + +command=%%PREFIX%%/bin/${name} +pidfile=/var/run/${name}/${name}.pid + +command_args="-d $pidfile -c $fluentd_config" + +init_fluentd_dir() +{ + # XXX: Using sudo for now. fluentd user have /nonexistent as + # $HOME, and nologin as shell. + install -d -o ${fluentd_user} -g ${fluentd_group} -m 775 ${fluentd_dir} + %%PREFIX%%/bin/sudo -u fluentd ${command} --setup ${fluentd_dir} +} + +run_rc_command "$1"