mirror of
https://github.com/grafana/grafana.git
synced 2024-11-28 03:34:15 -06:00
build: builds docker image from local grafna tgz.
This commit is contained in:
parent
bfe41d3cf1
commit
e3a907214d
@ -190,6 +190,7 @@ jobs:
|
||||
- setup_remote_docker
|
||||
- run: docker info
|
||||
- run: echo $GRAFANA_VERSION
|
||||
- run: cp dist/grafana-latest.linux-x64.tar.gz packaging/docker
|
||||
- run: cd packaging/docker && ./build.sh ${GRAFANA_VERSION}
|
||||
|
||||
build-enterprise:
|
||||
|
@ -1,6 +1,6 @@
|
||||
FROM debian:stretch-slim
|
||||
|
||||
ARG GRAFANA_URL="https://s3-us-west-2.amazonaws.com/grafana-releases/master/grafana-latest.linux-x64.tar.gz"
|
||||
ARG GRAFANA_TGZ="grafana-latest.linux-x64.tar.gz"
|
||||
ARG GF_UID="472"
|
||||
ARG GF_GID="472"
|
||||
|
||||
@ -12,9 +12,12 @@ ENV PATH=/usr/share/grafana/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bi
|
||||
GF_PATHS_PLUGINS="/var/lib/grafana/plugins" \
|
||||
GF_PATHS_PROVISIONING="/etc/grafana/provisioning"
|
||||
|
||||
RUN apt-get update && apt-get install -qq -y tar libfontconfig curl ca-certificates && \
|
||||
COPY ${GRAFANA_TGZ} /tmp/grafana.tar.gz
|
||||
|
||||
RUN apt-get update && apt-get install -qq -y tar libfontconfig ca-certificates && \
|
||||
mkdir -p "$GF_PATHS_HOME/.aws" && \
|
||||
curl "$GRAFANA_URL" | tar xfvz - --strip-components=1 -C "$GF_PATHS_HOME" && \
|
||||
tar xfvz /tmp/grafana.tar.gz --strip-components=1 -C "$GF_PATHS_HOME" && \
|
||||
rm /tmp/grafana.tar.gz && \
|
||||
apt-get autoremove -y && \
|
||||
rm -rf /var/lib/apt/lists/* && \
|
||||
groupadd -r -g $GF_GID grafana && \
|
||||
@ -35,4 +38,4 @@ COPY ./run.sh /run.sh
|
||||
|
||||
USER grafana
|
||||
WORKDIR /
|
||||
ENTRYPOINT [ "/run.sh" ]
|
||||
ENTRYPOINT [ "/run.sh" ]
|
||||
|
@ -10,7 +10,6 @@ echo ${_grafana_version}
|
||||
if [ "$_grafana_version" != "" ]; then
|
||||
echo "Building version ${_grafana_version}"
|
||||
docker build \
|
||||
--build-arg GRAFANA_URL="https://s3-us-west-2.amazonaws.com/grafana-releases/release/grafana-${_grafana_version}.linux-amd64.tar.gz" \
|
||||
--tag "${_docker_repo}:${_grafana_version}" \
|
||||
--no-cache=true .
|
||||
docker tag ${_docker_repo}:${_grafana_version} ${_docker_repo}:latest
|
||||
|
Loading…
Reference in New Issue
Block a user