@azure/arm-containerinstance 9.1.0-beta.1 → 9.1.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.
Files changed (64) hide show
  1. package/CHANGELOG.md +5 -1
  2. package/README.md +1 -1
  3. package/dist/index.js +145 -42
  4. package/dist/index.js.map +1 -1
  5. package/dist/index.min.js +1 -1
  6. package/dist/index.min.js.map +1 -1
  7. package/dist-esm/samples-dev/containerGroupsCreateOrUpdateSample.js +10 -6
  8. package/dist-esm/samples-dev/containerGroupsCreateOrUpdateSample.js.map +1 -1
  9. package/dist-esm/samples-dev/containerGroupsDeleteSample.js +1 -1
  10. package/dist-esm/samples-dev/containerGroupsGetSample.js +3 -3
  11. package/dist-esm/samples-dev/containerGroupsListByResourceGroupSample.js +1 -1
  12. package/dist-esm/samples-dev/containerGroupsListSample.js +1 -1
  13. package/dist-esm/samples-dev/containerGroupsRestartSample.js +1 -1
  14. package/dist-esm/samples-dev/containerGroupsStartSample.js +1 -1
  15. package/dist-esm/samples-dev/containerGroupsStopSample.js +1 -1
  16. package/dist-esm/samples-dev/containerGroupsUpdateSample.js +1 -1
  17. package/dist-esm/samples-dev/containersAttachSample.js +1 -1
  18. package/dist-esm/samples-dev/containersExecuteCommandSample.js +1 -1
  19. package/dist-esm/samples-dev/containersListLogsSample.js +1 -1
  20. package/dist-esm/samples-dev/locationListCachedImagesSample.js +1 -1
  21. package/dist-esm/samples-dev/locationListCapabilitiesSample.js +1 -1
  22. package/dist-esm/samples-dev/locationListUsageSample.js +1 -1
  23. package/dist-esm/samples-dev/operationsListSample.js +1 -1
  24. package/dist-esm/samples-dev/subnetServiceAssociationLinkDeleteSample.js +1 -1
  25. package/dist-esm/src/containerInstanceManagementClient.js +2 -2
  26. package/dist-esm/src/containerInstanceManagementClient.js.map +1 -1
  27. package/dist-esm/src/lroImpl.d.ts +6 -11
  28. package/dist-esm/src/lroImpl.d.ts.map +1 -1
  29. package/dist-esm/src/lroImpl.js +12 -20
  30. package/dist-esm/src/lroImpl.js.map +1 -1
  31. package/dist-esm/src/models/index.d.ts +26 -0
  32. package/dist-esm/src/models/index.d.ts.map +1 -1
  33. package/dist-esm/src/models/index.js.map +1 -1
  34. package/dist-esm/src/models/mappers.d.ts +2 -0
  35. package/dist-esm/src/models/mappers.d.ts.map +1 -1
  36. package/dist-esm/src/models/mappers.js +89 -0
  37. package/dist-esm/src/models/mappers.js.map +1 -1
  38. package/dist-esm/src/models/parameters.js +1 -1
  39. package/dist-esm/src/models/parameters.js.map +1 -1
  40. package/dist-esm/src/operations/containerGroups.d.ts +5 -5
  41. package/dist-esm/src/operations/containerGroups.d.ts.map +1 -1
  42. package/dist-esm/src/operations/containerGroups.js +34 -18
  43. package/dist-esm/src/operations/containerGroups.js.map +1 -1
  44. package/dist-esm/src/operations/subnetServiceAssociationLink.d.ts +2 -2
  45. package/dist-esm/src/operations/subnetServiceAssociationLink.d.ts.map +1 -1
  46. package/dist-esm/src/operations/subnetServiceAssociationLink.js +10 -6
  47. package/dist-esm/src/operations/subnetServiceAssociationLink.js.map +1 -1
  48. package/dist-esm/src/operationsInterfaces/containerGroups.d.ts +5 -5
  49. package/dist-esm/src/operationsInterfaces/containerGroups.d.ts.map +1 -1
  50. package/dist-esm/src/operationsInterfaces/subnetServiceAssociationLink.d.ts +2 -2
  51. package/dist-esm/src/operationsInterfaces/subnetServiceAssociationLink.d.ts.map +1 -1
  52. package/package.json +9 -9
  53. package/review/arm-containerinstance.api.md +25 -7
  54. package/src/containerInstanceManagementClient.ts +2 -2
  55. package/src/lroImpl.ts +31 -23
  56. package/src/models/index.ts +28 -0
  57. package/src/models/mappers.ts +91 -0
  58. package/src/models/parameters.ts +1 -1
  59. package/src/operations/containerGroups.ts +50 -40
  60. package/src/operations/subnetServiceAssociationLink.ts +15 -11
  61. package/src/operationsInterfaces/containerGroups.ts +7 -7
  62. package/src/operationsInterfaces/subnetServiceAssociationLink.ts +2 -2
  63. package/types/arm-containerinstance.d.ts +35 -7
  64. package/types/tsdoc-metadata.json +1 -1
package/CHANGELOG.md CHANGED
@@ -1,16 +1,20 @@
1
1
  # Release History
2
2
 
3
- ## 9.1.0-beta.1 (2023-01-13)
3
+ ## 9.1.0 (2023-04-24)
4
4
 
5
5
  **Features**
6
6
 
7
7
  - Added Interface ConfidentialComputeProperties
8
8
  - Added Interface DeploymentExtensionSpec
9
+ - Added Interface SecurityContextCapabilitiesDefinition
10
+ - Added Interface SecurityContextDefinition
9
11
  - Added Type Alias ContainerGroupPriority
12
+ - Interface Container has a new optional parameter securityContext
10
13
  - Interface ContainerGroupProperties has a new optional parameter confidentialComputeProperties
11
14
  - Interface ContainerGroupProperties has a new optional parameter extensions
12
15
  - Interface ContainerGroupProperties has a new optional parameter priority
13
16
  - Interface EncryptionProperties has a new optional parameter identity
17
+ - Interface InitContainerDefinition has a new optional parameter securityContext
14
18
  - Added Enum KnownContainerGroupPriority
15
19
  - Enum KnownContainerGroupSku has a new value Confidential
16
20
  - Added function getContinuationToken
package/README.md CHANGED
@@ -6,7 +6,7 @@ This package contains an isomorphic SDK (runs both in Node.js and in browsers) f
6
6
 
7
7
  [Source code](https://github.com/Azure/azure-sdk-for-js/tree/main/sdk/containerinstance/arm-containerinstance) |
8
8
  [Package (NPM)](https://www.npmjs.com/package/@azure/arm-containerinstance) |
9
- [API reference documentation](https://docs.microsoft.com/javascript/api/@azure/arm-containerinstance?view=azure-node-preview) |
9
+ [API reference documentation](https://docs.microsoft.com/javascript/api/@azure/arm-containerinstance) |
10
10
  [Samples](https://github.com/Azure-Samples/azure-samples-js-management)
11
11
 
12
12
  ## Getting started
package/dist/index.js CHANGED
@@ -582,6 +582,13 @@ const Container = {
582
582
  name: "Composite",
583
583
  className: "ContainerProbe"
584
584
  }
585
+ },
586
+ securityContext: {
587
+ serializedName: "properties.securityContext",
588
+ type: {
589
+ name: "Composite",
590
+ className: "SecurityContextDefinition"
591
+ }
585
592
  }
586
593
  }
587
594
  }
@@ -1027,6 +1034,81 @@ const HttpHeader = {
1027
1034
  }
1028
1035
  }
1029
1036
  };
1037
+ const SecurityContextDefinition = {
1038
+ type: {
1039
+ name: "Composite",
1040
+ className: "SecurityContextDefinition",
1041
+ modelProperties: {
1042
+ privileged: {
1043
+ serializedName: "privileged",
1044
+ type: {
1045
+ name: "Boolean"
1046
+ }
1047
+ },
1048
+ allowPrivilegeEscalation: {
1049
+ serializedName: "allowPrivilegeEscalation",
1050
+ type: {
1051
+ name: "Boolean"
1052
+ }
1053
+ },
1054
+ capabilities: {
1055
+ serializedName: "capabilities",
1056
+ type: {
1057
+ name: "Composite",
1058
+ className: "SecurityContextCapabilitiesDefinition"
1059
+ }
1060
+ },
1061
+ runAsGroup: {
1062
+ serializedName: "runAsGroup",
1063
+ type: {
1064
+ name: "Number"
1065
+ }
1066
+ },
1067
+ runAsUser: {
1068
+ serializedName: "runAsUser",
1069
+ type: {
1070
+ name: "Number"
1071
+ }
1072
+ },
1073
+ seccompProfile: {
1074
+ serializedName: "seccompProfile",
1075
+ type: {
1076
+ name: "String"
1077
+ }
1078
+ }
1079
+ }
1080
+ }
1081
+ };
1082
+ const SecurityContextCapabilitiesDefinition = {
1083
+ type: {
1084
+ name: "Composite",
1085
+ className: "SecurityContextCapabilitiesDefinition",
1086
+ modelProperties: {
1087
+ add: {
1088
+ serializedName: "add",
1089
+ type: {
1090
+ name: "Sequence",
1091
+ element: {
1092
+ type: {
1093
+ name: "String"
1094
+ }
1095
+ }
1096
+ }
1097
+ },
1098
+ drop: {
1099
+ serializedName: "drop",
1100
+ type: {
1101
+ name: "Sequence",
1102
+ element: {
1103
+ type: {
1104
+ name: "String"
1105
+ }
1106
+ }
1107
+ }
1108
+ }
1109
+ }
1110
+ }
1111
+ };
1030
1112
  const ImageRegistryCredential = {
1031
1113
  type: {
1032
1114
  name: "Composite",
@@ -1476,6 +1558,13 @@ const InitContainerDefinition = {
1476
1558
  }
1477
1559
  }
1478
1560
  }
1561
+ },
1562
+ securityContext: {
1563
+ serializedName: "properties.securityContext",
1564
+ type: {
1565
+ name: "Composite",
1566
+ className: "SecurityContextDefinition"
1567
+ }
1479
1568
  }
1480
1569
  }
1481
1570
  }
@@ -2087,6 +2176,8 @@ var Mappers = /*#__PURE__*/Object.freeze({
2087
2176
  ContainerExec: ContainerExec,
2088
2177
  ContainerHttpGet: ContainerHttpGet,
2089
2178
  HttpHeader: HttpHeader,
2179
+ SecurityContextDefinition: SecurityContextDefinition,
2180
+ SecurityContextCapabilitiesDefinition: SecurityContextCapabilitiesDefinition,
2090
2181
  ImageRegistryCredential: ImageRegistryCredential,
2091
2182
  IpAddress: IpAddress,
2092
2183
  Port: Port,
@@ -2166,7 +2257,7 @@ const subscriptionId = {
2166
2257
  const apiVersion = {
2167
2258
  parameterPath: "apiVersion",
2168
2259
  mapper: {
2169
- defaultValue: "2022-10-01-preview",
2260
+ defaultValue: "2023-05-01",
2170
2261
  isConstant: true,
2171
2262
  serializedName: "api-version",
2172
2263
  type: {
@@ -2294,25 +2385,17 @@ const subnetName = {
2294
2385
  * Code generated by Microsoft (R) AutoRest Code Generator.
2295
2386
  * Changes may cause incorrect behavior and will be lost if the code is regenerated.
2296
2387
  */
2297
- class LroImpl {
2298
- constructor(sendOperationFn, args, spec, requestPath = spec.path, requestMethod = spec.httpMethod) {
2299
- this.sendOperationFn = sendOperationFn;
2300
- this.args = args;
2301
- this.spec = spec;
2302
- this.requestPath = requestPath;
2303
- this.requestMethod = requestMethod;
2304
- }
2305
- sendInitialRequest() {
2306
- return tslib.__awaiter(this, void 0, void 0, function* () {
2307
- return this.sendOperationFn(this.args, this.spec);
2308
- });
2309
- }
2310
- sendPollRequest(path) {
2311
- return tslib.__awaiter(this, void 0, void 0, function* () {
2312
- const _a = this.spec, restSpec = tslib.__rest(_a, ["requestBody"]);
2313
- return this.sendOperationFn(this.args, Object.assign(Object.assign({}, restSpec), { path, httpMethod: "GET" }));
2314
- });
2315
- }
2388
+ function createLroSpec(inputs) {
2389
+ const { args, spec, sendOperationFn } = inputs;
2390
+ return {
2391
+ requestMethod: spec.httpMethod,
2392
+ requestPath: spec.path,
2393
+ sendInitialRequest: () => sendOperationFn(args, spec),
2394
+ sendPollRequest: (path, options) => {
2395
+ const restSpec = tslib.__rest(spec, ["requestBody"]);
2396
+ return sendOperationFn(args, Object.assign(Object.assign({}, restSpec), { httpMethod: "GET", path, abortSignal: options === null || options === void 0 ? void 0 : options.abortSignal }));
2397
+ }
2398
+ };
2316
2399
  }
2317
2400
 
2318
2401
  /*
@@ -2497,7 +2580,7 @@ class ContainerGroupsImpl {
2497
2580
  const directSendOperation = (args, spec) => tslib.__awaiter(this, void 0, void 0, function* () {
2498
2581
  return this.client.sendOperationRequest(args, spec);
2499
2582
  });
2500
- const sendOperation = (args, spec) => tslib.__awaiter(this, void 0, void 0, function* () {
2583
+ const sendOperationFn = (args, spec) => tslib.__awaiter(this, void 0, void 0, function* () {
2501
2584
  var _a;
2502
2585
  let currentRawResponse = undefined;
2503
2586
  const providedCallback = (_a = args.options) === null || _a === void 0 ? void 0 : _a.onResponse;
@@ -2516,9 +2599,13 @@ class ContainerGroupsImpl {
2516
2599
  }
2517
2600
  };
2518
2601
  });
2519
- const lro = new LroImpl(sendOperation, { resourceGroupName, containerGroupName, containerGroup, options }, createOrUpdateOperationSpec);
2520
- const poller = new coreLro.LroEngine(lro, {
2521
- resumeFrom: options === null || options === void 0 ? void 0 : options.resumeFrom,
2602
+ const lro = createLroSpec({
2603
+ sendOperationFn,
2604
+ args: { resourceGroupName, containerGroupName, containerGroup, options },
2605
+ spec: createOrUpdateOperationSpec
2606
+ });
2607
+ const poller = yield coreLro.createHttpPoller(lro, {
2608
+ restoreFrom: options === null || options === void 0 ? void 0 : options.resumeFrom,
2522
2609
  intervalInMs: options === null || options === void 0 ? void 0 : options.updateIntervalInMs
2523
2610
  });
2524
2611
  yield poller.poll();
@@ -2560,7 +2647,7 @@ class ContainerGroupsImpl {
2560
2647
  const directSendOperation = (args, spec) => tslib.__awaiter(this, void 0, void 0, function* () {
2561
2648
  return this.client.sendOperationRequest(args, spec);
2562
2649
  });
2563
- const sendOperation = (args, spec) => tslib.__awaiter(this, void 0, void 0, function* () {
2650
+ const sendOperationFn = (args, spec) => tslib.__awaiter(this, void 0, void 0, function* () {
2564
2651
  var _a;
2565
2652
  let currentRawResponse = undefined;
2566
2653
  const providedCallback = (_a = args.options) === null || _a === void 0 ? void 0 : _a.onResponse;
@@ -2579,9 +2666,13 @@ class ContainerGroupsImpl {
2579
2666
  }
2580
2667
  };
2581
2668
  });
2582
- const lro = new LroImpl(sendOperation, { resourceGroupName, containerGroupName, options }, deleteOperationSpec$1);
2583
- const poller = new coreLro.LroEngine(lro, {
2584
- resumeFrom: options === null || options === void 0 ? void 0 : options.resumeFrom,
2669
+ const lro = createLroSpec({
2670
+ sendOperationFn,
2671
+ args: { resourceGroupName, containerGroupName, options },
2672
+ spec: deleteOperationSpec$1
2673
+ });
2674
+ const poller = yield coreLro.createHttpPoller(lro, {
2675
+ restoreFrom: options === null || options === void 0 ? void 0 : options.resumeFrom,
2585
2676
  intervalInMs: options === null || options === void 0 ? void 0 : options.updateIntervalInMs
2586
2677
  });
2587
2678
  yield poller.poll();
@@ -2613,7 +2704,7 @@ class ContainerGroupsImpl {
2613
2704
  const directSendOperation = (args, spec) => tslib.__awaiter(this, void 0, void 0, function* () {
2614
2705
  return this.client.sendOperationRequest(args, spec);
2615
2706
  });
2616
- const sendOperation = (args, spec) => tslib.__awaiter(this, void 0, void 0, function* () {
2707
+ const sendOperationFn = (args, spec) => tslib.__awaiter(this, void 0, void 0, function* () {
2617
2708
  var _a;
2618
2709
  let currentRawResponse = undefined;
2619
2710
  const providedCallback = (_a = args.options) === null || _a === void 0 ? void 0 : _a.onResponse;
@@ -2632,9 +2723,13 @@ class ContainerGroupsImpl {
2632
2723
  }
2633
2724
  };
2634
2725
  });
2635
- const lro = new LroImpl(sendOperation, { resourceGroupName, containerGroupName, options }, restartOperationSpec);
2636
- const poller = new coreLro.LroEngine(lro, {
2637
- resumeFrom: options === null || options === void 0 ? void 0 : options.resumeFrom,
2726
+ const lro = createLroSpec({
2727
+ sendOperationFn,
2728
+ args: { resourceGroupName, containerGroupName, options },
2729
+ spec: restartOperationSpec
2730
+ });
2731
+ const poller = yield coreLro.createHttpPoller(lro, {
2732
+ restoreFrom: options === null || options === void 0 ? void 0 : options.resumeFrom,
2638
2733
  intervalInMs: options === null || options === void 0 ? void 0 : options.updateIntervalInMs
2639
2734
  });
2640
2735
  yield poller.poll();
@@ -2676,7 +2771,7 @@ class ContainerGroupsImpl {
2676
2771
  const directSendOperation = (args, spec) => tslib.__awaiter(this, void 0, void 0, function* () {
2677
2772
  return this.client.sendOperationRequest(args, spec);
2678
2773
  });
2679
- const sendOperation = (args, spec) => tslib.__awaiter(this, void 0, void 0, function* () {
2774
+ const sendOperationFn = (args, spec) => tslib.__awaiter(this, void 0, void 0, function* () {
2680
2775
  var _a;
2681
2776
  let currentRawResponse = undefined;
2682
2777
  const providedCallback = (_a = args.options) === null || _a === void 0 ? void 0 : _a.onResponse;
@@ -2695,9 +2790,13 @@ class ContainerGroupsImpl {
2695
2790
  }
2696
2791
  };
2697
2792
  });
2698
- const lro = new LroImpl(sendOperation, { resourceGroupName, containerGroupName, options }, startOperationSpec);
2699
- const poller = new coreLro.LroEngine(lro, {
2700
- resumeFrom: options === null || options === void 0 ? void 0 : options.resumeFrom,
2793
+ const lro = createLroSpec({
2794
+ sendOperationFn,
2795
+ args: { resourceGroupName, containerGroupName, options },
2796
+ spec: startOperationSpec
2797
+ });
2798
+ const poller = yield coreLro.createHttpPoller(lro, {
2799
+ restoreFrom: options === null || options === void 0 ? void 0 : options.resumeFrom,
2701
2800
  intervalInMs: options === null || options === void 0 ? void 0 : options.updateIntervalInMs
2702
2801
  });
2703
2802
  yield poller.poll();
@@ -3631,7 +3730,7 @@ class SubnetServiceAssociationLinkImpl {
3631
3730
  const directSendOperation = (args, spec) => tslib.__awaiter(this, void 0, void 0, function* () {
3632
3731
  return this.client.sendOperationRequest(args, spec);
3633
3732
  });
3634
- const sendOperation = (args, spec) => tslib.__awaiter(this, void 0, void 0, function* () {
3733
+ const sendOperationFn = (args, spec) => tslib.__awaiter(this, void 0, void 0, function* () {
3635
3734
  var _a;
3636
3735
  let currentRawResponse = undefined;
3637
3736
  const providedCallback = (_a = args.options) === null || _a === void 0 ? void 0 : _a.onResponse;
@@ -3650,9 +3749,13 @@ class SubnetServiceAssociationLinkImpl {
3650
3749
  }
3651
3750
  };
3652
3751
  });
3653
- const lro = new LroImpl(sendOperation, { resourceGroupName, virtualNetworkName, subnetName, options }, deleteOperationSpec);
3654
- const poller = new coreLro.LroEngine(lro, {
3655
- resumeFrom: options === null || options === void 0 ? void 0 : options.resumeFrom,
3752
+ const lro = createLroSpec({
3753
+ sendOperationFn,
3754
+ args: { resourceGroupName, virtualNetworkName, subnetName, options },
3755
+ spec: deleteOperationSpec
3756
+ });
3757
+ const poller = yield coreLro.createHttpPoller(lro, {
3758
+ restoreFrom: options === null || options === void 0 ? void 0 : options.resumeFrom,
3656
3759
  intervalInMs: options === null || options === void 0 ? void 0 : options.updateIntervalInMs
3657
3760
  });
3658
3761
  yield poller.poll();
@@ -3731,7 +3834,7 @@ class ContainerInstanceManagementClient extends coreClient__namespace.ServiceCli
3731
3834
  requestContentType: "application/json; charset=utf-8",
3732
3835
  credential: credentials
3733
3836
  };
3734
- const packageDetails = `azsdk-js-arm-containerinstance/9.1.0-beta.1`;
3837
+ const packageDetails = `azsdk-js-arm-containerinstance/9.1.0`;
3735
3838
  const userAgentPrefix = options.userAgentOptions && options.userAgentOptions.userAgentPrefix
3736
3839
  ? `${options.userAgentOptions.userAgentPrefix} ${packageDetails}`
3737
3840
  : `${packageDetails}`;
@@ -3764,7 +3867,7 @@ class ContainerInstanceManagementClient extends coreClient__namespace.ServiceCli
3764
3867
  this.subscriptionId = subscriptionId;
3765
3868
  // Assigning values to Constant parameters
3766
3869
  this.$host = options.$host || "https://management.azure.com";
3767
- this.apiVersion = options.apiVersion || "2022-10-01-preview";
3870
+ this.apiVersion = options.apiVersion || "2023-05-01";
3768
3871
  this.containerGroups = new ContainerGroupsImpl(this);
3769
3872
  this.operations = new OperationsImpl(this);
3770
3873
  this.location = new LocationImpl(this);