#NEWLINE# def configure( self ) : #NEWLINE# #INDENT# config = keepalived . KeepalivedConf ( ) #NEWLINE# instance1 = keepalived . KeepalivedInstance ( 'MASTER' , self . ha_port , 1 , [ '169.254.192.0/18' ] , advert_int = 5 ) #NEWLINE# instance1 . track_interfaces . append ( self . ha_port ) #NEWLINE# vip_addr1 = keepalived . KeepalivedVipAddress ( vip_addr1 . gw_vip , self . gw_port ) #NEWLINE# instance1 . vips . append ( vip_addr1 ) #NEWLINE# gateway_route = keepalived . KeepalivedVirtualRoute ( n_consts . IPv6_ANY , self . default_gw , self . gw_port ) #NEWLINE# instance1 . virtual_routes . gateway_routes = [ gateway_route ] #NEWLINE# config . add_instance ( instance1 ) #NEWLINE# self . config = config