diff options
Diffstat (limited to 'app-admin/vault')
-rw-r--r-- | app-admin/vault/Manifest | 2 | ||||
-rw-r--r-- | app-admin/vault/vault-1.6.1.ebuild | 78 |
2 files changed, 80 insertions, 0 deletions
diff --git a/app-admin/vault/Manifest b/app-admin/vault/Manifest index eb90f0f8783b..6e6580391901 100644 --- a/app-admin/vault/Manifest +++ b/app-admin/vault/Manifest @@ -6,3 +6,5 @@ DIST vault-1.5.6-webui.tar.xz 1237168 BLAKE2B 997a3ef1e297e288d2abf14647667fd07e DIST vault-1.5.6.tar.gz 35110596 BLAKE2B 6e2581b82dfc98f0fd4c807dd24c9e17b4e4c3252ab5744388e17a076d8ed613ea2360f8bf5b975ee5b15d6c7f96100f2b814e290ab47e33c565525ffe1eeda3 SHA512 1da2a6f1307583f03298a4199d301536783787ae1d9b16a8b0a4cce55d29a1fd8a1631366a55aa4671d5b7f6fb9108ffe55d9ec9575e887e495a512b00cf9cb3 DIST vault-1.6.0-webui.tar.xz 1272792 BLAKE2B cef45043b7ca26de774e17a994f35a3c52b796c94b75b9377300f8755bb4c0d8814147d740e07be8d5dd5f909051adf7fb05be29b1ca1e1db349a0c3977ec034 SHA512 3b13687f7f0f475513152544ae423914520d0bcd9c0ea4295277f326002048707adfdf5ac405561ddb415affb842952409d6586ef19c7faca37d87aee973337a DIST vault-1.6.0.tar.gz 38888893 BLAKE2B e6da6ba813625a2a00553181e5d16bb52510856d9ad4e1538b824b5f87b2beb6c8d19f60b274e68d9521210c72dbd93cb63ba73175d079b43b03b48fefd1e1be SHA512 f9a99c29de585031c00b7f0a2125f61df1cb0a15ab0aa04e3cca950bdd23a4055dd3764561594730e62a1b3ae4d13e66df30032bf2b1000063edc4f772a8146d +DIST vault-1.6.1-webui.tar.xz 1277456 BLAKE2B 7a63f676e4138c9ac0a9e550f5c195a68169c9214c4f232368356ed31e6a873242f069291fa6f56770bd84598333b9d9933da8544651836b04cf91b9c0d6e818 SHA512 0ce4fc98c8134d9ce39ce0bf7634b76cad8508d3f19480f32052dd6040a299b80406586d5c7c6d9571a4cced303dbab010b0761599c0fc4fe0d0556365564dc4 +DIST vault-1.6.1.tar.gz 39080880 BLAKE2B a66f48c0e7a4edbe9765f7f3e9349ee318415d42ebac9763d48fed4060a3a81613246528339e5cce091dc3ba3ad70062dc5e3b13fce29611a37729a81cf31bc7 SHA512 3dd272b5ca6b2858ab9c65a1abcf25bfd01d554c8f8c380ab1384c216bf14f9719ae0947f764cd7a08688899b7e5805e3ce2a96086772035abe54012b5f4ea72 diff --git a/app-admin/vault/vault-1.6.1.ebuild b/app-admin/vault/vault-1.6.1.ebuild new file mode 100644 index 000000000000..d339b69b89e5 --- /dev/null +++ b/app-admin/vault/vault-1.6.1.ebuild @@ -0,0 +1,78 @@ +# Copyright 1999-2020 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=7 + +inherit fcaps go-module systemd + +DESCRIPTION="A tool for managing secrets" +HOMEPAGE="https://vaultproject.io/" +VAULT_WEBUI_ARCHIVE="${P}-webui.tar.xz" +SRC_URI="https://github.com/hashicorp/vault/archive/v${PV}.tar.gz -> ${P}.tar.gz + webui? ( + https://dev.gentoo.org/~zmedico/dist/${VAULT_WEBUI_ARCHIVE} + )" + +LICENSE="MPL-2.0 Apache-2.0 BSD BSD-2 CC-BY-SA-4.0 ISC MIT" +SLOT="0" +KEYWORDS="~amd64" +IUSE="+webui" + +BDEPEND="dev-go/gox + >=dev-lang/go-1.15.3" +COMMON_DEPEND="acct-group/vault + acct-user/vault" + DEPEND="${COMMON_DEPEND}" + RDEPEND="${COMMON_DEPEND}" + +FILECAPS=( + -m 755 'cap_ipc_lock=+ep' usr/bin/${PN} +) + +RESTRICT+=" test" + +src_prepare() { + default + # Avoid the need to have a git checkout + sed -e 's:^\(GIT_COMMIT=\).*:\1:' \ + -e 's:^\(GIT_DIRTY=\).*:\1:' \ + -e s:\'\${GIT_COMMIT}\${GIT_DIRTY}\':: \ + -i scripts/build.sh || die + sed -e "/hooks/d" \ + -e 's|^\([[:space:]]*\)goimports .*)|\1true|' \ + -i Makefile || die + if [[ -f "${WORKDIR}/http/bindata_assetfs.go" ]]; then + mv "${WORKDIR}/http/bindata_assetfs.go" "${S}/http" || + die "mv failed" + fi +} + +src_compile() { + mkdir "${T}"/bin || die + BUILD_TAGS="$(usex webui ui '')" \ + GOFLAGS="-mod=vendor" \ + GOPATH="${T}" \ + XC_ARCH=$(go env GOARCH) \ + XC_OS=$(go env GOOS) \ + XC_OSARCH=$(go env GOOS)/$(go env GOARCH) \ + emake +} + +src_install() { + dobin bin/${PN} + dodoc CHANGELOG.md CONTRIBUTING.md README.md + insinto /etc/${PN}.d + doins "${FILESDIR}/"*.json.example + insinto /etc/logrotate.d + newins "${FILESDIR}/${PN}.logrotated" "${PN}" + newinitd "${FILESDIR}/${PN}.initd" "${PN}" + newconfd "${FILESDIR}/${PN}.confd" "${PN}" + systemd_dounit "${FILESDIR}/${PN}.service" + keepdir /var/log/${PN} + fowners ${PN}:${PN} /var/log/${PN} +} + +pkg_postinst() { + fcaps_pkg_postinst + go-module_pkg_postinst +} |