Simple Loki Log Dashboard
Simple Loki Log Dashboard with docker
Simple Loki Log Dashboard
{
  "__inputs": [
    {
      "name": "DS_LOKI-001",
      "label": "",
      "description": "",
      "type": "datasource",
      "pluginId": "loki",
      "pluginName": "Loki"
    }
  ],
  "__elements": {},
  "__requires": [
    {
      "type": "grafana",
      "id": "grafana",
      "name": "Grafana",
      "version": "9.3.6"
    },
    {
      "type": "panel",
      "id": "logs",
      "name": "Logs",
      "version": ""
    },
    {
      "type": "datasource",
      "id": "loki",
      "name": "Loki",
      "version": "1.0.0"
    }
  ],
  "annotations": {
    "list": [
      {
        "builtIn": 1,
        "datasource": {
          "type": "datasource",
          "uid": "grafana"
        },
        "enable": true,
        "hide": true,
        "iconColor": "rgba(0, 211, 255, 1)",
        "name": "Annotations & Alerts",
        "target": {
          "limit": 100,
          "matchAny": false,
          "tags": [],
          "type": "dashboard"
        },
        "type": "dashboard"
      }
    ]
  },
  "description": "Simple Loki Log Dashboard with docker",
  "editable": true,
  "fiscalYearStartMonth": 0,
  "gnetId": 18702,
  "graphTooltip": 0,
  "id": null,
  "links": [],
  "liveNow": false,
  "panels": [
    {
      "datasource": {
        "type": "loki",
        "uid": "${DS_LOKI-001}"
      },
      "description": "",
      "gridPos": {
        "h": 20,
        "w": 24,
        "x": 0,
        "y": 0
      },
      "id": 5,
      "options": {
        "dedupStrategy": "none",
        "enableLogDetails": false,
        "prettifyLogMessage": true,
        "showCommonLabels": false,
        "showLabels": false,
        "showTime": true,
        "sortOrder": "Ascending",
        "wrapLogMessage": true
      },
      "pluginVersion": "7.3.6",
      "targets": [
        {
          "datasource": {
            "type": "loki",
            "uid": "${DS_LOKI-001}"
          },
          "editorMode": "code",
          "expr": "{container_name=\"$container_name\"} |~ `(?i)$searchable_pattern`",
          "legendFormat": "",
          "queryType": "range",
          "refId": "A"
        }
      ],
      "title": "Logs Lines",
      "type": "logs"
    }
  ],
  "refresh": "5s",
  "schemaVersion": 37,
  "style": "dark",
  "tags": [
    "loki"
  ],
  "templating": {
    "list": [
      {
        "current": {},
        "datasource": {
          "type": "loki",
          "uid": "${DS_LOKI-001}"
        },
        "definition": "",
        "hide": 0,
        "includeAll": false,
        "label": "Service",
        "multi": false,
        "name": "container_name",
        "options": [],
        "query": {
          "label": "container_name",
          "refId": "LokiVariableQueryEditor-VariableQuery",
          "stream": "{container_name=~\".+\"}",
          "type": 1
        },
        "refresh": 1,
        "regex": "",
        "skipUrlSync": false,
        "sort": 0,
        "type": "query"
      },
      {
        "current": {
          "selected": true,
          "text": "",
          "value": ""
        },
        "description": "Search",
        "hide": 0,
        "label": "Search",
        "name": "searchable_pattern",
        "options": [
          {
            "selected": true,
            "text": "",
            "value": ""
          }
        ],
        "query": "",
        "skipUrlSync": false,
        "type": "textbox"
      }
    ]
  },
  "time": {
    "from": "now-12h",
    "to": "now"
  },
  "timepicker": {},
  "timezone": "",
  "title": "Simple Loki Log Dashboard",
  "uid": "slld-zuf-loki",
  "version": 1,
  "weekStart": ""
}