... | ... | @@ -13,9 +13,11 @@ https://wiki.openstack.org/wiki/Neutron/APIv2-specification#Show_Network |
|
|
|
|
|
### curl example
|
|
|
|
|
|
```
|
|
|
```bash
|
|
|
# opendaylight neutron api
|
|
|
curl --user "admin":"<password>" -H "Accept: application/json" -H "Content-type: application/json" \
|
|
|
-X PUT -d '{"port": {"name": "port1 updated"}}' http://sdncontrol:8080/controller/nb/v2/neutron/port/<port_id>
|
|
|
# neutron api on controlnode (get token from /var/log/nova/compute.log)
|
|
|
curl -H "X-Auth-Token: $(cat token)" -H "Accept: application/json" -H "Content-type: application/json" \
|
|
|
-X GET http://controlnode:9696/v2.0/ports.json 2>/dev/null | sed "s/,/,\n/g";echo;
|
|
|
```
|
... | ... | |