Chef Ideas

We believe that the best way to build software is to do it in close collaboration with the people who use it. We invite you to submit your ideas using the form below. Please be sure to include the problem for which you are solving and the benefits of implementing the idea.

We do our best to implement as many Ideas as we can. Our Product team will evaluate all submitted ideas in a timely manner and will disposition each into one of the following categories: will integrate into the product roadmap, further research is needed, unlikely to implement.

Thanks for collaborating with us!

File resource Checksums should match truncated Checksums

Moving from https://github.com/chef/chef/issues/2689


while deploying a file with remote_file I have following errors :


```

Chef::Exceptions::ChecksumMismatch

----------------------------------

Checksum on resource (713570) does not match checksum on content (713570)

```


As you see both checksum match.


chef-client release 12.0.0-1 and also 12.0.3-1 on ubuntu report the problem, chef until 11.16.4-1 work fine.


chef code :


```

remote_file("hidden_app") do

provider Chef::Provider::RemoteFile

action "create"

retries 0

retry_delay 2

default_guard_interpreter :default

path "/hidden/path/7135700/package.tgz"

backup 5

atomic_update true

source ["http://hidden.ip/path//package.tar.gz"]

use_etag true

use_last_modified true

declared_type :remote_file

cookbook_name "application"

recipe_name "hidenanme"

mode "0644"

checksum "7135700"

end

```


Checksum of the file manually :

`# sha256sum package.tar.gz

713570049424aee165d8dcc83bd27c3fc8281e61a2f268a215adf920f3ee7e9b package.tar.gz`


Cheksum found in chef cache file :

`{"etag":null,"mtime":null,"checksum":"713570049424aee165d8dcc83bd27c3fc8281e61a2f268a215adf920f3ee7e9b"}

`

If I download manually the file and put it in the good place /hidden/path/7135700/package.tgz, then it works. Checksum against an existing file is working.


  • Tim Smith
  • Oct 3 2021
  • New
  • Attach files