Commit 2bff1450 authored by Spiros Koulouzis's avatar Spiros Koulouzis

added WhetherCreateVPC property from ec2

parent 5c85c1d6
......@@ -17,6 +17,20 @@ import javax.validation.Valid;
public class CloudsStormVMs {
/**
* @return the whetherCreateVPC
*/
public Boolean getWhetherCreateVPC() {
return whetherCreateVPC;
}
/**
* @param whetherCreateVPC the whetherCreateVPC to set
*/
public void setWhetherCreateVPC(Boolean whetherCreateVPC) {
this.whetherCreateVPC = whetherCreateVPC;
}
/**
* @return the sliceName
*/
......@@ -81,6 +95,10 @@ public class CloudsStormVMs {
@Valid
private List<CloudsStormVM> vms = null;
@JsonProperty("WhetherCreateVPC")
@Valid
private Boolean whetherCreateVPC;
@JsonProperty("SEngineClass")
@Valid
private String sEngineClass = null;
......
......@@ -2,11 +2,7 @@
<project version="4">
<component name="ChangeListManager">
<list default="true" id="e478ccae-5352-4e8e-9efb-3f5cda44e877" name="Default Changelist" comment="">
<change beforePath="$PROJECT_DIR$/../TOSCA/application_example_updated.yaml" beforeDir="false" afterPath="$PROJECT_DIR$/../TOSCA/application_example_updated.yaml" afterDir="false" />
<change beforePath="$PROJECT_DIR$/.idea/workspace.xml" beforeDir="false" afterPath="$PROJECT_DIR$/.idea/workspace.xml" afterDir="false" />
<change beforePath="$PROJECT_DIR$/requirements.txt" beforeDir="false" afterPath="$PROJECT_DIR$/requirements.txt" afterDir="false" />
<change beforePath="$PROJECT_DIR$/../sure_tosca-flask-server/sure_tosca/service/tosca_template_service.py" beforeDir="false" afterPath="$PROJECT_DIR$/../sure_tosca-flask-server/sure_tosca/service/tosca_template_service.py" afterDir="false" />
<change beforePath="$PROJECT_DIR$/../sure_tosca-flask-server/sure_tosca/test/test_default_controller.py" beforeDir="false" afterPath="$PROJECT_DIR$/../sure_tosca-flask-server/sure_tosca/test/test_default_controller.py" afterDir="false" />
</list>
<option name="SHOW_DIALOG" value="false" />
<option name="HIGHLIGHT_CONFLICTS" value="true" />
......@@ -273,26 +269,26 @@
</state>
<state x="792" y="334" width="827" height="663" key="FileChooserDialogImpl/67.34.1853.1046@67.34.1853.1046" timestamp="1578326180157" />
<state x="1043" y="437" width="530" height="598" key="FileChooserDialogImpl/67.34.2493.1406@67.34.2493.1406" timestamp="1575907769017" />
<state width="2465" height="341" key="GridCell.Tab.0.bottom" timestamp="1580135261557">
<state width="2465" height="341" key="GridCell.Tab.0.bottom" timestamp="1580144167395">
<screen x="67" y="34" width="2493" height="1406" />
</state>
<state width="1825" height="341" key="GridCell.Tab.0.bottom/67.34.1853.1046@67.34.1853.1046" timestamp="1580127646320" />
<state width="2465" height="341" key="GridCell.Tab.0.bottom/67.34.2493.1406@67.34.2493.1406" timestamp="1580135261557" />
<state width="2465" height="341" key="GridCell.Tab.0.center" timestamp="1580135261557">
<state width="2465" height="341" key="GridCell.Tab.0.bottom/67.34.2493.1406@67.34.2493.1406" timestamp="1580144167395" />
<state width="2465" height="341" key="GridCell.Tab.0.center" timestamp="1580144167393">
<screen x="67" y="34" width="2493" height="1406" />
</state>
<state width="1825" height="341" key="GridCell.Tab.0.center/67.34.1853.1046@67.34.1853.1046" timestamp="1580127646318" />
<state width="2465" height="341" key="GridCell.Tab.0.center/67.34.2493.1406@67.34.2493.1406" timestamp="1580135261557" />
<state width="2465" height="341" key="GridCell.Tab.0.left" timestamp="1580135261556">
<state width="2465" height="341" key="GridCell.Tab.0.center/67.34.2493.1406@67.34.2493.1406" timestamp="1580144167393" />
<state width="2465" height="341" key="GridCell.Tab.0.left" timestamp="1580144167390">
<screen x="67" y="34" width="2493" height="1406" />
</state>
<state width="1825" height="341" key="GridCell.Tab.0.left/67.34.1853.1046@67.34.1853.1046" timestamp="1580127646317" />
<state width="2465" height="341" key="GridCell.Tab.0.left/67.34.2493.1406@67.34.2493.1406" timestamp="1580135261556" />
<state width="2465" height="341" key="GridCell.Tab.0.right" timestamp="1580135261557">
<state width="2465" height="341" key="GridCell.Tab.0.left/67.34.2493.1406@67.34.2493.1406" timestamp="1580144167390" />
<state width="2465" height="341" key="GridCell.Tab.0.right" timestamp="1580144167394">
<screen x="67" y="34" width="2493" height="1406" />
</state>
<state width="1825" height="341" key="GridCell.Tab.0.right/67.34.1853.1046@67.34.1853.1046" timestamp="1580127646319" />
<state width="2465" height="341" key="GridCell.Tab.0.right/67.34.2493.1406@67.34.2493.1406" timestamp="1580135261557" />
<state width="2465" height="341" key="GridCell.Tab.0.right/67.34.2493.1406@67.34.2493.1406" timestamp="1580144167394" />
<state width="2465" height="407" key="GridCell.Tab.1.bottom" timestamp="1580077545495">
<screen x="67" y="34" width="2493" height="1406" />
</state>
......
......@@ -71,6 +71,12 @@
<artifactId>commons-math3</artifactId>
<version>3.6.1</version>
</dependency>
<dependency>
<groupId>org.apache.maven.shared</groupId>
<artifactId>maven-shared-utils</artifactId>
<version>3.1.0</version>
<type>jar</type>
</dependency>
</dependencies>
......
......@@ -50,6 +50,7 @@ import nl.uva.sne.drip.sure.tosca.client.ApiException;
import org.apache.commons.io.FileUtils;
import org.apache.commons.io.FilenameUtils;
import org.apache.commons.math3.ml.distance.EuclideanDistance;
import org.apache.maven.shared.utils.io.DirectoryScanner;
/**
*
......@@ -322,7 +323,15 @@ class CloudStormService {
rootKeyPairCredential.setProtocol("ssh");
Map<String, String> rootKeys = new HashMap<>();
rootKeys.put("private_key", Converter.encodeFileToBase64Binary(rootKeyPairFolder + File.separator + "id_rsa"));
rootKeys.put("public_key", Converter.encodeFileToBase64Binary(rootKeyPairFolder + File.separator + "id_rsa.pub"));
DirectoryScanner scanner = new DirectoryScanner();
scanner.setIncludes(new String[]{"**/*.pub"});
scanner.setBasedir(rootKeyPairFolder + File.separator);
scanner.setCaseSensitive(false);
scanner.scan();
String[] fileNames = scanner.getIncludedFiles();
rootKeys.put("public_key", Converter.encodeFileToBase64Binary(rootKeyPairFolder + File.separator + File.separator + fileNames[0]));
rootKeyPairCredential.setKeys(rootKeys);
String userKyePairFolder = tempInputDirPath + TOPOLOGY_RELATIVE_PATH;
......
......@@ -7,6 +7,8 @@
type: object
additionalProperties:
type: object
WhetherCreateVPC:
type: "boolean"
sliceName:
type: "string"
duration:
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment