fix: handle skipping
continuous-integration/drone/push Build is passing
Details
continuous-integration/drone/push Build is passing
Details
This commit is contained in:
parent
15d1e9dee0
commit
190c1033e6
|
@ -194,15 +194,20 @@ func autoConfigure(c *cli.Context, provider *gandi.Provider, zone string) error
|
|||
return err
|
||||
}
|
||||
|
||||
discovered := false
|
||||
for _, existingRecord := range existingRecords {
|
||||
if existingRecord.Type == record.Type &&
|
||||
existingRecord.Name == record.Name &&
|
||||
existingRecord.Value == record.Value {
|
||||
logrus.Warnf("%v for %s already exists?", record, zone)
|
||||
continue
|
||||
logrus.Warnf("%s record: %s %s for %s already exists?", record.Type, record.Name, record.Value, zone)
|
||||
discovered = true
|
||||
}
|
||||
}
|
||||
|
||||
if discovered {
|
||||
continue
|
||||
}
|
||||
|
||||
createdRecords, err := provider.SetRecords(
|
||||
c.Context,
|
||||
zone,
|
||||
|
|
Loading…
Reference in New Issue