mirror of
https://github.com/moby/moby.git
synced 2022-11-09 12:21:53 -05:00
Merge pull request #31193 from docbobo/master-aarch64
Support for debian-jessie on aarch64
This commit is contained in:
commit
4108d6259a
5 changed files with 72 additions and 6 deletions
25
contrib/builder/deb/aarch64/debian-jessie/Dockerfile
Normal file
25
contrib/builder/deb/aarch64/debian-jessie/Dockerfile
Normal file
|
@ -0,0 +1,25 @@
|
|||
#
|
||||
# THIS FILE IS AUTOGENERATED; SEE "contrib/builder/deb/aarch64/generate.sh"!
|
||||
#
|
||||
|
||||
FROM aarch64/debian:jessie
|
||||
|
||||
RUN echo deb http://ftp.debian.org/debian jessie-backports main > /etc/apt/sources.list.d/backports.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 pkg-config vim-common libsystemd-journal-dev golang-1.6-go libseccomp-dev --no-install-recommends && rm -rf /var/lib/apt/lists/*
|
||||
|
||||
RUN update-alternatives --install /usr/bin/go go /usr/lib/go-1.6/bin/go 100
|
||||
|
||||
# Install Go
|
||||
# aarch64 doesn't have official go binaries, so use the version of go installed from
|
||||
# the image to build go from source.
|
||||
ENV GO_VERSION 1.7.5
|
||||
RUN mkdir /usr/src/go && curl -fsSL https://golang.org/dl/go${GO_VERSION}.src.tar.gz | tar -v -C /usr/src/go -xz --strip-components=1 \
|
||||
&& cd /usr/src/go/src \
|
||||
&& GOOS=linux GOARCH=arm64 GOROOT_BOOTSTRAP="$(go env GOROOT)" ./make.bash
|
||||
|
||||
ENV PATH /usr/src/go/bin:$PATH
|
||||
|
||||
ENV AUTO_GOPATH 1
|
||||
|
||||
ENV DOCKER_BUILDTAGS apparmor pkcs11 selinux seccomp
|
||||
ENV RUNC_BUILDTAGS apparmor selinux seccomp
|
22
contrib/builder/deb/aarch64/debian-stretch/Dockerfile
Normal file
22
contrib/builder/deb/aarch64/debian-stretch/Dockerfile
Normal file
|
@ -0,0 +1,22 @@
|
|||
#
|
||||
# THIS FILE IS AUTOGENERATED; SEE "contrib/builder/deb/aarch64/generate.sh"!
|
||||
#
|
||||
|
||||
FROM aarch64/debian:stretch
|
||||
|
||||
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-dev golang-go libseccomp-dev --no-install-recommends && rm -rf /var/lib/apt/lists/*
|
||||
|
||||
# Install Go
|
||||
# aarch64 doesn't have official go binaries, so use the version of go installed from
|
||||
# the image to build go from source.
|
||||
ENV GO_VERSION 1.7.5
|
||||
RUN mkdir /usr/src/go && curl -fsSL https://golang.org/dl/go${GO_VERSION}.src.tar.gz | tar -v -C /usr/src/go -xz --strip-components=1 \
|
||||
&& cd /usr/src/go/src \
|
||||
&& GOOS=linux GOARCH=arm64 GOROOT_BOOTSTRAP="$(go env GOROOT)" ./make.bash
|
||||
|
||||
ENV PATH /usr/src/go/bin:$PATH
|
||||
|
||||
ENV AUTO_GOPATH 1
|
||||
|
||||
ENV DOCKER_BUILDTAGS apparmor pkcs11 selinux seccomp
|
||||
ENV RUNC_BUILDTAGS apparmor selinux seccomp
|
|
@ -69,9 +69,20 @@ for version in "${versions[@]}"; do
|
|||
# golang-1.6-go package can be used as bootstrap.
|
||||
packages+=( golang-1.6-go )
|
||||
;;
|
||||
xenial)
|
||||
jessie)
|
||||
packages+=( libsystemd-journal-dev )
|
||||
# aarch64 doesn't have an official downloadable binary for go.
|
||||
# And gccgo for jessie only includes Go 1.2 implementation which
|
||||
# is too old to build current go source, fortunately jessie backports
|
||||
# has golang-1.6-go package can be used as bootstrap.
|
||||
packages+=( golang-1.6-go libseccomp-dev )
|
||||
|
||||
dockerBuildTags="$dockerBuildTags seccomp"
|
||||
runcBuildTags="$runcBuildTags seccomp"
|
||||
;;
|
||||
stretch|xenial)
|
||||
packages+=( libsystemd-dev )
|
||||
packages+=( golang-go libseccomp-dev)
|
||||
packages+=( golang-go libseccomp-dev )
|
||||
|
||||
dockerBuildTags="$dockerBuildTags seccomp"
|
||||
runcBuildTags="$runcBuildTags seccomp"
|
||||
|
@ -83,12 +94,20 @@ for version in "${versions[@]}"; do
|
|||
;;
|
||||
esac
|
||||
|
||||
case "$suite" in
|
||||
jessie)
|
||||
echo 'RUN echo deb http://ftp.debian.org/debian jessie-backports main > /etc/apt/sources.list.d/backports.list' >> "$version/Dockerfile"
|
||||
;;
|
||||
*)
|
||||
;;
|
||||
esac
|
||||
|
||||
# update and install packages
|
||||
echo "RUN apt-get update && apt-get install -y ${packages[*]} --no-install-recommends && rm -rf /var/lib/apt/lists/*" >> "$version/Dockerfile"
|
||||
echo >> "$version/Dockerfile"
|
||||
|
||||
case "$suite" in
|
||||
trusty)
|
||||
jessie|trusty)
|
||||
echo 'RUN update-alternatives --install /usr/bin/go go /usr/lib/go-1.6/bin/go 100' >> "$version/Dockerfile"
|
||||
echo >> "$version/Dockerfile"
|
||||
;;
|
||||
|
@ -106,7 +125,7 @@ for version in "${versions[@]}"; do
|
|||
echo ' && GOOS=linux GOARCH=arm64 GOROOT_BOOTSTRAP="$(go env GOROOT)" ./make.bash' >> "$version/Dockerfile"
|
||||
echo >> "$version/Dockerfile"
|
||||
|
||||
echo 'ENV PATH $PATH:/usr/src/go/bin' >> "$version/Dockerfile"
|
||||
echo 'ENV PATH /usr/src/go/bin:$PATH' >> "$version/Dockerfile"
|
||||
echo >> "$version/Dockerfile"
|
||||
|
||||
echo "ENV AUTO_GOPATH 1" >> "$version/Dockerfile"
|
||||
|
|
|
@ -16,7 +16,7 @@ RUN mkdir /usr/src/go && curl -fsSL https://golang.org/dl/go${GO_VERSION}.src.ta
|
|||
&& cd /usr/src/go/src \
|
||||
&& GOOS=linux GOARCH=arm64 GOROOT_BOOTSTRAP="$(go env GOROOT)" ./make.bash
|
||||
|
||||
ENV PATH $PATH:/usr/src/go/bin
|
||||
ENV PATH /usr/src/go/bin:$PATH
|
||||
|
||||
ENV AUTO_GOPATH 1
|
||||
|
||||
|
|
|
@ -14,7 +14,7 @@ RUN mkdir /usr/src/go && curl -fsSL https://golang.org/dl/go${GO_VERSION}.src.ta
|
|||
&& cd /usr/src/go/src \
|
||||
&& GOOS=linux GOARCH=arm64 GOROOT_BOOTSTRAP="$(go env GOROOT)" ./make.bash
|
||||
|
||||
ENV PATH $PATH:/usr/src/go/bin
|
||||
ENV PATH /usr/src/go/bin:$PATH
|
||||
|
||||
ENV AUTO_GOPATH 1
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue