@@ -89,14 +89,15 @@ func init() {
89
89
// Use V(5) for GCE Cloud Provider Call informational logging
90
90
// Use V(6) for extra repeated/polling information
91
91
enumFlag (& computeEnvironment , "compute-environment" , allowedComputeEnvironment , "Operating compute environment" )
92
- urlFlag (computeEndpoint , "compute-endpoint" , "Compute endpoint" )
92
+ urlFlag (& computeEndpoint , "compute-endpoint" , "Compute endpoint" )
93
93
klog .InitFlags (flag .CommandLine )
94
94
flag .Set ("logtostderr" , "true" )
95
95
}
96
96
97
97
func main () {
98
98
flag .Parse ()
99
99
rand .Seed (time .Now ().UnixNano ())
100
+ klog .Infof ("Operating compute environment set to: %s and computeEndpoint is set to: %v" , computeEnvironment , computeEndpoint )
100
101
handle ()
101
102
os .Exit (0 )
102
103
}
@@ -225,13 +226,14 @@ func enumFlag(target *gce.Environment, name string, allowedComputeEnvironment []
225
226
226
227
}
227
228
228
- func urlFlag (target * url.URL , name string , usage string ) {
229
+ func urlFlag (target * * url.URL , name string , usage string ) {
229
230
flag .Func (name , usage , func (flagValue string ) error {
230
231
computeURL , err := url .ParseRequestURI (flagValue )
231
232
if err == nil {
232
- target = computeURL
233
+ * target = computeURL
233
234
return nil
234
235
}
236
+ klog .Infof ("Error parsing endpoint compute endpoint %v" , err )
235
237
return err
236
238
})
237
239
}
0 commit comments