Instead of building a local grafana image with grafyaml installed, use the plain upstream grafana image along with the newly created separate opendev grafyaml image to run the dashboards. Depends-On: https://review.opendev.org/780119 Change-Id: If0d584f848f213aeea385885e3decfaee6303de5changes/28/780128/7
parent
6ebbe44528
commit
1492f22faa
@ -1,26 +0,0 @@
|
||||
# Copyright (c) 2020 Red Hat, Inc.
|
||||
#
|
||||
# Licensed under the Apache License, Version 2.0 (the "License");
|
||||
# you may not use this file except in compliance with the License.
|
||||
# You may obtain a copy of the License at
|
||||
#
|
||||
# http://www.apache.org/licenses/LICENSE-2.0
|
||||
#
|
||||
# Unless required by applicable law or agreed to in writing, software
|
||||
# distributed under the License is distributed on an "AS IS" BASIS,
|
||||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
|
||||
# implied.
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
|
||||
FROM docker.io/grafana/grafana:7.4.2-ubuntu
|
||||
|
||||
LABEL maintainer="infra-root@openstack.org"
|
||||
|
||||
USER root
|
||||
RUN apt-get update && apt-get install -y python3-pip \
|
||||
&& rm -rf /var/lib/apt/lists/*
|
||||
RUN pip3 install grafyaml
|
||||
|
||||
COPY update-grafana /usr/local/bin
|
||||
RUN chmod a+x /usr/local/bin/update-grafana
|
@ -1,11 +0,0 @@
|
||||
#!/bin/bash
|
||||
|
||||
#
|
||||
# Refresh grafana dashboards from project-config
|
||||
#
|
||||
|
||||
GF_USER="$(cat /etc/grafana/secrets/admin_user)"
|
||||
GF_PASSWORD="$(cat /etc/grafana/secrets/admin_password)"
|
||||
GF_URL="http://${GF_USER}:${GF_PASSWORD}@localhost:3000/"
|
||||
|
||||
grafana-dashboard --debug --grafana-url="${GF_URL}" update /opt/project-config/grafana
|
@ -0,0 +1 @@
|
||||
GRAFANA_URL=http://{{ grafana_admin_user }}:{{ grafana_admin_password }}@localhost:3000/
|
@ -1,27 +0,0 @@
|
||||
# Grafana jobs
|
||||
- job:
|
||||
name: system-config-build-image-grafana
|
||||
description: Build a grafana/grafyaml image.
|
||||
provides: grafana-container-image
|
||||
parent: system-config-build-image
|
||||
vars: &grafana_vars
|
||||
docker_images:
|
||||
- context: docker/grafana
|
||||
repository: opendevorg/grafana
|
||||
files: &grafana_files
|
||||
- docker/grafana/
|
||||
|
||||
- job:
|
||||
name: system-config-upload-image-grafana
|
||||
description: Build and upload a grafana image.
|
||||
provides: grafana-container-image
|
||||
parent: system-config-upload-image
|
||||
vars: *grafana_vars
|
||||
files: *grafana_files
|
||||
|
||||
- job:
|
||||
name: system-config-promote-image-grafana
|
||||
description: Promote a previously published grafana image to latest.
|
||||
parent: system-config-promote-image
|
||||
vars: *grafana_vars
|
||||
files: *grafana_files
|
Loading…
Reference in new issue