aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorCedric Ollivier <cedric.ollivier@orange.com>2019-04-13 09:27:07 +0000
committerGerrit Code Review <gerrit@opnfv.org>2019-04-13 09:27:07 +0000
commitb6d53211595f328c62c57a825f7de79ef805c877 (patch)
tree1b749cb091899ce6049e8cfcc4a3c0caa02cb841
parent657198e01d44c20610ea7b007dfeb7608a5996c6 (diff)
parent108be5e77a4832cd648474e4c3398fdaae9829ea (diff)
Merge "Build Raspberry PI image via travis-ci"
-rw-r--r--.travis.yml6
-rw-r--r--build.sh6
2 files changed, 10 insertions, 2 deletions
diff --git a/.travis.yml b/.travis.yml
index 20f4dd45..1aae11ed 100644
--- a/.travis.yml
+++ b/.travis.yml
@@ -20,10 +20,14 @@ jobs:
- script: sudo -E bash build.sh
env:
- REPO="${DOCKER_USERNAME}"
+ - arch="arm"
+ - script: sudo -E bash build.sh
+ env:
+ - REPO="${DOCKER_USERNAME}"
- arch="arm64"
- stage: publish xtesting manifests
script: >
sudo manifest-tool push from-args \
- --platforms linux/amd64,linux/arm64 \
+ --platforms linux/amd64,linux/arm,linux/arm64 \
--template ${DOCKER_USERNAME}/xtesting:ARCH-latest \
--target ${DOCKER_USERNAME}/xtesting:latest
diff --git a/build.sh b/build.sh
index 6c2a0c71..92e475c4 100644
--- a/build.sh
+++ b/build.sh
@@ -11,7 +11,8 @@ repo=${REPO:-opnfv}
tag=${BRANCH:-latest}
arch=${arch-"\
amd64 \
-arm64"}
+arm64 \
+arm"}
image="xtesting"
build_opts=(--pull=true --no-cache --force-rm=true)
@@ -19,6 +20,9 @@ for arch in ${arch};do
if [[ ${arch} == arm64 ]]; then
find . -name Dockerfile -exec sed -i \
-e "s|alpine:3.9|multiarch/alpine:arm64-v3.9|g" {} +
+ elif [[ ${arch} == arm ]]; then
+ find . -name Dockerfile -exec sed -i \
+ -e "s|alpine:3.9|multiarch/alpine:armhf-v3.9|g" {} +
fi
(cd docker && docker build "${build_opts[@]}" \
-t "${repo}/${image}:${arch}-${tag}" .)