| Dimitrios Mavrommatis | 7c0ff01 | 2017-12-07 00:25:58 -0800 | [diff] [blame^] | 1 | #!/bin/bash |
| 2 | |
| 3 | if [ "$#" -eq 2 ]; then |
| 4 | echo "" |
| 5 | curl -i -s \ |
| 6 | --header "Content-type: application/json" \ |
| 7 | --request POST \ |
| 8 | -u onos:rocks \ |
| 9 | --data '{ |
| 10 | "input": { |
| 11 | "client-id": "'$1'", |
| 12 | "tenant-id": "'$2'", |
| 13 | "supported-features": [ |
| 14 | "urn:ietf:params:xml:ns:yang:fpcagent:fpc-bundles", |
| 15 | "urn:ietf:params:xml:ns:yang:fpcagent:operation-ref-scope", |
| 16 | "urn:ietf:params:xml:ns:yang:fpcagent:fpc-agent-assignments", |
| 17 | "urn:ietf:params:xml:ns:yang:fpcagent:instruction-bitset" |
| 18 | ], |
| 19 | "endpoint-uri": "http://127.0.0.1:9997/" |
| 20 | } |
| 21 | }' 'http://localhost:8181/onos/restconf/operations/fpc:register-client' |
| 22 | echo "" |
| 23 | else |
| 24 | echo "usage: "$0" clientId tenantId" |
| 25 | fi |