diff --git a/doc/topics/releases/2016.3.5.rst b/doc/topics/releases/2016.3.5.rst index 60a9ec200d..d9555cab7c 100644 --- a/doc/topics/releases/2016.3.5.rst +++ b/doc/topics/releases/2016.3.5.rst @@ -4,3 +4,19 @@ Salt 2016.3.5 Release Notes Version 2016.3.5 is a bugfix release for :doc:`2016.3.0 `. + + +Improved Checksum Handling in :py:func:`file.managed `, :py:func:`archive.extracted ` States +----------------------------------------------------------------------------------------------------------------------------------------------------- + +When the ``source_hash`` argument for these states refers to a file containing +checksums, Salt now looks for checksums matching the name of the source URI, as +well as the file being managed. Prior releases only looked for checksums +matching the filename being managed. Additionally, a new argument +(``source_hash_name``) has been added, which allows the user to disambiguate +ambiguous matches when more than one matching checksum is found in the +``source_hash`` file. + +A more detailed explanation of this functionality can be found in the +:py:func:`file.managed ` documentation, in the +section for the new ``source_hash_name`` argument. diff --git a/salt/states/file.py b/salt/states/file.py index f40362d04b..8185482d54 100644 --- a/salt/states/file.py +++ b/salt/states/file.py @@ -1227,7 +1227,7 @@ def managed(name, source_hash_name When ``source_hash`` refers to a hash file, Salt will try to find the - correct hash by matching the filename associated with that hash. By + correct hash by matching the filename/URI associated with that hash. By default, Salt will look for the filename being managed. When managing a file at path ``/tmp/foo.txt``, then the following line in a hash file would match: