The old way of using the git archive doesn't seem
to work anymore so trying another approach
Was getting "fatal: operation not supported by protocol"
when trying the git archive
Fixes: https://tracker.ceph.com/issues/58222
Signed-off-by: Adam King <adking@redhat.com>
else:
ctx.cluster.run(
args=[
- 'git', 'archive',
- '--remote=' + git_url,
- ref,
- 'src/cephadm/cephadm',
- run.Raw('|'),
- 'tar', '-xO', 'src/cephadm/cephadm',
+ 'git', 'clone', git_url, 'testrepo',
+ run.Raw('&&'),
+ 'cd', 'testrepo',
+ run.Raw('&&'),
+ 'git', 'show', f'{ref}:src/cephadm/cephadm',
run.Raw('>'),
ctx.cephadm,
+ run.Raw('&&'),
+ 'ls', '-l', ctx.cephadm,
],
)
# sanity-check the resulting file and set executable bit