Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Split docker cli into separate package, deb packaging #128

Merged
merged 1 commit into from
Aug 2, 2018
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 2 additions & 4 deletions deb/Makefile
Original file line number Diff line number Diff line change
@@ -1,11 +1,10 @@
SHELL:=/bin/bash
ARCH:=$(shell uname -m)
ENGINE_DIR:=$(CURDIR)/../../engine
CLI_DIR:=$(CURDIR)/../../cli
GITCOMMIT?=$(shell cd $(ENGINE_DIR) && git rev-parse --short HEAD)
GITCOMMIT?=$(shell cd $(CLI_DIR) && git rev-parse --short HEAD)
VERSION?=0.0.0-dev
GO_VERSION:=1.10.3
DEB_VERSION=$(shell ./gen-deb-ver $(ENGINE_DIR) "$(VERSION)")
DEB_VERSION=$(shell ./gen-deb-ver $(CLI_DIR) "$(VERSION)")
CHOWN:=docker run --rm -v $(CURDIR):/v -w /v alpine chown
EPOCH?=2

Expand All @@ -16,7 +15,6 @@ RUN=docker run --rm -i \
-e VERSION=$(word 2, $(DEB_VERSION)) \
-e DOCKER_GITCOMMIT=$(GITCOMMIT) \
-v $(CURDIR)/debbuild/$@:/build \
-v $(ENGINE_DIR):/engine \
-v $(CLI_DIR):/cli \
-v $(CURDIR)/systemd:/root/build-deb/systemd \
debbuild-$@/$(ARCH)
Expand Down
13 changes: 2 additions & 11 deletions deb/build-deb
Original file line number Diff line number Diff line change
Expand Up @@ -13,18 +13,9 @@ if [[ -z "$DEB_VERSION" ]]; then
exit 1
fi

(
set -e
cd engine
# I want to rip this install-binaries script out so badly
for component in tini "proxy dynamic" "runc all" "containerd dynamic";do
TMP_GOPATH="/go" hack/dockerfile/install/install.sh $component
done
)

echo VERSION AAA $VERSION

VERSION=${VERSION:-$( cat engine/VERSION )}
VERSION=${VERSION:-$( cat cli/VERSION )}

echo VERSION bbb $VERSION

Expand All @@ -40,7 +31,7 @@ EOF
# The space above at the start of the line for the debMaintainer is very important

# Give the script a git commit because it wants it
export DOCKER_GITCOMMIT=${DOCKER_GITCOMMIT-$($GIT_COMMAND rev-parse --short HEAD)}
export DOCKER_GITCOMMIT=${DOCKER_GITCOMMIT-$(cd cli; $GIT_COMMAND rev-parse --short HEAD)}

echo VERSION BBB $VERSION
dpkg-buildpackage -uc -us -I.git
Expand Down
29 changes: 27 additions & 2 deletions deb/common/control
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,8 @@ Vcs-Git: git://github.com/docker/docker.git

Package: docker-ce
Architecture: linux-any
Depends: iptables, ${misc:Depends}, ${perl:Depends}, ${shlibs:Depends}
Recommends: aufs-tools,
Depends: docker-ce-cli, containerd, ${shlibs:Depends}
Recommends: abufs-tools,
ca-certificates,
cgroupfs-mount | cgroup-lite,
git,
Expand All @@ -29,3 +29,28 @@ Description: Docker: the open-source application container engine
language, framework or packaging system. That makes them great building blocks
for deploying and scaling web apps, databases, and backend services without
depending on a particular stack or provider.

Source: docker-ce-cli
Section: admin
Priority: optional
Maintainer: Docker <[email protected]>
Standards-Version: 3.9.6
Homepage: https://dockerproject.org
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should change this to https://docker.com

Vcs-Browser: https://github.com/docker/cli
Vcs-Git: git://github.com/docker/cli.git
Package: docker-ce-cli
Architecture: linux-any
Depends: ${shlibs:Depends}
Recommends:
Conflicts: docker (<< 1.5~), docker.io, lxc-docker, lxc-docker-virtual-package, docker-engine, docker-engine-cs, docker-ee-cli
Replaces:
Description: Docker CLI: the open-source application container engine
Docker is an open source project to build, ship and run any application as a
lightweight container
.
Docker containers are both hardware-agnostic and platform-agnostic. This means
they can run anywhere, from your laptop to the largest EC2 compute instance and
everything in between - and they don't require you to use a particular
language, framework or packaging system. That makes them great building blocks
for deploying and scaling web apps, databases, and backend services without
depending on a particular stack or provider.
2 changes: 2 additions & 0 deletions deb/common/docker-ce-cli.install
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
cli/contrib/completion/fish/docker.fish usr/share/fish/vendor_completions.d/
cli/contrib/completion/zsh/_docker usr/share/zsh/vendor-completions/
File renamed without changes.
20 changes: 0 additions & 20 deletions deb/common/docker-ce.docker.default

This file was deleted.

156 changes: 0 additions & 156 deletions deb/common/docker-ce.docker.init

This file was deleted.

72 changes: 0 additions & 72 deletions deb/common/docker-ce.docker.upstart

This file was deleted.

11 changes: 0 additions & 11 deletions deb/common/docker-ce.install

This file was deleted.

4 changes: 4 additions & 0 deletions deb/common/docker-ce.postinst
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,10 @@ case "$1" in
if ! getent group docker > /dev/null; then
groupadd --system docker
fi
# TODO Needs upgrade vs. install logic handling here
if ctr --namespace docker container info dockerd 2&>1 > /dev/null ; then
docker engine init
fi
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This script is far too naive for the final product, but should be enough to get us bootstrapped.

fi
;;
abort-*)
Expand Down
3 changes: 0 additions & 3 deletions deb/common/docker-ce.udev

This file was deleted.

2 changes: 1 addition & 1 deletion deb/common/docs
Original file line number Diff line number Diff line change
@@ -1 +1 @@
engine/README.md
cli/README.md
Loading