summaryrefslogtreecommitdiff
path: root/dev-util/clair
diff options
context:
space:
mode:
authorV3n3RiX <venerix@redcorelinux.org>2018-07-14 21:03:06 +0100
committerV3n3RiX <venerix@redcorelinux.org>2018-07-14 21:03:06 +0100
commit8376ef56580626e9c0f796d5b85b53a0a1c7d5f5 (patch)
tree7681bbd4e8b05407772df40a4bf04cbbc8afc3fa /dev-util/clair
parent30a9caf154332f12ca60756e1b75d2f0e3e1822d (diff)
gentoo resync : 14.07.2018
Diffstat (limited to 'dev-util/clair')
-rw-r--r--dev-util/clair/Manifest5
-rw-r--r--dev-util/clair/clair-2.0.3.ebuild46
-rw-r--r--dev-util/clair/files/clair.confd2
-rw-r--r--dev-util/clair/files/clair.initd19
-rw-r--r--dev-util/clair/metadata.xml11
5 files changed, 83 insertions, 0 deletions
diff --git a/dev-util/clair/Manifest b/dev-util/clair/Manifest
new file mode 100644
index 000000000000..08ca65b78523
--- /dev/null
+++ b/dev-util/clair/Manifest
@@ -0,0 +1,5 @@
+AUX clair.confd 75 BLAKE2B 8700f0e19734c3a6c0f0596e5fcbee5aafaf2bf19dd66fff0a94a29c9f886d6dba1803ba8e3a9e7f9286eaef512c34524a281c952943d455e35446b9a0511187 SHA512 9ff72a41da4600f7c266a7c763520c947e41c1c06dc93f9c8fcdc3f92d5b10ac4a2483122fedc4cf3bfc5de0a48f61366b0d2b72bcc348b736fa958b7065cc87
+AUX clair.initd 593 BLAKE2B ec5f50ef2fe997cd0f5e3aa7837be9bb7e39f4a5b766011034bde27c38d7eb32fc61853c8cc82d738724b4c6c5e01306c6e20c9968be0e4bbe8a5f4e7a79b7eb SHA512 827bf28ba4ad7a40f4eb916f315978da6d3fab52a8ac9b3316383d67ed90006f0b13e7cec3a8843d73e5d23ef27bcd53a9a02ec70c1795725cb98e5d1de788bb
+DIST clair-2.0.3.tar.gz 5194681 BLAKE2B b4f809e7699fbf66745c7f528f3f2c249e81541a64c540a8c39b9fa8f5b581d1297abdfe80bdb0ca3aec00010c6c95e8073397df284d2a92a3e95f91049cde80 SHA512 bf2d4ab15efc50bce3e828d0510ceb44463a6c1d978a854b3a05899996203a7c33bb6e60470eccb6e0a1e23b8ff41955cd0fdda4b77a9a7e042e1e27dd2e0885
+EBUILD clair-2.0.3.ebuild 1064 BLAKE2B 789ad8bf42f99a85dfb47453d2bd2b042ebe4d67235a581678240b46f0fe823adcb00abc2bebc4c3d127893be78ab8b5804712c275d7b7ff7655b86859a15089 SHA512 543dbea35a7de36d1e2cc0a1b3f87b9e91ca647dc642eb0b8cd1f8951b1394149d05a6bafddbdc5c11a9af0f6c6a96cb1a6cdd3a470514f456706a4d2cea368e
+MISC metadata.xml 322 BLAKE2B 0f3b559d05cfd49e83c1b71381ee3775e83420f601ddd1cd47bc9211ff4d08831992418e4869f02fe73e96ff9089117fddce8b980c0282b44e408eed9c3cbcb4 SHA512 7ac0fefec4d71b29fe295ebc41df72ff0d80ba327104ca124bdd700ea054c477ba6a040fcdce6fcae38ec437703ff31ae36a2a7c5683420c39db20d775e52919
diff --git a/dev-util/clair/clair-2.0.3.ebuild b/dev-util/clair/clair-2.0.3.ebuild
new file mode 100644
index 000000000000..8c92e5db7e56
--- /dev/null
+++ b/dev-util/clair/clair-2.0.3.ebuild
@@ -0,0 +1,46 @@
+# Copyright 1999-2018 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=6
+inherit user golang-build golang-vcs-snapshot
+
+EGO_PN="github.com/coreos/clair"
+EGIT_COMMIT="v${PV}"
+ARCHIVE_URI="https://${EGO_PN}/archive/${EGIT_COMMIT}.tar.gz -> ${P}.tar.gz"
+KEYWORDS="~amd64"
+
+DESCRIPTION="Vulnerability Static Analysis for Containers"
+HOMEPAGE="https://github.com/coreos/clair"
+SRC_URI="${ARCHIVE_URI}"
+LICENSE="Apache-2.0"
+SLOT="0"
+IUSE=""
+
+RDEPEND="app-arch/rpm
+ app-arch/xz-utils
+ dev-vcs/bzr
+ dev-vcs/git
+ !!sci-visualization/xd3d" # File collision (Bug #621044)
+
+pkg_setup() {
+ enewgroup ${PN}
+ enewuser ${PN} -1 -1 -1 ${PN}
+}
+
+src_compile() {
+ GOPATH="${S}" go build -o bin/${PN} -v ${EGO_PN}/cmd/${PN} || die
+}
+
+src_install() {
+ dobin bin/${PN}
+ pushd src/${EGO_PN} || die
+ dodoc {README,ROADMAP,CONTRIBUTING}.md
+ insinto /etc/${PN}
+ doins config.example.yaml
+ popd || die
+
+ newinitd "${FILESDIR}"/${PN}.initd ${PN}
+ newconfd "${FILESDIR}"/${PN}.confd ${PN}
+ keepdir /var/log/${PN}
+ fowners ${PN}:${PN} /var/log/${PN}
+}
diff --git a/dev-util/clair/files/clair.confd b/dev-util/clair/files/clair.confd
new file mode 100644
index 000000000000..e66675311de3
--- /dev/null
+++ b/dev-util/clair/files/clair.confd
@@ -0,0 +1,2 @@
+# arguments for clair config
+command_args="-config=/etc/clair/config.yaml"
diff --git a/dev-util/clair/files/clair.initd b/dev-util/clair/files/clair.initd
new file mode 100644
index 000000000000..53518fea6320
--- /dev/null
+++ b/dev-util/clair/files/clair.initd
@@ -0,0 +1,19 @@
+#!/sbin/openrc-run
+# Copyright 2017 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+description="Clair Vulnerability Static Analysis for Containers"
+pidfile=${pidfile:-"/run/${RC_SVCNAME}.pid"}
+user=${user:-${RC_SVCNAME}}
+group=${group:-${RC_SVCNAME}}
+
+command="/usr/bin/clair"
+command_args="${command_args:--config=/etc/clair/config.yaml}"
+command_background="true"
+start_stop_daemon_args="--user ${user} --group ${group} \
+ --stdout /var/log/${RC_SVCNAME}/${RC_SVCNAME}.log \
+ --stderr /var/log/${RC_SVCNAME}/${RC_SVCNAME}.log"
+
+depend() {
+ after net
+}
diff --git a/dev-util/clair/metadata.xml b/dev-util/clair/metadata.xml
new file mode 100644
index 000000000000..01abcbc89e22
--- /dev/null
+++ b/dev-util/clair/metadata.xml
@@ -0,0 +1,11 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+ <maintainer type="person">
+ <email>mrueg@gentoo.org</email>
+ <name>Manuel RĂ¼ger</name>
+ </maintainer>
+ <upstream>
+ <remote-id type="github">coreos/clair</remote-id>
+ </upstream>
+</pkgmetadata>