X-Git-Url: https://osm.etsi.org/gitweb/?a=blobdiff_plain;f=openflow;h=80cf624a826d4350b0d118231846bb6e19fe6cb1;hb=f9a1a8d51e7525f0d4acfe02dcb7fb8696fc20b0;hp=7ea59c4b4ab679a8544d10c690ba55eec9061421;hpb=f7aa8c4db7a57d5865d3b7767d5957fda6867198;p=osm%2Fopenvim.git diff --git a/openflow b/openflow index 7ea59c4..80cf624 100755 --- a/openflow +++ b/openflow @@ -205,6 +205,8 @@ def of_add(args): if r<0: print c return -1 + if args.print_id: + print rule["name"] return 0 def of_delete(args): @@ -280,6 +282,7 @@ if __name__=="__main__": add_parser.add_argument("--setvlan", action="append", dest="act", type=int, help="alternative to --actions. Use before --out to set vlan") add_parser.add_argument("--out", action="append", dest="act", type=str, help="alternative to --actions. out= can be used several times") add_parser.add_argument('--debug', '-d', action='store_true', help="show debug information") + add_parser.add_argument('--print-id', action='store_true', help="print the flow id after added") add_parser.set_defaults(func=of_add) delete_parser = subparsers.add_parser('delete', help="delete an openflow rule")