Kaynağa Gözat

fixed authenticator to wait only once

issue #1
tags/v1.1.0
Robin Thoni 6 yıl önce
ebeveyn
işleme
d5e61c2e4b

+ 4
- 2
certbot_pdns/PdnsApiAuthenticator.py Dosyayı Görüntüle

@@ -81,12 +81,14 @@ class PdnsApiAuthenticator:
81 81
         self.flush_zone(zone["name"])
82 82
         self.notify_zone(zone["name"])
83 83
 
84
+        return response
85
+
86
+    def wait_for_propagation(self, achalls):
87
+        # TODO search zones authoritative servers and check for TXT record on each of them
84 88
         # raw_input('Press <ENTER> to continue')
85 89
         logger.info("Waiting %i seconds..." % self.axfr_time)
86 90
         time.sleep(self.axfr_time)
87 91
 
88
-        return response
89
-
90 92
     def cleanup(self, achall):
91 93
         domain = achall.domain
92 94
         zone = self.find_best_matching_zone(domain)

+ 3
- 1
certbot_pdns/authenticator.py Dosyayı Görüntüle

@@ -49,7 +49,9 @@ necessary validation resources to appropriate records in a PowerDNS server."""
49 49
         pass
50 50
 
51 51
     def perform(self, achalls):  # pylint: disable=missing-docstring
52
-        return [self._perform_single(achall) for achall in achalls]
52
+        responses = [self._perform_single(achall) for achall in achalls]
53
+        self.backend.wait_for_propagation(achalls)
54
+        return responses
53 55
 
54 56
     def _perform_single(self, achall):
55 57
         response, validation = achall.response_and_validation()

Loading…
İptal
Kaydet