aboutsummaryrefslogtreecommitdiff
path: root/ftp/fastdfs
diff options
context:
space:
mode:
authorDanilo G. Baio <dbaio@FreeBSD.org>2017-11-04 21:35:36 +0000
committerDanilo G. Baio <dbaio@FreeBSD.org>2017-11-04 21:35:36 +0000
commitcb1fc942f32bec3e0ee70806ab568b46ff04b1ca (patch)
tree4af485768f5dd6c8c1807801a8f2a8e666bade24 /ftp/fastdfs
parent2ac724b87c9dc3c72a05ffcad63e5f658beda401 (diff)
downloadports-cb1fc942f32bec3e0ee70806ab568b46ff04b1ca.tar.gz
ports-cb1fc942f32bec3e0ee70806ab568b46ff04b1ca.zip
Notes
Diffstat (limited to 'ftp/fastdfs')
-rw-r--r--ftp/fastdfs/Makefile4
-rw-r--r--ftp/fastdfs/files/fdfs_status.in9
-rw-r--r--ftp/fastdfs/pkg-plist1
3 files changed, 14 insertions, 0 deletions
diff --git a/ftp/fastdfs/Makefile b/ftp/fastdfs/Makefile
index b56e985abc97..c50a2012c881 100644
--- a/ftp/fastdfs/Makefile
+++ b/ftp/fastdfs/Makefile
@@ -2,6 +2,7 @@
PORTNAME= fastdfs
PORTVERSION= 5.0.11
+PORTREVISION= 1
CATEGORIES= ftp
MAINTAINER= daniel@blodan.se
@@ -23,6 +24,8 @@ USE_GITHUB= yes
GH_ACCOUNT= happyfish100
GH_TAGNAME= 1e50b4f
+SUB_FILES= fdfs_status
+
MAKE_ENV+= DESTDIR=${STAGEDIR}
do-build:
@@ -33,5 +36,6 @@ do-install:
@${MKDIR} ${STAGEDIR}/var/db/fastdfs
@${MKDIR} ${STAGEDIR}/var/db/fastdfs/tracker
@${MKDIR} ${STAGEDIR}/var/db/fastdfs/storage
+ ${INSTALL_SCRIPT} ${WRKDIR}/fdfs_status ${STAGEDIR}${PREFIX}/bin
.include <bsd.port.mk>
diff --git a/ftp/fastdfs/files/fdfs_status.in b/ftp/fastdfs/files/fdfs_status.in
new file mode 100644
index 000000000000..b1e312e08812
--- /dev/null
+++ b/ftp/fastdfs/files/fdfs_status.in
@@ -0,0 +1,9 @@
+#!/bin/sh
+
+. /etc/rc.subr
+
+load_rc_config "fdfs_client"
+
+: ${fdfs_client_config="%%PREFIX%%/etc/fdfs/client.conf"}
+
+%%PREFIX%%/bin/fdfs_monitor ${fdfs_client_config}|grep -E 'Group|Storage|id|ip_addr|last_synced_timestamp'|grep -v 'trunk file'
diff --git a/ftp/fastdfs/pkg-plist b/ftp/fastdfs/pkg-plist
index e6589e3ad59f..89f9618ea16d 100644
--- a/ftp/fastdfs/pkg-plist
+++ b/ftp/fastdfs/pkg-plist
@@ -6,6 +6,7 @@ bin/fdfs_delete_file
bin/fdfs_download_file
bin/fdfs_file_info
bin/fdfs_monitor
+bin/fdfs_status
bin/fdfs_storaged
bin/fdfs_test
bin/fdfs_test1