Add another missing piece to activate bosh editor for cloud-config

This commit is contained in:
Kris De Volder
2017-08-04 16:45:22 -07:00
parent e9ecff3c74
commit e631fb0a9e
4 changed files with 6 additions and 9 deletions

View File

@@ -41,7 +41,6 @@ public class BoshCliConfig {
}
public void handleConfigurationChange(Settings newConfig) {
Log.info("BoshCliConfig changed: "+newConfig);
this.settings = newConfig;
}
}

View File

@@ -24,9 +24,9 @@ public class BoshCloudConfigSchema extends SchemaSupport implements YamlSchema {
public BoshCloudConfigSchema(YTypeFactory f, BoshModels models) {
super(f);
this.toplevelType = f.ybean("CloudConfig");
t_any = f.yany("Object");
this.toplevelType = f.ybean("CloudConfig");
addProp(toplevelType, "azs", t_any);
addProp(toplevelType, "networks", t_any);
addProp(toplevelType, "vm_types", t_any);

View File

@@ -102,15 +102,12 @@ public abstract class BoshCommandBasedModelProvider<T> implements DynamicModelPr
}
protected String executeCommand(ExternalCommand command) throws Exception {
Log.info("executing cmd: "+command);
if (command==null) {
throw new IOException("bosh cli based editor features are disabled");
}
try {
ExternalProcess process = new ExternalProcess(getWorkingDir(), command, true, config.getTimeout());
Log.info("executing cmd SUCCESS: "+process);
String out = process.getOut();
return out;
return process.getOut();
} catch (Exception e) {
Log.log("executing cmd FAILED", e);
throw e;