@azure/arm-imagebuilder 1.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +5 -0
- package/LICENSE +21 -0
- package/README.md +98 -0
- package/dist/index.js +2270 -0
- package/dist/index.js.map +1 -0
- package/dist/index.min.js +1 -0
- package/dist/index.min.js.map +1 -0
- package/dist-esm/src/imageBuilderClient.d.ts +20 -0
- package/dist-esm/src/imageBuilderClient.d.ts.map +1 -0
- package/dist-esm/src/imageBuilderClient.js +53 -0
- package/dist-esm/src/imageBuilderClient.js.map +1 -0
- package/dist-esm/src/index.d.ts +5 -0
- package/dist-esm/src/index.d.ts.map +1 -0
- package/dist-esm/src/index.js +12 -0
- package/dist-esm/src/index.js.map +1 -0
- package/dist-esm/src/lroImpl.d.ts +16 -0
- package/dist-esm/src/lroImpl.d.ts.map +1 -0
- package/dist-esm/src/lroImpl.js +29 -0
- package/dist-esm/src/lroImpl.js.map +1 -0
- package/dist-esm/src/models/index.d.ts +562 -0
- package/dist-esm/src/models/index.d.ts.map +1 -0
- package/dist-esm/src/models/index.js +37 -0
- package/dist-esm/src/models/index.js.map +1 -0
- package/dist-esm/src/models/mappers.d.ts +53 -0
- package/dist-esm/src/models/mappers.d.ts.map +1 -0
- package/dist-esm/src/models/mappers.js +1092 -0
- package/dist-esm/src/models/mappers.js.map +1 -0
- package/dist-esm/src/models/parameters.d.ts +13 -0
- package/dist-esm/src/models/parameters.d.ts.map +1 -0
- package/dist-esm/src/models/parameters.js +118 -0
- package/dist-esm/src/models/parameters.js.map +1 -0
- package/dist-esm/src/operations/index.d.ts +3 -0
- package/dist-esm/src/operations/index.d.ts.map +1 -0
- package/dist-esm/src/operations/index.js +10 -0
- package/dist-esm/src/operations/index.js.map +1 -0
- package/dist-esm/src/operations/operations.d.ts +32 -0
- package/dist-esm/src/operations/operations.d.ts.map +1 -0
- package/dist-esm/src/operations/operations.js +120 -0
- package/dist-esm/src/operations/operations.js.map +1 -0
- package/dist-esm/src/operations/virtualMachineImageTemplates.d.ts +167 -0
- package/dist-esm/src/operations/virtualMachineImageTemplates.d.ts.map +1 -0
- package/dist-esm/src/operations/virtualMachineImageTemplates.js +791 -0
- package/dist-esm/src/operations/virtualMachineImageTemplates.js.map +1 -0
- package/dist-esm/src/operationsInterfaces/index.d.ts +3 -0
- package/dist-esm/src/operationsInterfaces/index.d.ts.map +1 -0
- package/dist-esm/src/operationsInterfaces/index.js +10 -0
- package/dist-esm/src/operationsInterfaces/index.js.map +1 -0
- package/dist-esm/src/operationsInterfaces/operations.d.ts +11 -0
- package/dist-esm/src/operationsInterfaces/operations.d.ts.map +1 -0
- package/dist-esm/src/operationsInterfaces/operations.js +9 -0
- package/dist-esm/src/operationsInterfaces/operations.js.map +1 -0
- package/dist-esm/src/operationsInterfaces/virtualMachineImageTemplates.d.ts +114 -0
- package/dist-esm/src/operationsInterfaces/virtualMachineImageTemplates.d.ts.map +1 -0
- package/dist-esm/src/operationsInterfaces/virtualMachineImageTemplates.js +9 -0
- package/dist-esm/src/operationsInterfaces/virtualMachineImageTemplates.js.map +1 -0
- package/dist-esm/test/imagebuilder_examples.d.ts +4 -0
- package/dist-esm/test/imagebuilder_examples.d.ts.map +1 -0
- package/dist-esm/test/imagebuilder_examples.js +201 -0
- package/dist-esm/test/imagebuilder_examples.js.map +1 -0
- package/package.json +95 -0
- package/review/arm-imagebuilder.api.md +509 -0
- package/rollup.config.js +188 -0
- package/src/imageBuilderClient.ts +83 -0
- package/src/index.ts +12 -0
- package/src/lroImpl.ts +34 -0
- package/src/models/index.ts +668 -0
- package/src/models/mappers.ts +1214 -0
- package/src/models/parameters.ts +137 -0
- package/src/operations/index.ts +10 -0
- package/src/operations/operations.ts +137 -0
- package/src/operations/virtualMachineImageTemplates.ts +1085 -0
- package/src/operationsInterfaces/index.ts +10 -0
- package/src/operationsInterfaces/operations.ts +22 -0
- package/src/operationsInterfaces/virtualMachineImageTemplates.ts +213 -0
- package/tsconfig.json +19 -0
- package/types/arm-imagebuilder.d.ts +779 -0
- package/types/tsdoc-metadata.json +11 -0
|
@@ -0,0 +1,668 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Copyright (c) Microsoft Corporation.
|
|
3
|
+
* Licensed under the MIT License.
|
|
4
|
+
*
|
|
5
|
+
* Code generated by Microsoft (R) AutoRest Code Generator.
|
|
6
|
+
* Changes may cause incorrect behavior and will be lost if the code is regenerated.
|
|
7
|
+
*/
|
|
8
|
+
|
|
9
|
+
import * as coreClient from "@azure/core-client";
|
|
10
|
+
|
|
11
|
+
export type ImageTemplateSourceUnion =
|
|
12
|
+
| ImageTemplateSource
|
|
13
|
+
| ImageTemplatePlatformImageSource
|
|
14
|
+
| ImageTemplateManagedImageSource
|
|
15
|
+
| ImageTemplateSharedImageVersionSource;
|
|
16
|
+
export type ImageTemplateCustomizerUnion =
|
|
17
|
+
| ImageTemplateCustomizer
|
|
18
|
+
| ImageTemplateShellCustomizer
|
|
19
|
+
| ImageTemplateRestartCustomizer
|
|
20
|
+
| ImageTemplateWindowsUpdateCustomizer
|
|
21
|
+
| ImageTemplatePowerShellCustomizer
|
|
22
|
+
| ImageTemplateFileCustomizer;
|
|
23
|
+
export type ImageTemplateDistributorUnion =
|
|
24
|
+
| ImageTemplateDistributor
|
|
25
|
+
| ImageTemplateManagedImageDistributor
|
|
26
|
+
| ImageTemplateSharedImageDistributor
|
|
27
|
+
| ImageTemplateVhdDistributor;
|
|
28
|
+
|
|
29
|
+
/** The result of List image templates operation */
|
|
30
|
+
export interface ImageTemplateListResult {
|
|
31
|
+
/** An array of image templates */
|
|
32
|
+
value?: ImageTemplate[];
|
|
33
|
+
/** The continuation token. */
|
|
34
|
+
nextLink?: string;
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
/** Describes a virtual machine image source for building, customizing and distributing */
|
|
38
|
+
export interface ImageTemplateSource {
|
|
39
|
+
/** Polymorphic discriminator, which specifies the different types this object can be */
|
|
40
|
+
type: "PlatformImage" | "ManagedImage" | "SharedImageVersion";
|
|
41
|
+
}
|
|
42
|
+
|
|
43
|
+
/** Describes a unit of image customization */
|
|
44
|
+
export interface ImageTemplateCustomizer {
|
|
45
|
+
/** Polymorphic discriminator, which specifies the different types this object can be */
|
|
46
|
+
type: "Shell" | "WindowsRestart" | "WindowsUpdate" | "PowerShell" | "File";
|
|
47
|
+
/** Friendly Name to provide context on what this customization step does */
|
|
48
|
+
name?: string;
|
|
49
|
+
}
|
|
50
|
+
|
|
51
|
+
/** Generic distribution object */
|
|
52
|
+
export interface ImageTemplateDistributor {
|
|
53
|
+
/** Polymorphic discriminator, which specifies the different types this object can be */
|
|
54
|
+
type: "ManagedImage" | "SharedImage" | "VHD";
|
|
55
|
+
/** The name to be used for the associated RunOutput. */
|
|
56
|
+
runOutputName: string;
|
|
57
|
+
/** Tags that will be applied to the artifact once it has been created/updated by the distributor. */
|
|
58
|
+
artifactTags?: { [propertyName: string]: string };
|
|
59
|
+
}
|
|
60
|
+
|
|
61
|
+
/** Describes the error happened when create or update an image template */
|
|
62
|
+
export interface ProvisioningError {
|
|
63
|
+
/** Error code of the provisioning failure */
|
|
64
|
+
provisioningErrorCode?: ProvisioningErrorCode;
|
|
65
|
+
/** Verbose error message about the provisioning failure */
|
|
66
|
+
message?: string;
|
|
67
|
+
}
|
|
68
|
+
|
|
69
|
+
/** Describes the latest status of running an image template */
|
|
70
|
+
export interface ImageTemplateLastRunStatus {
|
|
71
|
+
/** Start time of the last run (UTC) */
|
|
72
|
+
startTime?: Date;
|
|
73
|
+
/** End time of the last run (UTC) */
|
|
74
|
+
endTime?: Date;
|
|
75
|
+
/** State of the last run */
|
|
76
|
+
runState?: RunState;
|
|
77
|
+
/** Sub-state of the last run */
|
|
78
|
+
runSubState?: RunSubState;
|
|
79
|
+
/** Verbose information about the last run state */
|
|
80
|
+
message?: string;
|
|
81
|
+
}
|
|
82
|
+
|
|
83
|
+
/** Describes the virtual machine used to build, customize and capture images */
|
|
84
|
+
export interface ImageTemplateVmProfile {
|
|
85
|
+
/** Size of the virtual machine used to build, customize and capture images. Omit or specify empty string to use the default (Standard_D2ds_v4). */
|
|
86
|
+
vmSize?: string;
|
|
87
|
+
/** Size of the OS disk in GB. Omit or specify 0 to use Azure's default OS disk size. */
|
|
88
|
+
osDiskSizeGB?: number;
|
|
89
|
+
/** Optional array of resource IDs of user assigned managed identities to be configured on the build VM. This may include the identity of the image template. */
|
|
90
|
+
userAssignedIdentities?: string[];
|
|
91
|
+
/** Optional configuration of the virtual network to use to deploy the build virtual machine in. Omit if no specific virtual network needs to be used. */
|
|
92
|
+
vnetConfig?: VirtualNetworkConfig;
|
|
93
|
+
}
|
|
94
|
+
|
|
95
|
+
/** Virtual Network configuration. */
|
|
96
|
+
export interface VirtualNetworkConfig {
|
|
97
|
+
/** Resource id of a pre-existing subnet. */
|
|
98
|
+
subnetId?: string;
|
|
99
|
+
/** Size of the virtual machine used to build, customize and capture images. Omit or specify empty string to use the default (Standard_D1_v2 for Gen1 images and Standard_D2ds_v4 for Gen2 images). */
|
|
100
|
+
proxyVmSize?: string;
|
|
101
|
+
}
|
|
102
|
+
|
|
103
|
+
/** Identity for the image template. */
|
|
104
|
+
export interface ImageTemplateIdentity {
|
|
105
|
+
/** The type of identity used for the image template. The type 'None' will remove any identities from the image template. */
|
|
106
|
+
type?: ResourceIdentityType;
|
|
107
|
+
/** The list of user identities associated with the image template. The user identity dictionary key references will be ARM resource ids in the form: '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ManagedIdentity/userAssignedIdentities/{identityName}'. */
|
|
108
|
+
userAssignedIdentities?: {
|
|
109
|
+
[propertyName: string]: ComponentsVrq145SchemasImagetemplateidentityPropertiesUserassignedidentitiesAdditionalproperties;
|
|
110
|
+
};
|
|
111
|
+
}
|
|
112
|
+
|
|
113
|
+
export interface ComponentsVrq145SchemasImagetemplateidentityPropertiesUserassignedidentitiesAdditionalproperties {
|
|
114
|
+
/**
|
|
115
|
+
* The principal id of user assigned identity.
|
|
116
|
+
* NOTE: This property will not be serialized. It can only be populated by the server.
|
|
117
|
+
*/
|
|
118
|
+
readonly principalId?: string;
|
|
119
|
+
/**
|
|
120
|
+
* The client id of user assigned identity.
|
|
121
|
+
* NOTE: This property will not be serialized. It can only be populated by the server.
|
|
122
|
+
*/
|
|
123
|
+
readonly clientId?: string;
|
|
124
|
+
}
|
|
125
|
+
|
|
126
|
+
/** Metadata pertaining to creation and last modification of the resource. */
|
|
127
|
+
export interface SystemData {
|
|
128
|
+
/** The identity that created the resource. */
|
|
129
|
+
createdBy?: string;
|
|
130
|
+
/** The type of identity that created the resource. */
|
|
131
|
+
createdByType?: CreatedByType;
|
|
132
|
+
/** The timestamp of resource creation (UTC). */
|
|
133
|
+
createdAt?: Date;
|
|
134
|
+
/** The identity that last modified the resource. */
|
|
135
|
+
lastModifiedBy?: string;
|
|
136
|
+
/** The type of identity that last modified the resource. */
|
|
137
|
+
lastModifiedByType?: CreatedByType;
|
|
138
|
+
/** The timestamp of resource last modification (UTC) */
|
|
139
|
+
lastModifiedAt?: Date;
|
|
140
|
+
}
|
|
141
|
+
|
|
142
|
+
/** Common fields that are returned in the response for all Azure Resource Manager resources */
|
|
143
|
+
export interface Resource {
|
|
144
|
+
/**
|
|
145
|
+
* Fully qualified resource ID for the resource. Ex - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}
|
|
146
|
+
* NOTE: This property will not be serialized. It can only be populated by the server.
|
|
147
|
+
*/
|
|
148
|
+
readonly id?: string;
|
|
149
|
+
/**
|
|
150
|
+
* The name of the resource
|
|
151
|
+
* NOTE: This property will not be serialized. It can only be populated by the server.
|
|
152
|
+
*/
|
|
153
|
+
readonly name?: string;
|
|
154
|
+
/**
|
|
155
|
+
* The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts"
|
|
156
|
+
* NOTE: This property will not be serialized. It can only be populated by the server.
|
|
157
|
+
*/
|
|
158
|
+
readonly type?: string;
|
|
159
|
+
}
|
|
160
|
+
|
|
161
|
+
/** An error response from the Azure VM Image Builder service. */
|
|
162
|
+
export interface CloudError {
|
|
163
|
+
/** Details about the error. */
|
|
164
|
+
error?: CloudErrorBody;
|
|
165
|
+
}
|
|
166
|
+
|
|
167
|
+
/** An error response from the Azure VM Image Builder service. */
|
|
168
|
+
export interface CloudErrorBody {
|
|
169
|
+
/** An identifier for the error. Codes are invariant and are intended to be consumed programmatically. */
|
|
170
|
+
code?: string;
|
|
171
|
+
/** A message describing the error, intended to be suitable for display in a user interface. */
|
|
172
|
+
message?: string;
|
|
173
|
+
/** The target of the particular error. For example, the name of the property in error. */
|
|
174
|
+
target?: string;
|
|
175
|
+
/** A list of additional details about the error. */
|
|
176
|
+
details?: CloudErrorBody[];
|
|
177
|
+
}
|
|
178
|
+
|
|
179
|
+
/** Parameters for updating an image template. */
|
|
180
|
+
export interface ImageTemplateUpdateParameters {
|
|
181
|
+
/** The identity of the image template, if configured. */
|
|
182
|
+
identity?: ImageTemplateIdentity;
|
|
183
|
+
/** The user-specified tags associated with the image template. */
|
|
184
|
+
tags?: { [propertyName: string]: string };
|
|
185
|
+
}
|
|
186
|
+
|
|
187
|
+
/** The result of List run outputs operation */
|
|
188
|
+
export interface RunOutputCollection {
|
|
189
|
+
/** An array of run outputs */
|
|
190
|
+
value?: RunOutput[];
|
|
191
|
+
/** The continuation token. */
|
|
192
|
+
nextLink?: string;
|
|
193
|
+
}
|
|
194
|
+
|
|
195
|
+
/** The Sub Resource model definition. */
|
|
196
|
+
export interface SubResource {
|
|
197
|
+
/**
|
|
198
|
+
* Resource Id
|
|
199
|
+
* NOTE: This property will not be serialized. It can only be populated by the server.
|
|
200
|
+
*/
|
|
201
|
+
readonly id?: string;
|
|
202
|
+
/** Resource name */
|
|
203
|
+
name: string;
|
|
204
|
+
/**
|
|
205
|
+
* Resource type
|
|
206
|
+
* NOTE: This property will not be serialized. It can only be populated by the server.
|
|
207
|
+
*/
|
|
208
|
+
readonly type?: string;
|
|
209
|
+
}
|
|
210
|
+
|
|
211
|
+
/** Result of the request to list REST API operations. It contains a list of operations and a URL nextLink to get the next set of results. */
|
|
212
|
+
export interface OperationListResult {
|
|
213
|
+
/** The list of operations supported by the resource provider. */
|
|
214
|
+
value?: Operation[];
|
|
215
|
+
/** The URL to get the next set of operation list results if there are any. */
|
|
216
|
+
nextLink?: string;
|
|
217
|
+
}
|
|
218
|
+
|
|
219
|
+
/** A REST API operation */
|
|
220
|
+
export interface Operation {
|
|
221
|
+
/** This is of the format {provider}/{resource}/{operation} */
|
|
222
|
+
name?: string;
|
|
223
|
+
/** The object that describes the operation. */
|
|
224
|
+
display?: OperationDisplay;
|
|
225
|
+
/** The intended executor of the operation. */
|
|
226
|
+
origin?: string;
|
|
227
|
+
/** Any object */
|
|
228
|
+
properties?: Record<string, unknown>;
|
|
229
|
+
/** The flag that indicates whether the operation applies to data plane. */
|
|
230
|
+
isDataAction?: boolean;
|
|
231
|
+
}
|
|
232
|
+
|
|
233
|
+
/** The object that describes the operation. */
|
|
234
|
+
export interface OperationDisplay {
|
|
235
|
+
/** Friendly name of the resource provider. */
|
|
236
|
+
provider?: string;
|
|
237
|
+
/** For example: read, write, delete, or listKeys/action */
|
|
238
|
+
operation?: string;
|
|
239
|
+
/** The resource type on which the operation is performed. */
|
|
240
|
+
resource?: string;
|
|
241
|
+
/** The friendly name of the operation */
|
|
242
|
+
description?: string;
|
|
243
|
+
}
|
|
244
|
+
|
|
245
|
+
/** Purchase plan configuration for platform image. */
|
|
246
|
+
export interface PlatformImagePurchasePlan {
|
|
247
|
+
/** Name of the purchase plan. */
|
|
248
|
+
planName: string;
|
|
249
|
+
/** Product of the purchase plan. */
|
|
250
|
+
planProduct: string;
|
|
251
|
+
/** Publisher of the purchase plan. */
|
|
252
|
+
planPublisher: string;
|
|
253
|
+
}
|
|
254
|
+
|
|
255
|
+
/** Describes an image source from [Azure Gallery Images](https://docs.microsoft.com/en-us/rest/api/compute/virtualmachineimages). */
|
|
256
|
+
export type ImageTemplatePlatformImageSource = ImageTemplateSource & {
|
|
257
|
+
/** Polymorphic discriminator, which specifies the different types this object can be */
|
|
258
|
+
type: "PlatformImage";
|
|
259
|
+
/** Image Publisher in [Azure Gallery Images](https://docs.microsoft.com/en-us/rest/api/compute/virtualmachineimages). */
|
|
260
|
+
publisher?: string;
|
|
261
|
+
/** Image offer from the [Azure Gallery Images](https://docs.microsoft.com/en-us/rest/api/compute/virtualmachineimages). */
|
|
262
|
+
offer?: string;
|
|
263
|
+
/** Image sku from the [Azure Gallery Images](https://docs.microsoft.com/en-us/rest/api/compute/virtualmachineimages). */
|
|
264
|
+
sku?: string;
|
|
265
|
+
/** Image version from the [Azure Gallery Images](https://docs.microsoft.com/en-us/rest/api/compute/virtualmachineimages). If 'latest' is specified here, the version is evaluated when the image build takes place, not when the template is submitted. */
|
|
266
|
+
version?: string;
|
|
267
|
+
/**
|
|
268
|
+
* Image version from the [Azure Gallery Images](https://docs.microsoft.com/en-us/rest/api/compute/virtualmachineimages). This readonly field differs from 'version', only if the value specified in 'version' field is 'latest'.
|
|
269
|
+
* NOTE: This property will not be serialized. It can only be populated by the server.
|
|
270
|
+
*/
|
|
271
|
+
readonly exactVersion?: string;
|
|
272
|
+
/** Optional configuration of purchase plan for platform image. */
|
|
273
|
+
planInfo?: PlatformImagePurchasePlan;
|
|
274
|
+
};
|
|
275
|
+
|
|
276
|
+
/** Describes an image source that is a managed image in customer subscription. */
|
|
277
|
+
export type ImageTemplateManagedImageSource = ImageTemplateSource & {
|
|
278
|
+
/** Polymorphic discriminator, which specifies the different types this object can be */
|
|
279
|
+
type: "ManagedImage";
|
|
280
|
+
/** ARM resource id of the managed image in customer subscription */
|
|
281
|
+
imageId: string;
|
|
282
|
+
};
|
|
283
|
+
|
|
284
|
+
/** Describes an image source that is an image version in a shared image gallery. */
|
|
285
|
+
export type ImageTemplateSharedImageVersionSource = ImageTemplateSource & {
|
|
286
|
+
/** Polymorphic discriminator, which specifies the different types this object can be */
|
|
287
|
+
type: "SharedImageVersion";
|
|
288
|
+
/** ARM resource id of the image version in the shared image gallery */
|
|
289
|
+
imageVersionId: string;
|
|
290
|
+
};
|
|
291
|
+
|
|
292
|
+
/** Runs a shell script during the customization phase (Linux). Corresponds to Packer shell provisioner. Exactly one of 'scriptUri' or 'inline' can be specified. */
|
|
293
|
+
export type ImageTemplateShellCustomizer = ImageTemplateCustomizer & {
|
|
294
|
+
/** Polymorphic discriminator, which specifies the different types this object can be */
|
|
295
|
+
type: "Shell";
|
|
296
|
+
/** URI of the shell script to be run for customizing. It can be a github link, SAS URI for Azure Storage, etc */
|
|
297
|
+
scriptUri?: string;
|
|
298
|
+
/** SHA256 checksum of the shell script provided in the scriptUri field */
|
|
299
|
+
sha256Checksum?: string;
|
|
300
|
+
/** Array of shell commands to execute */
|
|
301
|
+
inline?: string[];
|
|
302
|
+
};
|
|
303
|
+
|
|
304
|
+
/** Reboots a VM and waits for it to come back online (Windows). Corresponds to Packer windows-restart provisioner */
|
|
305
|
+
export type ImageTemplateRestartCustomizer = ImageTemplateCustomizer & {
|
|
306
|
+
/** Polymorphic discriminator, which specifies the different types this object can be */
|
|
307
|
+
type: "WindowsRestart";
|
|
308
|
+
/** Command to execute the restart [Default: 'shutdown /r /f /t 0 /c "packer restart"'] */
|
|
309
|
+
restartCommand?: string;
|
|
310
|
+
/** Command to check if restart succeeded [Default: ''] */
|
|
311
|
+
restartCheckCommand?: string;
|
|
312
|
+
/** Restart timeout specified as a string of magnitude and unit, e.g. '5m' (5 minutes) or '2h' (2 hours) [Default: '5m'] */
|
|
313
|
+
restartTimeout?: string;
|
|
314
|
+
};
|
|
315
|
+
|
|
316
|
+
/** Installs Windows Updates. Corresponds to Packer Windows Update Provisioner (https://github.com/rgl/packer-provisioner-windows-update) */
|
|
317
|
+
export type ImageTemplateWindowsUpdateCustomizer = ImageTemplateCustomizer & {
|
|
318
|
+
/** Polymorphic discriminator, which specifies the different types this object can be */
|
|
319
|
+
type: "WindowsUpdate";
|
|
320
|
+
/** Criteria to search updates. Omit or specify empty string to use the default (search all). Refer to above link for examples and detailed description of this field. */
|
|
321
|
+
searchCriteria?: string;
|
|
322
|
+
/** Array of filters to select updates to apply. Omit or specify empty array to use the default (no filter). Refer to above link for examples and detailed description of this field. */
|
|
323
|
+
filters?: string[];
|
|
324
|
+
/** Maximum number of updates to apply at a time. Omit or specify 0 to use the default (1000) */
|
|
325
|
+
updateLimit?: number;
|
|
326
|
+
};
|
|
327
|
+
|
|
328
|
+
/** Runs the specified PowerShell on the VM (Windows). Corresponds to Packer powershell provisioner. Exactly one of 'scriptUri' or 'inline' can be specified. */
|
|
329
|
+
export type ImageTemplatePowerShellCustomizer = ImageTemplateCustomizer & {
|
|
330
|
+
/** Polymorphic discriminator, which specifies the different types this object can be */
|
|
331
|
+
type: "PowerShell";
|
|
332
|
+
/** URI of the PowerShell script to be run for customizing. It can be a github link, SAS URI for Azure Storage, etc */
|
|
333
|
+
scriptUri?: string;
|
|
334
|
+
/** SHA256 checksum of the power shell script provided in the scriptUri field above */
|
|
335
|
+
sha256Checksum?: string;
|
|
336
|
+
/** Array of PowerShell commands to execute */
|
|
337
|
+
inline?: string[];
|
|
338
|
+
/** If specified, the PowerShell script will be run with elevated privileges */
|
|
339
|
+
runElevated?: boolean;
|
|
340
|
+
/** If specified, the PowerShell script will be run with elevated privileges using the Local System user. Can only be true when the runElevated field above is set to true. */
|
|
341
|
+
runAsSystem?: boolean;
|
|
342
|
+
/** Valid exit codes for the PowerShell script. [Default: 0] */
|
|
343
|
+
validExitCodes?: number[];
|
|
344
|
+
};
|
|
345
|
+
|
|
346
|
+
/** Uploads files to VMs (Linux, Windows). Corresponds to Packer file provisioner */
|
|
347
|
+
export type ImageTemplateFileCustomizer = ImageTemplateCustomizer & {
|
|
348
|
+
/** Polymorphic discriminator, which specifies the different types this object can be */
|
|
349
|
+
type: "File";
|
|
350
|
+
/** The URI of the file to be uploaded for customizing the VM. It can be a github link, SAS URI for Azure Storage, etc */
|
|
351
|
+
sourceUri?: string;
|
|
352
|
+
/** SHA256 checksum of the file provided in the sourceUri field above */
|
|
353
|
+
sha256Checksum?: string;
|
|
354
|
+
/** The absolute path to a file (with nested directory structures already created) where the file (from sourceUri) will be uploaded to in the VM */
|
|
355
|
+
destination?: string;
|
|
356
|
+
};
|
|
357
|
+
|
|
358
|
+
/** Distribute as a Managed Disk Image. */
|
|
359
|
+
export type ImageTemplateManagedImageDistributor = ImageTemplateDistributor & {
|
|
360
|
+
/** Polymorphic discriminator, which specifies the different types this object can be */
|
|
361
|
+
type: "ManagedImage";
|
|
362
|
+
/** Resource Id of the Managed Disk Image */
|
|
363
|
+
imageId: string;
|
|
364
|
+
/** Azure location for the image, should match if image already exists */
|
|
365
|
+
location: string;
|
|
366
|
+
};
|
|
367
|
+
|
|
368
|
+
/** Distribute via Shared Image Gallery. */
|
|
369
|
+
export type ImageTemplateSharedImageDistributor = ImageTemplateDistributor & {
|
|
370
|
+
/** Polymorphic discriminator, which specifies the different types this object can be */
|
|
371
|
+
type: "SharedImage";
|
|
372
|
+
/** Resource Id of the Shared Image Gallery image */
|
|
373
|
+
galleryImageId: string;
|
|
374
|
+
/** A list of regions that the image will be replicated to */
|
|
375
|
+
replicationRegions: string[];
|
|
376
|
+
/** Flag that indicates whether created image version should be excluded from latest. Omit to use the default (false). */
|
|
377
|
+
excludeFromLatest?: boolean;
|
|
378
|
+
/** Storage account type to be used to store the shared image. Omit to use the default (Standard_LRS). */
|
|
379
|
+
storageAccountType?: SharedImageStorageAccountType;
|
|
380
|
+
};
|
|
381
|
+
|
|
382
|
+
/** Distribute via VHD in a storage account. */
|
|
383
|
+
export type ImageTemplateVhdDistributor = ImageTemplateDistributor & {
|
|
384
|
+
/** Polymorphic discriminator, which specifies the different types this object can be */
|
|
385
|
+
type: "VHD";
|
|
386
|
+
};
|
|
387
|
+
|
|
388
|
+
/** The resource model definition for an Azure Resource Manager tracked top level resource which has 'tags' and a 'location' */
|
|
389
|
+
export type TrackedResource = Resource & {
|
|
390
|
+
/** Resource tags. */
|
|
391
|
+
tags?: { [propertyName: string]: string };
|
|
392
|
+
/** The geo-location where the resource lives */
|
|
393
|
+
location: string;
|
|
394
|
+
};
|
|
395
|
+
|
|
396
|
+
/** Represents an output that was created by running an image template. */
|
|
397
|
+
export type RunOutput = SubResource & {
|
|
398
|
+
/** The resource id of the artifact. */
|
|
399
|
+
artifactId?: string;
|
|
400
|
+
/** The location URI of the artifact. */
|
|
401
|
+
artifactUri?: string;
|
|
402
|
+
/**
|
|
403
|
+
* Provisioning state of the resource
|
|
404
|
+
* NOTE: This property will not be serialized. It can only be populated by the server.
|
|
405
|
+
*/
|
|
406
|
+
readonly provisioningState?: ProvisioningState;
|
|
407
|
+
};
|
|
408
|
+
|
|
409
|
+
/** Image template is an ARM resource managed by Microsoft.VirtualMachineImages provider */
|
|
410
|
+
export type ImageTemplate = TrackedResource & {
|
|
411
|
+
/** The identity of the image template, if configured. */
|
|
412
|
+
identity: ImageTemplateIdentity;
|
|
413
|
+
/**
|
|
414
|
+
* Metadata pertaining to creation and last modification of the resource.
|
|
415
|
+
* NOTE: This property will not be serialized. It can only be populated by the server.
|
|
416
|
+
*/
|
|
417
|
+
readonly systemData?: SystemData;
|
|
418
|
+
/** Specifies the properties used to describe the source image. */
|
|
419
|
+
source?: ImageTemplateSourceUnion;
|
|
420
|
+
/** Specifies the properties used to describe the customization steps of the image, like Image source etc */
|
|
421
|
+
customize?: ImageTemplateCustomizerUnion[];
|
|
422
|
+
/** The distribution targets where the image output needs to go to. */
|
|
423
|
+
distribute?: ImageTemplateDistributorUnion[];
|
|
424
|
+
/**
|
|
425
|
+
* Provisioning state of the resource
|
|
426
|
+
* NOTE: This property will not be serialized. It can only be populated by the server.
|
|
427
|
+
*/
|
|
428
|
+
readonly provisioningState?: ProvisioningState;
|
|
429
|
+
/**
|
|
430
|
+
* Provisioning error, if any
|
|
431
|
+
* NOTE: This property will not be serialized. It can only be populated by the server.
|
|
432
|
+
*/
|
|
433
|
+
readonly provisioningError?: ProvisioningError;
|
|
434
|
+
/**
|
|
435
|
+
* State of 'run' that is currently executing or was last executed.
|
|
436
|
+
* NOTE: This property will not be serialized. It can only be populated by the server.
|
|
437
|
+
*/
|
|
438
|
+
readonly lastRunStatus?: ImageTemplateLastRunStatus;
|
|
439
|
+
/** Maximum duration to wait while building the image template. Omit or specify 0 to use the default (4 hours). */
|
|
440
|
+
buildTimeoutInMinutes?: number;
|
|
441
|
+
/** Describes how virtual machine is set up to build images */
|
|
442
|
+
vmProfile?: ImageTemplateVmProfile;
|
|
443
|
+
};
|
|
444
|
+
|
|
445
|
+
/** Known values of {@link ProvisioningErrorCode} that the service accepts. */
|
|
446
|
+
export enum KnownProvisioningErrorCode {
|
|
447
|
+
BadSourceType = "BadSourceType",
|
|
448
|
+
BadPIRSource = "BadPIRSource",
|
|
449
|
+
BadManagedImageSource = "BadManagedImageSource",
|
|
450
|
+
BadSharedImageVersionSource = "BadSharedImageVersionSource",
|
|
451
|
+
BadCustomizerType = "BadCustomizerType",
|
|
452
|
+
UnsupportedCustomizerType = "UnsupportedCustomizerType",
|
|
453
|
+
NoCustomizerScript = "NoCustomizerScript",
|
|
454
|
+
BadDistributeType = "BadDistributeType",
|
|
455
|
+
BadSharedImageDistribute = "BadSharedImageDistribute",
|
|
456
|
+
ServerError = "ServerError",
|
|
457
|
+
Other = "Other"
|
|
458
|
+
}
|
|
459
|
+
|
|
460
|
+
/**
|
|
461
|
+
* Defines values for ProvisioningErrorCode. \
|
|
462
|
+
* {@link KnownProvisioningErrorCode} can be used interchangeably with ProvisioningErrorCode,
|
|
463
|
+
* this enum contains the known values that the service supports.
|
|
464
|
+
* ### Known values supported by the service
|
|
465
|
+
* **BadSourceType** \
|
|
466
|
+
* **BadPIRSource** \
|
|
467
|
+
* **BadManagedImageSource** \
|
|
468
|
+
* **BadSharedImageVersionSource** \
|
|
469
|
+
* **BadCustomizerType** \
|
|
470
|
+
* **UnsupportedCustomizerType** \
|
|
471
|
+
* **NoCustomizerScript** \
|
|
472
|
+
* **BadDistributeType** \
|
|
473
|
+
* **BadSharedImageDistribute** \
|
|
474
|
+
* **ServerError** \
|
|
475
|
+
* **Other**
|
|
476
|
+
*/
|
|
477
|
+
export type ProvisioningErrorCode = string;
|
|
478
|
+
|
|
479
|
+
/** Known values of {@link CreatedByType} that the service accepts. */
|
|
480
|
+
export enum KnownCreatedByType {
|
|
481
|
+
User = "User",
|
|
482
|
+
Application = "Application",
|
|
483
|
+
ManagedIdentity = "ManagedIdentity",
|
|
484
|
+
Key = "Key"
|
|
485
|
+
}
|
|
486
|
+
|
|
487
|
+
/**
|
|
488
|
+
* Defines values for CreatedByType. \
|
|
489
|
+
* {@link KnownCreatedByType} can be used interchangeably with CreatedByType,
|
|
490
|
+
* this enum contains the known values that the service supports.
|
|
491
|
+
* ### Known values supported by the service
|
|
492
|
+
* **User** \
|
|
493
|
+
* **Application** \
|
|
494
|
+
* **ManagedIdentity** \
|
|
495
|
+
* **Key**
|
|
496
|
+
*/
|
|
497
|
+
export type CreatedByType = string;
|
|
498
|
+
|
|
499
|
+
/** Known values of {@link SharedImageStorageAccountType} that the service accepts. */
|
|
500
|
+
export enum KnownSharedImageStorageAccountType {
|
|
501
|
+
StandardLRS = "Standard_LRS",
|
|
502
|
+
StandardZRS = "Standard_ZRS"
|
|
503
|
+
}
|
|
504
|
+
|
|
505
|
+
/**
|
|
506
|
+
* Defines values for SharedImageStorageAccountType. \
|
|
507
|
+
* {@link KnownSharedImageStorageAccountType} can be used interchangeably with SharedImageStorageAccountType,
|
|
508
|
+
* this enum contains the known values that the service supports.
|
|
509
|
+
* ### Known values supported by the service
|
|
510
|
+
* **Standard_LRS** \
|
|
511
|
+
* **Standard_ZRS**
|
|
512
|
+
*/
|
|
513
|
+
export type SharedImageStorageAccountType = string;
|
|
514
|
+
/** Defines values for ProvisioningState. */
|
|
515
|
+
export type ProvisioningState =
|
|
516
|
+
| "Creating"
|
|
517
|
+
| "Updating"
|
|
518
|
+
| "Succeeded"
|
|
519
|
+
| "Failed"
|
|
520
|
+
| "Deleting";
|
|
521
|
+
/** Defines values for RunState. */
|
|
522
|
+
export type RunState =
|
|
523
|
+
| "Running"
|
|
524
|
+
| "Canceling"
|
|
525
|
+
| "Succeeded"
|
|
526
|
+
| "PartiallySucceeded"
|
|
527
|
+
| "Failed"
|
|
528
|
+
| "Canceled";
|
|
529
|
+
/** Defines values for RunSubState. */
|
|
530
|
+
export type RunSubState =
|
|
531
|
+
| "Queued"
|
|
532
|
+
| "Building"
|
|
533
|
+
| "Customizing"
|
|
534
|
+
| "Distributing";
|
|
535
|
+
/** Defines values for ResourceIdentityType. */
|
|
536
|
+
export type ResourceIdentityType = "UserAssigned" | "None";
|
|
537
|
+
|
|
538
|
+
/** Optional parameters. */
|
|
539
|
+
export interface VirtualMachineImageTemplatesListOptionalParams
|
|
540
|
+
extends coreClient.OperationOptions {}
|
|
541
|
+
|
|
542
|
+
/** Contains response data for the list operation. */
|
|
543
|
+
export type VirtualMachineImageTemplatesListResponse = ImageTemplateListResult;
|
|
544
|
+
|
|
545
|
+
/** Optional parameters. */
|
|
546
|
+
export interface VirtualMachineImageTemplatesListByResourceGroupOptionalParams
|
|
547
|
+
extends coreClient.OperationOptions {}
|
|
548
|
+
|
|
549
|
+
/** Contains response data for the listByResourceGroup operation. */
|
|
550
|
+
export type VirtualMachineImageTemplatesListByResourceGroupResponse = ImageTemplateListResult;
|
|
551
|
+
|
|
552
|
+
/** Optional parameters. */
|
|
553
|
+
export interface VirtualMachineImageTemplatesCreateOrUpdateOptionalParams
|
|
554
|
+
extends coreClient.OperationOptions {
|
|
555
|
+
/** Delay to wait until next poll, in milliseconds. */
|
|
556
|
+
updateIntervalInMs?: number;
|
|
557
|
+
/** A serialized poller which can be used to resume an existing paused Long-Running-Operation. */
|
|
558
|
+
resumeFrom?: string;
|
|
559
|
+
}
|
|
560
|
+
|
|
561
|
+
/** Contains response data for the createOrUpdate operation. */
|
|
562
|
+
export type VirtualMachineImageTemplatesCreateOrUpdateResponse = ImageTemplate;
|
|
563
|
+
|
|
564
|
+
/** Optional parameters. */
|
|
565
|
+
export interface VirtualMachineImageTemplatesUpdateOptionalParams
|
|
566
|
+
extends coreClient.OperationOptions {
|
|
567
|
+
/** Delay to wait until next poll, in milliseconds. */
|
|
568
|
+
updateIntervalInMs?: number;
|
|
569
|
+
/** A serialized poller which can be used to resume an existing paused Long-Running-Operation. */
|
|
570
|
+
resumeFrom?: string;
|
|
571
|
+
}
|
|
572
|
+
|
|
573
|
+
/** Contains response data for the update operation. */
|
|
574
|
+
export type VirtualMachineImageTemplatesUpdateResponse = ImageTemplate;
|
|
575
|
+
|
|
576
|
+
/** Optional parameters. */
|
|
577
|
+
export interface VirtualMachineImageTemplatesGetOptionalParams
|
|
578
|
+
extends coreClient.OperationOptions {}
|
|
579
|
+
|
|
580
|
+
/** Contains response data for the get operation. */
|
|
581
|
+
export type VirtualMachineImageTemplatesGetResponse = ImageTemplate;
|
|
582
|
+
|
|
583
|
+
/** Optional parameters. */
|
|
584
|
+
export interface VirtualMachineImageTemplatesDeleteOptionalParams
|
|
585
|
+
extends coreClient.OperationOptions {
|
|
586
|
+
/** Delay to wait until next poll, in milliseconds. */
|
|
587
|
+
updateIntervalInMs?: number;
|
|
588
|
+
/** A serialized poller which can be used to resume an existing paused Long-Running-Operation. */
|
|
589
|
+
resumeFrom?: string;
|
|
590
|
+
}
|
|
591
|
+
|
|
592
|
+
/** Optional parameters. */
|
|
593
|
+
export interface VirtualMachineImageTemplatesRunOptionalParams
|
|
594
|
+
extends coreClient.OperationOptions {
|
|
595
|
+
/** Delay to wait until next poll, in milliseconds. */
|
|
596
|
+
updateIntervalInMs?: number;
|
|
597
|
+
/** A serialized poller which can be used to resume an existing paused Long-Running-Operation. */
|
|
598
|
+
resumeFrom?: string;
|
|
599
|
+
}
|
|
600
|
+
|
|
601
|
+
/** Optional parameters. */
|
|
602
|
+
export interface VirtualMachineImageTemplatesCancelOptionalParams
|
|
603
|
+
extends coreClient.OperationOptions {
|
|
604
|
+
/** Delay to wait until next poll, in milliseconds. */
|
|
605
|
+
updateIntervalInMs?: number;
|
|
606
|
+
/** A serialized poller which can be used to resume an existing paused Long-Running-Operation. */
|
|
607
|
+
resumeFrom?: string;
|
|
608
|
+
}
|
|
609
|
+
|
|
610
|
+
/** Optional parameters. */
|
|
611
|
+
export interface VirtualMachineImageTemplatesListRunOutputsOptionalParams
|
|
612
|
+
extends coreClient.OperationOptions {}
|
|
613
|
+
|
|
614
|
+
/** Contains response data for the listRunOutputs operation. */
|
|
615
|
+
export type VirtualMachineImageTemplatesListRunOutputsResponse = RunOutputCollection;
|
|
616
|
+
|
|
617
|
+
/** Optional parameters. */
|
|
618
|
+
export interface VirtualMachineImageTemplatesGetRunOutputOptionalParams
|
|
619
|
+
extends coreClient.OperationOptions {}
|
|
620
|
+
|
|
621
|
+
/** Contains response data for the getRunOutput operation. */
|
|
622
|
+
export type VirtualMachineImageTemplatesGetRunOutputResponse = RunOutput;
|
|
623
|
+
|
|
624
|
+
/** Optional parameters. */
|
|
625
|
+
export interface VirtualMachineImageTemplatesListNextOptionalParams
|
|
626
|
+
extends coreClient.OperationOptions {}
|
|
627
|
+
|
|
628
|
+
/** Contains response data for the listNext operation. */
|
|
629
|
+
export type VirtualMachineImageTemplatesListNextResponse = ImageTemplateListResult;
|
|
630
|
+
|
|
631
|
+
/** Optional parameters. */
|
|
632
|
+
export interface VirtualMachineImageTemplatesListByResourceGroupNextOptionalParams
|
|
633
|
+
extends coreClient.OperationOptions {}
|
|
634
|
+
|
|
635
|
+
/** Contains response data for the listByResourceGroupNext operation. */
|
|
636
|
+
export type VirtualMachineImageTemplatesListByResourceGroupNextResponse = ImageTemplateListResult;
|
|
637
|
+
|
|
638
|
+
/** Optional parameters. */
|
|
639
|
+
export interface VirtualMachineImageTemplatesListRunOutputsNextOptionalParams
|
|
640
|
+
extends coreClient.OperationOptions {}
|
|
641
|
+
|
|
642
|
+
/** Contains response data for the listRunOutputsNext operation. */
|
|
643
|
+
export type VirtualMachineImageTemplatesListRunOutputsNextResponse = RunOutputCollection;
|
|
644
|
+
|
|
645
|
+
/** Optional parameters. */
|
|
646
|
+
export interface OperationsListOptionalParams
|
|
647
|
+
extends coreClient.OperationOptions {}
|
|
648
|
+
|
|
649
|
+
/** Contains response data for the list operation. */
|
|
650
|
+
export type OperationsListResponse = OperationListResult;
|
|
651
|
+
|
|
652
|
+
/** Optional parameters. */
|
|
653
|
+
export interface OperationsListNextOptionalParams
|
|
654
|
+
extends coreClient.OperationOptions {}
|
|
655
|
+
|
|
656
|
+
/** Contains response data for the listNext operation. */
|
|
657
|
+
export type OperationsListNextResponse = OperationListResult;
|
|
658
|
+
|
|
659
|
+
/** Optional parameters. */
|
|
660
|
+
export interface ImageBuilderClientOptionalParams
|
|
661
|
+
extends coreClient.ServiceClientOptions {
|
|
662
|
+
/** server parameter */
|
|
663
|
+
$host?: string;
|
|
664
|
+
/** Api Version */
|
|
665
|
+
apiVersion?: string;
|
|
666
|
+
/** Overrides client endpoint. */
|
|
667
|
+
endpoint?: string;
|
|
668
|
+
}
|