File tree Expand file tree Collapse file tree 2 files changed +7
-2
lines changed
lib/interface/cli/commands/hybrid Expand file tree Collapse file tree 2 files changed +7
-2
lines changed Original file line number Diff line number Diff line change @@ -124,6 +124,10 @@ const deleteCmd = new Command({
124124 . option ( 'kube-config-path' , {
125125 describe : 'Path to kubeconfig file (default is $HOME/.kube/config)' ,
126126 } )
127+ . option ( 'keep-cluster-integration' , {
128+ describe : 'If true, will not delete dangling cluster integrations from Codefresh' ,
129+ type : Boolean ,
130+ } )
127131 . option ( 'values' , {
128132 describe : 'specify values in a YAML file' ,
129133 } )
@@ -142,6 +146,7 @@ const deleteCmd = new Command({
142146 verbose,
143147 force,
144148 'kube-config-path' : kubeConfigPath ,
149+ 'keep-cluster-integration' : keepClusterIntegration ,
145150 } = _argv ;
146151 let {
147152 url,
@@ -249,7 +254,7 @@ const deleteCmd = new Command({
249254 const runtimesToDelete = _ . filter ( runtimes , re => attachedRuntimes . includes ( _ . get ( re , 'metadata.name' ) ) ) ;
250255 const defaultRuntime = _ . get ( _ . find ( runtimes , re => re . default ) , 'metadata.name' ) ;
251256
252- const clustersToDelete = getClustersToDelete ( clusters , runtimes , runtimesToDelete ) ;
257+ const clustersToDelete = keepClusterIntegration ? [ ] : getClustersToDelete ( clusters , runtimes , runtimesToDelete ) ;
253258 const appProxyToDelete = getAppProxyToDelete ( runtimesToDelete ) ;
254259
255260 if ( ! force ) {
Original file line number Diff line number Diff line change 11{
22 "name" : " codefresh" ,
3- "version" : " 0.81.4 " ,
3+ "version" : " 0.81.5 " ,
44 "description" : " Codefresh command line utility" ,
55 "main" : " index.js" ,
66 "preferGlobal" : true ,
You can’t perform that action at this time.
0 commit comments