Skip to content

Instantly share code, notes, and snippets.

---
version: "2"
services:
broker:
image: confluentinc/cp-kafka:7.4.0
hostname: broker
container_name: broker
ports:
- "9092:9092"
- "9101:9101"
private const string ImposterPort = "10710";
private const string ImpostersUrl = "http://127.0.0.1:2525/imposters/";
Client = new RestClient();
ImposterUrl = string.Format("{0}{1}", ImpostersUrl, ImposterPort);
var setupImposter = new
{
port = ImposterPort,
if ((Get-Command "mb" -ErrorAction SilentlyContinue) -eq $null)
{
"install mountebank globally"
& npm install --g mountebank
}
$block = { & mb --mock }
$mountebank = Start-Job -scriptblock $block
$mountebank
$mountebank.JobStateInfo