mirror of https://github.com/apache/cloudstack.git
Revert "CLOUDSTACK-7312:ISOs cannot be downloaded from URLs without matching"
This reverts commit 737f76df8c.
This commit is contained in:
parent
a8316de725
commit
83bd4d60f1
|
|
@ -113,6 +113,12 @@ public class HypervisorTemplateAdapter extends TemplateAdapterBase {
|
|||
public TemplateProfile prepare(RegisterIsoCmd cmd) throws ResourceAllocationException {
|
||||
TemplateProfile profile = super.prepare(cmd);
|
||||
String url = profile.getUrl();
|
||||
|
||||
if ((!url.toLowerCase().endsWith("iso")) && (!url.toLowerCase().endsWith("iso.zip")) && (!url.toLowerCase().endsWith("iso.bz2")) &&
|
||||
(!url.toLowerCase().endsWith("iso.gz"))) {
|
||||
throw new InvalidParameterValueException("Please specify a valid iso");
|
||||
}
|
||||
|
||||
UriUtils.validateUrl(url);
|
||||
profile.setUrl(url);
|
||||
// Check that the resource limit for secondary storage won't be exceeded
|
||||
|
|
|
|||
Loading…
Reference in New Issue