Pushgateway windows
Jump to navigation
Jump to search
Windows
Not working
$cred = Get-Credential $r=(invoke-webrequest http://localhost:9182/metrics).content; $r.tostring() -split "[`r`n]" | select-string -pattern "go_|http_request|http_requests|http_response|process" -NotMatch | ConvertTo-Json | Invoke-WebRequest -Method POST -Uri https://pushgateway.example/metrics/job/windowsnode/instance/foo -cred $cred -ContentType 'application/json'