aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--GIDs2
-rw-r--r--UIDs2
-rw-r--r--net-im/Makefile1
-rw-r--r--net-im/matterircd/Makefile36
-rw-r--r--net-im/matterircd/distinfo3
-rw-r--r--net-im/matterircd/files/matterircd.in42
-rw-r--r--net-im/matterircd/pkg-descr6
-rw-r--r--net-im/matterircd/pkg-plist2
8 files changed, 92 insertions, 2 deletions
diff --git a/GIDs b/GIDs
index 471c89cef75e..928efb2ad4b3 100644
--- a/GIDs
+++ b/GIDs
@@ -830,7 +830,7 @@ chronyd:*:849:
# free: 887
vuls:*:888:
mattermost:*:889:
-# free: 890
+matterircd:*:890:
# free: 891
# free: 892
# free: 893
diff --git a/UIDs b/UIDs
index 40afbda2f08c..f65331ea9bae 100644
--- a/UIDs
+++ b/UIDs
@@ -836,7 +836,7 @@ archiva:*:871:871::0:0:Apache Archiva Daemon:/nonexistent:/usr/sbin/nologin
# free: 887
vuls:*:888:888::0:0:VULnerability Scanner:/var/db/vuls:/usr/sbin/nologin
mattermost:*:889:889::0:0:Mattermost:/usr/local/www/mattermost:/usr/sbin/nologin
-# free: 890
+matterircd:*:890:890::0:0:Matterircd User:/nonexistent:/usr/sbin/nologin
# free: 891
# free: 892
# free: 893
diff --git a/net-im/Makefile b/net-im/Makefile
index 81ce92d97d72..881e0fe0795c 100644
--- a/net-im/Makefile
+++ b/net-im/Makefile
@@ -74,6 +74,7 @@
SUBDIR += linux-telegram-desktop
SUBDIR += loudmouth
SUBDIR += mastodon
+ SUBDIR += matterircd
SUBDIR += mbpurple
SUBDIR += mcabber
SUBDIR += meanwhile
diff --git a/net-im/matterircd/Makefile b/net-im/matterircd/Makefile
new file mode 100644
index 000000000000..473ea2d3c6b8
--- /dev/null
+++ b/net-im/matterircd/Makefile
@@ -0,0 +1,36 @@
+# $FreeBSD$
+
+PORTNAME= matterircd
+PORTVERSION= 0.16.7
+DISTVERSIONPREFIX= v
+CATEGORIES= net-im irc
+
+MAINTAINER= norrland@nullbyte.se
+COMMENT= IRC bridge for Mattermost and Slack
+
+LICENSE= MIT
+LICENSE_FILE= ${WRKSRC}/LICENSE
+
+ONLY_FOR_ARCHS= amd64 armv6 armv7 i386
+
+BUILD_DEPENDS= go>=1.8:lang/go
+
+USE_RC_SUBR= matterircd
+
+USE_GITHUB= yes
+GH_ACCOUNT= 42wim
+GH_SUBDIR= src/github.com/${GH_ACCOUNT}/${PORTNAME}
+
+USERS= matterircd
+GROUPS= matterircd
+
+do-build:
+ @cd ${WRKSRC}/${GH_SUBDIR} && \
+ ${SETENV} ${MAKE_ENV} GOPATH=${WRKSRC} go build
+
+do-install:
+ ${INSTALL_PROGRAM} ${WRKSRC}/matterircd ${STAGEDIR}${PREFIX}/bin
+ ${INSTALL_DATA} ${WRKSRC}/matterircd.toml.example \
+ ${STAGEDIR}${PREFIX}/etc/matterircd.toml.sample
+
+.include <bsd.port.mk>
diff --git a/net-im/matterircd/distinfo b/net-im/matterircd/distinfo
new file mode 100644
index 000000000000..f1726c02a07e
--- /dev/null
+++ b/net-im/matterircd/distinfo
@@ -0,0 +1,3 @@
+TIMESTAMP = 1522178987
+SHA256 (42wim-matterircd-v0.16.7_GH0.tar.gz) = 3f9ef394d79c36990a9fff4b809a974d6f0e401377c4fd182de46fa8aefc1ca8
+SIZE (42wim-matterircd-v0.16.7_GH0.tar.gz) = 1595920
diff --git a/net-im/matterircd/files/matterircd.in b/net-im/matterircd/files/matterircd.in
new file mode 100644
index 000000000000..f0ed4a24c0aa
--- /dev/null
+++ b/net-im/matterircd/files/matterircd.in
@@ -0,0 +1,42 @@
+#!/bin/sh
+#
+# $FreeBSD$
+#
+# PROVIDE: matterircd
+# REQUIRE: DAEMON NETWORKING
+# BEFORE: LOGIN
+# KEYWORD: shutdown
+#
+# Options to configure matterircd via /etc/rc.conf:
+#
+# matterircd_enable (bool) Enable service on boot
+# Default: NO
+#
+# matterircd_conf (str) Config file to use
+# Default: ${PREFIX}/etc/matterircd.toml
+#
+# matterircd_uid (str) User to run matterircd as
+# Default: matterircd
+#
+# matterircd_flags (str) Extra flags passed to matterircd
+#
+
+. /etc/rc.subr
+
+name="matterircd"
+rcvar="matterircd_enable"
+pidfile="/var/run/matterircd.pid"
+procname="%%PREFIX%%/bin/matterircd"
+
+load_rc_config $name
+
+: ${matterircd_enable:="NO"}
+: ${matterircd_uid:="matterircd"}
+: ${matterircd_flags:=""}
+: ${matterircd_conf:="%%PREFIX%%/etc/matterircd.toml"}
+: ${matterircd_options:="${matterircd_flags} -conf=${matterircd_conf}"}
+
+command="/usr/sbin/daemon"
+command_args="-p ${pidfile} -u ${matterircd_uid} -S -T ${name} ${procname} ${matterircd_options}"
+
+run_rc_command "$1"
diff --git a/net-im/matterircd/pkg-descr b/net-im/matterircd/pkg-descr
new file mode 100644
index 000000000000..b5ab5a553089
--- /dev/null
+++ b/net-im/matterircd/pkg-descr
@@ -0,0 +1,6 @@
+Minimal IRC server which integrates with Mattermost and Slack.
+
+Connect to your local/remote Mattermost installation or to Slack via your
+IRC-client.
+
+WWW: https://github.com/42wim/matterircd
diff --git a/net-im/matterircd/pkg-plist b/net-im/matterircd/pkg-plist
new file mode 100644
index 000000000000..e697e6b7568b
--- /dev/null
+++ b/net-im/matterircd/pkg-plist
@@ -0,0 +1,2 @@
+@sample etc/matterircd.toml.sample
+bin/matterircd