|
| 1 | +{ |
| 2 | +"__inputs": [ |
| 3 | + { |
| 4 | +"name":"DS_MIMIR_API", |
| 5 | +"label":"Mimir API", |
| 6 | +"description":"", |
| 7 | +"type":"datasource", |
| 8 | +"pluginId":"marcusolsson-json-datasource", |
| 9 | +"pluginName":"JSON API" |
| 10 | + } |
| 11 | + ], |
| 12 | +"__elements": {}, |
| 13 | +"__requires": [ |
| 14 | + { |
| 15 | +"type":"grafana", |
| 16 | +"id":"grafana", |
| 17 | +"name":"Grafana", |
| 18 | +"version":"11.5.2" |
| 19 | + }, |
| 20 | + { |
| 21 | +"type":"datasource", |
| 22 | +"id":"marcusolsson-json-datasource", |
| 23 | +"name":"JSON API", |
| 24 | +"version":"1.3.23" |
| 25 | + }, |
| 26 | + { |
| 27 | +"type":"panel", |
| 28 | +"id":"table", |
| 29 | +"name":"Table", |
| 30 | +"version":"" |
| 31 | + } |
| 32 | + ], |
| 33 | +"annotations": { |
| 34 | +"list": [ |
| 35 | + { |
| 36 | +"builtIn":1, |
| 37 | +"datasource": { |
| 38 | +"type":"grafana", |
| 39 | +"uid":"-- Grafana --" |
| 40 | + }, |
| 41 | +"enable":true, |
| 42 | +"hide":true, |
| 43 | +"iconColor":"rgba(0, 211, 255, 1)", |
| 44 | +"name":"Annotations & Alerts", |
| 45 | +"type":"dashboard" |
| 46 | + } |
| 47 | + ] |
| 48 | + }, |
| 49 | +"editable":true, |
| 50 | +"fiscalYearStartMonth":0, |
| 51 | +"graphTooltip":0, |
| 52 | +"id":null, |
| 53 | +"links": [], |
| 54 | +"panels": [ |
| 55 | + { |
| 56 | +"datasource": { |
| 57 | +"type":"marcusolsson-json-datasource", |
| 58 | +"uid":"${DS_MIMIR_API}" |
| 59 | + }, |
| 60 | +"fieldConfig": { |
| 61 | +"defaults": { |
| 62 | +"color": { |
| 63 | +"mode":"thresholds" |
| 64 | + }, |
| 65 | +"custom": { |
| 66 | +"align":"auto", |
| 67 | +"cellOptions": { |
| 68 | +"type":"auto" |
| 69 | + }, |
| 70 | +"inspect":false |
| 71 | + }, |
| 72 | +"mappings": [], |
| 73 | +"thresholds": { |
| 74 | +"mode":"absolute", |
| 75 | +"steps": [ |
| 76 | + { |
| 77 | +"color":"green", |
| 78 | +"value":null |
| 79 | + }, |
| 80 | + { |
| 81 | +"color":"red", |
| 82 | +"value":80 |
| 83 | + } |
| 84 | + ] |
| 85 | + } |
| 86 | + }, |
| 87 | +"overrides": [ |
| 88 | + { |
| 89 | +"matcher": { |
| 90 | +"id":"byName", |
| 91 | +"options":"account" |
| 92 | + }, |
| 93 | +"properties": [ |
| 94 | + { |
| 95 | +"id":"links", |
| 96 | +"value": [ |
| 97 | + { |
| 98 | +"targetBlank":true, |
| 99 | +"title":"", |
| 100 | +"url":"https://g.codefresh.io/admin/accounts?filter=search:%5E${__value.text}$" |
| 101 | + } |
| 102 | + ] |
| 103 | + } |
| 104 | + ] |
| 105 | + } |
| 106 | + ] |
| 107 | + }, |
| 108 | +"gridPos": { |
| 109 | +"h":26, |
| 110 | +"w":24, |
| 111 | +"x":0, |
| 112 | +"y":0 |
| 113 | + }, |
| 114 | +"id":5, |
| 115 | +"options": { |
| 116 | +"cellHeight":"sm", |
| 117 | +"footer": { |
| 118 | +"countRows":false, |
| 119 | +"fields":"", |
| 120 | +"reducer": [ |
| 121 | +"sum" |
| 122 | + ], |
| 123 | +"show":false |
| 124 | + }, |
| 125 | +"frameIndex":2, |
| 126 | +"showHeader":true, |
| 127 | +"sortBy": [ |
| 128 | + { |
| 129 | +"desc":false, |
| 130 | +"displayName":"account" |
| 131 | + } |
| 132 | + ] |
| 133 | + }, |
| 134 | +"pluginVersion":"11.5.2", |
| 135 | +"targets": [ |
| 136 | + { |
| 137 | +"cacheDurationSeconds":0, |
| 138 | +"datasource": { |
| 139 | +"type":"marcusolsson-json-datasource", |
| 140 | +"uid":"${DS_MIMIR_API}" |
| 141 | + }, |
| 142 | +"fields": [ |
| 143 | + { |
| 144 | +"jsonPath":"$distinct(\n data.{\n\"account\": $.account_name,\n\"image\": $.image_name,\n\"pipeline\": $.pipeline_id\n})", |
| 145 | +"language":"jsonata" |
| 146 | + } |
| 147 | + ], |
| 148 | +"hide":false, |
| 149 | +"method":"GET", |
| 150 | +"params": [ |
| 151 | + [ |
| 152 | +"match[]", |
| 153 | +"{__name__=\"codefresh_engine_deprecated_images_pulled_total\", account_name=~\"$account\"}" |
| 154 | + ], |
| 155 | + [ |
| 156 | +"start", |
| 157 | +"${__from:date:seconds}" |
| 158 | + ] |
| 159 | + ], |
| 160 | +"queryParams":"", |
| 161 | +"refId":"A", |
| 162 | +"urlPath":"/series" |
| 163 | + } |
| 164 | + ], |
| 165 | +"title":"Deprecated images in time interval", |
| 166 | +"transformations": [ |
| 167 | + { |
| 168 | +"id":"extractFields", |
| 169 | +"options": { |
| 170 | +"format":"auto", |
| 171 | +"keepTime":false, |
| 172 | +"replace":true, |
| 173 | +"source":"result" |
| 174 | + } |
| 175 | + } |
| 176 | + ], |
| 177 | +"type":"table" |
| 178 | + } |
| 179 | + ], |
| 180 | +"schemaVersion":40, |
| 181 | +"tags": [], |
| 182 | +"templating": { |
| 183 | +"list": [ |
| 184 | + { |
| 185 | +"allValue":".+", |
| 186 | +"current": {}, |
| 187 | +"definition":"label_values(codefresh_engine_deprecated_images_pulled_total,account_name)", |
| 188 | +"includeAll":true, |
| 189 | +"multi":true, |
| 190 | +"name":"account", |
| 191 | +"options": [], |
| 192 | +"query": { |
| 193 | +"qryType":1, |
| 194 | +"query":"label_values(codefresh_engine_deprecated_images_pulled_total,account_name)", |
| 195 | +"refId":"PrometheusVariableQueryEditor-VariableQuery" |
| 196 | + }, |
| 197 | +"refresh":2, |
| 198 | +"regex":"", |
| 199 | +"sort":1, |
| 200 | +"type":"query" |
| 201 | + } |
| 202 | + ] |
| 203 | + }, |
| 204 | +"time": { |
| 205 | +"from":"now-30d", |
| 206 | +"to":"now" |
| 207 | + }, |
| 208 | +"timepicker": {}, |
| 209 | +"timezone":"browser", |
| 210 | +"title":"Deprecated Images", |
| 211 | +"uid":"bea5uff48krgge", |
| 212 | +"version":2, |
| 213 | +"weekStart":"" |
| 214 | +} |