Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 2 Feb 2018 08:50:35 +0000 (UTC)
From:      Olivier Cochard <olivier@FreeBSD.org>
To:        ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org
Subject:   svn commit: r460678 - in head/www: . mattermost-server mattermost-server/files
Message-ID:  <201802020850.w128oZT6028452@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: olivier
Date: Fri Feb  2 08:50:34 2018
New Revision: 460678
URL: https://svnweb.freebsd.org/changeset/ports/460678

Log:
  Add new port: www/mattermost-server
  
  Open source Slack-alternative in Golang and React
  
  PR:		225413
  Submitted by:	loic.blot@unix-experience.fr

Added:
  head/www/mattermost-server/
  head/www/mattermost-server/Makefile   (contents, props changed)
  head/www/mattermost-server/distinfo   (contents, props changed)
  head/www/mattermost-server/files/
  head/www/mattermost-server/files/mattermostd.in   (contents, props changed)
  head/www/mattermost-server/pkg-descr   (contents, props changed)
  head/www/mattermost-server/pkg-plist   (contents, props changed)
Modified:
  head/www/Makefile

Modified: head/www/Makefile
==============================================================================
--- head/www/Makefile	Fri Feb  2 08:39:46 2018	(r460677)
+++ head/www/Makefile	Fri Feb  2 08:50:34 2018	(r460678)
@@ -395,6 +395,7 @@
     SUBDIR += man2web
     SUBDIR += mathjax
     SUBDIR += mathopd
+    SUBDIR += mattermost-server
     SUBDIR += mattermost-webapp
     SUBDIR += mediawiki123
     SUBDIR += mediawiki127

Added: head/www/mattermost-server/Makefile
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/www/mattermost-server/Makefile	Fri Feb  2 08:50:34 2018	(r460678)
@@ -0,0 +1,57 @@
+# $FreeBSD$
+
+PORTNAME=	mattermost-server
+PORTVERSION=	4.6.0
+DISTVERSIONPREFIX=	v
+CATEGORIES=	www
+
+MAINTAINER=	loic.blot@unix-experience.fr
+COMMENT=	Open source Slack-alternative in Golang and React
+
+LICENSE=	MIT
+LICENSE_FILE=	${WRKSRC}/LICENSE.txt
+
+ONLY_FOR_ARCHS=	amd64 armv6 armv7 i386
+
+BUILD_DEPENDS=	go>=1.8.1:lang/go
+RUN_DEPENDS=	${LOCALBASE}/share/certs/ca-root-nss.crt:security/ca_root_nss \
+		mattermost-webapp>=${PORTVERSION}:www/mattermost-webapp
+
+GO_LDFLAGS=	-X github.com/mattermost/mattermost-server/model.BuildNumber=${PORTVERSION}
+
+USE_RC_SUBR=	mattermostd
+
+USE_GITHUB=	yes
+GH_ACCOUNT=	mattermost:DEFAULT
+
+WWWDIR=		${PREFIX}/www/mattermost
+
+MATTERMOSTD_USER=	mattermost
+MATTERMOSTD_GROUP=	mattermost
+
+USERS=		${MATTERMOSTD_USER}
+GROUPS=		${MATTERMOSTD_GROUP}
+
+.include <bsd.port.pre.mk>
+
+pre-build:
+	@${MKDIR} ${WRKSRC}/src/github.com/${GH_ACCOUNT_DEFAULT}/${PORTNAME}
+	@cd ${WRKSRC} && \
+		${MV} api api4 app cmd doc einterfaces imports jobs manualtesting \
+		model plugin store utils web wsapi vendor \
+		${WRKSRC}/src/github.com/${GH_ACCOUNT_DEFAULT}/${PORTNAME}
+
+do-build:
+	@cd ${WRKSRC}/src/github.com/${GH_ACCOUNT_DEFAULT}/${GH_PROJECT} && \
+		${SETENV} GOPATH=${WRKSRC} go install -ldflags="${GO_LDFLAGS}" ./...
+
+do-install:
+	${INSTALL_PROGRAM} ${WRKSRC}/bin/platform ${STAGEDIR}${PREFIX}/bin/mattermostd
+	${MKDIR} ${STAGEDIR}${PREFIX}/etc/mattermost
+	${CP} ${WRKSRC}/config/default.json ${STAGEDIR}${PREFIX}/etc/mattermost/config.json.sample
+	${MKDIR} ${STAGEDIR}${WWWDIR}
+	${CP} -R ${WRKSRC}/fonts ${STAGEDIR}${WWWDIR}
+	${CP} -R ${WRKSRC}/i18n ${STAGEDIR}${WWWDIR}
+	${CP} -R ${WRKSRC}/templates ${STAGEDIR}${WWWDIR}
+
+.include <bsd.port.post.mk>

Added: head/www/mattermost-server/distinfo
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/www/mattermost-server/distinfo	Fri Feb  2 08:50:34 2018	(r460678)
@@ -0,0 +1,3 @@
+TIMESTAMP = 1516745059
+SHA256 (mattermost-mattermost-server-v4.6.0_GH0.tar.gz) = 89177a57c9a26b1a9e8c26b17846d15af21c1b7aca4d6fc0ffe475650de37496
+SIZE (mattermost-mattermost-server-v4.6.0_GH0.tar.gz) = 52906052

Added: head/www/mattermost-server/files/mattermostd.in
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/www/mattermost-server/files/mattermostd.in	Fri Feb  2 08:50:34 2018	(r460678)
@@ -0,0 +1,56 @@
+#!/bin/sh
+# $FreeBSD$
+
+# PROVIDE: mattermostd
+# REQUIRE: DAEMON NETWORKING
+# BEFORE: LOGIN
+# KEYWORD: shutdown
+
+# Add the following lines to /etc/rc.conf to enable mattermostdb:
+# mattermostd_enable="YES"
+#
+# mattermostd_enable (bool):	Set to YES to enable influxd
+#				Default: NO
+# mattermostd_conf (str):		influxd configuration file
+#				Default: ${PREFIX}/etc/mattermostd.conf
+# mattermostd_user (str):		influxd daemon user
+#				Default: mattermostd
+# mattermostd_group (str):		influxd daemon group
+#				Default: mattermostd
+# mattermostd_flags (str):		Extra flags passed to influxd
+#
+# mattermostd_facility (str):       Syslog facility to use
+#                               Default: daemon
+# mattermostd_priority (str):       Syslog priority to use
+#                               Default: info
+
+. /etc/rc.subr
+
+name="mattermostd"
+rcvar=mattermostd_enable
+load_rc_config $name
+
+: ${mattermostd_enable:="NO"}
+: ${mattermostd_user:="mattermost"}
+: ${mattermostd_group:="mattermost"}
+: ${mattermostd_flags:="--disableconfigwatch"}
+: ${mattermostd_facility:="daemon"}
+: ${mattermostd_priority:="info"}
+: ${mattermostd_conf:="%%PREFIX%%/etc/mattermost/config.json"}
+: ${mattermostd_options:="${mattermostd_flags} --config=${mattermostd_conf}"}
+
+# daemon
+mattermostd_pidfile="/var/run/${name}.pid"
+procname="%%PREFIX%%/bin/${name}"
+command=/usr/sbin/daemon
+start_cmd="mattermostd_startcmd_daemon"
+
+mattermostd_startcmd_daemon()
+{
+    echo "Starting ${name}."
+    cd /usr/local/www/mattermost && \
+        /usr/sbin/daemon -p ${mattermostd_pidfile} -S -s ${mattermostd_priority} -l ${mattermostd_facility} \
+       	-u ${mattermostd_user} ${procname} ${mattermostd_options}
+}
+
+run_rc_command "$1"

Added: head/www/mattermost-server/pkg-descr
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/www/mattermost-server/pkg-descr	Fri Feb  2 08:50:34 2018	(r460678)
@@ -0,0 +1,5 @@
+Mattermost is an open source, private cloud, Slack-alternative.
+It's written in Golang and React and runs as a single Linux binary with MySQL
+or PostgreSQL.
+
+WWW: https://mattermost.org/

Added: head/www/mattermost-server/pkg-plist
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/www/mattermost-server/pkg-plist	Fri Feb  2 08:50:34 2018	(r460678)
@@ -0,0 +1,37 @@
+bin/mattermostd
+etc/mattermost/config.json.sample
+%%WWWDIR%%/fonts/luximbi.ttf
+%%WWWDIR%%/i18n/de.json
+%%WWWDIR%%/i18n/en.json
+%%WWWDIR%%/i18n/es.json
+%%WWWDIR%%/i18n/fr.json
+%%WWWDIR%%/i18n/it.json
+%%WWWDIR%%/i18n/ja.json
+%%WWWDIR%%/i18n/ko.json
+%%WWWDIR%%/i18n/nl.json
+%%WWWDIR%%/i18n/pl.json
+%%WWWDIR%%/i18n/pt-BR.json
+%%WWWDIR%%/i18n/ru.json
+%%WWWDIR%%/i18n/tr.json
+%%WWWDIR%%/i18n/zh-CN.json
+%%WWWDIR%%/i18n/zh-TW.json
+%%WWWDIR%%/templates/email_change_body.html
+%%WWWDIR%%/templates/username_change_body.html
+%%WWWDIR%%/templates/invite_body.html
+%%WWWDIR%%/templates/email_info.html
+%%WWWDIR%%/templates/post_body_full.html
+%%WWWDIR%%/templates/email_change_verify_body.html
+%%WWWDIR%%/templates/reset_body.html
+%%WWWDIR%%/templates/signin_change_body.html
+%%WWWDIR%%/templates/verify_body.html
+%%WWWDIR%%/templates/signup_team_body.html
+%%WWWDIR%%/templates/unsupported_browser.html
+%%WWWDIR%%/templates/post_batched_body.html
+%%WWWDIR%%/templates/post_body_generic.html
+%%WWWDIR%%/templates/mfa_change_body.html
+%%WWWDIR%%/templates/password_change_body.html
+%%WWWDIR%%/templates/email_footer.html
+%%WWWDIR%%/templates/post_batched_post_generic.html
+%%WWWDIR%%/templates/welcome_body.html
+%%WWWDIR%%/templates/upgrade_30_body.html
+%%WWWDIR%%/templates/post_batched_post_full.html



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