WebserviceDeploymentConfiguration 类
为所有 Webservice 部署配置对象定义基类功能。
此类表示用于将 Webservice 部署到特定目标上的配置参数。
例如,若要为 Azure Kubernetes 服务创建部署,请使用 AksWebservice 类的 deploy_configuration 方法。
- 继承
-
WebserviceDeploymentConfiguration
构造函数
WebserviceDeploymentConfiguration(type, description=None, tags=None, properties=None, primary_key=None, secondary_key=None, location=None)
参数
变量
- azureml.core.webservice.Webservice.description
提供此 Webservice 的说明。
- azureml.core.webservice.Webservice.tags
提供此 Webservice 的键值标签字典。
- azureml.core.webservice.Webservice.properties
提供此 Webservice 的键值属性字典。 这些属性在部署后无法更改,但是可以添加新的键值对。
- azureml.core.webservice.Webservice.primary_key
要用于此 Webservice 的主要身份验证密钥。
- azureml.core.webservice.Webservice.secondary_key
要用于此 Webservice 的辅助身份验证密钥。
- azureml.core.webservice.Webservice.location
要将此 Webservice 部署到的 Azure 区域。
方法
| print_deploy_configuration |
打印部署配置。 |
| validate_configuration |
检查指定的配置值是否有效。 如果验证失败,则会引发 WebserviceException。 |
| validate_image |
检查要部署到 Webservice 的映像是否有效。 如果验证失败,则会引发 WebserviceException。 |
print_deploy_configuration
打印部署配置。
abstract print_deploy_configuration()
validate_configuration
validate_image
检查要部署到 Webservice 的映像是否有效。
如果验证失败,则会引发 WebserviceException。
validate_image(image)
参数
- cls
必需
指示这是一个类方法。
例外
反馈
提交和查看相关反馈