kubepug/kubepug.spec
Your Name eb93136e38
All checks were successful
Run CI/CD... / main (push) Successful in 44m52s
1.6.1
2025-02-10 20:49:55 +00:00

47 lines
1.2 KiB
RPMSpec

%define debug %nil
%define debug_package %nil
Name: kubepug
Version: 1.6.1
Release: 1
Summary: Kubernetes PreUpGrade (Checker)
URL: https://github.com/rikatz/kubepug
Source0: %{url}/archive/v%{version}/%{name}-%{version}.tar.gz
License: Apache-2.0
Group: Development/Other
BuildRequires: go
BuildRequires: git-core
BuildRequires: upx
%description
KubePug/Deprecations is intended to be a kubectl plugin,
which:
- Downloads a swagger.json from a specific Kubernetes
version
- Parses this Json finding deprecation notices
- Verifies the current kubernetes cluster or input files
checking whether exists objects in this deprecated API
Versions, allowing the user to check before migrating
%prep
%setup -q
%build
export GOPROXY=direct
CGO_ENABLED=0 go build -trimpath -ldflags "-X sigs.k8s.io/release-utils/version.gitVersion=%{version}" -o ./bin/kubepug .
upx bin/%{name}
# gen completion
./bin/%{name} completion bash > %{name}.completion
%install
install -Dm0755 bin/%{name} %{buildroot}%{_bindir}/%{name}
install -Dm0644 %{name}.completion %{buildroot}%{_datadir}/bash-completion/completions/%{name}
%files
%doc README.md LICENSE
%{_bindir}/%{name}
%{_datadir}/bash-completion/completions/%{name}