Environments - Create Or Update
Meglévő környezet létrehozása vagy cseréje. Ez a művelet eltarthat egy ideig.
PUT https://management.azure.com/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DevTestLab/labs/{labName}/users/{userName}/environments/{name}?api-version=2018-09-15
URI-paraméterek
| Name | In | Kötelező | Típus | Description |
|---|---|---|---|---|
|
lab
|
path | True |
string |
A labor neve. |
|
name
|
path | True |
string |
A DtlEnvironment neve |
|
resource
|
path | True |
string minLength: 1maxLength: 90 |
Az erőforráscsoport neve. A név nem megkülönbözteti a kis- és nagybetűket. |
|
subscription
|
path | True |
string minLength: 1 |
A cél-előfizetés azonosítója. |
|
user
|
path | True |
string |
A felhasználói profil neve. |
|
api-version
|
query | True |
string minLength: 1 |
A művelethez használandó API-verzió. |
Kérelem törzse
| Name | Típus | Description |
|---|---|---|
| location |
string |
Az erőforrás helye. |
| properties.armTemplateDisplayName |
string |
A környezetet létrehozó Azure Resource Manager-sablon megjelenítendő neve. |
| properties.deploymentProperties |
A környezet üzembehelyezési tulajdonságai. |
|
| tags |
object |
Az erőforrás címkéi. |
Válaszok
| Name | Típus | Description |
|---|---|---|
| 200 OK |
A "DtlEnvironment" erőforrás frissítési művelete sikeres volt |
|
| 201 Created |
A "DtlEnvironment" erőforrás létrehozási művelete sikeres volt Fejlécek
|
|
| Other Status Codes |
Váratlan hibaválasz. |
Biztonság
azure_auth
Azure Active Directory Oauth2-folyamat.
Típus:
oauth2
Folyamat:
implicit
Engedélyezési URL:
https://login.microsoftonline.com/common/oauth2/authorize
Hatókörök
| Name | Description |
|---|---|
| user_impersonation | a felhasználói fiók megszemélyesítése |
Példák
Environments_CreateOrUpdate
Mintakérelem
PUT https://management.azure.com/subscriptions/{subscriptionId}/resourceGroups/resourceGroupName/providers/Microsoft.DevTestLab/labs/{labName}/users/@me/environments/{environmentName}?api-version=2018-09-15
{
"properties": {
"deploymentProperties": {
"armTemplateId": "/subscriptions/{subscriptionId}/resourceGroups/resourceGroupName/providers/Microsoft.DevTestLab/labs/{labName}/artifactSources/{artifactSourceName}/armTemplates/{armTemplateName}",
"parameters": []
}
}
}
Mintaválasz
{
"name": "{environmentName}",
"type": "Microsoft.DevTestLab/labs/users/environments",
"id": "/subscriptions/{subscriptionId}/resourcegroups/resourceGroupName/providers/microsoft.devtestlab/labs/{labName}/users/{uniqueIdentifier}/environments/{environmentName}",
"location": "{location}",
"properties": {
"createdByUser": "user@contoso.com",
"deploymentProperties": {
"armTemplateId": "/subscriptions/{subscriptionId}/resourcegroups/resourceGroupName/providers/microsoft.devtestlab/labs/{labName}/artifactSources/{artifactSourceName}/armTemplates/{armTemplateName}"
},
"provisioningState": "Succeeded",
"uniqueIdentifier": "{uniqueIdentifier}"
},
"tags": {
"tagName1": "tagValue1"
}
}
{
"name": "{environmentName}",
"type": "Microsoft.DevTestLab/labs/users/environments",
"id": "/subscriptions/{subscriptionId}/resourcegroups/resourceGroupName/providers/microsoft.devtestlab/labs/{labName}/users/{uniqueIdentifier}/environments/{environmentName}",
"location": "{location}",
"properties": {
"createdByUser": "user@contoso.com",
"deploymentProperties": {
"armTemplateId": "/subscriptions/{subscriptionId}/resourcegroups/resourceGroupName/providers/microsoft.devtestlab/labs/{labName}/artifactSources/{artifactSourceName}/armTemplates/{armTemplateName}"
},
"provisioningState": "Creating",
"uniqueIdentifier": "{uniqueIdentifier}"
},
"tags": {
"tagName1": "tagValue1"
}
}
Definíciók
| Name | Description |
|---|---|
|
Arm |
Egy Azure Resource Manager-sablonparaméter tulajdonságai. |
|
Dtl |
Egy környezet, amely lényegében egy ARM-sablon üzembe helyezése. |
|
Environment |
A környezet üzembe helyezésének tulajdonságai. |
|
Error |
Az erőforrás-kezelési hiba további információi. |
|
Error |
A hiba részletei. |
|
Error |
Hibaválasz |
ArmTemplateParameterProperties
Egy Azure Resource Manager-sablonparaméter tulajdonságai.
| Name | Típus | Description |
|---|---|---|
| name |
string |
A sablonparaméter neve. |
| value |
string |
A sablonparaméter értéke. |
DtlEnvironment
Egy környezet, amely lényegében egy ARM-sablon üzembe helyezése.
| Name | Típus | Description |
|---|---|---|
| id |
string |
Az erőforrás azonosítója. |
| location |
string |
Az erőforrás helye. |
| name |
string |
Az erőforrás neve. |
| properties.armTemplateDisplayName |
string |
A környezetet létrehozó Azure Resource Manager-sablon megjelenítendő neve. |
| properties.createdByUser |
string |
A környezet megteremtője. |
| properties.deploymentProperties |
A környezet üzembehelyezési tulajdonságai. |
|
| properties.provisioningState |
string |
Az erőforrás kiépítési állapota. |
| properties.resourceGroupId |
string |
A környezet erőforrásait tartalmazó erőforráscsoport azonosítója. |
| properties.uniqueIdentifier |
string |
Az erőforrás egyedi nem módosítható azonosítója (Guid). |
| tags |
object |
Az erőforrás címkéi. |
| type |
string |
Az erőforrás típusa. |
EnvironmentDeploymentProperties
A környezet üzembe helyezésének tulajdonságai.
| Name | Típus | Description |
|---|---|---|
| armTemplateId |
string |
Az Azure Resource Manager-sablon azonosítója. |
| parameters |
Az Azure Resource Manager-sablon paraméterei. |
ErrorAdditionalInfo
Az erőforrás-kezelési hiba további információi.
| Name | Típus | Description |
|---|---|---|
| info |
object |
A további információk. |
| type |
string |
A további információtípus. |
ErrorDetail
A hiba részletei.
| Name | Típus | Description |
|---|---|---|
| additionalInfo |
A hiba további információi. |
|
| code |
string |
A hibakód. |
| details |
A hiba részletei. |
|
| message |
string |
A hibaüzenet. |
| target |
string |
A hibacél. |
ErrorResponse
Hibaválasz
| Name | Típus | Description |
|---|---|---|
| error |
A hibaobjektum. |