mirror of
https://github.com/apache/cloudstack.git
synced 2025-10-26 08:42:29 +01:00
Changes: - CreateTemplate and RegisterTemplate now support adding a template tag. It is a string value. This is root-admin only action - only admin can add template tags. - ListTemplates will return the template tag in response. - HostAllocator changed to use template tag along with the existing tag on service offering. If both tags are present, allocator now finds hosts satisfying both tags. If no hosts have both tags, allocation will fail. - DB changes to add new column to vm_template table. - DB upgrade changes for upgrade from 2.2.10 to 2.2.11
91 lines
2.6 KiB
Java
Executable File
91 lines
2.6 KiB
Java
Executable File
/**
|
|
* Copyright (C) 2010 Cloud.com, Inc. All rights reserved.
|
|
*
|
|
* This software is licensed under the GNU General Public License v3 or later.
|
|
*
|
|
* It is free software: you can redistribute it and/or modify
|
|
* it under the terms of the GNU General Public License as published by
|
|
* the Free Software Foundation, either version 3 of the License, or any later version.
|
|
* This program is distributed in the hope that it will be useful,
|
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
* GNU General Public License for more details.
|
|
*
|
|
* You should have received a copy of the GNU General Public License
|
|
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
|
*
|
|
*/
|
|
package com.cloud.template;
|
|
|
|
import java.util.Date;
|
|
|
|
import com.cloud.acl.ControlledEntity;
|
|
import com.cloud.hypervisor.Hypervisor.HypervisorType;
|
|
import com.cloud.storage.Storage.ImageFormat;
|
|
import com.cloud.storage.Storage.TemplateType;
|
|
|
|
public interface VirtualMachineTemplate extends ControlledEntity {
|
|
|
|
public static enum BootloaderType { PyGrub, HVM, External, CD };
|
|
public enum TemplateFilter {
|
|
featured, // returns templates that have been marked as featured and public
|
|
self, // returns templates that have been registered or created by the calling user
|
|
selfexecutable, // same as self, but only returns templates that are ready to be deployed with
|
|
sharedexecutable, // ready templates that have been granted to the calling user by another user
|
|
executable, // templates that are owned by the calling user, or public templates, that can be used to deploy a new VM
|
|
community, // returns templates that have been marked as public but not featured
|
|
all // all templates (only usable by ROOT admins)
|
|
}
|
|
|
|
/**
|
|
* @return id.
|
|
*/
|
|
long getId();
|
|
|
|
boolean isFeatured();
|
|
|
|
/**
|
|
* @return public or private template
|
|
*/
|
|
boolean isPublicTemplate();
|
|
|
|
boolean isExtractable();
|
|
|
|
/**
|
|
* @return name
|
|
*/
|
|
String getName();
|
|
|
|
ImageFormat getFormat();
|
|
|
|
boolean isRequiresHvm();
|
|
|
|
String getDisplayText();
|
|
|
|
boolean getEnablePassword();
|
|
|
|
boolean isCrossZones();
|
|
|
|
Date getCreated();
|
|
|
|
long getGuestOSId();
|
|
|
|
boolean isBootable();
|
|
|
|
TemplateType getTemplateType();
|
|
|
|
HypervisorType getHypervisorType();
|
|
|
|
int getBits();
|
|
|
|
String getUniqueName();
|
|
|
|
String getUrl();
|
|
|
|
String getChecksum();
|
|
|
|
Long getSourceTemplateId();
|
|
|
|
String getTemplateTag();
|
|
}
|