Skip to content

Commit b03a8d8

Browse files
committed
Fix restart MS issue and method mappings in provisioner.sh
1 parent 32ffb32 commit b03a8d8

File tree

2 files changed

+4
-5
lines changed

2 files changed

+4
-5
lines changed

plugins/hypervisors/external/src/main/java/com/cloud/hypervisor/external/provisioner/simpleprovisioner/SimpleExternalProvisioner.java

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -272,13 +272,12 @@ public RunCustomActionAnswer runCustomAction(RunCustomActionCommand cmd) {
272272
public void prepareScripts(Long extensionId, Long extensionResourceId) {
273273
String destinationPath = String.format(EXTENSION_SCRIPT_PATH, extensionId, extensionResourceId);
274274
File destinationFile = new File(destinationPath);
275+
filledExtensionPath = destinationPath;
275276
if (destinationFile.exists()) {
276277
logger.info("File already exists at " + destinationPath + ", skipping copy.");
277278
return;
278279
}
279280

280-
filledExtensionPath = destinationPath;
281-
282281
String destinationDir = destinationPath.substring(0, destinationPath.lastIndexOf('/'));
283282
Script mkdirScript = new Script(true, "/bin/mkdir", 0, logger);
284283
mkdirScript.add("-p", destinationDir);

scripts/vm/hypervisor/external/simpleExternalProvisioner/provisioner.sh

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -99,13 +99,13 @@ case $action in
9999
delete "$parameters"
100100
;;
101101
start)
102-
prepare "$parameters"
102+
start "$parameters"
103103
;;
104104
stop)
105-
create "$parameters"
105+
stop "$parameters"
106106
;;
107107
reboot)
108-
delete "$parameters"
108+
reboot "$parameters"
109109
;;
110110
status)
111111
status "$parameters"

0 commit comments

Comments
 (0)