ves-io-schema-network_connector-API-Replace

Examples of replacing network_connector

Usecase:

Replace connect-in-out to now update no proxy to do forward proxy between inside network and outside network

Request using vesctl:

vesctl configuration replace network_connector -i network_connector.yaml

where file networkconnector.yaml has following contents (networkconnector.ReplaceRequest):

metadata:
  name: connect-in-out
  namespace: system
spec:
  enableForwardProxy:
    maxConnectAttempts: 2
  sliToSloSnat:
    defaultGwSnat: {}
    interfaceIp: {}

vesctl yaml response: None

Request using curl:

curl -X 'PUT' -d '{"metadata":{"name":"connect-in-out","namespace":"system"},"spec":{"sliToSloSnat":{"defaultGwSnat":{},"interfaceIp":{}},"enableForwardProxy":{"maxConnectAttempts":2}}}' -H 'X-Volterra-Useragent: v1/pgm=_tmp_go-build970361017_b001_apidocs.test/host=docker-desktop' 'https://acmecorp.console.ves.volterra.io/api/config/namespaces/system/network_connectors/connect-in-out'

curl response:

HTTP/1.1 200 OK
Content-Length: 4
Content-Type: application/json
Date: Wed, 25 Aug 2021 09:03:31 GMT
Vary: Accept-Encoding

{

}