Merge pull request #31 from navi-infra/infra-425
INFRA-425 | Abhishek | Improve error message while applying
This commit is contained in:
@@ -185,8 +185,10 @@ public class KubernetesManifestService {
|
||||
namespace, clusterName);
|
||||
log.info("Executing command {}", command);
|
||||
|
||||
if (BashExecute.execute(command) > 0) {
|
||||
throw new RuntimeException(String.format("Unable to apply %s", manifestObject));
|
||||
try{
|
||||
BashExecute.execute(command);
|
||||
}catch(RuntimeException runtimeException){
|
||||
throw new RuntimeException(String.format("Unable to apply %s.Error = %s",manifestObject,runtimeException.getMessage()));
|
||||
}
|
||||
log.info("Successfully applied {}", manifestObject);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user