Select Service
ves-io-schema-views-http_loadbalancer-API-Replace
Published April 5, 2023 | Last modified June 26, 2025
Examples of replacing http_loadbalancer
Usecase:
Replace "productpage" http_loadbalancer to now support mTLS
- Trusted CA parameter is added to TLS config
Request using vesctl:
vesctl configuration replace http_loadbalancer -i http_loadbalancer.yaml
where file http_loadbalancer.yaml has following contents (http_loadbalancer.ReplaceRequest):
RequestJSON:
{
"metadata": {
"name": "productpage",
"namespace": "documentation",
"labels": {
"ves.io/app_type": "bookinfo"
}
},
"spec": {
"domains": [
"www.bookinfo.com"
],
"https": {
"tls_cert_params": {
"tls_config": {
"default_security": {}
},
"certificates": [
{
"name": "cert1"
}
],
"use_mtls": {
"trusted_ca_url": "string:///\u003cBase64\u003e",
"crl": {
"tenant": "acmecorp",
"namespace": "documentation",
"name": "crl-1"
}
}
},
"enable_path_normalize": {},
"port_ranges": "80,443"
},
"advertise_on_public_default_vip": {},
"default_route_pools": [
{
"pool": {
"name": "ppage-route"
}
}
],
"disable_waf": {},
"no_challenge": {},
"user_id_client_ip": {},
"disable_rate_limit": {},
"waf_exclusion_rules": [
{
"any_domain": null,
"path_regex": "",
"methods": [
"ANY"
],
"metadata": {
"name": "another-name"
},
"app_firewall_detection_control": {
"exclude_signature_contexts": [
{
"signature_id": 10000000
}
],
"exclude_violation_contexts": [
{
"exclude_violation": "VIOL_ASM_COOKIE_MODIFIED"
}
],
"exclude_attack_type_contexts": [
{
"exclude_attack_type": "ATTACK_TYPE_ABUSE_OF_FUNCTIONALITY"
}
]
}
}
],
"l7_ddos_protection": {
"mitigation_block": {},
"rps_threshold": 10000,
"clientside_action_none": {},
"ddos_policy_none": {}
},
"service_policies_from_namespace": {},
"round_robin": {},
"multi_lb_app": {}
}
}
Copied!
vesctl yaml response: None
Request using curl:
curl -X 'PUT' -d '{"metadata":{"name":"productpage","namespace":"documentation","labels":{"ves.io/app_type":"bookinfo"}},"spec":{"domains":["www.bookinfo.com"],"https":{"tls_cert_params":{"tls_config":{"default_security":{}},"certificates":[{"name":"cert1"}],"use_mtls":{"trusted_ca_url":"string:///\u003cBase64\u003e","crl":{"tenant":"acmecorp","namespace":"documentation","name":"crl-1"}}},"enable_path_normalize":{},"port_ranges":"80,443"},"advertise_on_public_default_vip":{},"default_route_pools":[{"pool":{"name":"ppage-route"}}],"disable_waf":{},"no_challenge":{},"user_id_client_ip":{},"disable_rate_limit":{},"waf_exclusion_rules":[{"any_domain":null,"path_regex":"","methods":["ANY"],"metadata":{"name":"another-name"},"app_firewall_detection_control":{"exclude_signature_contexts":[{"signature_id":10000000}],"exclude_violation_contexts":[{"exclude_violation":"VIOL_ASM_COOKIE_MODIFIED"}],"exclude_attack_type_contexts":[{"exclude_attack_type":"ATTACK_TYPE_ABUSE_OF_FUNCTIONALITY"}]}}],"l7_ddos_protection":{"mitigation_block":{},"rps_threshold":10000,"clientside_action_none":{},"ddos_policy_none":{}},"service_policies_from_namespace":{},"round_robin":{},"multi_lb_app":{}}}' -H 'X-Volterra-Useragent: v1/pgm=_var_folders_q2_3kp8z3zs0x5_m7pk1bgb0_ph0000gp_T_go-build336959812_b001_apidocs.test/host=MTY6VVHQPH/svc=S:examplesvc/site=mytestce01' 'https://acmecorp.console.ves.volterra.io/api/config/namespaces/documentation/http_loadbalancers/productpage'
Copied!
curl response:
HTTP/1.1 200 OK
Content-Length: 4
Content-Type: application/json
Date: Thu, 26 Jun 2025 23:56:52 GMT
Vary: Accept-Encoding
{
}
Copied!