diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..c678a1a --- /dev/null +++ b/.gitignore @@ -0,0 +1 @@ +prometheus/apache-http-mixin/vendor \ No newline at end of file diff --git a/prometheus/apache-http-mixin/config.libsonnet b/prometheus/apache-http-mixin/config.libsonnet index 8eb55c8..41833d4 100644 --- a/prometheus/apache-http-mixin/config.libsonnet +++ b/prometheus/apache-http-mixin/config.libsonnet @@ -1,5 +1,8 @@ { _config+:: { dashboardTags: ['apache-http-mixin'], + dashboardPeriod: 'now-1h', + dashboardTimezone: 'default', + dashboardRefresh: '1m', }, } diff --git a/prometheus/apache-http-mixin/dashboards/apache-exporter-full.libsonnet b/prometheus/apache-http-mixin/dashboards/apache-exporter-full.libsonnet index b4cdfc4..8a96ac6 100644 --- a/prometheus/apache-http-mixin/dashboards/apache-exporter-full.libsonnet +++ b/prometheus/apache-http-mixin/dashboards/apache-exporter-full.libsonnet @@ -1,762 +1,685 @@ +local grafana = import 'github.com/grafana/grafonnet-lib/grafonnet/grafana.libsonnet'; +local dashboard = grafana.dashboard; +local row = grafana.row; +local prometheus = grafana.prometheus; +local graphPanel = grafana.graphPanel; + { grafanaDashboards+:: { 'apache-http.json': - { - __inputs: [ + dashboard.new( + 'Apache Dashboard', + time_from='%s' % $._config.dashboardPeriod, + editable=false, + tags=($._config.dashboardTags), + timezone='%s' % $._config.dashboardTimezone, + refresh='%s' % $._config.dashboardRefresh, + graphTooltip='shared_crosshair', + ).addTemplates( + [ { + current: { + text: 'default', + value: 'default', + }, + hide: 0, + label: 'Data Source', name: 'datasource', - label: 'localhost', - description: '', + options: [], + query: 'prometheus', + refresh: 1, + regex: '', type: 'datasource', - pluginId: 'prometheus', - pluginName: 'Prometheus', - }, - ], - __requires: [ - { - type: 'grafana', - id: 'grafana', - name: 'Grafana', - version: '4.4.3', }, { - type: 'panel', - id: 'graph', - name: 'Graph', - version: '', + allValue: null, + current: {}, + datasource: '${datasource}', + hide: 0, + includeAll: false, + label: 'host', + multi: false, + name: 'host', + options: [], + query: 'label_values(apache_up, instance)', + refresh: 2, + regex: '/([^:]+):.*/', + sort: 1, + tagValuesQuery: '', + tags: [], + tagsQuery: '', + type: 'query', + useTags: false, }, { - type: 'datasource', - id: 'prometheus', - name: 'Prometheus', - version: '1.0.0', + allValue: null, + current: {}, + datasource: '${datasource}', + hide: 2, + includeAll: false, + label: null, + multi: false, + name: 'port', + options: [], + query: 'label_values(apache_up, instance)', + refresh: 1, + regex: '/[^:]+:(.*)/', + sort: 0, + tagValuesQuery: '', + tags: [], + tagsQuery: '', + type: 'query', + useTags: false, }, + ] + ) + .addPanels([ { - type: 'panel', - id: 'singlestat', - name: 'Singlestat', - version: '', - }, - ], - annotations: { - list: [], - }, - editable: true, - gnetId: null, - graphTooltip: 0, - hideControls: false, - id: null, - links: [], - refresh: '1m', - rows: [ - { - collapse: false, - height: 102, - panels: [ - { - cacheTimeout: null, - colorBackground: false, - colorValue: false, - colors: [ - 'rgba(245, 54, 54, 0.9)', - 'rgba(237, 129, 40, 0.89)', - 'rgba(50, 172, 45, 0.97)', - ], - datasource: '${datasource}', + datasource: { + uid: '${datasource}', + }, + fieldConfig: { + defaults: { + color: { + mode: 'thresholds', + }, decimals: 1, - format: 's', - gauge: { - maxValue: 100, - minValue: 0, - show: false, - thresholdLabels: false, - thresholdMarkers: true, + mappings: [ + { + options: { + match: 'null', + result: { + text: 'N/A', + }, + }, + type: 'special', + }, + ], + thresholds: { + mode: 'absolute', + steps: [ + { + color: 'green', + value: null, + }, + { + color: 'red', + value: 80, + }, + ], }, - id: 8, - interval: null, - links: [], - mappingType: 1, - mappingTypes: [ - { - name: 'value to text', - value: 1, - }, - { - name: 'range to text', - value: 2, - }, - ], - maxDataPoints: 100, - nullPointMode: 'connected', - nullText: null, - postfix: 's', - postfixFontSize: '50%', - prefix: '', - prefixFontSize: '50%', - rangeMaps: [ - { - from: 'null', - text: 'N/A', - to: 'null', - }, - ], - span: 2, - sparkline: { - fillColor: 'rgba(31, 118, 189, 0.18)', - full: false, - lineColor: 'rgb(31, 120, 193)', - show: false, - }, - tableColumn: '', - targets: [ - { - expr: 'apache_uptime_seconds_total{instance=~"$host:$port"}', - format: 'time_series', - intervalFactor: 1, - refId: 'A', - step: 240, - }, - ], - thresholds: '', - title: 'Uptime', - type: 'singlestat', - valueFontSize: '50%', - valueMaps: [ - { - op: '=', - text: 'N/A', - value: 'null', - }, - ], - valueName: 'avg', + unit: 's', }, - { - aliasColors: {}, - bars: false, - dashLength: 10, - dashes: false, - datasource: '${datasource}', - decimals: 0, - fill: 7, - id: 5, - legend: { - alignAsTable: true, - avg: true, - current: true, - max: true, - min: true, - rightSide: true, - show: true, - total: false, - values: true, - }, - lines: true, - linewidth: 3, - links: [], - nullPointMode: 'null', - percentage: false, - pointradius: 5, - points: false, - renderer: 'flot', - seriesOverrides: [ - { - alias: 'Apache Down', - color: '#BF1B00', - }, - { - alias: 'Apache Down', - transform: 'negative-Y', - }, - ], - spaceLength: 10, - span: 10, - stack: false, - steppedLine: false, - targets: [ - { - expr: 'count(apache_up{instance=~"$host:$port"} == 1)', - format: 'time_series', - intervalFactor: 1, - legendFormat: 'Apache Up', - refId: 'A', - step: 240, - }, - { - expr: 'scalar(count(apache_up{instance=~"$host:$port"} == 0))', - format: 'time_series', - intervalFactor: 1, - legendFormat: 'Apache Down', - refId: 'B', - step: 240, - }, - ], - thresholds: [], - timeFrom: null, - timeShift: null, - title: 'Apache Up / Down', - tooltip: { - shared: true, - sort: 0, - value_type: 'individual', - }, - type: 'graph', - xaxis: { - buckets: null, - mode: 'time', - name: null, - show: true, - values: [], - }, - yaxes: [ - { - format: 'short', - label: null, - logBase: 1, - max: '1', - min: null, - show: true, - }, - { - format: 'short', - label: null, - logBase: 1, - max: null, - min: null, - show: false, - }, - ], - }, - ], - repeat: null, - repeatIteration: null, - repeatRowId: null, - showTitle: false, - title: 'Basic Apache status', - titleSize: 'h6', - }, - { - collapse: false, - height: '365', - panels: [ - { - aliasColors: {}, - bars: false, - dashLength: 10, - dashes: false, - datasource: '${datasource}', - decimals: 2, - fill: 1, - id: 3, - legend: { - alignAsTable: true, - avg: true, - current: true, - max: true, - min: true, - show: true, - total: false, - values: true, - }, - lines: true, - linewidth: 1, - links: [], - nullPointMode: 'null', - percentage: false, - pointradius: 5, - points: false, - renderer: 'flot', - seriesOverrides: [], - spaceLength: 10, - span: 6, - stack: false, - steppedLine: false, - targets: [ - { - expr: 'rate(apache_sent_kilobytes_total{instance=~"$host:$port"}[5m])', - format: 'time_series', - intervalFactor: 1, - legendFormat: 'Kilobytes Sent', - refId: 'A', - step: 240, - }, - ], - thresholds: [], - timeFrom: null, - timeShift: null, - title: 'Current total kbytes sent', - tooltip: { - shared: true, - sort: 0, - value_type: 'individual', - }, - type: 'graph', - xaxis: { - buckets: null, - mode: 'time', - name: null, - show: true, - values: [], - }, - yaxes: [ - { - format: 'deckbytes', - label: null, - logBase: 1, - max: null, - min: null, - show: true, - }, - { - format: 'short', - label: null, - logBase: 1, - max: null, - min: null, - show: false, - }, - ], - }, - { - aliasColors: {}, - bars: false, - dashLength: 10, - dashes: false, - datasource: '${datasource}', - decimals: 2, - fill: 1, - id: 1, - legend: { - alignAsTable: true, - avg: true, - current: true, - max: true, - min: true, - show: true, - total: false, - values: true, - }, - lines: true, - linewidth: 1, - links: [], - nullPointMode: 'null', - percentage: false, - pointradius: 5, - points: false, - renderer: 'flot', - seriesOverrides: [], - spaceLength: 10, - span: 6, - stack: false, - steppedLine: false, - targets: [ - { - expr: 'rate(apache_accesses_total{instance=~"$host:$port"}[5m])', - format: 'time_series', - intervalFactor: 1, - legendFormat: 'Accesses', - refId: 'A', - step: 240, - }, - ], - thresholds: [], - timeFrom: null, - timeShift: null, - title: 'Current total apache accesses', - tooltip: { - shared: true, - sort: 0, - value_type: 'individual', - }, - type: 'graph', - xaxis: { - buckets: null, - mode: 'time', - name: null, - show: true, - values: [], - }, - yaxes: [ - { - format: 'short', - label: null, - logBase: 1, - max: null, - min: null, - show: true, - }, - { - format: 'short', - label: null, - logBase: 1, - max: null, - min: null, - show: false, - }, - ], - }, - ], - repeat: null, - repeatIteration: null, - repeatRowId: null, - showTitle: false, - title: 'Traffic Load', - titleSize: 'h6', - }, - { - collapse: false, - height: '365', - panels: [ - { - aliasColors: {}, - bars: false, - dashLength: 10, - dashes: false, - datasource: '${datasource}', - decimals: 2, - fill: 1, - id: 2, - legend: { - alignAsTable: true, - avg: true, - current: true, - max: true, - min: true, - rightSide: true, - show: true, - total: false, - values: true, - }, - lines: true, - linewidth: 1, - links: [], - nullPointMode: 'null', - percentage: false, - pointradius: 5, - points: false, - renderer: 'flot', - seriesOverrides: [], - spaceLength: 10, - span: 12, - stack: true, - steppedLine: false, - targets: [ - { - expr: 'apache_scoreboard{instance=~"$host:$port"}', - format: 'time_series', - intervalFactor: 1, - legendFormat: '{{ state }}', - refId: 'A', - step: 240, - }, - ], - thresholds: [], - timeFrom: null, - timeShift: null, - title: 'Apache scoreboard statuses', - tooltip: { - shared: true, - sort: 0, - value_type: 'individual', - }, - type: 'graph', - xaxis: { - buckets: null, - mode: 'time', - name: null, - show: true, - values: [], - }, - yaxes: [ - { - format: 'short', - label: null, - logBase: 1, - max: null, - min: null, - show: true, - }, - { - format: 'short', - label: null, - logBase: 1, - max: null, - min: null, - show: false, - }, - ], - }, - ], - repeat: null, - repeatIteration: null, - repeatRowId: null, - showTitle: false, - title: 'Scoreboard', - titleSize: 'h6', - }, - { - collapse: false, - height: '365', - panels: [ - { - aliasColors: {}, - bars: false, - dashLength: 10, - dashes: false, - datasource: '${datasource}', - decimals: 2, - fill: 1, - id: 7, - legend: { - alignAsTable: true, - avg: true, - current: true, - max: true, - min: true, - show: true, - total: false, - values: true, - }, - lines: true, - linewidth: 1, - links: [], - nullPointMode: 'null', - percentage: false, - pointradius: 5, - points: false, - renderer: 'flot', - seriesOverrides: [], - spaceLength: 10, - span: 6, - stack: true, - steppedLine: false, - targets: [ - { - expr: 'apache_workers{instance=~"$host:$port"}\n', - format: 'time_series', - intervalFactor: 1, - legendFormat: '{{ state }}', - refId: 'A', - step: 240, - }, - ], - thresholds: [], - timeFrom: null, - timeShift: null, - title: 'Apache worker statuses', - tooltip: { - shared: true, - sort: 0, - value_type: 'individual', - }, - type: 'graph', - xaxis: { - buckets: null, - mode: 'time', - name: null, - show: true, - values: [], - }, - yaxes: [ - { - format: 'short', - label: null, - logBase: 1, - max: null, - min: null, - show: true, - }, - { - format: 'short', - label: null, - logBase: 1, - max: null, - min: null, - show: false, - }, - ], - }, - { - aliasColors: {}, - bars: false, - dashLength: 10, - dashes: false, - datasource: '${datasource}', - decimals: 2, - fill: 1, - id: 4, - legend: { - alignAsTable: true, - avg: true, - current: true, - max: true, - min: true, - show: true, - total: false, - values: true, - }, - lines: true, - linewidth: 1, - links: [], - nullPointMode: 'null', - percentage: false, - pointradius: 5, - points: false, - renderer: 'flot', - seriesOverrides: [], - spaceLength: 10, - span: 6, - stack: false, - steppedLine: false, - targets: [ - { - expr: 'apache_cpuload{instance=~"$host:$port"}', - format: 'time_series', - intervalFactor: 1, - legendFormat: 'Load', - refId: 'A', - step: 240, - }, - ], - thresholds: [], - timeFrom: null, - timeShift: null, - title: 'Apache CPU load', - tooltip: { - shared: true, - sort: 0, - value_type: 'individual', - }, - type: 'graph', - xaxis: { - buckets: null, - mode: 'time', - name: null, - show: true, - values: [], - }, - yaxes: [ - { - format: 'short', - label: null, - logBase: 1, - max: null, - min: '0', - show: true, - }, - { - format: 'short', - label: null, - logBase: 1, - max: null, - min: null, - show: false, - }, - ], - }, - ], - repeat: null, - repeatIteration: null, - repeatRowId: null, - showTitle: false, - title: 'Processing Load', - titleSize: 'h6', - }, - ], - schemaVersion: 14, - style: 'dark', - tags: [], - templating: { - list: [ - { - current: {}, - description: null, - 'error': null, - hide: 0, - includeAll: false, - label: 'Data Source', - multi: false, - name: 'datasource', - options: [], - query: 'prometheus', - refresh: 1, - regex: '', - skipUrlSync: false, - type: 'datasource', + overrides: [], }, - { - allValue: null, - current: {}, - datasource: '${datasource}', - hide: 0, - includeAll: false, - label: 'host', - multi: false, - name: 'host', - options: [], - query: 'label_values(apache_up, instance)', - refresh: 2, - regex: '/([^:]+):.*/', - sort: 1, - tagValuesQuery: '', - tags: [], - tagsQuery: '', - type: 'query', - useTags: false, + gridPos: { + h: 3, + w: 4, + x: 0, + y: 0, }, - { - allValue: null, - current: {}, - datasource: '${datasource}', - hide: 2, - includeAll: false, - label: null, - multi: false, - name: 'port', - options: [], - query: 'label_values(apache_up, instance)', - refresh: 1, - regex: '/[^:]+:(.*)/', + id: 8, + links: [], + maxDataPoints: 100, + options: { + colorMode: 'none', + graphMode: 'none', + justifyMode: 'auto', + orientation: 'horizontal', + reduceOptions: { + calcs: [ + 'mean', + ], + fields: '', + values: false, + }, + textMode: 'auto', + }, + pluginVersion: '8.4.5', + targets: [ + { + expr: 'apache_uptime_seconds_total{instance=~"$host:$port"}', + format: 'time_series', + intervalFactor: 1, + refId: 'A', + step: 240, + }, + ], + title: 'Uptime', + type: 'stat', + }, + { + aliasColors: {}, + bars: false, + dashLength: 10, + dashes: false, + datasource: { + uid: '${datasource}', + }, + decimals: 0, + fill: 7, + fillGradient: 0, + gridPos: { + h: 3, + w: 20, + x: 4, + y: 0, + }, + hiddenSeries: false, + id: 5, + legend: { + alignAsTable: true, + avg: true, + current: true, + max: true, + min: true, + rightSide: true, + show: true, + total: false, + values: true, + }, + lines: true, + linewidth: 3, + links: [], + nullPointMode: 'null', + options: { + alertThreshold: true, + }, + percentage: false, + pluginVersion: '8.4.5', + pointradius: 5, + points: false, + renderer: 'flot', + seriesOverrides: [ + { + alias: 'Apache Down', + color: '#BF1B00', + }, + { + alias: 'Apache Down', + transform: 'negative-Y', + }, + ], + spaceLength: 10, + stack: false, + steppedLine: false, + targets: [ + { + expr: 'count(apache_up{instance=~"$host:$port"} == 1)', + format: 'time_series', + intervalFactor: 1, + legendFormat: 'Apache Up', + refId: 'A', + step: 240, + }, + { + expr: 'scalar(count(apache_up{instance=~"$host:$port"} == 0))', + format: 'time_series', + intervalFactor: 1, + legendFormat: 'Apache Down', + refId: 'B', + step: 240, + }, + ], + thresholds: [], + timeRegions: [], + title: 'Apache Up / Down', + tooltip: { + shared: true, sort: 0, - tagValuesQuery: '', - tags: [], - tagsQuery: '', - type: 'query', - useTags: false, + value_type: 'individual', }, - ], - }, - time: { - from: 'now-24h', - to: 'now', - }, - timepicker: { - refresh_intervals: [ - '5s', - '10s', - '30s', - '1m', - '5m', - '15m', - '30m', - '1h', - '2h', - '1d', - ], - time_options: [ - '5m', - '15m', - '1h', - '6h', - '12h', - '24h', - '2d', - '7d', - '30d', - ], - }, - timezone: '', - title: 'Apache', - version: 13, - }, + type: 'graph', + xaxis: { + mode: 'time', + show: true, + values: [], + }, + yaxes: [ + { + format: 'short', + logBase: 1, + max: '1', + show: true, + }, + { + format: 'short', + logBase: 1, + show: false, + }, + ], + yaxis: { + align: false, + }, + }, + { + aliasColors: {}, + bars: false, + dashLength: 10, + dashes: false, + datasource: { + uid: '${datasource}', + }, + decimals: 2, + fill: 1, + fillGradient: 0, + gridPos: { + h: 10, + w: 12, + x: 0, + y: 3, + }, + hiddenSeries: false, + id: 3, + legend: { + alignAsTable: true, + avg: true, + current: true, + max: true, + min: true, + show: true, + total: false, + values: true, + }, + lines: true, + linewidth: 1, + links: [], + nullPointMode: 'null', + options: { + alertThreshold: true, + }, + percentage: false, + pluginVersion: '8.4.5', + pointradius: 5, + points: false, + renderer: 'flot', + seriesOverrides: [], + spaceLength: 10, + stack: false, + steppedLine: false, + targets: [ + { + expr: 'rate(apache_sent_kilobytes_total{instance=~"$host:$port"}[5m])', + format: 'time_series', + intervalFactor: 1, + legendFormat: 'Kilobytes Sent', + refId: 'A', + step: 240, + }, + ], + thresholds: [], + timeRegions: [], + title: 'Current total kbytes sent', + tooltip: { + shared: true, + sort: 0, + value_type: 'individual', + }, + type: 'graph', + xaxis: { + mode: 'time', + show: true, + values: [], + }, + yaxes: [ + { + format: 'deckbytes', + logBase: 1, + show: true, + }, + { + format: 'short', + logBase: 1, + show: false, + }, + ], + yaxis: { + align: false, + }, + }, + { + aliasColors: {}, + bars: false, + dashLength: 10, + dashes: false, + datasource: { + uid: '${datasource}', + }, + decimals: 2, + fill: 1, + fillGradient: 0, + gridPos: { + h: 10, + w: 12, + x: 12, + y: 3, + }, + hiddenSeries: false, + id: 1, + legend: { + alignAsTable: true, + avg: true, + current: true, + max: true, + min: true, + show: true, + total: false, + values: true, + }, + lines: true, + linewidth: 1, + links: [], + nullPointMode: 'null', + options: { + alertThreshold: true, + }, + percentage: false, + pluginVersion: '8.4.5', + pointradius: 5, + points: false, + renderer: 'flot', + seriesOverrides: [], + spaceLength: 10, + stack: false, + steppedLine: false, + targets: [ + { + expr: 'rate(apache_accesses_total{instance=~"$host:$port"}[5m])', + format: 'time_series', + intervalFactor: 1, + legendFormat: 'Accesses', + refId: 'A', + step: 240, + }, + ], + thresholds: [], + timeRegions: [], + title: 'Current total apache accesses', + tooltip: { + shared: true, + sort: 0, + value_type: 'individual', + }, + type: 'graph', + xaxis: { + mode: 'time', + show: true, + values: [], + }, + yaxes: [ + { + format: 'short', + logBase: 1, + show: true, + }, + { + format: 'short', + logBase: 1, + show: false, + }, + ], + yaxis: { + align: false, + }, + }, + { + aliasColors: {}, + bars: false, + dashLength: 10, + dashes: false, + datasource: { + uid: '${datasource}', + }, + decimals: 2, + fill: 1, + fillGradient: 0, + gridPos: { + h: 10, + w: 24, + x: 0, + y: 13, + }, + hiddenSeries: false, + id: 2, + legend: { + alignAsTable: true, + avg: true, + current: true, + max: true, + min: true, + rightSide: true, + show: true, + total: false, + values: true, + }, + lines: true, + linewidth: 1, + links: [], + nullPointMode: 'null', + options: { + alertThreshold: true, + }, + percentage: false, + pluginVersion: '8.4.5', + pointradius: 5, + points: false, + renderer: 'flot', + seriesOverrides: [], + spaceLength: 10, + stack: true, + steppedLine: false, + targets: [ + { + expr: 'apache_scoreboard{instance=~"$host:$port"}', + format: 'time_series', + intervalFactor: 1, + legendFormat: '{{ state }}', + refId: 'A', + step: 240, + }, + ], + thresholds: [], + timeRegions: [], + title: 'Apache scoreboard statuses', + tooltip: { + shared: true, + sort: 0, + value_type: 'individual', + }, + type: 'graph', + xaxis: { + mode: 'time', + show: true, + values: [], + }, + yaxes: [ + { + format: 'short', + logBase: 1, + show: true, + }, + { + format: 'short', + logBase: 1, + show: false, + }, + ], + yaxis: { + align: false, + }, + }, + { + aliasColors: {}, + bars: false, + dashLength: 10, + dashes: false, + datasource: { + uid: '${datasource}', + }, + decimals: 2, + fill: 1, + fillGradient: 0, + gridPos: { + h: 10, + w: 12, + x: 0, + y: 23, + }, + hiddenSeries: false, + id: 7, + legend: { + alignAsTable: true, + avg: true, + current: true, + max: true, + min: true, + show: true, + total: false, + values: true, + }, + lines: true, + linewidth: 1, + links: [], + nullPointMode: 'null', + options: { + alertThreshold: true, + }, + percentage: false, + pluginVersion: '8.4.5', + pointradius: 5, + points: false, + renderer: 'flot', + seriesOverrides: [], + spaceLength: 10, + stack: true, + steppedLine: false, + targets: [ + { + expr: 'apache_workers{instance=~"$host:$port"}\n', + format: 'time_series', + intervalFactor: 1, + legendFormat: '{{ state }}', + refId: 'A', + step: 240, + }, + ], + thresholds: [], + timeRegions: [], + title: 'Apache worker statuses', + tooltip: { + shared: true, + sort: 0, + value_type: 'individual', + }, + type: 'graph', + xaxis: { + mode: 'time', + show: true, + values: [], + }, + yaxes: [ + { + format: 'short', + logBase: 1, + show: true, + }, + { + format: 'short', + logBase: 1, + show: false, + }, + ], + yaxis: { + align: false, + }, + }, + { + aliasColors: {}, + bars: false, + dashLength: 10, + dashes: false, + datasource: { + uid: '${datasource}', + }, + decimals: 2, + fill: 1, + fillGradient: 0, + gridPos: { + h: 10, + w: 12, + x: 12, + y: 23, + }, + hiddenSeries: false, + id: 4, + legend: { + alignAsTable: true, + avg: true, + current: true, + max: true, + min: true, + show: true, + total: false, + values: true, + }, + lines: true, + linewidth: 1, + links: [], + nullPointMode: 'null', + options: { + alertThreshold: true, + }, + percentage: false, + pluginVersion: '8.4.5', + pointradius: 5, + points: false, + renderer: 'flot', + seriesOverrides: [], + spaceLength: 10, + stack: false, + steppedLine: false, + targets: [ + { + expr: 'apache_cpuload{instance=~"$host:$port"}', + format: 'time_series', + intervalFactor: 1, + legendFormat: 'Load', + refId: 'A', + step: 240, + }, + ], + thresholds: [], + timeRegions: [], + title: 'Apache CPU load', + tooltip: { + shared: true, + sort: 0, + value_type: 'individual', + }, + type: 'graph', + xaxis: { + mode: 'time', + show: true, + values: [], + }, + yaxes: [ + { + format: 'short', + logBase: 1, + min: '0', + show: true, + }, + { + format: 'short', + logBase: 1, + show: false, + }, + ], + yaxis: { + align: false, + }, + }, + ]), + }, } diff --git a/prometheus/apache-http-mixin/jsonnetfile.json b/prometheus/apache-http-mixin/jsonnetfile.json new file mode 100644 index 0000000..0a57771 --- /dev/null +++ b/prometheus/apache-http-mixin/jsonnetfile.json @@ -0,0 +1,15 @@ +{ + "version": 1, + "dependencies": [ + { + "source": { + "git": { + "remote": "https://github.com/grafana/grafonnet-lib.git", + "subdir": "grafonnet" + } + }, + "version": "master" + } + ], + "legacyImports": false +} \ No newline at end of file diff --git a/prometheus/apache-http-mixin/jsonnetfile.lock.json b/prometheus/apache-http-mixin/jsonnetfile.lock.json new file mode 100644 index 0000000..f538d0d --- /dev/null +++ b/prometheus/apache-http-mixin/jsonnetfile.lock.json @@ -0,0 +1,16 @@ +{ + "version": 1, + "dependencies": [ + { + "source": { + "git": { + "remote": "https://github.com/grafana/grafonnet-lib.git", + "subdir": "grafonnet" + } + }, + "version": "6db00c292d3a1c71661fc875f90e0ec7caa538c2", + "sum": "gF8foHByYcB25jcUOBqP6jxk0OPifQMjPvKY0HaCk6w=" + } + ], + "legacyImports": false +}