Project

General

Profile

action #154240

Updated by livdywan 4 months ago

## Motivation 
 As part of #138029 support for git caching was included in os-autoinst. We already have some special handling for CACHE directories so that people cloning without knowing about GIT_CACHE_DIR are not confronted with errors. 

  

 ## Acceptance criteria 
 * **AC1:** Cloning jobs to a local openQA instance when jobs that have GIT_CACHE_DIR set to a directory local instance that does do not exist locally have that directory works without errors 

 ## Acceptance tests 
 * **AT1-1:** *Given* an openQA job on o3 with GIT_CACHE_DIR set *When* cloning that to a local instance *And* the specified GIT_CACHE_DIR does not exist locally *And* there is no locally specified GIT_CACHE_DIR *Then* no git caching is done *And* no error is given 
 * **AT1-2:** *Given* an openQA job on o3 with GIT_CACHE_DIR set *When* cloning that to a local instance *And* the specified GIT_CACHE_DIR does not exist locally *And* there is a locally specified GIT_CACHE_DIR *Then* git caching is done into the locally specified GIT_CACHE_DIR 

 ## Suggestions 
 * See what had been done in #154156 
 * Lookup in our cloning tools and worker code how we handle cache directories 
 * Add according handling for GIT_CACHE_DIR so that usual use cases for cloning to other openQA instances are handled 
 * Set a local GIT_CACHE_DIR, and cross-check without it set and see what happens 

 ## Out of scope 
 And security considerations as we have apparmor and directory permissions for that

Back