gitops-engine
gitops-engine copied to clipboard
Enable consumers of gitops-engine API to specify an alternative temp directory for generated manifests, as an alternative '/dev/shm'
See parent issue for details: https://github.com/argoproj/gitops-engine/issues/614
This PR:
- When calling gitops-engine, you will now need to explicitly define the temporary path to write kubectl manifests to:
- Add new parameter
tmpManifestPathto public APIs:-
NewEngineinpkg/engine/engine.go -
NewClusterCachein `pkg/cache/cluster.go
-
- In both cases, when calling these functions, you now must specify where to store temporary manifest files that are generated
- If you wish to preserve the existing behaviour, just use the value from calling
io.TempPathUseDevShmIfAvailable()(see examples in this PR)
- Add new parameter
- Updates existing gitops-engine code to use new API
- Preserves the existing behaviour of the code: code and tests that were previously using
/dev/shmwill continue to do so - Updates
pkg/utils/io/io.goAPI to make it more explicit about behaviour
Quality Gate passed
Issues
0 New issues
0 Accepted issues
Measures
0 Security Hotspots
0.0% Coverage on New Code
0.0% Duplication on New Code
The gitops-engine repository is migrating to https://github.com/argoproj/argo-cd. We are closing all draft PRs. Please feel free to submit it again once the migration is over.