From patchwork Thu Mar 9 15:35:06 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Aaron Conole X-Patchwork-Id: 737029 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from mail.linuxfoundation.org (mail.linuxfoundation.org [140.211.169.12]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 3vfDwt5YrLz9s7Z for ; Fri, 10 Mar 2017 02:35:10 +1100 (AEDT) Received: from mail.linux-foundation.org (localhost [127.0.0.1]) by mail.linuxfoundation.org (Postfix) with ESMTP id 45D4EBAA; Thu, 9 Mar 2017 15:35:09 +0000 (UTC) X-Original-To: dev@openvswitch.org Delivered-To: ovs-dev@mail.linuxfoundation.org Received: from smtp1.linuxfoundation.org (smtp1.linux-foundation.org [172.17.192.35]) by mail.linuxfoundation.org (Postfix) with ESMTPS id 2AF7BBA3 for ; Thu, 9 Mar 2017 15:35:08 +0000 (UTC) X-Greylist: domain auto-whitelisted by SQLgrey-1.7.6 Received: from mx1.redhat.com (mx1.redhat.com [209.132.183.28]) by smtp1.linuxfoundation.org (Postfix) with ESMTPS id BF4BE1CA for ; Thu, 9 Mar 2017 15:35:07 +0000 (UTC) Received: from int-mx14.intmail.prod.int.phx2.redhat.com (int-mx14.intmail.prod.int.phx2.redhat.com [10.5.11.27]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id 46D6F12B9 for ; Thu, 9 Mar 2017 15:35:08 +0000 (UTC) Received: from dhcp-25-97.bos.redhat.com ([10.18.25.172]) by int-mx14.intmail.prod.int.phx2.redhat.com (8.14.4/8.14.4) with ESMTP id v29FZ7Ru001621 for ; Thu, 9 Mar 2017 10:35:07 -0500 From: Aaron Conole To: dev@openvswitch.org Date: Thu, 9 Mar 2017 10:35:06 -0500 Message-Id: <20170309153506.17749-1-aconole@redhat.com> X-Scanned-By: MIMEDefang 2.68 on 10.5.11.27 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.30]); Thu, 09 Mar 2017 15:35:08 +0000 (UTC) X-Spam-Status: No, score=-6.9 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_HI, RP_MATCHES_RCVD autolearn=ham version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on smtp1.linux-foundation.org Subject: [ovs-dev] [RFC] lib/automake.mk: remove runtime directories X-BeenThere: ovs-dev@openvswitch.org X-Mailman-Version: 2.1.12 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Sender: ovs-dev-bounces@openvswitch.org Errors-To: ovs-dev-bounces@openvswitch.org The Open vSwitch run, log, and DB directories are installed as part of the normal `make install` process. However, this means they are created with user and group ownership that may conflict with the desired user. For example, running `make install` as root will install those files as root:root, whereas the runtime user desired may be openvswitch:openvswitch. Since these directories are automatically created as part of the ovs-ctl command, and with the correct user:group permissions, it makes sense to delay creation until these directories are actually required. Signed-off-by: Aaron Conole Reviewed-by: Markos Chandras --- NOTE: An alternate approach where ovs-ctl would use chown/chmod to set the permissions could also work, but I haven't considered what the side effects would be. lib/automake.mk | 3 --- 1 file changed, 3 deletions(-) diff --git a/lib/automake.mk b/lib/automake.mk index b266af1..e095d29 100644 --- a/lib/automake.mk +++ b/lib/automake.mk @@ -533,10 +533,7 @@ EXTRA_DIST += build-aux/extract-ofp-msgs INSTALL_DATA_LOCAL += lib-install-data-local lib-install-data-local: - $(MKDIR_P) $(DESTDIR)$(RUNDIR) $(MKDIR_P) $(DESTDIR)$(PKIDIR) - $(MKDIR_P) $(DESTDIR)$(LOGDIR) - $(MKDIR_P) $(DESTDIR)$(DBDIR) $(MKDIR_P) $(DESTDIR)$(sysconfdir)/openvswitch man_MANS += lib/ovs-fields.7