deploy docker vm without starting it
diff --git a/engine/orchestration/src/com/cloud/vm/VirtualMachineManagerImpl.java b/engine/orchestration/src/com/cloud/vm/VirtualMachineManagerImpl.java index 6d18f86..6e9e78c 100755 --- a/engine/orchestration/src/com/cloud/vm/VirtualMachineManagerImpl.java +++ b/engine/orchestration/src/com/cloud/vm/VirtualMachineManagerImpl.java
@@ -405,7 +405,7 @@ if (template.getFormat() == ImageFormat.ISO) { volumeMgr.allocateRawVolume(Type.ROOT, "ROOT-" + vmFinal.getId(), rootDiskOffering.first(), rootDiskOffering.second(), vmFinal, template, owner); - } else if (template.getFormat() == ImageFormat.BAREMETAL) { + } else if (template.getFormat() == ImageFormat.BAREMETAL || template.getHypervisorType() == HypervisorType.Docker) { // Do nothing } else { volumeMgr.allocateTemplatedVolume(Type.ROOT, "ROOT-" + vmFinal.getId(), rootDiskOffering.first(), template, vmFinal, owner);
diff --git a/server/src/com/cloud/vm/UserVmManagerImpl.java b/server/src/com/cloud/vm/UserVmManagerImpl.java index 052c678..7c2fd4f 100755 --- a/server/src/com/cloud/vm/UserVmManagerImpl.java +++ b/server/src/com/cloud/vm/UserVmManagerImpl.java
@@ -2578,7 +2578,7 @@ } } - _networkModel.checkNetworkPermissions(owner, network); +// _networkModel.checkNetworkPermissions(owner, network); // don't allow to use system networks NetworkOffering networkOffering = _entityMgr.findById(NetworkOffering.class, network.getNetworkOfferingId()); @@ -2734,7 +2734,8 @@ } } - if (template.getHypervisorType() != null && template.getHypervisorType() != HypervisorType.BareMetal) { + if (template.getHypervisorType() != null && template.getHypervisorType() != HypervisorType.BareMetal + && template.getHypervisorType() != HypervisorType.Docker) { // check if we have available pools for vm deployment long availablePools = _storagePoolDao.countPoolsByStatus(StoragePoolStatus.Up); if (availablePools < 1) {