Open Aketzu opened 6 years ago
As noted in the refereced issue this is unsupported way from git-lfs side. So it might be easier to change cookbook-omnifetch in the short term.
Background about the case: We use policyfile to distribute cookbooks to a server behind firewalls and transferring a single package is the easiest way. Also due to firewalls we need to include all related software (Java, Payara, apps) in the cookbooks and storing large binary blobs in Git repo is rather inefficient without lfs support.
We need to check if this is still an issue
Description
When I try to run chef install Policyfile.rb the run will end with
Smudge error: Error downloading
from git-lfs.Not sure whether the problem is in the way cookbook-omnifetch uses git or in git-lfs not providing support for this case.
ChefDK Version
Chef Development Kit Version: 2.3.4 chef-client version: 13.4.19 delivery version: master (73ebb72a6c42b3d2ff5370c476be800fee7e5427) berks version: 6.3.1 kitchen version: 1.17.0 inspec version: 1.36.1
Platform Version
Debian 9.1 (docker bitnami/minideb:latest)
Log
Log of the run in https://gist.github.com/Aketzu/79bafc57d0c276acfe06acfc9b9bf31c
Main points:
Thoughts
Since cookbook-omnifetch is doing clone --bare + clone + reset the first repo will not contain git-lfs files and subsequent reset will fail to connect the dots between clone and real original repo (GitLab server in this case).
If I do just git clone (without --bare) I get the full repo with lfs files so permissions and URLs work in the normal case.
In this case command is run in a clean docker container every time so caching the repo is pointless but there is no option to disable caching.