Sign Up
Log In
Log In
or
Sign Up
Places
All Projects
Status Monitor
Collapse sidebar
openSUSE:Backports:SLE-15-SP1
container-diff
container-diff.spec
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File container-diff.spec of Package container-diff
# # spec file for package container-diff # # Copyright (c) 2018 SUSE LINUX GmbH, Nuernberg, Germany. # # All modifications and additions to the file contributed by third parties # remain the property of their copyright owners, unless otherwise agreed # upon. The license for this file, and modifications and additions to the # file, is the same license as for the pristine package itself (unless the # license for the pristine package is not an Open Source License, in which # case the license is the MIT License). An "Open Source License" is a # license that conforms to the Open Source Definition (Version 1.9) # published by the Open Source Initiative. # Please submit bugfixes or comments via http://bugs.opensuse.org/ # %define project github.com/GoogleCloudPlatform/container-diff Name: container-diff Version: 0.9.0 Release: 0 Summary: Analyze and compare container images License: Apache-2.0 Group: System/Management Url: https://github.com/GoogleCloudPlatform/container-diff Source0: %{name}-%{version}.tar.xz BuildRequires: fdupes BuildRequires: golang-packaging BuildRequires: golang(API) >= 1.7 Requires: docker # disable stripping of binaries %{go_nostrip} %description container-diff is a tool for analyzing and comparing container images. container-diff can examine images along several different criteria, including: - Docker Image History - Image file system - Apt packages - RPM packages - pip packages - npm packages These analyses can be performed on a single image, or a diff can be performed on two images to compare. %prep %setup -q %build # We can't use symlinks here because go-list gets confused by symlinks, so we # have to copy the source to $HOME/go and then use that as the GOPATH. export GOPATH=$HOME/go mkdir -pv $HOME/go/src/%{project} rm -rf $HOME/go/src/%{project}/* cp -avr * $HOME/go/src/%{project} cd $HOME/go/src/%{project} # Patch the version variable # Build container-diff export BUILDTAGS="" go build -tags "$BUILDTAGS" \ -buildmode=pie \ -ldflags '-s -w -X %{project}/version.version=v%{version}' \ -o bin/container-diff \ %{project} %check # We can't use symlinks here because go-list gets confused by symlinks, so we # have to copy the source to $HOME/go and then use that as the GOPATH. export GOPATH=$HOME/go mkdir -pv $HOME/go/src/%{project} rm -rf $HOME/go/src/%{project}/* cp -avr * $HOME/go/src/%{project} cd $HOME/go/src/%{project} # Test container-diff. Exclude ppc64le, which has known issue with gotest. PKG_LIST=$(go list ./... | grep -v %{project}/vendor}) %ifnarch ppc64le go test $PKG_LIST %endif %install cd $HOME/go/src/%{project} # Binaries install -D -m 0755 bin/container-diff %{buildroot}/%{_bindir}/container-diff %fdupes -s %{buildroot}/%{_prefix} %files # Binaries %{_bindir}/container-diff %changelog
Locations
Projects
Search
Status Monitor
Help
OpenBuildService.org
Documentation
API Documentation
Code of Conduct
Contact
Support
@OBShq
Terms
openSUSE Build Service is sponsored by
The Open Build Service is an
openSUSE project
.
Sign Up
Log In
Places
Places
All Projects
Status Monitor