Fix cache update after initial apt_repository fail
If apt_repository fails to update the apt cache after updating the
configuration, retries don't register there was a change and so no
attempt is made to update the cache by the module on the second attempt.
This failure can result in a failure to install packages.
This change adds an apt module task to update the cache if the
apt_repository task registers a change. This means updating the cache
will get retried on failure and no longer fail silently.
Change-Id: I1d71deeee64fe27df1275965aac8240cc2ab427c
Partial-Bug: #1750656
(cherry picked from commit fe537c7a29ff7022e30771d2f59c00c9bece008e)
Reviewed: https:/ /review. openstack. org/547433 /git.openstack. org/cgit/ openstack/ openstack- ansible- os_nova/ commit/ ?id=d85329add05 4c834e2c1f4a059 3c4038f67a0593
Committed: https:/
Submitter: Zuul
Branch: stable/newton
commit d85329add054c83 4e2c1f4a0593c40 38f67a0593
Author: Jesse Pretorius <email address hidden>
Date: Thu Feb 22 14:34:56 2018 +0000
Fix cache update after initial apt_repository fail
If apt_repository fails to update the apt cache after updating the
configuration, retries don't register there was a change and so no
attempt is made to update the cache by the module on the second attempt.
This failure can result in a failure to install packages.
This change adds an apt module task to update the cache if the
apt_repository task registers a change. This means updating the cache
will get retried on failure and no longer fail silently.
Change-Id: I1d71deeee64fe2 7df1275965aac82 40cc2ab427c 2e30771d2f59c00 c9bece008e)
Partial-Bug: #1750656
(cherry picked from commit fe537c7a29ff702