Skip to content
Snippets Groups Projects
Verified Commit 2f8bbe12 authored by Maarten de Waard's avatar Maarten de Waard :angel:
Browse files

grafana or prometheus renamed both to prometheus-stack

parent 7f2ef8f2
No related branches found
No related tags found
No related merge requests found
......@@ -41,7 +41,7 @@
# - A pipeline gets started from the UI and the job name is included in the
# CI variable `TRIGGER_JOBS`
# - A commit is pushed containing the pattern TRIGGER_JOBS=.*<job name>
# (i.e. TRIGGER_JOBS=ci-test-image-build,enable-grafana)
# (i.e. TRIGGER_JOBS=ci-test-image-build,enable-nextcloud)
#
# Gitlab CI allows pushing CI vars via `git push` but a bug prevents this when
# using merge request pipelines (see https://gitlab.com/gitlab-org/gitlab/-/issues/326098)
......@@ -407,15 +407,6 @@ eventrouter-ready:
- .apps-ready
- .eventrouter_rules
grafana-ready:
variables:
APP: "grafana"
needs:
- job: prometheus-stack-helm-release
extends:
- .apps-ready
- .prometheus_stack_rules
nextcloud-ready:
variables:
APP: "nextcloud"
......@@ -480,15 +471,6 @@ wordpress-ready:
extends:
- .ssh_setup
grafana-cert:
variables:
APP: "grafana"
needs:
- job: grafana-ready
extends:
- .apps-cert
- .prometheus_stack_rules
nextcloud-cert:
variables:
APP: "nextcloud"
......@@ -593,11 +575,11 @@ prometheus-stack-alerts:
extends:
- .ssh_setup
grafana-behave:
prometheus-stack-behave:
variables:
APP: "grafana"
APP: "prometheus-stack"
needs:
- job: grafana-cert
- job: prometheus-stack-cert
extends:
- .behave
- .prometheus_stack_rules
......
---
- name: Create Kubernetes secret with grafana settings
tags:
- config
- flux
- monitoring
- grafana
vars:
flux_secret:
name: "grafana"
namespace: "oas"
include_tasks:
file: flux_secret.yml
apply:
tags:
- config
- flux
- monitoring
- grafana
- name: Create monitoring-related persistent volumes
tags:
- config
- monitoring
- grafana
vars:
pvc:
name: "{{ item.name }}"
namespace: "oas"
size: "{{ item.size }}"
include_tasks:
file: pvc.yml
apply:
tags:
- config
- monitoring
- grafana
loop:
- name: "grafana"
size: "2Gi"
......@@ -83,6 +83,21 @@ alertmanager:
prometheus:
prometheusSpec:
scrapeInterval: "3m"
evaluationInterval: "3m"
retention: "10d"
# replicas: 2
# podAntiAffinity: "hard"
storageSpec:
volumeClaimTemplate:
spec:
accessModes: ["ReadWriteOnce"]
resources:
requests:
storage: 10Gi
{% if prometheus_enable_ingress is defined and prometheus_enable_ingress %}
ingress:
enabled: true
......@@ -98,20 +113,6 @@ prometheus:
hosts:
- "prometheus.{{ domain }}"
{% endif %}
prometheusSpec:
scrapeInterval: "3m"
evaluationInterval: "3m"
retention: "10d"
# replicas: 2
# podAntiAffinity: "hard"
storageSpec:
volumeClaimTemplate:
spec:
accessModes: ["ReadWriteOnce"]
resources:
requests:
storage: 10Gi
# resources:
# limits:
......@@ -158,48 +159,48 @@ grafana:
backup.velero.io/backup-volumes: "storage"
# This allows us to pick up the Loki datasource
sidecar:
datasources:
enabled: true
label: grafana_datasource
# Make a configmap with the label `grafana_dashboard` to add dashboards to
# Grafana.
dashboards:
enabled: true
lablel: grafana_dashboard
# sidecar:
# datasources:
# enabled: true
# label: grafana_datasource
# # Make a configmap with the label `grafana_dashboard` to add dashboards to
# # Grafana.
# dashboards:
# enabled: true
# lablel: grafana_dashboard
dashboardProviders:
dashboardproviders.yaml:
apiVersion: 1
providers:
- name: 'default'
orgId: 1
folder: ''
type: file
disableDeletion: false
editable: true
options:
path: /var/lib/grafana/dashboards
dashboards:
default:
kube-dash:
gnetId: 11074
revision: 2
datasource: Prometheus
loki-dash:
gnetId: 10880
revision: 1
datasource: Loki
# dashboardProviders:
# dashboardproviders.yaml:
# apiVersion: 1
# providers:
# - name: 'default'
# orgId: 1
# folder: ''
# type: file
# disableDeletion: false
# editable: true
# options:
# path: /var/lib/grafana/dashboards
# dashboards:
# default:
# kube-dash:
# gnetId: 11074
# revision: 2
# datasource: Prometheus
# loki-dash:
# gnetId: 10880
# revision: 1
# datasource: Loki
datasources:
datasources.yaml:
apiVersion: 1
datasources:
- name: Prometheus
type: prometheus
url: http://prometheus-server
access: proxy
isDefault: true
# datasources:
# datasources.yaml:
# apiVersion: 1
# datasources:
# - name: Prometheus
# type: prometheus
# url: http://prometheus-server
# access: proxy
# isDefault: true
plugins:
- grafana-piechart-panel
......
---
apiVersion: helm.fluxcd.io/v1
kind: HelmRelease
metadata:
name: grafana
namespace: oas
annotations:
flux.weave.works/automated: "false"
spec:
releaseName: grafana
chart:
repository: https://grafana.github.io/helm-charts
name: grafana
version: 6.2.1
valuesFrom:
- secretKeyRef:
name: grafana-settings
key: values.yaml
@grafana
@prometheus-stack
Feature: Test grafana admin login
As an OAS admin
I want to be able to login to grafana as the user admin
......
......@@ -17,7 +17,6 @@ EXPECTED_RELEASES = {
'oas': [
'ingress',
'prometheus',
'grafana',
'loki-stack',
'eventrouter',
'single-sign-on'
......@@ -35,15 +34,12 @@ EXPECTED_APP_LABELS = {
'rocketchat': {
'namespace': 'oas-apps',
'label_selector': 'app.kubernetes.io/instance=rocketchat'},
'grafana': {
'prometheus-stack': {
'namespace': 'oas',
'label_selector': 'app=grafana'},
'label_selector': 'app in (grafana,prometheus)'},
'eventrouter': {
'namespace': 'oas',
'label_selector': 'app=eventrouter'},
'prometheus': {
'namespace': 'oas',
'label_selector': 'app=prometheus'},
'single-sign-on': {
'namespace': 'oas',
'label_selector': 'app.kubernetes.io/name in (hydra,hydra-maester,single-sign-on-userbackend,single-sign-on-consent,single-sign-on-userpanel,single-sign-on-login)'}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment