Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add Perses to monitor example #6149

Open
wants to merge 4 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 11 additions & 0 deletions docker-compose/monitor/docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -64,5 +64,16 @@ services:
ports:
- "3000:3000"

perses:
networks:
- backend
image: persesdev/perses:v0.49
command: "--config=/etc/perses.yaml"
volumes:
- ./perses:/etc/perses/provisioning
- ./perses/perses.yaml:/etc/perses.yaml
ports:
- "8080:8080"

networks:
backend:
67 changes: 67 additions & 0 deletions docker-compose/monitor/perses/dashboards/monitor.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,67 @@
{
"kind": "Dashboard",
"metadata": {
"name": "monitor",
"createdAt": "2024-11-01T10:33:05.237682703Z",
"updatedAt": "2024-11-01T10:33:05.237682703Z",
"version": 0,
"project": "jaeger"
},
"spec": {
"display": {
"name": "monitor"
},
"panels": {
"calls": {
"kind": "Panel",
"spec": {
"display": {
"name": "calls"
},
"plugin": {
"kind": "TimeSeriesChart",
"spec": {}
},
"queries": [
{
"kind": "TimeSeriesQuery",
"spec": {
"plugin": {
"kind": "PrometheusTimeSeriesQuery",
"spec": {
"query": "traces_span_metrics_calls_total"
}
}
}
}
]
}
}
},
"layouts": [
{
"kind": "Grid",
"spec": {
"display": {
"title": "Panel Group",
"collapse": {
"open": true
}
},
"items": [
{
"x": 0,
"y": 0,
"width": 12,
"height": 6,
"content": {
"$ref": "#/spec/panels/calls"
}
}
]
}
}
],
"duration": "1h"
}
}
54 changes: 54 additions & 0 deletions docker-compose/monitor/perses/globaldatasources/prometheus.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,54 @@
# percli describe gdts prometheus -o json | jq
{
"kind": "GlobalDatasource",
"metadata": {
"name": "prometheus",
"createdAt": "2024-11-01T10:31:22.358795716Z",
"updatedAt": "2024-11-01T10:31:22.358795716Z",
"version": 0
},
"spec": {
"default": true,
"plugin": {
"kind": "PrometheusDatasource",
"spec": {
"proxy": {
"kind": "HTTPProxy",
"spec": {
"allowedEndpoints": [
{
"endpointPattern": "/api/v1/labels",
"method": "POST"
},
{
"endpointPattern": "/api/v1/series",
"method": "POST"
},
{
"endpointPattern": "/api/v1/metadata",
"method": "GET"
},
{
"endpointPattern": "/api/v1/query",
"method": "POST"
},
{
"endpointPattern": "/api/v1/query_range",
"method": "POST"
},
{
"endpointPattern": "/api/v1/label/([a-zA-Z0-9_-]+)/values",
"method": "GET"
},
{
"endpointPattern": "/api/v1/parse_query",
"method": "POST"
}
],
"url": "http://prometheus:9090"
}
}
}
}
}
}
32 changes: 32 additions & 0 deletions docker-compose/monitor/perses/perses.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
database:
file:
extension: "json"
folder: "/perses"
case_sensitive: false
schemas:
panels_path: "/etc/perses/cue/schemas/panels"
queries_path: "/etc/perses/cue/schemas/queries"
datasources_path: "/etc/perses/cue/schemas/datasources"
variables_path: "/etc/perses/cue/schemas/variables"
interval: "5m"


provisioning:
interval: "12h"
folders:
- "/etc/perses/provisioning"

frontend:
explorer:
enable: true

important_dashboards:
- project: "jaeger"
dashboard: "monitor"

information: |-
# Welcome to the Demo instance of Perses!

This public demo instance is here to show you what Perses looks like
and what's possible to do with it. You can have a look at the example
dashboards, or create your own ones!
14 changes: 14 additions & 0 deletions docker-compose/monitor/perses/projects/jaeger.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
{
"kind": "Project",
"metadata": {
"name": "jaeger",
"createdAt": "2024-11-01T10:25:06.797226244Z",
"updatedAt": "2024-11-01T10:25:06.797226244Z",
"version": 0
},
"spec": {
"display": {
"name": "jaeger"
}
}
}
Loading