mirror of
https://github.com/kubernetes-sigs/external-dns.git
synced 2025-08-07 01:56:57 +02:00
Update provider/scaleway/scaleway.go
Co-authored-by: Michel Loiseleur <97035654+mloiseleur@users.noreply.github.com>
This commit is contained in:
parent
1dc4690dcb
commit
e542a62033
@ -66,18 +66,16 @@ func NewScalewayProvider(ctx context.Context, domainFilter endpoint.DomainFilter
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
p := &scw.Profile{}
|
p := &scw.Profile{}
|
||||||
c, err := scw.LoadConfig()
|
c, err := scw.LoadConfig()
|
||||||
if err != nil {
|
if err != nil {
|
||||||
log.Infof("%s", err)
|
log.Warnf("Cannot load config: %v", err)
|
||||||
} else {
|
} else {
|
||||||
tempProfile, err := c.GetActiveProfile()
|
p, err = c.GetActiveProfile()
|
||||||
if err != nil {
|
if err != nil {
|
||||||
log.Infof("%s", err)
|
log.Warnf("Cannot get active profile: %v", err)
|
||||||
} else {
|
}
|
||||||
p = tempProfile
|
}
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
scwClient, err := scw.NewClient(
|
scwClient, err := scw.NewClient(
|
||||||
scw.WithProfile(p),
|
scw.WithProfile(p),
|
||||||
|
Loading…
Reference in New Issue
Block a user