@@ -111,9 +111,9 @@ var args = acn.ArgumentList{
111111 DefaultValue : "" ,
112112 },
113113 {
114- Name : acn .OptStopAzureVnet ,
115- Shorthand : acn .OptStopAzureVnetAlias ,
116- Description : "Stop Azure-CNM if flag is true " ,
114+ Name : acn .OptStartAzureCNM ,
115+ Shorthand : acn .OptStartAzureCNMAlias ,
116+ Description : "Start Azure-CNM if flag is set " ,
117117 Type : "bool" ,
118118 DefaultValue : false ,
119119 },
@@ -162,7 +162,6 @@ func printVersion() {
162162
163163// Main is the entry point for CNS.
164164func main () {
165- var stopcnm = false
166165 // Initialize and parse command line arguments.
167166 acn .ParseArgs (& args , printVersion )
168167
@@ -176,7 +175,7 @@ func main() {
176175 logDirectory := acn .GetArg (acn .OptLogLocation ).(string )
177176 ipamQueryUrl , _ := acn .GetArg (acn .OptIpamQueryUrl ).(string )
178177 ipamQueryInterval , _ := acn .GetArg (acn .OptIpamQueryInterval ).(int )
179- stopcnm = acn .GetArg (acn .OptStopAzureVnet ).(bool )
178+ startCNM : = acn .GetArg (acn .OptStartAzureCNM ).(bool )
180179 vers := acn .GetArg (acn .OptVersion ).(bool )
181180 createDefaultExtNetworkType := acn .GetArg (acn .OptCreateDefaultExtNetworkType ).(string )
182181 telemetryEnabled := acn .GetArg (acn .OptTelemetry ).(bool )
@@ -271,7 +270,7 @@ func main() {
271270 var netPlugin network.NetPlugin
272271 var ipamPlugin ipam.IpamPlugin
273272
274- if ! stopcnm {
273+ if startCNM {
275274 var pluginConfig acn.PluginConfig
276275 pluginConfig .Version = version
277276
@@ -344,7 +343,7 @@ func main() {
344343
345344 telemetryStopProcessing <- true
346345
347- if ! stopcnm {
346+ if startCNM {
348347 if netPlugin != nil {
349348 netPlugin .Stop ()
350349 }
0 commit comments