docker-compose/docker-compose.spec

57 lines
1.4 KiB
RPMSpec
Raw Normal View History

2024-05-18 22:26:27 +00:00
%define debug %nil
%define debug_package %nil
2021-12-15 23:08:55 +03:00
2024-05-18 22:26:27 +00:00
%define plugin compose
2021-12-15 23:08:55 +03:00
2024-05-18 22:26:27 +00:00
%define _libexec /usr/libexec
%define _dockerpluginsdir %{_libexec}/docker/cli-plugins
Name: docker-%{plugin}
2024-09-13 08:49:48 +00:00
Version: 2.29.3
2024-05-24 20:25:31 +00:00
Release: 1
2021-12-15 23:08:55 +03:00
Summary: Docker compose golang version
2024-05-18 22:26:27 +00:00
URL: https://docs.docker.com/%{plugin}
Source0: https://github.com/docker/%{plugin}/archive/v%{version}/%{plugin}-%{version}.tar.gz
2021-12-15 23:08:55 +03:00
Group: Development/Other
License: ASL 2.0
2023-09-23 09:21:01 +00:00
BuildRequires: go >= 1.21
2021-12-15 23:08:55 +03:00
BuildRequires: git-core
BuildRequires: upx
Requires: docker
2019-02-15 17:52:21 +03:00
%description
2021-12-15 23:08:55 +03:00
Docker Compose v2
Docker Compose is a tool for running multi-container
applications on Docker defined using the Compose file
format. A Compose file is used to define how the one or
more containers that make up your application are
configured. Once you have a Compose file, you can
create and start your application with a single command:
2019-02-15 17:52:21 +03:00
2021-12-15 23:08:55 +03:00
docker compose up
2019-02-15 17:52:21 +03:00
%prep
2024-05-18 22:26:27 +00:00
%setup -qn %{plugin}-%{version}
2019-02-15 17:52:21 +03:00
%build
2024-03-15 15:50:09 +00:00
export GOPROXY=https://proxy.golang.org/cached-only
2023-09-23 22:15:29 +00:00
2024-05-18 22:26:27 +00:00
CGO_ENABLED=0 go build -trimpath -ldflags="-s -w -X github.com/docker/compose/v2/internal.Version=%{version}" -o bin/%{name} ./cmd
upx bin/%{name}
2021-12-15 23:08:55 +03:00
find . -type f -size 0 -exec rm -f {} \;
2019-02-15 17:52:21 +03:00
%install
2024-05-18 22:26:27 +00:00
install -Dm0755 bin/%{name} %{buildroot}%{_bindir}/%{name}
install -d %{buildroot}%{_dockerpluginsdir}
ln -s ../../../bin/%{name} %{buildroot}%{_dockerpluginsdir}/%{name}
2019-02-15 17:52:21 +03:00
%files
2021-12-15 23:08:55 +03:00
%doc README.md LICENSE docs
2024-05-18 22:26:27 +00:00
%{_bindir}/%{name}
%{_dockerpluginsdir}/%{name}