cat << EOF | curl -X POST -u admin:admin -H “Content-Type: application/json” -d @- “http://127.0.0.1:{{ grafana_http_port }}/api/datasources”
{
“name”: “Prometheus”,
“type”: “prometheus”,
“url”: “http://127.0.0.1:{{ prometheus_port }}”,
“access”: “proxy”,
“basicauth”: false
}
EOF
curl -X POST -H “Content-Type: application/json” -d @- <<EOF
{
“key1”: “value1”,
“key2”: “value2”,
“key3”: “value3”
}
EOF