Subject: [PATCH] testing/lynis: new aport

From: Ivan Tham <[email-masked]>
Date: Wed, 18 Sep 2019 01:11:55 +0800

https://cisofy.com/lynis/
Security auditing and hardening tool, for UNIX-based systems
---
 testing/lynis/APKBUILD | 43 ++++++++++++++++++++++++++++++++++++++++++
 1 file changed, 43 insertions(+)
 create mode 100644 testing/lynis/APKBUILD

diff --git a/testing/lynis/APKBUILD b/testing/lynis/APKBUILD
new file mode 100644
index 0000000000..d801fa8a44
--- /dev/null
+++ b/testing/lynis/APKBUILD
@@ -0,0 +1,43 @@
+# Contributor: Ivan Tham <[email-masked]>
+# Maintainer: Ivan Tham <[email-masked]>
+pkgname="lynis"
+pkgver="2.7.5"
+pkgrel=0
+pkgdesc="Security auditing and hardening tool, for UNIX-based systems"
+url="https://cisofy.com/lynis/"
+arch="noarch"
+license="GPL-3.0-or-later"
+options="!check"
+subpackages="$pkgname-doc
+	$pkgname-bash-completion:bashcomp:noarch"
+source="$pkgname-$pkgver.tar.gz::https://github.com/CISOfy/$pkgname/archive/$pkgver.tar.gz"
+
+package() {
+	cd "$builddir"
+
+	# binary
+	install -Dm755 lynis "$pkgdir/usr/bin/$pkgname"
+
+	# profile
+	install -Dm644 default.prf "$pkgdir/etc/$pkgname/default.prf"
+
+	# plugins, include, db
+	install -d "$pkgdir/usr/share/$pkgname"
+	cp -ra db include plugins "$pkgdir/usr/share/$pkgname"
+
+	# doc files
+	install -Dm644 README INSTALL CHANGELOG.md FAQ \
+		-t "$pkgdir/usr/share/$pkgname"
+	install -Dm644 $pkgname.8 -t "$pkgdir/usr/share/man/man8"
+}
+
+bashcomp() {
+	depends=""
+	pkgdesc="Bash completions for $pkgname"
+	install_if="$pkgname=$pkgver-r$pkgrel bash-completion"
+
+	install -Dm644 "$builddir"/extras/bash_completion.d/$pkgname \
+		-t "$subpkgdir/usr/share/bash-completion/completions"
+}
+
+sha512sums="4930ce886d6aeec0c96b220a4ccba70fb8e1a62dcada557f184d538e6b24283a95256ee90a8186678bbbff0081e18ee6c1177c03774202069b301aa40c28781b  lynis-2.7.5.tar.gz"
-- 
2.22.0