diff options
author | Yves Fischer <yvesf+git@xapek.org> | 2015-05-03 21:30:38 +0000 |
---|---|---|
committer | Charlie Root <root@db.2.localnet.cc> | 2015-05-03 21:31:19 +0000 |
commit | e3120d2ae02090f820f0b00f657c5fd80877a1a1 (patch) | |
tree | 320b2aaf6b7f9ff3c32cfec631a91b42cb25a120 /databases/influxdb | |
download | freebsd-ports-influxdb-e3120d2ae02090f820f0b00f657c5fd80877a1a1.tar.gz freebsd-ports-influxdb-e3120d2ae02090f820f0b00f657c5fd80877a1a1.zip |
add influxdb from cheffo/FreeBSD-Ports
Diffstat (limited to 'databases/influxdb')
-rw-r--r-- | databases/influxdb/Makefile | 125 | ||||
-rw-r--r-- | databases/influxdb/distinfo | 20 | ||||
-rw-r--r-- | databases/influxdb/files/influxd.in | 47 | ||||
-rw-r--r-- | databases/influxdb/pkg-descr | 13 | ||||
-rw-r--r-- | databases/influxdb/pkg-plist | 6 |
5 files changed, 211 insertions, 0 deletions
diff --git a/databases/influxdb/Makefile b/databases/influxdb/Makefile new file mode 100644 index 0000000..96dd864 --- /dev/null +++ b/databases/influxdb/Makefile @@ -0,0 +1,125 @@ +# $FreeBSD$ + +PORTNAME= influxdb +PORTVERSION= 0.9.0.r28 +CATEGORIES= databases net-mgmt +MASTER_SITES= GITHUB:github \ + https://codeload.github.com/BurntSushi/toml/legacy.tar.gz/${TOML_GH_COMMIT}?dummy=/:toml \ + https://codeload.github.com/bmizerany/pat/legacy.tar.gz/${PAT_GH_COMMIT}?dummy=/:pat \ + https://codeload.github.com/boltdb/bolt/legacy.tar.gz/${BOLT_GH_COMMIT}?dummy=/:bolt \ + https://codeload.github.com/kimor79/gollectd/legacy.tar.gz/${GOLLECTD_GH_COMMIT}?dummy=/:gollectd \ + https://codeload.github.com/peterh/liner/legacy.tar.gz/${LINER_GH_COMMIT}?dummy=/:liner \ + https://codeload.github.com/rakyll/statik/legacy.tar.gz/${STATIK_GH_COMMIT}?dummy=/:statik \ + https://codeload.github.com/alecthomas/log4go/legacy.tar.gz/${LOG4GO_GH_COMMIT}?dummy=/:log4go \ + https://codeload.github.com/cheffo/crypto/legacy.tar.gz/${GOCRYPTO_GH_COMMIT}?dummy=/:crypto \ + https://codeload.github.com/cheffo/go-uuid/legacy.tar.gz/${GO_UUID_GH_COMMIT}?dummy=/:uuid +DISTFILES= ${PORTNAME}-${DISTVERSION}${EXTRACT_SUFX}:github \ + BurntSushi-toml-${TOML_GH_COMMIT}.tar.gz:toml \ + bmizerany-pat-${PAT_GH_COMMIT}.tar.gz:pat \ + boltdb-bolt-${BOLT_GH_COMMIT}.tar.gz:bolt \ + kimor79-gollectd-${GOLLECTD_GH_COMMIT}.tar.gz:gollectd \ + peterh-liner-${LINER_GH_COMMIT}.tar.gz:liner \ + rakyll-statik-${STATIK_GH_COMMIT}.tar.gz:statik \ + alecthomas-log4go-${LOG4GO_GH_COMMIT}.tar.gz:log4go \ + cheffo-crypto-${GOCRYPTO_GH_COMMIT}.tar.gz:crypto \ + cheffo-go-uuid-${GO_UUID_GH_COMMIT}.tar.gz:uuid + +MAINTAINER= cheffo@freebsd-bg.org +COMMENT= Open-source distributed time series database + +LICENSE= MIT + +BUILD_DEPENDS= go>=1.4.0:${PORTSDIR}/lang/go \ + hg:${PORTSDIR}/devel/mercurial \ + git:${PORTSDIR}/devel/git + +ONLY_FOR_ARCHS= i386 amd64 + +USE_RC_SUBR= influxd + +USE_GITHUB= yes +GH_ACCOUNT= influxdb +GH_PROJECT= influxdb +GH_COMMIT= f50b2a0a98 +GH_TAGNAME= ${GH_COMMIT} + +TOML_GH_COMMIT= 443a628 +PAT_GH_COMMIT= b8a3500 +BOLT_GH_COMMIT= 550b8c7 +GOLLECTD_GH_COMMIT= 1d0fc88 +LINER_GH_COMMIT= 29f6a64 +STATIK_GH_COMMIT= 4a16c83 +LOG4GO_GH_COMMIT= 1bcc57d +GOCRYPTO_GH_COMMIT= 1351f93 +GO_UUID_GH_COMMIT= ed3ca8a + +SUB_FILES= influxd +SUB_LIST+= INFLUXD_USER=${INFLUXD_USER} \ + INFLUXD_GROUP=${INFLUXD_GROUP} \ + INFLUXD_DBDIR=${INFLUXD_DBDIR} \ + INFLUXD_PIDDIR=${INFLUXD_PIDDIR} \ + INFLUXD_LOGDIR=${INFLUXD_LOGDIR} + +PLIST_SUB= INFLUXD_USER=${INFLUXD_USER} \ + INFLUXD_GROUP=${INFLUXD_GROUP} \ + INFLUXD_DBDIR=${INFLUXD_DBDIR} \ + INFLUXD_PIDDIR=${INFLUXD_PIDDIR} \ + INFLUXD_LOGDIR=${INFLUXD_LOGDIR} + +INFLUXD_USER?= influxd +INFLUXD_GROUP?= influxd + +INFLUXD_DBDIR= /var/db/${PORTNAME}/ +INFLUXD_LOGDIR= /var/log/${PORTNAME}/ +INFLUXD_PIDDIR= /var/run/${PORTNAME}/ + +USERS= ${INFLUXD_USER} +GROUPS= ${INFLUXD_GROUP} + +STRIP= # stripping can break go binaries + +post-patch: + @${MKDIR} ${WRKDIR}/src/code.google.com/p + @${MKDIR} ${WRKDIR}/src/github.com/BurntSushi + @${MKDIR} ${WRKDIR}/src/github.com/bmizerany + @${MKDIR} ${WRKDIR}/src/github.com/boltdb + @${MKDIR} ${WRKDIR}/src/github.com/influxdb + @${MKDIR} ${WRKDIR}/src/github.com/kimor79 + @${MKDIR} ${WRKDIR}/src/github.com/peterh + @${MKDIR} ${WRKDIR}/src/github.com/rakyll + @${MKDIR} ${WRKDIR}/src/golang.org/x + @${MV} ${WRKDIR}/${GH_PROJECT}-${GH_COMMIT} ${WRKDIR}/src/github.com/${GH_ACCOUNT}/${GH_PROJECT} + @${MV} ${WRKDIR}/cheffo-go-uuid-${GO_UUID_GH_COMMIT} ${WRKDIR}/src/code.google.com/p/go-uuid + @${MV} ${WRKDIR}/alecthomas-log4go-${LOG4GO_GH_COMMIT} ${WRKDIR}/src/code.google.com/p/log4go + @${MV} ${WRKDIR}/BurntSushi-toml-${TOML_GH_COMMIT} ${WRKDIR}/src/github.com/BurntSushi/toml + @${MV} ${WRKDIR}/bmizerany-pat-${PAT_GH_COMMIT} ${WRKDIR}/src/github.com/bmizerany/pat + @${MV} ${WRKDIR}/boltdb-bolt-${BOLT_GH_COMMIT} ${WRKDIR}/src/github.com/boltdb/bolt + @${MV} ${WRKDIR}/kimor79-gollectd-${GOLLECTD_GH_COMMIT} ${WRKDIR}/src/github.com/kimor79/gollectd + @${MV} ${WRKDIR}/peterh-liner-${LINER_GH_COMMIT} ${WRKDIR}/src/github.com/peterh/liner + @${MV} ${WRKDIR}/rakyll-statik-${STATIK_GH_COMMIT} ${WRKDIR}/src/github.com/rakyll/statik + @${MV} ${WRKDIR}/cheffo-crypto-${GOCRYPTO_GH_COMMIT} ${WRKDIR}/src/golang.org/x/crypto + +do-build: + @cd ${WRKDIR}/src/github.com/influxdb/ && ${SETENV} ${GO_ENV} go get ./... + @cd ${WRKDIR}/src/github.com/influxdb/ && ${SETENV} ${GO_ENV} go build ./... + +do-install: + ${MKDIR} ${STAGEDIR}${INFLUXD_DBDIR} \ + ${STAGEDIR}${INFLUXD_PIDDIR} \ + ${STAGEDIR}${INFLUXD_LOGDIR} + +post-install: + ${INSTALL_PROGRAM} ${WRKDIR}/bin/influxd ${STAGEDIR}${PREFIX}/bin/influxd + ${INSTALL_PROGRAM} ${WRKDIR}/bin/influx ${STAGEDIR}${PREFIX}/bin/influx + @${SED} -i .bak -e \ + "s|/tmp/influxdb/development|/var/db/influxdb|g" \ + ${WRKDIR}/src/github.com/${GH_ACCOUNT}/${GH_PROJECT}/etc/config.sample.toml + ${INSTALL_DATA} \ + ${WRKDIR}/src/github.com/${GH_ACCOUNT}/${GH_PROJECT}/etc/config.sample.toml \ + ${STAGEDIR}${PREFIX}/etc/influxd.conf.sample + @${MKDIR} ${STAGEDIR}/var/db/influxdb + @${MKDIR} ${STAGEDIR}/var/log/influxdb + +.include <bsd.port.pre.mk> +.include "${.CURDIR}/../../lang/go/files/bsd.go.mk" +.include <bsd.port.post.mk> diff --git a/databases/influxdb/distinfo b/databases/influxdb/distinfo new file mode 100644 index 0000000..e607189 --- /dev/null +++ b/databases/influxdb/distinfo @@ -0,0 +1,20 @@ +SHA256 (influxdb-0.9.0.r28.tar.gz) = 24d4440a81e2440170008fc5a3e0546adfcda425327dcf995a208573937e65f5 +SIZE (influxdb-0.9.0.r28.tar.gz) = 2584274 +SHA256 (BurntSushi-toml-443a628.tar.gz) = 073fb7f4e978444fa14e7b3f0c3138762385d150414b91b7afc5680ec532e368 +SIZE (BurntSushi-toml-443a628.tar.gz) = 36602 +SHA256 (bmizerany-pat-b8a3500.tar.gz) = ca2c893110e6a0bf16ea5bac7ba9430d75605ddca3d32eb50baa4e085c4de17f +SIZE (bmizerany-pat-b8a3500.tar.gz) = 5211 +SHA256 (boltdb-bolt-550b8c7.tar.gz) = 1f8ee5912b410e89149e3c907eaafbd9acbd5ccc3abbc4078bd7b6854f84b75d +SIZE (boltdb-bolt-550b8c7.tar.gz) = 69190 +SHA256 (kimor79-gollectd-1d0fc88.tar.gz) = d95dc9cffbe84728d6c7a5d76feea2327af8a771a60329a7da92057329c8f03b +SIZE (kimor79-gollectd-1d0fc88.tar.gz) = 9338 +SHA256 (peterh-liner-29f6a64.tar.gz) = 63742324e99578659caea92918693cee7fe28b2c7b75d2e40cceb8479326db0a +SIZE (peterh-liner-29f6a64.tar.gz) = 16576 +SHA256 (rakyll-statik-4a16c83.tar.gz) = 6ac4c9fa02c442e588d4d240dbf8694a6cc1375356e88808cdea0255c1001435 +SIZE (rakyll-statik-4a16c83.tar.gz) = 77645 +SHA256 (alecthomas-log4go-1bcc57d.tar.gz) = 099a05acac36f9c9390aa3e5972a37f31907a501b47368a292831de573c6a626 +SIZE (alecthomas-log4go-1bcc57d.tar.gz) = 16203 +SHA256 (cheffo-crypto-1351f93.tar.gz) = 907f58e69a185a30f8020366720ff5c5fd9df53b5f3e35bf85a4b3cc4daaf838 +SIZE (cheffo-crypto-1351f93.tar.gz) = 860408 +SHA256 (cheffo-go-uuid-ed3ca8a.tar.gz) = 5cdfbc417d8f0a1030ad70aeca4c5cff40af0d64d5d4352b9b4fac0126f2946e +SIZE (cheffo-go-uuid-ed3ca8a.tar.gz) = 41029 diff --git a/databases/influxdb/files/influxd.in b/databases/influxdb/files/influxd.in new file mode 100644 index 0000000..75c693b --- /dev/null +++ b/databases/influxdb/files/influxd.in @@ -0,0 +1,47 @@ +#!/bin/sh +# $FreeBSD$ + +# PROVIDE: influxd +# REQUIRE: DAEMON NETWORKING +# BEFORE: LOGIN +# KEYWORD: shutdown + +# Add the following lines to /etc/rc.conf to enable influxdb: +# influxd_enable="YES" +# +# influxd_enable (bool): Set to YES to enable influxd +# Default: NO +# influxd_conf (str): influxd configuration file +# Default: ${PREFIX}/etc/influxd.conf +# influxd_user (str): influxd daemon user +# Default: influxd +# influxd_group (str): influxd daemon group +# Default: influxd +# influxd_flags (str): Extra flags passed to influxd + +. /etc/rc.subr + +name="influxd" +rcvar=influxd_enable + +: ${influxd_enable:="NO"} +: ${influxd_user:="%%INFLUXD_USER%%"} +: ${influxd_group:="%%INFLUXD_GROUP%%"} +: ${influxd_flags:=""} +: ${influxd_conf:="%%PREFIX%%/etc/${name}.conf"} +: ${influxd_options:="${influxdb_flags} -config=${influxd_conf}"} + +# daemon +influxd_pidfile="%%INFLUXD_PIDDIR%%${name}.pid" +procname="%%PREFIX%%/bin/${name}" +command=/usr/sbin/daemon +command_args=" -f -c -p ${influxd_pidfile} sh -c \\\"${procname} ${influxd_options} 2>&1| logger -t ${name}\\\"" +start_precmd="influxd_precmd" + +influxd_precmd() +{ + install -o ${influxd_user} /dev/null ${influxd_pidfile} +} + +load_rc_config $name +run_rc_command "$1" diff --git a/databases/influxdb/pkg-descr b/databases/influxdb/pkg-descr new file mode 100644 index 0000000..8cd9fca --- /dev/null +++ b/databases/influxdb/pkg-descr @@ -0,0 +1,13 @@ +An open-source, distributed, time series database with no external dependencies. +InfluxDB is the new home for all of your metrics, events, and analytics. + +InfluxDB is a time series, metrics, and analytics database. It'written in Go and +has no external dependencies. That means once you install it there's nothing +else to manage (like Redis, ZooKeeper, HBase, or whatever). + +InfluxDB is targeted at use cases for DevOps, metrics, sensor data, and +real-time analytics. It arose from our need for a database like this on more +than a few previous products we' built. You can read more about our jurney from +SaaS application to open source time series database. + +WWW: http://influxdb.com diff --git a/databases/influxdb/pkg-plist b/databases/influxdb/pkg-plist new file mode 100644 index 0000000..0edbca6 --- /dev/null +++ b/databases/influxdb/pkg-plist @@ -0,0 +1,6 @@ +bin/influx +bin/influxd +@dir(%%INFLUXD_USER%%,%%INFLUXD_GROUP%%,0750) %%INFLUXD_DBDIR%% +@dir(%%INFLUXD_USER%%,%%INFLUXD_GROUP%%,0750) %%INFLUXD_LOGDIR%% +@dir(%%INFLUXD_USER%%,%%INFLUXD_GROUP%%,0750) %%INFLUXD_PIDDIR%% +@sample etc/%%INFLUXD_USER%%.conf.sample |