Commit 13a962cc by Leonard Gram

Revert "Docker image for ARM"

This reverts commit 5f7e6a5c.
parent a237a495
...@@ -200,45 +200,45 @@ jobs: ...@@ -200,45 +200,45 @@ jobs:
- dist/grafana* - dist/grafana*
grafana-docker-master: grafana-docker-master:
machine: docker:
image: circleci/classic:201808-01 - image: docker:stable-git
steps: steps:
- checkout - checkout
- attach_workspace: - attach_workspace:
at: . at: .
- setup_remote_docker
- run: docker info - run: docker info
- run: docker run --privileged linuxkit/binfmt:v0.6 - run: cp dist/grafana-latest.linux-x64.tar.gz packaging/docker
- run: cp dist/grafana-latest.linux-*.tar.gz packaging/docker
- run: cd packaging/docker && ./build-deploy.sh "master-${CIRCLE_SHA1}" - run: cd packaging/docker && ./build-deploy.sh "master-${CIRCLE_SHA1}"
- run: rm packaging/docker/grafana-latest.linux-*.tar.gz - run: rm packaging/docker/grafana-latest.linux-x64.tar.gz
- run: cp enterprise-dist/grafana-enterprise-*.linux-amd64.tar.gz packaging/docker/grafana-latest.linux-x64.tar.gz - run: cp enterprise-dist/grafana-enterprise-*.linux-amd64.tar.gz packaging/docker/grafana-latest.linux-x64.tar.gz
- run: cd packaging/docker && ./build-enterprise.sh "master" - run: cd packaging/docker && ./build-enterprise.sh "master"
grafana-docker-pr: grafana-docker-pr:
machine: docker:
image: circleci/classic:201808-01 - image: docker:stable-git
steps: steps:
- checkout - checkout
- attach_workspace: - attach_workspace:
at: . at: .
- setup_remote_docker
- run: docker info - run: docker info
- run: docker run --privileged linuxkit/binfmt:v0.6 - run: cp dist/grafana-latest.linux-x64.tar.gz packaging/docker
- run: cp dist/grafana-latest.linux-*.tar.gz packaging/docker
- run: cd packaging/docker && ./build.sh "${CIRCLE_SHA1}" - run: cd packaging/docker && ./build.sh "${CIRCLE_SHA1}"
grafana-docker-release: grafana-docker-release:
machine: docker:
image: circleci/classic:201808-01 - image: docker:stable-git
steps: steps:
- checkout - checkout
- attach_workspace: - attach_workspace:
at: . at: .
- setup_remote_docker
- run: docker info - run: docker info
- run: docker run --privileged linuxkit/binfmt:v0.6 - run: cp dist/grafana-latest.linux-x64.tar.gz packaging/docker
- run: cp dist/grafana-latest.linux-*.tar.gz packaging/docker
- run: cd packaging/docker && ./build-deploy.sh "${CIRCLE_TAG}" - run: cd packaging/docker && ./build-deploy.sh "${CIRCLE_TAG}"
- run: rm packaging/docker/grafana-latest.linux-*.tar.gz - run: rm packaging/docker/grafana-latest.linux-x64.tar.gz
- run: cp enterprise-dist/grafana-enterprise-*.linux-amd64.tar.gz packaging/docker/grafana-latest.linux-x64.tar.gz - run: cp enterprise-dist/grafana-enterprise-*.linux-amd64.tar.gz packaging/docker/grafana-latest.linux-x64.tar.gz
- run: cd packaging/docker && ./build-enterprise.sh "${CIRCLE_TAG}" - run: cd packaging/docker && ./build-enterprise.sh "${CIRCLE_TAG}"
......
...@@ -164,8 +164,6 @@ func makeLatestDistCopies() { ...@@ -164,8 +164,6 @@ func makeLatestDistCopies() {
"_amd64.deb": "dist/grafana_latest_amd64.deb", "_amd64.deb": "dist/grafana_latest_amd64.deb",
".x86_64.rpm": "dist/grafana-latest-1.x86_64.rpm", ".x86_64.rpm": "dist/grafana-latest-1.x86_64.rpm",
".linux-amd64.tar.gz": "dist/grafana-latest.linux-x64.tar.gz", ".linux-amd64.tar.gz": "dist/grafana-latest.linux-x64.tar.gz",
".linux-armv7.tar.gz": "dist/grafana-latest.linux-armv7.tar.gz",
".linux-arm64.tar.gz": "dist/grafana-latest.linux-arm64.tar.gz",
} }
for _, file := range files { for _, file := range files {
......
ARG BASE_IMAGE=debian:stretch-slim FROM debian:stretch-slim
FROM ${BASE_IMAGE}
ARG GRAFANA_TGZ="grafana-latest.linux-x64.tar.gz" ARG GRAFANA_TGZ="grafana-latest.linux-x64.tar.gz"
...@@ -11,8 +10,7 @@ COPY ${GRAFANA_TGZ} /tmp/grafana.tar.gz ...@@ -11,8 +10,7 @@ COPY ${GRAFANA_TGZ} /tmp/grafana.tar.gz
RUN mkdir /tmp/grafana && tar xfvz /tmp/grafana.tar.gz --strip-components=1 -C /tmp/grafana RUN mkdir /tmp/grafana && tar xfvz /tmp/grafana.tar.gz --strip-components=1 -C /tmp/grafana
ARG BASE_IMAGE=debian:stretch-slim FROM debian:stretch-slim
FROM ${BASE_IMAGE}
ARG GF_UID="472" ARG GF_UID="472"
ARG GF_GID="472" ARG GF_GID="472"
......
...@@ -13,37 +13,13 @@ fi ...@@ -13,37 +13,13 @@ fi
echo "Building ${_docker_repo}:${_grafana_version}" echo "Building ${_docker_repo}:${_grafana_version}"
export DOCKER_CLI_EXPERIMENTAL=enabled docker build \
--tag "${_docker_repo}:${_grafana_version}" \
# Build grafana image for a specific arch
docker_build () {
base_image=$1
grafana_tgz=$2
tag=$3
docker build \
--build-arg BASE_IMAGE=${base_image} \
--build-arg GRAFANA_TGZ=${grafana_tgz} \
--tag "${tag}" \
--no-cache=true . --no-cache=true .
}
# Tag docker images of all architectures
docker_tag_all () {
repo=$1
tag=$2
docker tag "${_docker_repo}:${_grafana_version}" "${repo}:${tag}"
docker tag "${_docker_repo}-arm32v7-linux:${_grafana_version}" "${repo}-arm32v7-linux:${tag}"
docker tag "${_docker_repo}-arm64v8-linux:${_grafana_version}" "${repo}-arm64v8-linux:${tag}"
}
docker_build "debian:stretch-slim" "grafana-latest.linux-x64.tar.gz" "${_docker_repo}:${_grafana_version}"
docker_build "arm32v7/debian:stretch-slim" "grafana-latest.linux-armv7.tar.gz" "${_docker_repo}-arm32v7-linux:${_grafana_version}"
docker_build "arm64v8/debian:stretch-slim" "grafana-latest.linux-arm64.tar.gz" "${_docker_repo}-arm64v8-linux:${_grafana_version}"
# Tag as 'latest' for official release; otherwise tag as grafana/grafana:master # Tag as 'latest' for official release; otherwise tag as grafana/grafana:master
if echo "$_grafana_tag" | grep -q "^v"; then if echo "$_grafana_tag" | grep -q "^v"; then
docker_tag_all "${_docker_repo}" "latest" docker tag "${_docker_repo}:${_grafana_version}" "${_docker_repo}:latest"
else else
docker_tag_all "grafana/grafana" "master" docker tag "${_docker_repo}:${_grafana_version}" "grafana/grafana:master"
fi fi
...@@ -12,34 +12,13 @@ else ...@@ -12,34 +12,13 @@ else
_docker_repo=${2:-grafana/grafana-dev} _docker_repo=${2:-grafana/grafana-dev}
fi fi
export DOCKER_CLI_EXPERIMENTAL=enabled
echo "pushing ${_docker_repo}:${_grafana_version}" echo "pushing ${_docker_repo}:${_grafana_version}"
docker push "${_docker_repo}:${_grafana_version}"
docker_push_all () {
repo=$1
tag=$2
# Push each image individually
docker push "${repo}:${tag}"
docker push "${repo}-arm32v7-linux:${tag}"
docker push "${repo}-arm64v8-linux:${tag}"
# Create and push a multi-arch manifest
docker manifest create "${repo}:${tag}" \
"${repo}:${tag}" \
"${repo}-arm32v7-linux:${tag}" \
"${repo}-arm64v8-linux:${tag}"
docker manifest push "${repo}:${tag}"
}
docker_push_all "${_docker_repo}" "${_grafana_version}"
if echo "$_grafana_tag" | grep -q "^v" && echo "$_grafana_tag" | grep -vq "beta"; then if echo "$_grafana_tag" | grep -q "^v" && echo "$_grafana_tag" | grep -vq "beta"; then
echo "pushing ${_docker_repo}:latest" echo "pushing ${_docker_repo}:latest"
docker_push_all "${_docker_repo}" "latest" docker push "${_docker_repo}:latest"
elif echo "$_grafana_tag" | grep -q "master"; then elif echo "$_grafana_tag" | grep -q "master"; then
docker_push_all "grafana/grafana" "master" echo "pushing grafana/grafana:master"
docker push grafana/grafana:master
fi fi
...@@ -8,8 +8,6 @@ set -e ...@@ -8,8 +8,6 @@ set -e
EXTRA_OPTS="$@" EXTRA_OPTS="$@"
CCARMV7=arm-linux-gnueabihf-gcc
CCARM64=aarch64-linux-gnu-gcc
CCX64=/tmp/x86_64-centos6-linux-gnu/bin/x86_64-centos6-linux-gnu-gcc CCX64=/tmp/x86_64-centos6-linux-gnu/bin/x86_64-centos6-linux-gnu-gcc
GOPATH=/go GOPATH=/go
...@@ -28,9 +26,6 @@ fi ...@@ -28,9 +26,6 @@ fi
echo "Build arguments: $OPT" echo "Build arguments: $OPT"
go run build.go -goarch armv7 -cc ${CCARMV7} ${OPT} build
go run build.go -goarch arm64 -cc ${CCARM64} ${OPT} build
CC=${CCX64} go run build.go ${OPT} build CC=${CCX64} go run build.go ${OPT} build
yarn install --pure-lockfile --no-progress yarn install --pure-lockfile --no-progress
...@@ -49,5 +44,3 @@ source /etc/profile.d/rvm.sh ...@@ -49,5 +44,3 @@ source /etc/profile.d/rvm.sh
echo "Packaging" echo "Packaging"
go run build.go -goos linux -pkg-arch amd64 ${OPT} package-only latest go run build.go -goos linux -pkg-arch amd64 ${OPT} package-only latest
go run build.go -goos linux -pkg-arch armv7 ${OPT} package-only latest
go run build.go -goos linux -pkg-arch arm64 ${OPT} package-only latest
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment