From 686bb252b4228a13cc3c6eda8e28717bd85b85d7 Mon Sep 17 00:00:00 2001 From: Sergey Zhemoytel Date: Thu, 21 Mar 2024 01:28:06 +0300 Subject: [PATCH] Imported from SRPM --- .abf.yml | 2 ++ kube-bench.spec | 36 ++++++++++++++++++++++++++++++++++++ 2 files changed, 38 insertions(+) create mode 100644 .abf.yml create mode 100644 kube-bench.spec diff --git a/.abf.yml b/.abf.yml new file mode 100644 index 0000000..abf887a --- /dev/null +++ b/.abf.yml @@ -0,0 +1,2 @@ +sources: + kube-bench-0.7.2.tar.gz: 9489fe0129a47ec3023dd18f363d46c342263617 diff --git a/kube-bench.spec b/kube-bench.spec new file mode 100644 index 0000000..b0265db --- /dev/null +++ b/kube-bench.spec @@ -0,0 +1,36 @@ +%define debug %nil +%define debug_package %nil + +Name: kube-bench +Version: 0.7.2 +Release: 1 +Summary: Checks whether Kubernetes +URL: https://github.com/aquasecurity/kube-bench +Source0: %{url}/archive/v%{version}/%{name}-%{version}.tar.gz +License: ASL 2.0 +Group: Development/Other +BuildRequires: go +BuildRequires: git-core +BuildRequires: upx + +%description +kube-bench is a tool that checks whether Kubernetes is +deployed securely by running the checks documented in +the CIS Kubernetes Benchmark. + +%prep +%setup -q + +%build +export GOPROXY=direct +CGO_ENABLED=0 go build -ldflags "-X github.com/aquasecurity/kube-bench/cmd.KubeBenchVersion=%{version}" -o bin/%{name} . + +upx bin/%{name} + +%install +install -Dm0755 bin/%{name} %{buildroot}%{_bindir}/%{name} + +%files +%doc README.md LICENSE docs +%{_bindir}/%{name} +