SHA256
1
0
forked from pool/docker
docker/docker.spec

288 lines
8.6 KiB
RPMSpec
Raw Normal View History

#
# spec file for package docker
#
# Copyright (c) 2015 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/
#
- Upgrade to 1.9.1(bnc#956434) * Runtime: - Do not prevent daemon from booting if images could not be restored (#17695) - Force IPC mount to unmount on daemon shutdown/init (#17539) - Turn IPC unmount errors into warnings (#17554) - Fix `docker stats` performance regression (#17638) - Clarify cryptic error message upon `docker logs` if `--log-driver=none` (#17767) - Fix seldom panics (#17639, #17634, #17703) - Fix opq whiteouts problems for files with dot prefix (#17819) - devicemapper: try defaulting to xfs instead of ext4 for performance reasons (#17903, #17918) - devicemapper: fix displayed fs in docker info (#17974) - selinux: only relabel if user requested so with the `z` option (#17450, #17834) - Do not make network calls when normalizing names (#18014) *Client: - Fix `docker login` on windows (#17738) - Fix bug with `docker inspect` output when not connected to daemon (#17715) - Fix `docker inspect -f {{.HostConfig.Dns}} somecontainer` (#17680) * Builder: - Fix regression with symlink behavior in ADD/COPY (#17710) * Networking: - Allow passing a network ID as an argument for `--net` (#17558) - Fix connect to host and prevent disconnect from host for `host` network (#17476) - Fix `--fixed-cidr` issue when gateway ip falls in ip-range and ip-range is not the first block in the network (#17853) - Restore deterministic `IPv6` generation from `MAC` address on default `bridge` network (#17890) - Allow port-mapping only for endpoints created on docker run (#17858) - Fixed an endpoint delete issue with a possible stale sbox (#18102) * Distribution: - Correct parent chain in v2 push when v1Compatibility files on the disk are inconsistent (#18047) OBS-URL: https://build.opensuse.org/package/show/Virtualization:containers/docker?expand=0&rev=44
2015-11-24 12:52:52 +01:00
%define git_version a34a1d5
%define go_arches %ix86 x86_64
Name: docker
- Upgrade to 1.9.1(bnc#956434) * Runtime: - Do not prevent daemon from booting if images could not be restored (#17695) - Force IPC mount to unmount on daemon shutdown/init (#17539) - Turn IPC unmount errors into warnings (#17554) - Fix `docker stats` performance regression (#17638) - Clarify cryptic error message upon `docker logs` if `--log-driver=none` (#17767) - Fix seldom panics (#17639, #17634, #17703) - Fix opq whiteouts problems for files with dot prefix (#17819) - devicemapper: try defaulting to xfs instead of ext4 for performance reasons (#17903, #17918) - devicemapper: fix displayed fs in docker info (#17974) - selinux: only relabel if user requested so with the `z` option (#17450, #17834) - Do not make network calls when normalizing names (#18014) *Client: - Fix `docker login` on windows (#17738) - Fix bug with `docker inspect` output when not connected to daemon (#17715) - Fix `docker inspect -f {{.HostConfig.Dns}} somecontainer` (#17680) * Builder: - Fix regression with symlink behavior in ADD/COPY (#17710) * Networking: - Allow passing a network ID as an argument for `--net` (#17558) - Fix connect to host and prevent disconnect from host for `host` network (#17476) - Fix `--fixed-cidr` issue when gateway ip falls in ip-range and ip-range is not the first block in the network (#17853) - Restore deterministic `IPv6` generation from `MAC` address on default `bridge` network (#17890) - Allow port-mapping only for endpoints created on docker run (#17858) - Fixed an endpoint delete issue with a possible stale sbox (#18102) * Distribution: - Correct parent chain in v2 push when v1Compatibility files on the disk are inconsistent (#18047) OBS-URL: https://build.opensuse.org/package/show/Virtualization:containers/docker?expand=0&rev=44
2015-11-24 12:52:52 +01:00
Version: 1.9.1
Release: 0
Summary: The Linux container runtime
License: Apache-2.0
Group: System/Management
Url: http://www.docker.io
Source: %{name}-%{version}.tar.xz
Source1: docker.service
Source3: 80-docker.rules
Source4: sysconfig.docker
%if 0%{?suse_version} > 1320
Source5: docker.socket
%else
Source5: docker_systemd_lt_214.socket
%endif
Source6: docker-rpmlintrc
Source7: README_SUSE.md
Source8: docker-audit.rules
# TODO: remove once we figure out what is wrong with iptables on ppc64le
Source100: sysconfig.docker.ppc64le
- Updated to 1.7.0 (2015-06-16) - bnc#935570 * Runtime - Experimental feature: support for out-of-process volume plugins - The userland proxy can be disabled in favor of hairpin NAT using the daemon’s `--userland-proxy=false` flag - The `exec` command supports the `-u|--user` flag to specify the new process owner - Default gateway for containers can be specified daemon-wide using the `--default-gateway` and `--default-gateway-v6` flags - The CPU CFS (Completely Fair Scheduler) quota can be set in `docker run` using `--cpu-quota` - Container block IO can be controlled in `docker run` using`--blkio-weight` - ZFS support - The `docker logs` command supports a `--since` argument - UTS namespace can be shared with the host with `docker run --uts=host` * Quality - Networking stack was entirely rewritten as part of the libnetwork effort - Engine internals refactoring - Volumes code was entirely rewritten to support the plugins effort - Sending SIGUSR1 to a daemon will dump all goroutines stacks without exiting * Build - Support ${variable:-value} and ${variable:+value} syntax for environment variables - Support resource management flags `--cgroup-parent`, `--cpu-period`, `--cpu-quota`, `--cpuset-cpus`, `--cpuset-mems` - git context changes with branches and directories - The .dockerignore file support exclusion rules * Distribution - Client support for v2 mirroring support for the official registry * Bugfixes - Firewalld is now supported and will automatically be used when available - mounting --device recursively - Patch 0002-Stripped-dockerinit-binary.patch renamed to fix-docker-init.patch and fixed to build with latest version of docker OBS-URL: https://build.opensuse.org/package/show/Virtualization:containers/docker?expand=0&rev=12
2015-06-22 11:09:23 +02:00
Patch0: fix-docker-init.patch
# PATCH-FIX-OPENSUSE libcontainer-apparmor-fixes.patch -- mount rules aren't supported in our apparmor
Patch1: libcontainer-apparmor-fixes.patch
# Required to overcome some limitations of gcc-go: https://groups.google.com/forum/#!msg/golang-nuts/SlGCPYkjxo4/4DjcjXRCqAkJ
# Right now docker passes the sha1sum of the dockerinit binary to the docker binary at build time
# We cannot do that, right now a quick and really dirty way to get it running is
# to simply disable this check
Patch100: ignore-dockerinit-checksum.patch
Patch101: gcc-go-build-static-libgo.patch
Patch102: add_bolt_ppc64.patch
Patch103: docker_remove_journald_to_fix_dynbinary_build_on_arm.patch
Patch104: docker_remove_journald_to_fix_dynbinary_build_on_powerpc.patch
Patch105: add_bolt_arm64.patch
Patch106: docker_remove_journald_to_fix_dynbinary_build_on_arm64.patch
BuildRequires: audit
BuildRequires: bash-completion
BuildRequires: device-mapper-devel >= 1.2.68
BuildRequires: glibc-devel-static
%ifarch %go_arches
- Updated to 1.7.0 (2015-06-16) - bnc#935570 * Runtime - Experimental feature: support for out-of-process volume plugins - The userland proxy can be disabled in favor of hairpin NAT using the daemon’s `--userland-proxy=false` flag - The `exec` command supports the `-u|--user` flag to specify the new process owner - Default gateway for containers can be specified daemon-wide using the `--default-gateway` and `--default-gateway-v6` flags - The CPU CFS (Completely Fair Scheduler) quota can be set in `docker run` using `--cpu-quota` - Container block IO can be controlled in `docker run` using`--blkio-weight` - ZFS support - The `docker logs` command supports a `--since` argument - UTS namespace can be shared with the host with `docker run --uts=host` * Quality - Networking stack was entirely rewritten as part of the libnetwork effort - Engine internals refactoring - Volumes code was entirely rewritten to support the plugins effort - Sending SIGUSR1 to a daemon will dump all goroutines stacks without exiting * Build - Support ${variable:-value} and ${variable:+value} syntax for environment variables - Support resource management flags `--cgroup-parent`, `--cpu-period`, `--cpu-quota`, `--cpuset-cpus`, `--cpuset-mems` - git context changes with branches and directories - The .dockerignore file support exclusion rules * Distribution - Client support for v2 mirroring support for the official registry * Bugfixes - Firewalld is now supported and will automatically be used when available - mounting --device recursively - Patch 0002-Stripped-dockerinit-binary.patch renamed to fix-docker-init.patch and fixed to build with latest version of docker OBS-URL: https://build.opensuse.org/package/show/Virtualization:containers/docker?expand=0&rev=12
2015-06-22 11:09:23 +02:00
BuildRequires: go >= 1.4
BuildRequires: go-go-md2man
%else
BuildRequires: gcc5-go >= 5.0
%endif
BuildRequires: libapparmor-devel
BuildRequires: libbtrfs-devel >= 3.8
BuildRequires: procps
BuildRequires: sqlite3-devel
BuildRequires: systemd-devel
BuildRequires: zsh
Requires: apparmor-parser
Requires: bridge-utils
Requires: ca-certificates-mozilla
# Provides mkfs.ext4 - used by Docker when devicemapper storage driver is used
Requires: e2fsprogs
Requires: git-core >= 1.7
Requires: iproute2 >= 3.5
Requires: iptables >= 1.4
Requires: kernel >= 3.8.0
Requires: lvm2 >= 2.2.89
Requires: procps
Requires: tar >= 1.26
Requires: xz >= 4.9
Conflicts: lxc < 1.0
PreReq: %fillup_prereq
BuildRoot: %{_tmppath}/%{name}-%{version}-build
ExcludeArch: %ix86
ExcludeArch: s390
ExcludeArch: s390x
ExcludeArch: ppc
%description
Docker complements LXC with a high-level API which operates at the process
level. It runs unix processes with strong guarantees of isolation and
repeatability across servers.
Docker is a great building block for automating distributed systems: large-scale
web deployments, database clusters, continuous deployment systems, private PaaS,
service-oriented architectures, etc.
%package bash-completion
Summary: Bash Completion for %{name}
Group: System/Management
Requires: %{name} = %{version}
Requires: bash-completion
BuildArch: noarch
%description bash-completion
Bash command line completion support for %{name}.
%package zsh-completion
Summary: Zsh Completion for %{name}
Group: System/Management
Requires: %{name} = %{version}
Requires: zsh
BuildArch: noarch
%description zsh-completion
Zsh command line completion support for %{name}.
%package test
Summary: Test package for docker
Group: System/Management
Requires: device-mapper-devel >= 1.2.68
Requires: glibc-devel-static
%ifarch %go_arches
Requires: go >= 1.4
%else
Requires: gcc5-go >= 5.0
%endif
BuildRequires: fdupes
Requires: apparmor-parser
Requires: bash-completion
Requires: libapparmor-devel
Requires: libbtrfs-devel >= 3.8
Requires: procps
Requires: sqlite3-devel
BuildArch: noarch
%description test
Test package for docker. It contains the source code and the tests.
%prep
%setup -q -n docker-%{version}
%patch0 -p1
%patch1 -p1
%ifnarch %go_arches
%patch100 -p1
%patch101 -p0
%patch102 -p1
%patch103 -p1
%patch104 -p1
%patch105 -p1
%patch106 -p1
%endif
cp %{SOURCE7} .
%build
%ifnarch %go_arches
tmphack=/tmp/dirty-hack
[ -e $tmphack ] && rm -rf $tmphack
mkdir $tmphack
ln -s /usr/bin/go-5 $tmphack/go
export PATH=$tmphack:$PATH
%endif
(cat <<EOF
export AUTO_GOPATH=1
export DOCKER_BUILDTAGS="exclude_graphdriver_aufs apparmor selinux"
export DOCKER_GITCOMMIT=%{git_version}
EOF
) > docker_build_env
. ./docker_build_env
./hack/make.sh dynbinary
%ifarch %go_arches
- Updated to 1.7.0 (2015-06-16) - bnc#935570 * Runtime - Experimental feature: support for out-of-process volume plugins - The userland proxy can be disabled in favor of hairpin NAT using the daemon’s `--userland-proxy=false` flag - The `exec` command supports the `-u|--user` flag to specify the new process owner - Default gateway for containers can be specified daemon-wide using the `--default-gateway` and `--default-gateway-v6` flags - The CPU CFS (Completely Fair Scheduler) quota can be set in `docker run` using `--cpu-quota` - Container block IO can be controlled in `docker run` using`--blkio-weight` - ZFS support - The `docker logs` command supports a `--since` argument - UTS namespace can be shared with the host with `docker run --uts=host` * Quality - Networking stack was entirely rewritten as part of the libnetwork effort - Engine internals refactoring - Volumes code was entirely rewritten to support the plugins effort - Sending SIGUSR1 to a daemon will dump all goroutines stacks without exiting * Build - Support ${variable:-value} and ${variable:+value} syntax for environment variables - Support resource management flags `--cgroup-parent`, `--cpu-period`, `--cpu-quota`, `--cpuset-cpus`, `--cpuset-mems` - git context changes with branches and directories - The .dockerignore file support exclusion rules * Distribution - Client support for v2 mirroring support for the official registry * Bugfixes - Firewalld is now supported and will automatically be used when available - mounting --device recursively - Patch 0002-Stripped-dockerinit-binary.patch renamed to fix-docker-init.patch and fixed to build with latest version of docker OBS-URL: https://build.opensuse.org/package/show/Virtualization:containers/docker?expand=0&rev=12
2015-06-22 11:09:23 +02:00
man/md2man-all.sh
%endif
# remove other than systemd
# otherwise the resulting package will have extra requires
- Updated to 1.7.0 (2015-06-16) - bnc#935570 * Runtime - Experimental feature: support for out-of-process volume plugins - The userland proxy can be disabled in favor of hairpin NAT using the daemon’s `--userland-proxy=false` flag - The `exec` command supports the `-u|--user` flag to specify the new process owner - Default gateway for containers can be specified daemon-wide using the `--default-gateway` and `--default-gateway-v6` flags - The CPU CFS (Completely Fair Scheduler) quota can be set in `docker run` using `--cpu-quota` - Container block IO can be controlled in `docker run` using`--blkio-weight` - ZFS support - The `docker logs` command supports a `--since` argument - UTS namespace can be shared with the host with `docker run --uts=host` * Quality - Networking stack was entirely rewritten as part of the libnetwork effort - Engine internals refactoring - Volumes code was entirely rewritten to support the plugins effort - Sending SIGUSR1 to a daemon will dump all goroutines stacks without exiting * Build - Support ${variable:-value} and ${variable:+value} syntax for environment variables - Support resource management flags `--cgroup-parent`, `--cpu-period`, `--cpu-quota`, `--cpuset-cpus`, `--cpuset-mems` - git context changes with branches and directories - The .dockerignore file support exclusion rules * Distribution - Client support for v2 mirroring support for the official registry * Bugfixes - Firewalld is now supported and will automatically be used when available - mounting --device recursively - Patch 0002-Stripped-dockerinit-binary.patch renamed to fix-docker-init.patch and fixed to build with latest version of docker OBS-URL: https://build.opensuse.org/package/show/Virtualization:containers/docker?expand=0&rev=12
2015-06-22 11:09:23 +02:00
rm -rf hack/make/.build-deb
%install
install -d %{buildroot}%{go_contribdir}
install -d %{buildroot}%{_bindir}
install -D -m755 bundles/%{version}/dynbinary/%{name}-%{version} %{buildroot}/%{_bindir}/%{name}
install -d %{buildroot}/%{_prefix}/lib/docker
install -D -m755 bundles/%{version}/dynbinary/dockerinit-%{version} %{buildroot}/%{_prefix}/lib/docker/dockerinit
install -Dd -m 0755 \
%{buildroot}%{_sysconfdir}/init.d \
%{buildroot}%{_sbindir}
install -D -m0644 contrib/completion/bash/docker "%{buildroot}/etc/bash_completion.d/%{name}"
install -D -m0644 contrib/completion/zsh/_docker "%{buildroot}/etc/zsh_completion.d/%{name}"
# copy all for the test package
install -d %{buildroot}/usr/src/docker/
cp -av . %{buildroot}/usr/src/docker/
#
# systemd service
#
install -D -m 0644 %SOURCE1 %{buildroot}%{_unitdir}/%{name}.service
install -D -m 0644 %SOURCE5 %{buildroot}%{_unitdir}/%{name}.socket
ln -sf /sbin/service $RPM_BUILD_ROOT/usr/sbin/rcdocker
#
# udev rules that prevents dolphin to show all docker devices and slows down
# upstream report https://bugs.kde.org/show_bug.cgi?id=329930
#
install -D -m 0644 %SOURCE3 %{buildroot}%{_prefix}/lib/udev/rules.d/80-%{name}.rules
# audit rules
install -D -m 0640 %SOURCE8 %{buildroot}%{_sysconfdir}/audit/rules.d/%{name}.rules
# sysconfig file
%ifarch ppc64le
install -D -m 644 %SOURCE100 %{buildroot}/var/adm/fillup-templates/sysconfig.docker
%else
install -D -m 644 %SOURCE4 %{buildroot}/var/adm/fillup-templates/sysconfig.docker
%endif
%ifarch %go_arches
# install manpages
install -d %{buildroot}%{_mandir}/man1
- Updated to 1.7.0 (2015-06-16) - bnc#935570 * Runtime - Experimental feature: support for out-of-process volume plugins - The userland proxy can be disabled in favor of hairpin NAT using the daemon’s `--userland-proxy=false` flag - The `exec` command supports the `-u|--user` flag to specify the new process owner - Default gateway for containers can be specified daemon-wide using the `--default-gateway` and `--default-gateway-v6` flags - The CPU CFS (Completely Fair Scheduler) quota can be set in `docker run` using `--cpu-quota` - Container block IO can be controlled in `docker run` using`--blkio-weight` - ZFS support - The `docker logs` command supports a `--since` argument - UTS namespace can be shared with the host with `docker run --uts=host` * Quality - Networking stack was entirely rewritten as part of the libnetwork effort - Engine internals refactoring - Volumes code was entirely rewritten to support the plugins effort - Sending SIGUSR1 to a daemon will dump all goroutines stacks without exiting * Build - Support ${variable:-value} and ${variable:+value} syntax for environment variables - Support resource management flags `--cgroup-parent`, `--cpu-period`, `--cpu-quota`, `--cpuset-cpus`, `--cpuset-mems` - git context changes with branches and directories - The .dockerignore file support exclusion rules * Distribution - Client support for v2 mirroring support for the official registry * Bugfixes - Firewalld is now supported and will automatically be used when available - mounting --device recursively - Patch 0002-Stripped-dockerinit-binary.patch renamed to fix-docker-init.patch and fixed to build with latest version of docker OBS-URL: https://build.opensuse.org/package/show/Virtualization:containers/docker?expand=0&rev=12
2015-06-22 11:09:23 +02:00
install -p -m 644 man/man1/*.1 %{buildroot}%{_mandir}/man1
install -d %{buildroot}%{_mandir}/man5
- Updated to 1.7.0 (2015-06-16) - bnc#935570 * Runtime - Experimental feature: support for out-of-process volume plugins - The userland proxy can be disabled in favor of hairpin NAT using the daemon’s `--userland-proxy=false` flag - The `exec` command supports the `-u|--user` flag to specify the new process owner - Default gateway for containers can be specified daemon-wide using the `--default-gateway` and `--default-gateway-v6` flags - The CPU CFS (Completely Fair Scheduler) quota can be set in `docker run` using `--cpu-quota` - Container block IO can be controlled in `docker run` using`--blkio-weight` - ZFS support - The `docker logs` command supports a `--since` argument - UTS namespace can be shared with the host with `docker run --uts=host` * Quality - Networking stack was entirely rewritten as part of the libnetwork effort - Engine internals refactoring - Volumes code was entirely rewritten to support the plugins effort - Sending SIGUSR1 to a daemon will dump all goroutines stacks without exiting * Build - Support ${variable:-value} and ${variable:+value} syntax for environment variables - Support resource management flags `--cgroup-parent`, `--cpu-period`, `--cpu-quota`, `--cpuset-cpus`, `--cpuset-mems` - git context changes with branches and directories - The .dockerignore file support exclusion rules * Distribution - Client support for v2 mirroring support for the official registry * Bugfixes - Firewalld is now supported and will automatically be used when available - mounting --device recursively - Patch 0002-Stripped-dockerinit-binary.patch renamed to fix-docker-init.patch and fixed to build with latest version of docker OBS-URL: https://build.opensuse.org/package/show/Virtualization:containers/docker?expand=0&rev=12
2015-06-22 11:09:23 +02:00
install -p -m 644 man/man5/Dockerfile.5 %{buildroot}%{_mandir}/man5
%endif
%fdupes %{buildroot}
%pre
echo "creating group docker..."
groupadd -r docker 2>/dev/null || :
%service_add_pre %{name}.service %{name}.socket
%post
%service_add_post %{name}.service %{name}.socket
%{fillup_only -n docker}
%preun
%service_del_preun %{name}.service %{name}.socket
%postun
%service_del_postun %{name}.service %{name}.socket
%files
%defattr(-,root,root)
%doc README.md LICENSE README_SUSE.md
%{_bindir}/docker
%{_sbindir}/rcdocker
%{_prefix}/lib/docker/
%{_prefix}/lib/docker/dockerinit
%{_unitdir}/%{name}.service
%{_unitdir}/%{name}.socket
%config %{_sysconfdir}/audit/rules.d/%{name}.rules
%{_prefix}/lib/udev/rules.d/80-%{name}.rules
/var/adm/fillup-templates/sysconfig.docker
%ifarch %go_arches
%{_mandir}/man1/docker-*.1.gz
%{_mandir}/man1/docker.1.gz
%{_mandir}/man5/Dockerfile.5.gz
%endif
%files bash-completion
%defattr(-,root,root)
%config %{_sysconfdir}/bash_completion.d/%{name}
%files zsh-completion
%defattr(-,root,root)
%config %{_sysconfdir}/zsh_completion.d/%{name}
%files test
%defattr(-,root,root)
/usr/src/docker/
# exclude binaries
%exclude /usr/src/docker/bundles/
# exclude init configurations other than systemd
%exclude /usr/src/docker/contrib/init/openrc
%exclude /usr/src/docker/contrib/init/sysvinit-debian
%exclude /usr/src/docker/contrib/init/sysvinit-redhat
%exclude /usr/src/docker/contrib/init/upstart
%changelog