Edit vCloud Network Interface

To edit a network interface, use the following request:

1
2
PUT /virtual_machines/:virtual_server_id/network_interfaces/:id.xml
PUT /virtual_machines/:virtual_server_id/network_interfaces/:id.json

XML Request Example

1
curl -i -X PUT http://onapp.test/virtual_machines/12/network_interfaces/2.xml -H 'Accept: application/xml' -H 'Content-type: application/xml' -u user:userpass -d '<network_interface><primary>1</primary><connected>1</connected><network_join_id>9</network_join_id></network_interface>'

JSON Request Example

1
curl -i -X PUT http://onapp.test/virtual_machines/12/network_interfaces/2.json -H 'Accept: application/json' -H 'Content-type: application/json' -u user:userpass -d '{"network_interface":{"primary":"1","connected":"1","network_join_id":"9"}}'

Where:

primary - indicate whether this interface is primary

connected - indicate whether the network interface is connected to a VS

network_join_id - choose a network join