Always ensure that the local lxc cache file matches the upstream image
Ansible 1.9x only actually checks whether there's a local file - it never
checks whether the local file matches the given sha256sum.
We therefore need to set 'force:yes' to ensure that Ansible does the
following:
- download the file to a temporary location, checking its sha256sum
against the given value
- check the sha256sum of the existing file and the downloaded file
- if the sha256sums match, then throw away the temp file
- if the sha256sums do not match, replace the existing file
In order to also provide the ability to forcibly delete any existing lxc
cache which was previously prepared (successfully or unsuccessfully), the
boolean variable 'lxc_container_base_delete' has been added.
Reviewed: https:/ /review. openstack. org/289339 /git.openstack. org/cgit/ openstack/ openstack- ansible- lxc_hosts/ commit/ ?id=45beccf508b 9fcd31d85e0895e fc1efaac0e2032
Committed: https:/
Submitter: Jenkins
Branch: master
commit 45beccf508b9fcd 31d85e0895efc1e faac0e2032
Author: Jesse Pretorius <email address hidden>
Date: Mon Mar 7 13:35:08 2016 +0000
Always ensure that the local lxc cache file matches the upstream image
Ansible 1.9x only actually checks whether there's a local file - it never
checks whether the local file matches the given sha256sum.
We therefore need to set 'force:yes' to ensure that Ansible does the
following:
- download the file to a temporary location, checking its sha256sum
against the given value
- check the sha256sum of the existing file and the downloaded file
- if the sha256sums match, then throw away the temp file
- if the sha256sums do not match, replace the existing file
In order to also provide the ability to forcibly delete any existing lxc base_delete' has been added.
cache which was previously prepared (successfully or unsuccessfully), the
boolean variable 'lxc_container_
Change-Id: I988940892c8967 9edea8877168513 14fc1cf13b5
Closes-Bug: #1539236