Init. name: name to give controller. ryuArgs: modules to pass to Ryu (ryu.app.simple_switch) command: command to run Ryu ('ryu run')
( self, name, ryuArgs='ryu.app.simple_switch',
command='ryu run', **kwargs )
| 1534 | class Ryu( Controller ): |
| 1535 | "Ryu OpenFlow Controller" |
| 1536 | def __init__( self, name, ryuArgs='ryu.app.simple_switch', |
| 1537 | command='ryu run', **kwargs ): |
| 1538 | """Init. |
| 1539 | name: name to give controller. |
| 1540 | ryuArgs: modules to pass to Ryu (ryu.app.simple_switch) |
| 1541 | command: command to run Ryu ('ryu run')""" |
| 1542 | if isinstance( ryuArgs, ( list, tuple ) ): |
| 1543 | ryuArgs = ' '.join( ryuArgs ) |
| 1544 | cargs = kwargs.pop( |
| 1545 | 'cargs', ryuArgs + ' --ofp-tcp-listen-port %s' ) |
| 1546 | Controller.__init__( self, name, command=command, |
| 1547 | cargs=cargs, **kwargs ) |
| 1548 | |
| 1549 | |
| 1550 | class RemoteController( Controller ): |