Start and set management IP address
( self, controllers )
| 122 | self.switchIP = ip |
| 123 | |
| 124 | def start( self, controllers ): |
| 125 | "Start and set management IP address" |
| 126 | # Call superclass constructor |
| 127 | UserSwitch.start( self, controllers ) |
| 128 | # Set Switch IP address |
| 129 | if self.switchIP is not None: |
| 130 | if not self.inNamespace: |
| 131 | self.cmd( 'ifconfig', self, self.switchIP ) |
| 132 | else: |
| 133 | self.cmd( 'ifconfig lo', self.switchIP ) |
| 134 | |
| 135 | class LegacyRouter( Node ): |
| 136 | "Simple IP router" |