Repository: kubernetes-sigs/external-dns (language: go)

Issue:
hetzner provider applies changes regardless of --dry-run flag
**What happened**:
wanted to preview my settings with --dry-run, but despite the startup message "running in dry-run mode. No changes to DNS records will be made.", changes where in fact made to DNS.

**What you expected to happen**:
--dry-run should prevent changes to DNS to be applied

**How to reproduce it (as minimally and precisely as possible)**:
external-dns --provider hetzner --dry-run ...

**Environment**:
- External-DNS version (use `external-dns --version`): used image k8s.gcr.io/external-dns/external-dns:v0.9.0
- DNS provider: hetzner



Discussion / hints:

Fix patch:
diff --git a/provider/hetzner/hetzner.go b/provider/hetzner/hetzner.go
index 4e84c122ae..5f367bb2c2 100644
--- a/provider/hetzner/hetzner.go
+++ b/provider/hetzner/hetzner.go
@@ -141,6 +141,10 @@ func (p *HetznerProvider) submitChanges(ctx context.Context, changes []*HetznerC
 				}
 			}
 
+			logMessage := "Changing record"
+			if p.DryRun {
+				logMessage = "Would change record"
+			}
 			log.WithFields(log.Fields{
 				"id":      change.ResourceRecordSet.ID,
 				"record":  change.ResourceRecordSet.Name,
@@ -150,7 +154,10 @@ func (p *HetznerProvider) submitChanges(ctx context.Context, changes []*HetznerC
 				"action":  change.Action,
 				"zone":    change.ZoneName,
 				"zone_id": change.ZoneID,
-			}).Info("Changing record")
+			}).Info(logMessage)
+			if p.DryRun {
+				continue
+			}
 
 			switch change.Action {
 			case hetznerCreate:


Test patch: