]>
Commit | Line | Data |
---|---|---|
18c175b8 JP |
1 | Summary: A tool for managing OCI containers and pods |
2 | Name: podman | |
d0102ee0 | 3 | Version: 4.0.3 |
18c175b8 JP |
4 | Release: 1 |
5 | License: Apache v2.0 | |
6 | Group: Applications/System | |
7 | #Source0Download: https://github.com/containers/podman/releases | |
8 | Source0: https://github.com/containers/podman/archive/v%{version}/%{name}-%{version}.tar.gz | |
d0102ee0 | 9 | # Source0-md5: 35d774254fd067ee6c7de40311584162 |
35a38226 | 10 | Source1: policy.json |
00346cb1 | 11 | Source2: registries.conf |
18c175b8 | 12 | URL: https://github.com/containers/podman |
cbf5965c | 13 | BuildRequires: device-mapper-devel |
18c175b8 JP |
14 | BuildRequires: go-md2man |
15 | BuildRequires: golang | |
16 | BuildRequires: golang-varlink | |
cbf5965c JP |
17 | BuildRequires: gpgme-devel |
18 | BuildRequires: libseccomp-devel | |
19 | BuildRequires: pkgconfig | |
93c72252 | 20 | BuildRequires: rpm-build >= 4.6 |
48a1ddc7 | 21 | BuildRequires: rpmbuild(macros) >= 2.009 |
cbf5965c | 22 | BuildRequires: systemd-devel |
18c175b8 | 23 | Requires: conmon |
94a7f745 | 24 | Requires: containernetworking-plugins |
18c175b8 | 25 | Requires: crun |
2d104b8a JP |
26 | Suggests: slirp4netns |
27 | Suggests: uidmap | |
d113c837 | 28 | ExclusiveArch: %go_arches |
18c175b8 JP |
29 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) |
30 | ||
8a009d33 JP |
31 | %define _enable_debug_packages 0 |
32 | ||
18c175b8 JP |
33 | %description |
34 | Podman (the POD MANager) is a tool for managing containers and images, | |
35 | volumes mounted into those containers, and pods made from groups of | |
36 | containers. Podman is based on libpod, a library for container | |
37 | lifecycle management that is also contained in this repository. The | |
38 | libpod library provides APIs for managing containers, pods, container | |
39 | images, and volumes. | |
40 | ||
93c72252 JP |
41 | %package -n bash-completion-podman |
42 | Summary: bash-completion for podman | |
43 | Group: Applications/Shells | |
44 | Requires: %{name} = %{version}-%{release} | |
45 | Requires: bash-completion >= 2.0 | |
46 | BuildArch: noarch | |
47 | ||
48 | %description -n bash-completion-podman | |
49 | This package provides bash-completion for podman. | |
50 | ||
51 | %package -n fish-completion-podman | |
52 | Summary: Fish completion for podman command | |
53 | Group: Applications/Shells | |
54 | Requires: %{name} = %{version}-%{release} | |
55 | Requires: fish | |
56 | BuildArch: noarch | |
57 | ||
58 | %description -n fish-completion-podman | |
59 | Fish completion for podman command. | |
60 | ||
61 | %package -n zsh-completion-podman | |
62 | Summary: Zsh completion for podman command | |
63 | Group: Applications/Shells | |
64 | Requires: %{name} = %{version}-%{release} | |
65 | Requires: zsh | |
66 | BuildArch: noarch | |
67 | ||
68 | %description -n zsh-completion-podman | |
69 | Zsh completion for podman command. | |
70 | ||
18c175b8 JP |
71 | %prep |
72 | %setup -q | |
73 | ||
74 | %build | |
a6a3c572 JP |
75 | %{__make} \ |
76 | GO=/usr/bin/go \ | |
48a1ddc7 | 77 | GOCMD="CGO_ENABLED=1 %__go" \ |
e908b902 | 78 | GOPATH=$(pwd)/.gopath \ |
e7ee545a JP |
79 | PREFIX="%{_prefix}" \ |
80 | BINDIR="%{_bindir}" \ | |
81 | LIBEXECDIR="%{_libexecdir}" \ | |
82 | MANDIR="%{_mandir}" \ | |
83 | SHAREDIR_CONTAINERS="%{_datadir}/containers" \ | |
84 | ETCDIR="%{_sysconfdir}" \ | |
85 | TMPFILESDIR="%{systemdtmpfilesdir}" \ | |
86 | SYSTEMDDIR="%{systemdunitdir}" \ | |
87 | USERSYSTEMDDIR="%{systemduserunitdir}" \ | |
88 | PYTHON="%{__python3}" | |
18c175b8 JP |
89 | |
90 | %install | |
91 | rm -rf $RPM_BUILD_ROOT | |
92 | ||
ad6ad319 | 93 | install -d $RPM_BUILD_ROOT{%{_sysconfdir}/containers,%{bash_compdir},%{fish_compdir},%{zsh_compdir},%{_sharedstatedir}/containers} |
35a38226 | 94 | |
18c175b8 JP |
95 | %{__make} install \ |
96 | DESTDIR=$RPM_BUILD_ROOT \ | |
e7ee545a JP |
97 | PREFIX="%{_prefix}" \ |
98 | BINDIR="%{_bindir}" \ | |
99 | LIBEXECDIR="%{_libexecdir}" \ | |
100 | MANDIR="%{_mandir}" \ | |
101 | SHAREDIR_CONTAINERS="%{_datadir}/containers" \ | |
102 | ETCDIR="%{_sysconfdir}" \ | |
103 | TMPFILESDIR="%{systemdtmpfilesdir}" \ | |
104 | SYSTEMDDIR="%{systemdunitdir}" \ | |
105 | USERSYSTEMDDIR="%{systemduserunitdir}" \ | |
106 | PYTHON="%{__python3}" | |
18c175b8 | 107 | |
ad6ad319 JP |
108 | cp -p %{SOURCE1} %{SOURCE2} \ |
109 | vendor/github.com/containers/common/pkg/config/containers.conf \ | |
110 | $RPM_BUILD_ROOT%{_sysconfdir}/containers | |
111 | ||
112 | %{__sed} -e 's|/var/lib/containers|%{_sharedstatedir}/containers|g' \ | |
113 | vendor/github.com/containers/storage/storage.conf \ | |
114 | > $RPM_BUILD_ROOT%{_sysconfdir}/containers/storage.conf | |
35a38226 | 115 | |
93c72252 JP |
116 | $RPM_BUILD_ROOT%{_bindir}/podman completion -f $RPM_BUILD_ROOT%{bash_compdir}/podman bash |
117 | $RPM_BUILD_ROOT%{_bindir}/podman completion -f $RPM_BUILD_ROOT%{fish_compdir}/podman.fish fish | |
118 | $RPM_BUILD_ROOT%{_bindir}/podman completion -f $RPM_BUILD_ROOT%{zsh_compdir}/_podman zsh | |
119 | ||
18c175b8 JP |
120 | %clean |
121 | rm -rf $RPM_BUILD_ROOT | |
122 | ||
b74ba7ea JP |
123 | %post |
124 | %systemd_post podman.service podman.socket | |
125 | ||
126 | %preun | |
127 | %systemd_preun podman.service podman.socket | |
128 | ||
129 | %postun | |
130 | %systemd_reload | |
131 | ||
18c175b8 JP |
132 | %files |
133 | %defattr(644,root,root,755) | |
c22a6efc | 134 | %doc README.md |
35a38226 | 135 | %dir %{_sysconfdir}/containers |
ad6ad319 | 136 | %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/containers/containers.conf |
35a38226 | 137 | %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/containers/policy.json |
00346cb1 | 138 | %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/containers/registries.conf |
ad6ad319 | 139 | %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/containers/storage.conf |
18c175b8 JP |
140 | %attr(755,root,root) %{_bindir}/podman |
141 | %attr(755,root,root) %{_bindir}/podman-remote | |
5cd7f4f0 JP |
142 | %dir %{_libexecdir}/podman |
143 | %attr(755,root,root) %{_libexecdir}/podman/rootlessport | |
18c175b8 JP |
144 | %{systemdunitdir}/podman.service |
145 | %{systemdunitdir}/podman.socket | |
a6a3c572 JP |
146 | %{systemdunitdir}/podman-auto-update.service |
147 | %{systemdunitdir}/podman-auto-update.timer | |
41286851 | 148 | %{systemdunitdir}/podman-restart.service |
18c175b8 JP |
149 | %{systemduserunitdir}/podman.service |
150 | %{systemduserunitdir}/podman.socket | |
a6a3c572 JP |
151 | %{systemduserunitdir}/podman-auto-update.service |
152 | %{systemduserunitdir}/podman-auto-update.timer | |
41286851 | 153 | %{systemduserunitdir}/podman-restart.service |
18c175b8 | 154 | %{_mandir}/man1/podman*.1* |
18c175b8 | 155 | %{_mandir}/man5/oci-hooks.5* |
e7ee545a | 156 | /usr/lib/tmpfiles.d/podman.conf |
ad6ad319 | 157 | %dir %{_sharedstatedir}/containers |
93c72252 JP |
158 | |
159 | %files -n bash-completion-podman | |
160 | %defattr(644,root,root,755) | |
161 | %{bash_compdir}/podman | |
162 | ||
163 | %files -n fish-completion-%{name} | |
164 | %defattr(644,root,root,755) | |
165 | %{fish_compdir}/podman.fish | |
166 | ||
167 | %files -n zsh-completion-%{name} | |
168 | %defattr(644,root,root,755) | |
169 | %{zsh_compdir}/_podman |