19 lines
426 B
Bash
19 lines
426 B
Bash
curl -X POST \
|
|
--user admin:adminpwd \
|
|
-H "Content-Type: application/json" \
|
|
-d '{
|
|
"name": "lololo",
|
|
"mode": "http",
|
|
"balance": {
|
|
"algorithm": "roundrobin"
|
|
},
|
|
"default_server": {
|
|
"alpn": "h2",
|
|
"check": "enabled",
|
|
"check_alpn": "h2",
|
|
"maxconn": 30,
|
|
"weight": 100
|
|
}
|
|
}' \
|
|
"http://192.168.0.200:8080/v3/services/haproxy/configuration/backends?version=$CFGVER"
|