diff options
author | V3n3RiX <venerix@redcorelinux.org> | 2020-02-17 01:16:38 +0000 |
---|---|---|
committer | V3n3RiX <venerix@redcorelinux.org> | 2020-02-17 01:16:38 +0000 |
commit | 53cba99042fa967e2a93da9f8db806fe2d035543 (patch) | |
tree | 9780d3b87dfc6bdebc6b7b7d15af1ecb813c6853 /net-p2p/go-ipfs | |
parent | 71deace00d1a2b091313fe137ab7092418c6f87c (diff) |
gentoo resync : 17.02.2020
Diffstat (limited to 'net-p2p/go-ipfs')
-rw-r--r-- | net-p2p/go-ipfs/Manifest | 8 | ||||
-rw-r--r-- | net-p2p/go-ipfs/files/ipfs-at.service | 18 | ||||
-rw-r--r-- | net-p2p/go-ipfs/files/ipfs.confd | 1 | ||||
-rw-r--r-- | net-p2p/go-ipfs/files/ipfs.init | 17 | ||||
-rw-r--r-- | net-p2p/go-ipfs/files/ipfs.service | 19 | ||||
-rw-r--r-- | net-p2p/go-ipfs/go-ipfs-0.4.23.ebuild | 69 | ||||
-rw-r--r-- | net-p2p/go-ipfs/metadata.xml | 12 |
7 files changed, 144 insertions, 0 deletions
diff --git a/net-p2p/go-ipfs/Manifest b/net-p2p/go-ipfs/Manifest new file mode 100644 index 000000000000..071cb6d43d67 --- /dev/null +++ b/net-p2p/go-ipfs/Manifest @@ -0,0 +1,8 @@ +AUX ipfs-at.service 340 BLAKE2B 776676603baa61cc2b76de86d8b3b1b43810ed81a703f827d5ad095824235870b73ddd4096f1e747ad6d872774fc38e2750792b5c516072cafa82fdcf275426a SHA512 90ff078ca99ef3815318e7b34be31df8531c449687e6fcc36e73ca0671b294ed8cfec922d98b8416a4410c33f587231722b483a2ab3c9e1de47e367fd37f807b +AUX ipfs.confd 30 BLAKE2B 7ecaa40f2a4097690f9d8091da5891e0bbfb0f298bed4a59769c8d0ef978a2471865a01177950da5869b61f3b8c124f43eab97daf297c06efecdc25785a5846d SHA512 c55afeb3efe381d18258ddf00f58325b77156375cf223fb2daa049df056efe22e9139cce0f81dc4c73759dad5097af5f3201414beb5950bd894df9ae8c7c4ed1 +AUX ipfs.init 461 BLAKE2B e2887e774ff5b805842c59812cb49102d3722d7cde56a2e3594c2d3d3c156f673460e371247c41657ac2e39ba169b743823bfdc58f30cb64342bcfb18a84fad8 SHA512 102b1f39dc52358593ec6a156fd11e20a47f4a52eb8e3899db1df134e07133b147c9f83b3601b5dadbdeae2db3e967fb03c8d728e8d146f6b748446110468685 +AUX ipfs.service 372 BLAKE2B 8989cc474ab46309dda6d167fb89476b01d10e07374d53c480a7ee345f13827e25ca19d84b0a3974e45c5d9a0c78abdfd7be262bff48f427aedaac2a9c4094a8 SHA512 35d5edda83bd296f92ffe3ee61f2608eb9ec464225e32ca52582d8e8fe699466c9b412ed224ff44e36e34d3d41a618d50082dd677feeaba53429d3a6913a869a +DIST go-ipfs-0.4.23.bash 20753 BLAKE2B c34d29a48cf249b7a646a8a7b6015b9c4a4a5d8656187ec5984b0dfb741a8ca7b2f2d0a10bc0288aa862679c6d52145936b46497936565ba7cdb2ba847fda5b8 SHA512 acd3bdb689964aa5e15965bfea3cd1267f54a2014c05f49f4e536902cbdab3e22038f4f5db5ecc273c147135b265fcb82a41db22bfc3fd8f6ddc8ae43fd053ea +DIST go-ipfs-0.4.23.tar.gz 9415138 BLAKE2B 20f9aa246e2170fd8438fbb98ee92a4b1657f1d3e059530cc8e0a1d98a84ea7bdf5de97980f7b345110bcdbd7ed999a5d814c12eaa051aecc28d2d0a47f88272 SHA512 d87513392336fc537bf9c8578d34d650482001c37c1636d64f68fe5d5291c21990c72286c26f43cb6bc2c9c9df14bae69996b60ad6744f335276d52b0cb6978e +EBUILD go-ipfs-0.4.23.ebuild 1609 BLAKE2B 0d0343f647cc769de8fcd49947da79bc6c2a6a2df2a8cd4afdc2ad27d4776eef2012cba7feb64256e3d96f8d5a6967ea0e5ef6bfa04d6fb955752d9f80c2cd72 SHA512 20a174741064170b164e6e75a15664233414a3167cf39d49034b3afc760d0eac6ac7f033155c93e76acf050b1b1bff76fe5b8308c865c8e1ac6820d1437988cd +MISC metadata.xml 366 BLAKE2B 5241e8eccd804117b97d239ac7ac9688090d6f417465976c31edb72780288ef9ce725126e2c8d5483c220de9ffb4bc863102e9342a0b1d48cb780d401a32eb3d SHA512 5b748222be57a2754237bd77677cde457e5b43a87b6ddc0cf05903e1e7121f0c6e0ef260ce4c9f46ceeacbcd69b1150a29e48c562d1bb09ecfb5a6029d3e99cc diff --git a/net-p2p/go-ipfs/files/ipfs-at.service b/net-p2p/go-ipfs/files/ipfs-at.service new file mode 100644 index 000000000000..c9ce91294177 --- /dev/null +++ b/net-p2p/go-ipfs/files/ipfs-at.service @@ -0,0 +1,18 @@ +[Unit] +Description=InterPlanetary File System +After=network.target + +[Service] +CPUSchedulingPolicy=batch +Environment=IPFS_PATH= +ExecStart=/usr/bin/ipfs daemon --enable-gc --migrate +ExecStop=/usr/bin/ipfs shutdown +LimitNOFILE=8192 +PrivateTmp=yes +ProtectSystem=full +Restart=on-failure +Type=simple +User=%i + +[Install] +WantedBy=multi-user.target diff --git a/net-p2p/go-ipfs/files/ipfs.confd b/net-p2p/go-ipfs/files/ipfs.confd new file mode 100644 index 000000000000..f1e8eb77adf5 --- /dev/null +++ b/net-p2p/go-ipfs/files/ipfs.confd @@ -0,0 +1 @@ +IPFS_PATH=/var/lib/ipfs/.ipfs diff --git a/net-p2p/go-ipfs/files/ipfs.init b/net-p2p/go-ipfs/files/ipfs.init new file mode 100644 index 000000000000..52f48c52d1cd --- /dev/null +++ b/net-p2p/go-ipfs/files/ipfs.init @@ -0,0 +1,17 @@ +#!/sbin/openrc-run +# Copyright 1999-2020 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +export IPFS_PATH=${IPFS_PATH:-/var/lib/ipfs/.ipfs} + +pidfile="/run/ipfs.pid" +command="/usr/bin/ipfs" +command_args="daemon --enable-gc --migrate" +command_user="ipfs:ipfs" +start_stop_daemon_args="--wait 1000 -b \ + -1 /var/log/ipfs/ipfs.log \ + -2 /var/log/ipfs/ipfs.log" + +depend() { + need net +} diff --git a/net-p2p/go-ipfs/files/ipfs.service b/net-p2p/go-ipfs/files/ipfs.service new file mode 100644 index 000000000000..12e9d19fd965 --- /dev/null +++ b/net-p2p/go-ipfs/files/ipfs.service @@ -0,0 +1,19 @@ +[Unit] +Description=InterPlanetary File System +After=network.target + +[Service] +CPUSchedulingPolicy=batch +Environment=IPFS_PATH=/var/lib/ipfs/.ipfs +ExecStart=/usr/bin/ipfs daemon --enable-gc --migrate +ExecStop=/usr/bin/ipfs shutdown +Group=ipfs +LimitNOFILE=8192 +PrivateTmp=yes +ProtectSystem=full +Restart=on-failure +Type=simple +User=ipfs + +[Install] +WantedBy=multi-user.target diff --git a/net-p2p/go-ipfs/go-ipfs-0.4.23.ebuild b/net-p2p/go-ipfs/go-ipfs-0.4.23.ebuild new file mode 100644 index 000000000000..4b2936e8a480 --- /dev/null +++ b/net-p2p/go-ipfs/go-ipfs-0.4.23.ebuild @@ -0,0 +1,69 @@ +# Copyright 1999-2020 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=7 + +inherit bash-completion-r1 go-module golang-build systemd + +DESCRIPTION="Main implementation of IPFS" +HOMEPAGE="https://ipfs.io/" +SRC_URI="https://dist.ipfs.io/go-ipfs/v${PV}/go-ipfs-source.tar.gz -> ${P}.tar.gz + https://raw.githubusercontent.com/ipfs/go-ipfs/v${PV}/misc/completion/ipfs-completion.bash -> ${P}.bash" +EGO_PN="github.com/ipfs/go-ipfs" + +LICENSE="Apache-2.0 BSD BSD-2 CC0-1.0 ISC MIT MPL-2.0" +SLOT="0" +KEYWORDS="~amd64 ~x86" + +RDEPEND=" + !net-p2p/go-ipfs-bin + acct-group/ipfs + acct-user/ipfs + sys-fs/fuse:0 +" + +S="${WORKDIR}" + +DOCS=(CHANGELOG.md CONTRIBUTING.md README.md docs/) + +src_compile() { + local mygoargs=( + -v + -work + -x + -tags release + ) + + go build "${mygoargs[@]}" -o ipfs ${EGO_PN}/cmd/ipfs || die + go build "${mygoargs[@]}" -o ipfswatch ${EGO_PN}/cmd/ipfswatch || die +} + +src_test() { + go test ${EGO_PN}/cmd/ipfs/... ${EGO_PN}/cmd/ipfswatch/... || die +} + +src_install() { + dobin ipfs + dobin ipfswatch + + einstalldocs + + systemd_dounit "${FILESDIR}/ipfs.service" + systemd_newunit "${FILESDIR}/ipfs-at.service" "ipfs@.service" + + newinitd "${FILESDIR}/ipfs.init" ipfs + newconfd "${FILESDIR}/ipfs.confd" ipfs + + newbashcomp "${DISTDIR}/${P}.bash" "ipfs" + keepdir /var/log/ipfs +} + +pkg_preinst() { + fowners -R ipfs:ipfs /var/log/ipfs +} + +pkg_postinst() { + elog 'To be able to use the ipfs service you will need to create the ipfs repository' + elog '(eg: su -s /bin/sh -c "ipfs init -e" ipfs)' + elog 'or change IPFS_PATH of /etc/conf.d/ipfs with another with proper permissions.' +} diff --git a/net-p2p/go-ipfs/metadata.xml b/net-p2p/go-ipfs/metadata.xml new file mode 100644 index 000000000000..b69fe2e3c4ab --- /dev/null +++ b/net-p2p/go-ipfs/metadata.xml @@ -0,0 +1,12 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd"> +<pkgmetadata> + <maintainer type="person"> + <email>davidroman96@gmail.com</email> + <name>David Roman</name> + </maintainer> + <maintainer type="project"> + <email>proxy-maint@gentoo.org</email> + <name>Proxy Maintainers</name> + </maintainer> +</pkgmetadata> |