ves-io-schema-fleet-API-Replace
On This Page:
Examples of replacing fleet
Usecase:
Replace superstore fleet to change the software version
Request using vesctl:
vesctl configuration replace fleet -i fleet.yaml
where file fleet.yaml has following contents (fleet.ReplaceRequest):
RequestJSON:
{
"metadata": {
"name": "superstore-fleet",
"namespace": "system"
},
"spec": {
"volterra_software_version": "2019-build-9990",
"network_connectors": [
{
"kind": "network_connector",
"tenant": "acmecorp",
"namespace": "system",
"name": "connect-in-out"
}
],
"network_firewall": [
{
"kind": "network_firewall",
"tenant": "acmecorp",
"namespace": "system",
"name": "superstore-firewall"
}
],
"interface_list": {
"interfaces": [
{
"tenant": "acmecorp",
"namespace": "system",
"name": "int-eth0"
},
{
"tenant": "acmecorp",
"namespace": "system",
"name": "int-eth1"
}
]
},
"no_bond_devices": {},
"no_storage_interfaces": {},
"no_storage_device": {},
"default_storage_class": {},
"no_dc_cluster_group": {},
"disable_gpu": {},
"no_storage_static_routes": {},
"logs_streaming_disabled": {},
"allow_all_usb": {},
"disable_vm": {}
}
}
vesctl yaml response: None
Request using curl:
curl -X 'PUT' -d '{"metadata":{"name":"superstore-fleet","namespace":"system"},"spec":{"volterra_software_version":"2019-build-9990","network_connectors":[{"kind":"network_connector","tenant":"acmecorp","namespace":"system","name":"connect-in-out"}],"network_firewall":[{"kind":"network_firewall","tenant":"acmecorp","namespace":"system","name":"superstore-firewall"}],"interface_list":{"interfaces":[{"tenant":"acmecorp","namespace":"system","name":"int-eth0"},{"tenant":"acmecorp","namespace":"system","name":"int-eth1"}]},"no_bond_devices":{},"no_storage_interfaces":{},"no_storage_device":{},"default_storage_class":{},"no_dc_cluster_group":{},"disable_gpu":{},"no_storage_static_routes":{},"logs_streaming_disabled":{},"allow_all_usb":{},"disable_vm":{}}}' -H 'X-Volterra-Useragent: v1/pgm=_var_folders_2__8qnt6fwd5dvglr1xqq6l8b7w0000gp_T_go-build3109416560_b001_apidocs.test/host=C02FN35BMD6R/svc=S:examplesvc/site=mytestce01' 'https://acmecorp.console.ves.volterra.io/api/config/namespaces/system/fleets/superstore-fleet'
curl response:
HTTP/1.1 200 OK
Content-Length: 4
Content-Type: application/json
Date: Thu, 21 Mar 2024 14:05:22 GMT
Vary: Accept-Encoding
{
}