diff --git a/google/config.go b/google/config.go index 47d27630e08..6aaa9aaaafa 100644 --- a/google/config.go +++ b/google/config.go @@ -33,6 +33,7 @@ import ( "google.golang.org/api/dataproc/v1" "google.golang.org/api/dns/v1" dnsBeta "google.golang.org/api/dns/v1beta2" + file "google.golang.org/api/file/v1beta1" "google.golang.org/api/iam/v1" cloudlogging "google.golang.org/api/logging/v2" "google.golang.org/api/pubsub/v1" @@ -70,6 +71,7 @@ type Config struct { clientDataflow *dataflow.Service clientDns *dns.Service clientDnsBeta *dnsBeta.Service + clientFile *file.Service clientKms *cloudkms.Service clientLogging *cloudlogging.Service clientPubsub *pubsub.Service @@ -348,6 +350,12 @@ func (c *Config) loadAndValidate() error { } c.clientDataproc.UserAgent = userAgent + c.clientFile, err = file.New(client) + if err != nil { + return err + } + c.clientFile.UserAgent = userAgent + log.Printf("[INFO] Instantiating Google Cloud IoT Core Client...") c.clientCloudIoT, err = cloudiot.New(client) if err != nil {