diff --git a/src/app/app.module.ts b/src/app/app.module.ts
index 3edba25a..fbcdc4ff 100644
--- a/src/app/app.module.ts
+++ b/src/app/app.module.ts
@@ -211,6 +211,8 @@ import { ProjectsFilter } from './filters/projectsFilter.pipe';
import { ComputeService } from './services/compute.service';
import { ReloadNodeActionComponent } from './components/project-map/context-menu/actions/reload-node-action/reload-node-action.component';
import { SuspendNodeActionComponent } from './components/project-map/context-menu/actions/suspend-node-action/suspend-node-action.component';
+import { ConfigActionComponent } from './components/project-map/context-menu/actions/config-action/config-action.component';
+import { ConfiguratorDialogVpcsComponent } from './components/project-map/node-editors/configurator/vpcs/configurator-vpcs.component';
if (environment.production) {
Raven.config('https://b2b1cfd9b043491eb6b566fd8acee358@sentry.io/842726', {
@@ -349,7 +351,9 @@ if (environment.production) {
ChangeSymbolActionComponent,
EditProjectDialogComponent,
ReloadNodeActionComponent,
- SuspendNodeActionComponent
+ SuspendNodeActionComponent,
+ ConfigActionComponent,
+ ConfiguratorDialogVpcsComponent
],
imports: [
BrowserModule,
@@ -449,7 +453,8 @@ if (environment.production) {
SaveProjectDialogComponent,
InfoDialogComponent,
ChangeSymbolDialogComponent,
- EditProjectDialogComponent
+ EditProjectDialogComponent,
+ ConfiguratorDialogVpcsComponent
],
bootstrap: [AppComponent]
})
diff --git a/src/app/cartography/models/node.ts b/src/app/cartography/models/node.ts
index 5caf995f..3478617f 100644
--- a/src/app/cartography/models/node.ts
+++ b/src/app/cartography/models/node.ts
@@ -5,6 +5,7 @@ export class Node {
command_line: string;
compute_id: string;
console: number;
+ console_auto_start: boolean;
console_host: string;
console_type: string;
first_port_name: string;
diff --git a/src/app/components/project-map/context-menu/actions/config-action/config-action.component.html b/src/app/components/project-map/context-menu/actions/config-action/config-action.component.html
new file mode 100644
index 00000000..3290ba3a
--- /dev/null
+++ b/src/app/components/project-map/context-menu/actions/config-action/config-action.component.html
@@ -0,0 +1,4 @@
+
diff --git a/src/app/components/project-map/context-menu/actions/config-action/config-action.component.spec.ts b/src/app/components/project-map/context-menu/actions/config-action/config-action.component.spec.ts
new file mode 100644
index 00000000..e69de29b
diff --git a/src/app/components/project-map/context-menu/actions/config-action/config-action.component.ts b/src/app/components/project-map/context-menu/actions/config-action/config-action.component.ts
new file mode 100644
index 00000000..5d9d0974
--- /dev/null
+++ b/src/app/components/project-map/context-menu/actions/config-action/config-action.component.ts
@@ -0,0 +1,58 @@
+import { Component, Input, OnInit, OnChanges } from '@angular/core';
+import { Server } from '../../../../../models/server';
+import { Node } from '../../../../../cartography/models/node';
+import { MatDialog, MatDialogRef } from '@angular/material';
+import { ConfiguratorDialogVpcsComponent } from '../../../node-editors/configurator/vpcs/configurator-vpcs.component';
+
+
+@Component({
+ selector: 'app-config-node-action',
+ templateUrl: './config-action.component.html'
+})
+export class ConfigActionComponent {
+ @Input() server: Server;
+ @Input() node: Node;
+ private conf = {
+ width: '600px',
+ autoFocus: false
+ };
+ dialogRef;
+
+ constructor(private dialog: MatDialog) {}
+
+ configureNode() {
+ if (this.node.node_type === 'vpcs') {
+ this.dialogRef = this.dialog.open(ConfiguratorDialogVpcsComponent, this.conf);
+ } else if (this.node.node_type === 'ethernet_hub') {
+
+ } else if (this.node.node_type === 'ethernet_switch') {
+
+ } else if (this.node.node_type === 'cloud') {
+
+ } else if (this.node.node_type === 'dynamips') {
+
+ } else if (this.node.node_type === 'iou') {
+
+ } else if (this.node.node_type === 'qemu') {
+
+ } else if (this.node.node_type === 'virtualbox') {
+
+ } else if (this.node.node_type === 'vmware') {
+
+ } else if (this.node.node_type === 'docker') {
+
+ } else if (this.node.node_type === 'nat') {
+
+ } else if (this.node.node_type === 'frame_relay_switch') {
+
+ } else if (this.node.node_type === 'atm_switch') {
+
+ } else if (this.node.node_type === 'traceng') {
+
+ }
+
+ let instance = this.dialogRef.componentInstance;
+ instance.server = this.server;
+ instance.node = this.node;
+ }
+}
diff --git a/src/app/components/project-map/context-menu/context-menu.component.html b/src/app/components/project-map/context-menu/context-menu.component.html
index 091a6fcf..177d607d 100644
--- a/src/app/components/project-map/context-menu/context-menu.component.html
+++ b/src/app/components/project-map/context-menu/context-menu.component.html
@@ -5,6 +5,10 @@
[server]="server"
[node]="nodes[0]"
>
+