Skip to content

Instantly share code, notes, and snippets.

@douglasmiranda
Last active January 30, 2018 11:21
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save douglasmiranda/41c582be2e216f09e1c1081a69e66f87 to your computer and use it in GitHub Desktop.
Save douglasmiranda/41c582be2e216f09e1c1081a69e66f87 to your computer and use it in GitHub Desktop.
Packaging Docker CE 17.07 aarch64 on Pine64 (DietPi)
git clone https://github.com/docker/docker-ce
git checkout 17.07

create the dockerfile

components/packaging/deb/debian-jessie/Dockerfile.aarch64

FROM arm64v8/debian:jessie-backports

# allow replacing httpredir or deb mirror
ARG APT_MIRROR=deb.debian.org
RUN sed -ri "s/(httpredir|deb).debian.org/$APT_MIRROR/g" /etc/apt/sources.list

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 gnupg dirmngr --no-install-recommends && rm -rf /var/lib/apt/lists/*

RUN echo "deb http://ppa.launchpad.net/longsleep/golang-backports/ubuntu xenial main" >>/etc/apt/sources.list && \
    apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv-keys 52B59B1571A79DBC054901C0F6BC817356A3D45E  && \
    apt-get update && apt-get install -y golang-1.8 && \
    ln -s /usr/lib/go-1.8/bin/* /usr/bin/

ENV GOPATH /go
ENV PATH $PATH:$GOPATH/bin
ENV DOCKER_BUILDTAGS apparmor pkcs11 seccomp selinux
ENV RUNC_BUILDTAGS apparmor seccomp selinux

COPY common/ /root/build-deb/debian
COPY build-deb /root/build-deb/build-deb

RUN mkdir -p /go/src/github.com/docker && \
    mkdir -p /go/src/github.com/opencontainers && \
    ln -snf /engine /root/build-deb/engine && \
    ln -snf /cli /root/build-deb/cli && \
    ln -snf /root/build-deb/engine /go/src/github.com/docker/docker && \
    ln -snf /root/build-deb/cli /go/src/github.com/docker/cli


ENV DISTRO debian
ENV SUITE jessie

WORKDIR /root/build-deb

ENTRYPOINT ["/root/build-deb/build-deb"]
make deb DOCKER_BUILD_PKGS=debian-jessie

https://github.com/douglas-archives/stuff/blob/master/docker-ce_17.07.0~ce~rc1-0~debian_arm64.deb?raw=true

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment