Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 9 Mar 2019 18:14:59 +0000 (UTC)
From:      Mark Felder <feld@FreeBSD.org>
To:        ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-branches@freebsd.org
Subject:   svn commit: r495185 - in branches/2019Q1/net-mgmt/unifi-lts: . files
Message-ID:  <201903091814.x29IExNJ002197@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: feld
Date: Sat Mar  9 18:14:58 2019
New Revision: 495185
URL: https://svnweb.freebsd.org/changeset/ports/495185

Log:
  MFH: r495184
  
  net-mgmt/unifi-lts: Fix support for Mongo 3.6+
  
  Ubiquiti still hasn't fixed UniFi-LTS after this was reported ages ago, so
  I guess every OS will have to fix this manually.
  
  Reported by:	many

Added:
  branches/2019Q1/net-mgmt/unifi-lts/files/mongod.in
     - copied unchanged from r495184, head/net-mgmt/unifi-lts/files/mongod.in
Modified:
  branches/2019Q1/net-mgmt/unifi-lts/Makefile
Directory Properties:
  branches/2019Q1/   (props changed)

Modified: branches/2019Q1/net-mgmt/unifi-lts/Makefile
==============================================================================
--- branches/2019Q1/net-mgmt/unifi-lts/Makefile	Sat Mar  9 18:12:18 2019	(r495184)
+++ branches/2019Q1/net-mgmt/unifi-lts/Makefile	Sat Mar  9 18:14:58 2019	(r495185)
@@ -3,7 +3,7 @@
 
 PORTNAME=	unifi
 PORTVERSION=	5.6.40
-PORTREVISION=	1
+PORTREVISION=	2
 CATEGORIES=	net-mgmt java
 MASTER_SITES=	http://dl.ubnt.com/unifi/${PORTVERSION}/
 PKGNAMESUFFIX=	-lts
@@ -17,6 +17,7 @@ COMMENT=	UniFi Controller v5
 RUN_DEPENDS=	mongodb36>0:databases/mongodb36 \
 		snappyjava>0:archivers/snappy-java
 
+SUB_FILES=	mongod
 SUB_LIST+=	USERS=${USERS} GROUPS=${GROUPS} JAVASHAREDIR=${JAVASHAREDIR} \
 		JAVA=${JAVA}
 
@@ -54,7 +55,7 @@ post-patch:
 do-install:
 	${MKDIR} ${STAGEDIR}${JAVASHAREDIR}/unifi
 	(cd ${WRKSRC}/usr/lib/unifi && ${COPYTREE_SHARE} \* ${STAGEDIR}${JAVASHAREDIR}/unifi/)
-	${LN} -sf ${PREFIX}/bin/mongod ${STAGEDIR}${JAVASHAREDIR}/unifi/bin/mongod
+	${INSTALL_SCRIPT} ${WRKDIR}/mongod ${STAGEDIR}${JAVASHAREDIR}/unifi/bin/mongod
 # Create directories that will be writable by unifi
 .for i in data logs run work
 	${MKDIR} ${STAGEDIR}/${JAVASHAREDIR}/unifi/${i}

Copied: branches/2019Q1/net-mgmt/unifi-lts/files/mongod.in (from r495184, head/net-mgmt/unifi-lts/files/mongod.in)
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ branches/2019Q1/net-mgmt/unifi-lts/files/mongod.in	Sat Mar  9 18:14:58 2019	(r495185, copy of r495184, head/net-mgmt/unifi-lts/files/mongod.in)
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+# Remove argument that doesn't exist on mongodb 3.6+
+ARGS="$(echo -n ${@} | /usr/bin/sed 's,--nohttpinterface,,')"
+
+%%PREFIX%%/bin/mongod ${ARGS} &



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201903091814.x29IExNJ002197>