Skip to content

Commit 96d0383

Browse files
committed
Install wizard updates
-Fix tooltips -Poll system VMs and enable zone at end
1 parent 078f80b commit 96d0383

2 files changed

Lines changed: 46 additions & 7 deletions

File tree

‎ui/scripts/installWizard.js‎

Lines changed: 45 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -64,37 +64,37 @@
6464
});
6565
},
6666

67-
'tooltip.addGuestNetwork.name': function(args) {
67+
'tooltip.configureGuestTraffic.name': function(args) {
6868
args.response.success({
6969
text: 'A name for your network'
7070
});
7171
},
7272

73-
'tooltip.addGuestNetwork.description': function(args) {
73+
'tooltip.configureGuestTraffic.description': function(args) {
7474
args.response.success({
7575
text: 'A description for your network'
7676
});
7777
},
7878

79-
'tooltip.addGuestNetwork.guestGateway': function(args) {
79+
'tooltip.configureGuestTraffic.guestGateway': function(args) {
8080
args.response.success({
8181
text: 'The gateway that the guests should use'
8282
});
8383
},
8484

85-
'tooltip.addGuestNetwork.guestNetmask': function(args) {
85+
'tooltip.configureGuestTraffic.guestNetmask': function(args) {
8686
args.response.success({
8787
text: 'The netmask in use on the subnet that the guests should use'
8888
});
8989
},
9090

91-
'tooltip.addGuestNetwork.guestStartIp': function(args) {
91+
'tooltip.configureGuestTraffic.guestStartIp': function(args) {
9292
args.response.success({
9393
text: 'The range of IP addresses that will be available for allocation to guests in this zone. If one NIC is used, these IPs should be in the same CIDR as the pod CIDR.'
9494
});
9595
},
9696

97-
'tooltip.addGuestNetwork.guestEndIp': function(args) {
97+
'tooltip.configureGuestTraffic.guestEndIp': function(args) {
9898
args.response.success({
9999
text: 'The range of IP addresses that will be available for allocation to guests in this zone. If one NIC is used, these IPs should be in the same CIDR as the pod CIDR.'
100100
});
@@ -229,6 +229,8 @@
229229
},
230230

231231
action: function(args) {
232+
var success = args.response.success;
233+
var message = args.response.message;
232234

233235
// Get default network offering
234236
var selectedNetworkOffering;
@@ -258,6 +260,43 @@
258260
domain: 1,
259261
networkOfferingId: selectedNetworkOffering.id
260262
}
263+
},
264+
response: {
265+
success: function(args) {
266+
// Poll System VMs, then enable zone
267+
message('Creating system VMs (this may take a while)');
268+
var poll = setInterval(function() {
269+
$.ajax({
270+
url: createURL('listSystemVms'),
271+
dataType: 'json',
272+
async: true,
273+
success: function(data) {
274+
var systemVMs = data.listsystemvmsresponse.systemvm;
275+
276+
if (systemVMs && systemVMs.length > 1) {
277+
if (systemVMs.length == $.grep(systemVMs, function(vm) {
278+
return vm.state == 'Running';
279+
}).length) {
280+
clearInterval(poll);
281+
message('System VMs are up.');
282+
message('Enabling zone...');
283+
cloudStack.zoneWizard.enableZoneAction({
284+
data: args.data,
285+
formData: args.formData,
286+
response: {
287+
success: function(args) {
288+
message('Done!');
289+
290+
setTimeout(success, 2000);
291+
}
292+
}
293+
})
294+
}
295+
}
296+
}
297+
});
298+
}, 5000);
299+
}
261300
}
262301
}));
263302
}

‎ui/scripts/zoneWizard.js‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2209,7 +2209,7 @@
22092209

22102210
var complete = function(args) {
22112211
message('Zone creation complete!');
2212-
success({});
2212+
success(args);
22132213
};
22142214

22152215
if (startFn) {

0 commit comments

Comments
 (0)