diff --git a/components/packaging/deb/common/rules b/components/packaging/deb/common/rules index e2962bb78e..14d91c3b21 100644 --- a/components/packaging/deb/common/rules +++ b/components/packaging/deb/common/rules @@ -1,7 +1,6 @@ #!/usr/bin/make -f VERSION ?= $(shell cat engine/VERSION) -BUNDLE_VERSION = $(shell cat engine/VERSION) SYSTEMD_VERSION := $(shell dpkg-query -W -f='$${Version}\n' systemd | cut -d- -f1) SYSTEMD_GT_227 := $(shell [ '$(SYSTEMD_VERSION)' ] && [ '$(SYSTEMD_VERSION)' -gt 227 ] && echo true ) @@ -15,7 +14,7 @@ override_dh_auto_build: cd /go/src/github.com/docker/cli && LDFLAGS='' make VERSION=$(VERSION) GITCOMMIT=$(DOCKER_GITCOMMIT) dynbinary manpages override_dh_auto_test: - ./engine/bundles/$(BUNDLE_VERSION)/dynbinary-daemon/dockerd -v + ./engine/bundles/dynbinary-daemon/dockerd -v override_dh_strip: # Go has lots of problems with stripping, so just don't @@ -23,7 +22,7 @@ override_dh_strip: override_dh_auto_install: mkdir -p debian/docker-ce/usr/bin cp -aTL cli/build/docker debian/docker-ce/usr/bin/docker - cp -aT "$$(readlink -f engine/bundles/$(BUNDLE_VERSION)/dynbinary-daemon/dockerd)" debian/docker-ce/usr/bin/dockerd + cp -aT "$$(readlink -f engine/bundles/dynbinary-daemon/dockerd)" debian/docker-ce/usr/bin/dockerd cp -aT /usr/local/bin/docker-proxy debian/docker-ce/usr/bin/docker-proxy cp -aT /usr/local/bin/docker-containerd debian/docker-ce/usr/bin/docker-containerd cp -aT /usr/local/bin/docker-containerd-shim debian/docker-ce/usr/bin/docker-containerd-shim diff --git a/components/packaging/deb/debian-jessie/Dockerfile.armv7l b/components/packaging/deb/debian-jessie/Dockerfile.armv7l index 6bebacabf2..12426ddaf5 100644 --- a/components/packaging/deb/debian-jessie/Dockerfile.armv7l +++ b/components/packaging/deb/debian-jessie/Dockerfile.armv7l @@ -1,4 +1,4 @@ -FROM armhf/debian:jessie +FROM arm32v7/debian:jessie # allow replacing httpredir or deb mirror ARG APT_MIRROR=deb.debian.org diff --git a/components/packaging/deb/debian-stretch/Dockerfile.armv7l b/components/packaging/deb/debian-stretch/Dockerfile.armv7l index f173cfd465..27edd03182 100644 --- a/components/packaging/deb/debian-stretch/Dockerfile.armv7l +++ b/components/packaging/deb/debian-stretch/Dockerfile.armv7l @@ -1,4 +1,4 @@ -FROM armhf/debian:stretch +FROM arm32v7/debian:stretch # allow replacing httpredir or deb mirror ARG APT_MIRROR=deb.debian.org diff --git a/components/packaging/deb/ubuntu-trusty/Dockerfile.armv7l b/components/packaging/deb/ubuntu-trusty/Dockerfile.armv7l index b39912c706..8b414afc9b 100644 --- a/components/packaging/deb/ubuntu-trusty/Dockerfile.armv7l +++ b/components/packaging/deb/ubuntu-trusty/Dockerfile.armv7l @@ -1,4 +1,4 @@ -FROM armhf/ubuntu:trusty +FROM arm32v7/ubuntu:trusty RUN apt-get update && apt-get install -y apparmor bash-completion btrfs-tools build-essential cmake curl ca-certificates debhelper dh-apparmor dh-systemd git libapparmor-dev libdevmapper-dev libltdl-dev pkg-config vim-common libsystemd-journal-dev --no-install-recommends && rm -rf /var/lib/apt/lists/* diff --git a/components/packaging/deb/ubuntu-xenial/Dockerfile.aarch64 b/components/packaging/deb/ubuntu-xenial/Dockerfile.aarch64 index fd2ca681d2..cfa8db3e65 100644 --- a/components/packaging/deb/ubuntu-xenial/Dockerfile.aarch64 +++ b/components/packaging/deb/ubuntu-xenial/Dockerfile.aarch64 @@ -1,4 +1,4 @@ -FROM aarch64/ubuntu:xenial +FROM arm64v8/ubuntu:xenial RUN apt-get update && apt-get install -y golang-go apparmor bash-completion btrfs-tools build-essential cmake curl ca-certificates debhelper dh-apparmor dh-systemd git libapparmor-dev libdevmapper-dev libltdl-dev libseccomp-dev pkg-config vim-common libsystemd-dev --no-install-recommends && rm -rf /var/lib/apt/lists/* diff --git a/components/packaging/deb/ubuntu-xenial/Dockerfile.armv7l b/components/packaging/deb/ubuntu-xenial/Dockerfile.armv7l index d51ffa6b52..39c83c45b0 100644 --- a/components/packaging/deb/ubuntu-xenial/Dockerfile.armv7l +++ b/components/packaging/deb/ubuntu-xenial/Dockerfile.armv7l @@ -1,4 +1,4 @@ -FROM armhf/ubuntu:xenial +FROM arm32v7/ubuntu:xenial RUN apt-get update && apt-get install -y apparmor bash-completion btrfs-tools build-essential cmake curl ca-certificates debhelper dh-apparmor dh-systemd git libapparmor-dev libdevmapper-dev libltdl-dev libseccomp-dev pkg-config vim-common libsystemd-dev --no-install-recommends && rm -rf /var/lib/apt/lists/* diff --git a/components/packaging/deb/ubuntu-zesty/Dockerfile.armv7l b/components/packaging/deb/ubuntu-zesty/Dockerfile.armv7l index 670e8f1d6c..3a5f9d23c0 100644 --- a/components/packaging/deb/ubuntu-zesty/Dockerfile.armv7l +++ b/components/packaging/deb/ubuntu-zesty/Dockerfile.armv7l @@ -1,4 +1,4 @@ -FROM armhf/ubuntu:zesty +FROM arm32v7/ubuntu:zesty RUN apt-get update && apt-get install -y apparmor bash-completion btrfs-tools build-essential cmake curl ca-certificates debhelper dh-apparmor dh-systemd git libapparmor-dev libdevmapper-dev libltdl-dev libseccomp-dev pkg-config vim-common libsystemd-dev --no-install-recommends && rm -rf /var/lib/apt/lists/* diff --git a/components/packaging/detect_alpine_image b/components/packaging/detect_alpine_image index 756e7dd550..4efa32e4aa 100755 --- a/components/packaging/detect_alpine_image +++ b/components/packaging/detect_alpine_image @@ -6,11 +6,11 @@ img="unknown" if [ "$arch" = "x86_64" ]; then img="alpine" elif [ "$arch" = "armv7l" ]; then - img="armhf/alpine" + img="arm32v6/alpine" elif [ "$arch" = "s390x" ]; then img="s390x/alpine" elif [ "$arch" = "aarch64" ]; then - img="aarch64/alpine" + img="arm64v8/alpine" elif [ "$arch" = "ppc64le" ]; then img="ppc64le/alpine" else diff --git a/components/packaging/rpm/centos-7/docker-ce.spec b/components/packaging/rpm/centos-7/docker-ce.spec index 82aaad9676..a1abe5c0fa 100644 --- a/components/packaging/rpm/centos-7/docker-ce.spec +++ b/components/packaging/rpm/centos-7/docker-ce.spec @@ -66,18 +66,18 @@ make VERSION=%{_origversion} GITCOMMIT=%{_gitcommit} dynbinary manpages # cli popd pushd engine TMP_GOPATH="/go" hack/dockerfile/install-binaries.sh runc-dynamic containerd-dynamic proxy-dynamic tini -hack/make.sh dynbinary +VERSION=%{_origversion} hack/make.sh dynbinary popd %check cli/build/docker -v -engine/bundles/%{_origversion}/dynbinary-daemon/dockerd -v +engine/bundles/dynbinary-daemon/dockerd -v %install # install binary install -d $RPM_BUILD_ROOT/%{_bindir} install -p -m 755 cli/build/docker $RPM_BUILD_ROOT/%{_bindir}/docker -install -p -m 755 engine/bundles/%{_origversion}/dynbinary-daemon/dockerd-%{_origversion} $RPM_BUILD_ROOT/%{_bindir}/dockerd +install -p -m 755 $(readlink -f engine/bundles/dynbinary-daemon/dockerd) $RPM_BUILD_ROOT/%{_bindir}/dockerd # install proxy install -p -m 755 /usr/local/bin/docker-proxy $RPM_BUILD_ROOT/%{_bindir}/docker-proxy diff --git a/components/packaging/rpm/fedora-25/docker-ce.spec b/components/packaging/rpm/fedora-25/docker-ce.spec index 86c953a475..20ca378c2a 100644 --- a/components/packaging/rpm/fedora-25/docker-ce.spec +++ b/components/packaging/rpm/fedora-25/docker-ce.spec @@ -65,18 +65,18 @@ make VERSION=%{_origversion} GITCOMMIT=%{_gitcommit} dynbinary manpages # cli popd pushd engine TMP_GOPATH="/go" hack/dockerfile/install-binaries.sh runc-dynamic containerd-dynamic proxy-dynamic tini -hack/make.sh dynbinary +VERSION=%{_origversion} hack/make.sh dynbinary popd %check cli/build/docker -v -engine/bundles/%{_origversion}/dynbinary-daemon/dockerd -v +engine/bundles/dynbinary-daemon/dockerd -v %install # install binary install -d $RPM_BUILD_ROOT/%{_bindir} install -p -m 755 cli/build/docker $RPM_BUILD_ROOT/%{_bindir}/docker -install -p -m 755 engine/bundles/%{_origversion}/dynbinary-daemon/dockerd-%{_origversion} $RPM_BUILD_ROOT/%{_bindir}/dockerd +install -p -m 755 $(readlink -f engine/bundles/dynbinary-daemon/dockerd) $RPM_BUILD_ROOT/%{_bindir}/dockerd # install proxy install -p -m 755 /usr/local/bin/docker-proxy $RPM_BUILD_ROOT/%{_bindir}/docker-proxy diff --git a/components/packaging/rpm/fedora-26/docker-ce.spec b/components/packaging/rpm/fedora-26/docker-ce.spec index 08b7df168e..179e684a70 100644 --- a/components/packaging/rpm/fedora-26/docker-ce.spec +++ b/components/packaging/rpm/fedora-26/docker-ce.spec @@ -65,20 +65,20 @@ make VERSION=%{_origversion} GITCOMMIT=%{_gitcommit} dynbinary manpages # cli popd pushd engine TMP_GOPATH="/go" hack/dockerfile/install-binaries.sh runc-dynamic containerd-dynamic proxy-dynamic tini -hack/make.sh dynbinary +VERSION=%{_origversion} hack/make.sh dynbinary popd mkdir -p plugin printf '{"edition_type":"ce","edition_name":"%s","edition_version":"%s"}\n' "${DISTRO}" "%{_version}" > plugin/.plugin-metadata %check cli/build/docker -v -engine/bundles/%{_origversion}/dynbinary-daemon/dockerd -v +engine/bundles/dynbinary-daemon/dockerd -v %install # install binary install -d $RPM_BUILD_ROOT/%{_bindir} install -p -m 755 cli/build/docker $RPM_BUILD_ROOT/%{_bindir}/docker -install -p -m 755 engine/bundles/%{_origversion}/dynbinary-daemon/dockerd-%{_origversion} $RPM_BUILD_ROOT/%{_bindir}/dockerd +install -p -m 755 $(readlink -f engine/bundles/dynbinary-daemon/dockerd) $RPM_BUILD_ROOT/%{_bindir}/dockerd # install proxy install -p -m 755 /usr/local/bin/docker-proxy $RPM_BUILD_ROOT/%{_bindir}/docker-proxy diff --git a/components/packaging/static/Makefile b/components/packaging/static/Makefile index a6c727682d..d8d657d99e 100644 --- a/components/packaging/static/Makefile +++ b/components/packaging/static/Makefile @@ -2,7 +2,6 @@ SHELL:=/bin/bash ALPINE_IMG:=$(shell $(CURDIR)/../detect_alpine_image) ENGINE_DIR:=$(CURDIR)/../../engine CLI_DIR:=$(CURDIR)/../../cli -ENGINE_VER=$(shell cat $(ENGINE_DIR)/VERSION) VERSION=$(shell cat $(ENGINE_DIR)/VERSION) CHOWN=docker run --rm -v $(CURDIR):/v -w /v $(ALPINE_IMG) chown HASH_CMD=docker run -v $(CURDIR):/sum -w /sum debian:jessie bash hash_files @@ -23,7 +22,7 @@ static-linux: static-cli static-engine ## create tgz with linux x86_64 client an mkdir -p build/linux/docker cp $(CLI_DIR)/build/docker build/linux/docker/ for f in dockerd docker-containerd docker-containerd-ctr docker-containerd-shim docker-init docker-proxy docker-runc; do \ - cp $(ENGINE_DIR)/bundles/$(ENGINE_VER)/binary-daemon/$$f build/linux/docker; \ + cp -L $(ENGINE_DIR)/bundles/binary-daemon/$$f build/linux/docker/$$f; \ done tar -C build/linux -c -z -f build/linux/docker-$(VERSION).tgz docker @@ -39,7 +38,7 @@ cross-mac: cross-all-cli ## create tgz with darwin x86_64 client only cross-win: cross-all-cli cross-win-engine ## create zip file with windows x86_64 client and server mkdir -p build/win/docker cp $(CLI_DIR)/build/docker-windows-amd64 build/win/docker/docker.exe - cp $(ENGINE_DIR)/bundles/$(ENGINE_VER)/cross/windows/amd64/dockerd-$(ENGINE_VER).exe build/win/docker/dockerd.exe + cp $(ENGINE_DIR)/bundles/cross/windows/amd64/dockerd-$(VERSION).exe build/win/docker/dockerd.exe docker run --rm -v $(CURDIR)/build/win:/v -w /v $(ALPINE_IMG) sh -c 'apk update&&apk add zip&&zip -r docker-$(VERSION).zip docker' $(CHOWN) -R $(shell id -u):$(shell id -g) build