Open lukaszachy opened 1 year ago
Hello @lukaszachy , just checking up on this. I ran into this issue and then got distracted with other things, now seeing this again :)
Working on adding centos stream tests to buildah at https://github.com/containers/buildah/pull/5289 . A lot of the makefile targets expect .git
to exist and since the test env can't find the git metadata dir, I see failures like: https://artifacts.dev.testing-farm.io/fbf0329b-8a3b-4f27-8f80-706c295f6946/
fatal: not a git repository (or any of the parent directories): .git
Makefile:39: *** "git failed". Stop.
Shared connection to 18.118.6.58 closed.
As first step we can fix keep-git-metadata
flag to be usable without url ...
Decision from the hacking session:
keep-git-metadata
Is the plan to implement a prepare.how: keep-git-metadata
step after which the fmf tree has the same .git
metadata with whatever changes are added before/after this step?
Currently we have few options and some auto detection. Would be good to have it under same name and documented behavior to limit surprises.
Motivation to remove this directory is to save disk space and limit the amount of transferred data between host and guests. But sometimes user needs it at guest as well.
At the moment:
_initialize_worktree()
always skips .git (affects 'prepare', 'finish' and 'discover.shell' without url option)discover.shell
has--keep-git-metadata
which applies only if 'url' is used, by default .git is removed. There is no way how to keep .git without the 'url' option.discover.fmf
has .git always present. Note the--sync-repo
exists to copy git root instead of fmf root to the test directory.The expected behavior:
.git
is not present in the worktree or test directories unless user asks for it or user uses option which requires .git to be present..git
has same name across all plugins (IMO--keep-git-metadata
is verbose enough)