aboutsummaryrefslogtreecommitdiff
path: root/sysutils/ipfs-go
diff options
context:
space:
mode:
authorWilliam Grzybowski <wg@FreeBSD.org>2015-09-24 17:18:13 +0000
committerWilliam Grzybowski <wg@FreeBSD.org>2015-09-24 17:18:13 +0000
commitf18c1f059b512cbfbe493dd4bd716be822060050 (patch)
treeabfba27ab36b4d744b8bf041a8ea03e8e7c8a862 /sysutils/ipfs-go
parent6d96b8e3fc962cbf35a26676efc673459ef0aa87 (diff)
downloadports-f18c1f059b512cbfbe493dd4bd716be822060050.tar.gz
ports-f18c1f059b512cbfbe493dd4bd716be822060050.zip
sysutils/ipfs-go: IPFS implementation in Go
IPFS is a global, versioned, peer-to-peer filesystem. It combines good ideas from Git, BitTorrent, Kademlia, SFS, and the Web. It is like a single bittorrent swarm, exchanging git objects. IPFS provides an interface as simple as the HTTP web, but with permanence built in. WWW: https://github.com/ipfs/go-ipfs
Notes
Notes: svn path=/head/; revision=397699
Diffstat (limited to 'sysutils/ipfs-go')
-rw-r--r--sysutils/ipfs-go/Makefile41
-rw-r--r--sysutils/ipfs-go/distinfo6
-rw-r--r--sysutils/ipfs-go/files/ipfs-go.in38
-rw-r--r--sysutils/ipfs-go/pkg-descr6
4 files changed, 91 insertions, 0 deletions
diff --git a/sysutils/ipfs-go/Makefile b/sysutils/ipfs-go/Makefile
new file mode 100644
index 000000000000..209c03c45e6c
--- /dev/null
+++ b/sysutils/ipfs-go/Makefile
@@ -0,0 +1,41 @@
+# $FreeBSD$
+
+PORTNAME= ipfs-go
+PORTVERSION= 0.3.7
+DISTVERSIONPREFIX= v
+CATEGORIES= sysutils
+
+MAINTAINER= wg@FreeBSD.org
+COMMENT= IPFS implementation in Go
+
+BUILD_DEPENDS= ${LOCALBASE}/bin/go:${PORTSDIR}/lang/go
+
+USES= gmake
+
+USE_GITHUB= yes
+GH_ACCOUNT= ipfs
+GH_PROJECT= go-ipfs
+
+MAKE_ENV+= GOPATH=${WRKSRC}
+
+PLIST_FILES= bin/${PORTNAME}
+
+USE_RC_SUBR= ${PORTNAME}
+
+STRIP= # stripping can break go binaries
+
+# Prepare for possible extra modules in future
+post-extract:
+ @${MKDIR} ${WRKSRC}/src/github.com/${GH_ACCOUNT}/${GH_PROJECT}
+.for src in CHANGELOG.md Dockerfile Godeps LICENSE Makefile README.md assets bin blocks blockservice circle.yml cmd commands core dev dev.md diagnostics doc.go docs exchange fuse importer ipnsfs jenkins merkledag metrics misc namesys notifications p2p path pin repo routing test thirdparty tour unixfs updates util
+ ${MV} ${WRKSRC}/${src} \
+ ${WRKSRC}/src/github.com/ipfs/${GH_PROJECT}
+.endfor
+
+do-build:
+ cd ${WRKSRC}/src/github.com/${GH_ACCOUNT}/${GH_PROJECT}; ${SETENV} ${MAKE_ENV} ${MAKE_CMD} build
+
+do-install:
+ ${INSTALL_PROGRAM} ${WRKSRC}/src/github.com/${GH_ACCOUNT}/${GH_PROJECT}/cmd/ipfs/ipfs ${STAGEDIR}${PREFIX}/bin/${PORTNAME}
+
+.include <bsd.port.mk>
diff --git a/sysutils/ipfs-go/distinfo b/sysutils/ipfs-go/distinfo
new file mode 100644
index 000000000000..67e76f75481e
--- /dev/null
+++ b/sysutils/ipfs-go/distinfo
@@ -0,0 +1,6 @@
+SHA256 (ipfs-go-ipfs-v0.3.7_GH0.tar.gz) = 4f811ff9a949162513585a073b97973029788561eace2f8b956884af968f717d
+SIZE (ipfs-go-ipfs-v0.3.7_GH0.tar.gz) = 2500872
+SHA256 (golang-crypto-74f810a_GH0.tar.gz) = 25e0c9cb7c6d6a5935aa318c9792fa6e18c8e0238994b5be039f90c8d58fd680
+SIZE (golang-crypto-74f810a_GH0.tar.gz) = 864642
+SHA256 (codahale-metrics-7c37910_GH0.tar.gz) = 6d8da9cd2be5f02afadbd12154a6ebdd5a79bc3dd2904339b017db3cd7607492
+SIZE (codahale-metrics-7c37910_GH0.tar.gz) = 5282
diff --git a/sysutils/ipfs-go/files/ipfs-go.in b/sysutils/ipfs-go/files/ipfs-go.in
new file mode 100644
index 000000000000..3f0badeb0a33
--- /dev/null
+++ b/sysutils/ipfs-go/files/ipfs-go.in
@@ -0,0 +1,38 @@
+#!/bin/sh
+#
+# $FreeBSD$
+#
+
+# PROVIDE: ipfs_go
+# REQUIRE: NETWORKING
+# BEFORE: LOGIN
+# KEYWORD: shutdown
+
+# Define these ipfs_go_* variables in /etc/rc.conf[.local]:
+#
+# ipfs_go_enable="YES"
+# ipfs_go_path="/tank/ipfs"
+
+. /etc/rc.subr
+
+ipfs_go_enable=${exp_ipfs_enable-"NO"}
+ipfs_go_path="/var/db/ipfs"
+
+name=ipfs_go
+rcvar=ipfs_go_enable
+command="%%PREFIX%%/bin/ipfs-go"
+
+start_precmd="ipfs_go_prestart"
+start_cmd="ipfs_go_start"
+
+ipfs_go_prestart() {
+ [ -d ${ipfs_go_path}/datastore ] || env IPFS_PATH=${ipfs_go_path} ${command} init
+}
+
+ipfs_go_start() {
+ echo running ${command} daemon
+ env IPFS_PATH=${ipfs_go_path} daemon -f ${command} daemon
+}
+
+load_rc_config $name
+run_rc_command "$1"
diff --git a/sysutils/ipfs-go/pkg-descr b/sysutils/ipfs-go/pkg-descr
new file mode 100644
index 000000000000..e0159748fbce
--- /dev/null
+++ b/sysutils/ipfs-go/pkg-descr
@@ -0,0 +1,6 @@
+IPFS is a global, versioned, peer-to-peer filesystem. It combines good ideas
+from Git, BitTorrent, Kademlia, SFS, and the Web. It is like a single
+bittorrent swarm, exchanging git objects. IPFS provides an interface as simple
+as the HTTP web, but with permanence built in.
+
+WWW: https://github.com/ipfs/go-ipfs