Chef::Exceptions::ChecksumMismatch when installing nginx-1.7.8 from source

主宰稳场 提交于 2019-12-04 03:56:41

The nginx cookbook requires you to edit the checksum attribute when using another version of nginx. The remote_file resource that is causing you an error is:

remote_file nginx_url do
  source   nginx_url
  checksum node['nginx']['source']['checksum']
  path     src_filepath
  backup   false
end

You need to update the checksum value. Specifically node['nginx']['source']['checksum'].

So in your JSON, you would add this line:

"source": {"checksum": "insert checksum here" }

Edit: As pointed out in the comments, the checksum is SHA256. You can generate the checksum of the file like so:

shasum -a 256 nginx-1.7.8.tar.gz
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!