| # Copyright 2017-present Open Networking Foundation |
| # Licensed under the Apache License, Version 2.0 (the "License"); |
| # you may not use this file except in compliance with the License. |
| # You may obtain a copy of the License at |
| # http://www.apache.org/licenses/LICENSE-2.0 |
| # Unless required by applicable law or agreed to in writing, software |
| # distributed under the License is distributed on an "AS IS" BASIS, |
| # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| # See the License for the specific language governing permissions and |
| # limitations under the License. |
| from scripts.scriptbase import ScriptBase |
| Make sure you have VOLTHA_BASE_URL environment variable |
| export VOLTHA_BASE_URL=https://localhost:8881/api/v1 |
| export VOLTHA_BASE_URL=https://10.100.192.220:8881/api/v1 |
| device = self.fetch_device_info(self.voltha_base_url, device_id) |
| flows=device['flows']['items'], |
| groups=device['flow_groups']['items'] |
| if __name__ == '__main__': |