From owner-freebsd-ports-bugs@FreeBSD.ORG Mon Apr 14 12:00:00 2014 Return-Path: Delivered-To: freebsd-ports-bugs@smarthost.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id E117E710 for ; Mon, 14 Apr 2014 12:00:00 +0000 (UTC) Received: from freefall.freebsd.org (freefall.freebsd.org [IPv6:2001:1900:2254:206c::16:87]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id C0F591D55 for ; Mon, 14 Apr 2014 12:00:00 +0000 (UTC) Received: from freefall.freebsd.org (localhost [127.0.0.1]) by freefall.freebsd.org (8.14.8/8.14.8) with ESMTP id s3EC00N1044516 for ; Mon, 14 Apr 2014 12:00:00 GMT (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.14.8/8.14.8/Submit) id s3EC009C044515; Mon, 14 Apr 2014 12:00:00 GMT (envelope-from gnats) Resent-Date: Mon, 14 Apr 2014 12:00:00 GMT Resent-Message-Id: <201404141200.s3EC009C044515@freefall.freebsd.org> Resent-From: FreeBSD-gnats-submit@FreeBSD.org (GNATS Filer) Resent-To: freebsd-ports-bugs@FreeBSD.org Resent-Reply-To: FreeBSD-gnats-submit@FreeBSD.org, David Demelier Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 0981C5D5; Mon, 14 Apr 2014 11:58:42 +0000 (UTC) Received: from postfix.malikania.fr (ks3292218.kimsufi.com [5.135.187.121]) by mx1.freebsd.org (Postfix) with ESMTP id 971401D31; Mon, 14 Apr 2014 11:58:41 +0000 (UTC) Received: from postfix.malikania.fr (unknown [10.0.0.5]) by postfix.malikania.fr (Postfix) with ESMTPS id 02B595872; Mon, 14 Apr 2014 13:58:40 +0200 (CEST) Received: by postfix.malikania.fr (sSMTP sendmail emulation); Mon, 14 Apr 2014 13:58:39 +0200 Message-Id: <20140414115840.02B595872@postfix.malikania.fr> Date: Mon, 14 Apr 2014 13:58:39 +0200 From: "David Demelier" To: FreeBSD-gnats-submit@freebsd.org X-Send-Pr-Version: 3.114 Subject: ports/188607: [patch] www/redmine: fix permissions and thin option Cc: swills@FreeBSD.org X-BeenThere: freebsd-ports-bugs@freebsd.org X-Mailman-Version: 2.1.17 Precedence: list Reply-To: David Demelier List-Id: Ports bug reports List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 14 Apr 2014 12:00:00 -0000 >Number: 188607 >Category: ports >Synopsis: [patch] www/redmine: fix permissions and thin option >Confidential: no >Severity: critical >Priority: high >Responsible: freebsd-ports-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: change-request >Submitter-Id: current-users >Arrival-Date: Mon Apr 14 12:00:00 UTC 2014 >Closed-Date: >Last-Modified: >Originator: David Demelier >Release: FreeBSD 10.0-RELEASE-p1 amd64 >Organization: >Environment: System: FreeBSD Pomme.malikania.fr 10.0-RELEASE-p1 FreeBSD 10.0-RELEASE-p1 #1 r264293: Wed Apr 9 10:34:18 CEST 2014 root@Pomme.malikania.fr:/usr/obj/usr/src/sys/Pomme amd64 >Description: The port has been broken again, this patch includes : 1. Fix permission on redmine directories: log, files, tmp and public as described in the redmine installation guide 2. Add gem thin in the Gemfile if the option THIN is enabled, otherwise won't start 3. Clean up thM makefile, CHOWN commands in the Makefile are useless with stage >How-To-Repeat: >Fix: --- redmine.diff begins here --- --- Makefile.orig 2014-04-14 12:20:04.000000000 +0200 +++ Makefile 2014-04-14 12:42:43.000000000 +0200 @@ -28,6 +28,9 @@ USE_RAKE= yes NO_BUILD= yes SUB_LIST+= RUBY_NAME=${RUBY_NAME} +USERS= ${WWWOWN} +GROUPS= ${WWWGRP} +PLIST_SUB+= WWWOWN=${WWWOWN} WWWGRP=${WWWGRP} OPTIONS_DEFINE= MYSQL MYSQL2 POSTGRESQL RMAGIC WWWSERVER OPTIONS_DEFAULT=MYSQL2 RMAGIC WWWSERVER THIN @@ -62,11 +65,10 @@ .if ${PORT_OPTIONS:MWWWSERVER} .if ${PORT_OPTIONS:MTHIN} -USERS= ${WWWOWN} -GROUPS= ${WWWGRP} RUN_DEPENDS+= thin:${PORTSDIR}/www/rubygem-thin USE_RC_SUBR= redmine SUB_LIST+= WWWOWN=${WWWOWN} WWWGRP=${WWWGRP} +EXTRA_PATCHES+= ${FILESDIR}/extra-patch-thin-Gemfile .endif .if ${PORT_OPTIONS:MPASSENGER} @@ -89,16 +91,11 @@ post-install: ${TOUCH} ${STAGEDIR}${WWWDIR}/Gemfile.lock - ${CHOWN} ${WWWOWN}:${WWWGRP} ${STAGEDIR}${WWWDIR}/Gemfile.lock if ! [ -r ${STAGEDIR}${WWWDIR}/config/settings.yml ]; then \ ${INSTALL_DATA} ${STAGEDIR}${WWWDIR}/config/settings.yml-dist \ ${STAGEDIR}${WWWDIR}/config/settings.yml; \ fi - for subdir in files log tmp public/plugin_assets; do \ - ${CHOWN} -R :${WWWGRP} ${STAGEDIR}${WWWDIR}/$$subdir; \ - ${CHMOD} -R g+w ${STAGEDIR}${WWWDIR}/$$subdir; \ - done @${CAT} ${PKGMESSAGE} .include --- pkg-plist.orig 2014-04-14 10:47:41.000000000 +0200 +++ pkg-plist 2014-04-14 12:50:20.000000000 +0200 @@ -1,6 +1,12 @@ %%WWWDIR%%/CONTRIBUTING.md +@owner %%WWWOWN%% +@group %%WWWGRP%% %%WWWDIR%%/Gemfile +@owner %%WWWOWN%% +@group %%WWWGRP%% %%WWWDIR%%/Gemfile.lock +@owner +@group %%WWWDIR%%/README.rdoc %%WWWDIR%%/Rakefile %%WWWDIR%%/app/controllers/account_controller.rb @@ -2174,3 +2180,7 @@ @dirrmtry %%WWWDIR%%/app/controllers @dirrmtry %%WWWDIR%%/app @dirrmtry %%WWWDIR%% +@exec chown -R %%WWWOWN%%:%%WWWGRP%% %D/%%WWWDIR%%/files +@exec chown -R %%WWWOWN%%:%%WWWGRP%% %D/%%WWWDIR%%/log +@exec chown -R %%WWWOWN%%:%%WWWGRP%% %D/%%WWWDIR%%/public/plugin_assets +@exec chown -R %%WWWOWN%%:%%WWWGRP%% %D/%%WWWDIR%%/tmp --- /dev/null 2014-04-14 12:50:36.000000000 +0200 +++ files/extra-patch-thin-Gemfile 2014-04-14 12:21:58.000000000 +0200 @@ -0,0 +1,12 @@ +--- Gemfile.orig 2014-04-14 12:20:52.000000000 +0200 ++++ Gemfile 2014-04-14 12:21:07.000000000 +0200 +@@ -9,6 +9,9 @@ + gem "mime-types" + gem "awesome_nested_set", "2.1.6" + ++# Thin webserver ++gem "thin", "~> 1.6.2" ++ + # Optional gem for LDAP authentication + group :ldap do + gem "net-ldap", "~> 0.3.1" --- redmine.diff ends here --- >Release-Note: >Audit-Trail: >Unformatted: