mirror of https://github.com/apache/cloudstack.git
deploy docker vm without starting it
This commit is contained in:
parent
4ab0625c88
commit
7c3ab31fbb
|
|
@ -405,7 +405,7 @@ public class VirtualMachineManagerImpl extends ManagerBase implements VirtualMac
|
|||
|
||||
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);
|
||||
|
|
|
|||
|
|
@ -2578,7 +2578,7 @@ public class UserVmManagerImpl extends ManagerBase implements UserVmManager, Vir
|
|||
}
|
||||
}
|
||||
|
||||
_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 @@ public class UserVmManagerImpl extends ManagerBase implements UserVmManager, Vir
|
|||
}
|
||||
}
|
||||
|
||||
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) {
|
||||
|
|
|
|||
Loading…
Reference in New Issue