netgod / rpms / anaconda

Forked from rpms/anaconda 2 years ago
Clone
6e5b62
diff -uNr anaconda-21.48.22.56__orig/pyanaconda/packaging/yumpayload.py anaconda-21.48.22.56/pyanaconda/packaging/yumpayload.py
6e5b62
--- anaconda-21.48.22.56__orig/pyanaconda/packaging/yumpayload.py       2015-12-08 14:36:52.533000000 +0000
6e5b62
+++ anaconda-21.48.22.56/pyanaconda/packaging/yumpayload.py     2015-12-08 14:38:51.464000000 +0000
6e5b62
@@ -648,6 +648,10 @@
6e5b62
                     # so that unattended installations on unreliable networks have
6e5b62
                     # a higher chance of finishing successfully
6e5b62
                     xdelay = xprogressive_delay()
6e5b62
+                    if not nm_is_connected():
6e5b62
+                      MAX_METADATA_DOWNLOAD_RETRIES = 1
6e5b62
+                    else:
6e5b62
+                      MAX_METADATA_DOWNLOAD_RETRIES = 10
6e5b62
                     for retry_count in xrange(0, MAX_METADATA_DOWNLOAD_RETRIES + 1):
6e5b62
                         if retry_count > 0:
6e5b62
                             # introduce a retry delay