@pulumi/newrelic 5.72.1 → 5.72.2

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/fleet.d.ts CHANGED
@@ -89,7 +89,7 @@ export declare class Fleet extends pulumi.CustomResource {
89
89
  */
90
90
  readonly name: pulumi.Output<string>;
91
91
  /**
92
- * The operating system type for HOST fleets. **Required when `managedEntityType` is `HOST`**. Valid values are `LINUX` or `WINDOWS`. **Must not be set when `managedEntityType` is `KUBERNETESCLUSTER`**. **Note**: This cannot be changed after creation (forces new resource).
92
+ * The operating system type for HOST fleets. **Required when `managedEntityType` is `HOST`**. Valid values are `LINUX` or `WINDOWS`. **Must not be set when `managedEntityType` is `KUBERNETESCLUSTER`**. Both pairings are validated at plan time so misconfigurations surface before apply. **Note**: This cannot be changed after creation (forces new resource).
93
93
  */
94
94
  readonly operatingSystem: pulumi.Output<string | undefined>;
95
95
  /**
@@ -126,7 +126,7 @@ export interface FleetState {
126
126
  */
127
127
  name?: pulumi.Input<string | undefined>;
128
128
  /**
129
- * The operating system type for HOST fleets. **Required when `managedEntityType` is `HOST`**. Valid values are `LINUX` or `WINDOWS`. **Must not be set when `managedEntityType` is `KUBERNETESCLUSTER`**. **Note**: This cannot be changed after creation (forces new resource).
129
+ * The operating system type for HOST fleets. **Required when `managedEntityType` is `HOST`**. Valid values are `LINUX` or `WINDOWS`. **Must not be set when `managedEntityType` is `KUBERNETESCLUSTER`**. Both pairings are validated at plan time so misconfigurations surface before apply. **Note**: This cannot be changed after creation (forces new resource).
130
130
  */
131
131
  operatingSystem?: pulumi.Input<string | undefined>;
132
132
  /**
@@ -155,7 +155,7 @@ export interface FleetArgs {
155
155
  */
156
156
  name?: pulumi.Input<string | undefined>;
157
157
  /**
158
- * The operating system type for HOST fleets. **Required when `managedEntityType` is `HOST`**. Valid values are `LINUX` or `WINDOWS`. **Must not be set when `managedEntityType` is `KUBERNETESCLUSTER`**. **Note**: This cannot be changed after creation (forces new resource).
158
+ * The operating system type for HOST fleets. **Required when `managedEntityType` is `HOST`**. Valid values are `LINUX` or `WINDOWS`. **Must not be set when `managedEntityType` is `KUBERNETESCLUSTER`**. Both pairings are validated at plan time so misconfigurations surface before apply. **Note**: This cannot be changed after creation (forces new resource).
159
159
  */
160
160
  operatingSystem?: pulumi.Input<string | undefined>;
161
161
  /**
@@ -1,10 +1,8 @@
1
1
  import * as pulumi from "@pulumi/pulumi";
2
- import * as inputs from "./types/input";
3
- import * as outputs from "./types/output";
4
2
  /**
5
3
  * Use this resource to create and manage New Relic fleet configurations for centralized agent management.
6
4
  *
7
- * A fleet configuration defines versioned agent settings deployable to your fleets. Each configuration is specific to an agent type and managed entity type. Versions are immutable - their content cannot be modified after creation. To add a new configuration, add a `version` block; to remove one, delete its block.
5
+ * A fleet configuration holds versioned agent settings. The configuration content is immutable each change to `configurationContent` creates a new version on the API automatically, similar to how AWS launch templates work. The resource ID (the configuration entity GUID) never changes across updates. Use the `newrelic.FleetConfiguration` data source to access the content of a specific historical version.
8
6
  *
9
7
  * ## Example Usage
10
8
  *
@@ -18,45 +16,22 @@ import * as outputs from "./types/output";
18
16
  * name: "Production Infrastructure Config",
19
17
  * agentType: "NRInfra",
20
18
  * managedEntityType: "HOST",
21
- * versions: [{
22
- * configurationContent: `log:
19
+ * operatingSystem: "LINUX",
20
+ * configurationContent: `log:
23
21
  * level: info
24
22
  * file: /var/log/newrelic-infra/newrelic-infra.log
25
23
  * metrics:
26
24
  * enabled: true
27
25
  * system_sample_rate: 15
28
26
  * `,
29
- * }],
30
27
  * });
31
28
  * ```
32
29
  *
33
- * ### Version Immutability
30
+ * ## Out-of-band drift warnings
34
31
  *
35
- * Version content is **immutable** - the API does not support updating the content of an existing version. If you attempt to modify `configurationContent` of an already-applied `version` block, Terraform will catch this at plan time and surface an error before any API call is made:
32
+ * If a version is deleted outside of Terraform (UI, API, or another tool), the next `plan` or `refresh` will surface a warning so you understand why state changed:
36
33
  *
37
- * To update the configuration in use:
38
- * - **Add** a new `version` block with the updated content.
39
- * - **Remove** the old `version` block whose content you no longer need.
40
- *
41
- * Terraform applies removals (API deletes) before creates, so if you add and remove a block in the same `apply`, the old version is deleted first and the new one is created after.
42
- *
43
- * ### Unique Content Requirement
44
- *
45
- * All `version` blocks within a resource must have distinct `configurationContent` values. Duplicate content is caught at plan time before any changes are applied:
46
- *
47
- * This also applies to rollback scenarios. If you previously had versions A → B and want to roll back by reintroducing A's content as a new version, add a new `version` block with A's content rather than restoring an old block - the new version will get a new version number from the API.
48
- *
49
- * ### Version Numbering
50
- *
51
- * Version numbers are assigned sequentially by the API and are never reused or renumbered. When you remove a `version` block, the remaining versions keep their original numbers. For example, if you have versions 1, 2, and 3 and remove version 2, the configuration will have versions 1 and 3 - the API does not compact the sequence.
52
- *
53
- * `latestVersionNumber` and `latestVersionEntityId` always reflect the highest-numbered version, regardless of how many versions exist.
54
- *
55
- * ### Externally Deleted Versions
56
- *
57
- * If a version is deleted outside of Terraform (for example, via the API or the New Relic UI), the next `pulumi preview` will show a warning for the affected version:
58
- *
59
- * The warning indicates that Terraform will recreate the missing version on the next `apply`. If the deletion was intentional, remove the corresponding `version` block from your configuration before applying.
34
+ * If the previously-tracked **latest** version was the one deleted, an additional, stronger warning fires explaining that `configurationContent` has been refreshed from the new latest version on the API. If your declared content differs from that new latest, the next `apply` will create a new version restoring your declared content — this is the expected, self-healing behavior.
60
35
  *
61
36
  * ## Import
62
37
  *
@@ -67,7 +42,7 @@ import * as outputs from "./types/output";
67
42
  * $ pulumi import newrelic:index/fleetConfiguration:FleetConfiguration infra <configuration_guid>:KUBERNETESCLUSTER
68
43
  * ```
69
44
  *
70
- * The `managedEntityType` portion is required because the New Relic API does not return it via the entity lookup query (a GraphQL schema constraint). All other attributes — `name`, `agentType`, `operatingSystem`, `organizationId` — are resolved automatically from the API.
45
+ * The `managedEntityType` portion is required because the New Relic API does not return it via the entity lookup query (a GraphQL schema constraint). All other attributes — `name`, `agentType`, `operatingSystem`, `organizationId`, `configurationContent` — are resolved automatically from the API.
71
46
  */
72
47
  export declare class FleetConfiguration extends pulumi.CustomResource {
73
48
  /**
@@ -89,6 +64,10 @@ export declare class FleetConfiguration extends pulumi.CustomResource {
89
64
  * The type of agent this configuration is for. Valid values: `NRInfra`, `NRDOT`, `FluentBit`, `NRPrometheusAgent`. **Cannot be changed after creation.**
90
65
  */
91
66
  readonly agentType: pulumi.Output<string>;
67
+ /**
68
+ * The YAML or JSON content for this configuration. Use `file()` to load content from a file. Each change to this field creates a new immutable version on the API; the resource ID remains constant.
69
+ */
70
+ readonly configurationContent: pulumi.Output<string>;
92
71
  /**
93
72
  * The entity GUID of the configuration.
94
73
  */
@@ -98,7 +77,7 @@ export declare class FleetConfiguration extends pulumi.CustomResource {
98
77
  */
99
78
  readonly latestVersionEntityId: pulumi.Output<string>;
100
79
  /**
101
- * The highest version number across all versions.
80
+ * The highest version number across all versions created so far.
102
81
  */
103
82
  readonly latestVersionNumber: pulumi.Output<number>;
104
83
  /**
@@ -106,7 +85,7 @@ export declare class FleetConfiguration extends pulumi.CustomResource {
106
85
  */
107
86
  readonly managedEntityType: pulumi.Output<string>;
108
87
  /**
109
- * The name of the configuration.
88
+ * The name of the configuration. **Changing this forces resource recreation** — the API does not support renaming a configuration in place.
110
89
  */
111
90
  readonly name: pulumi.Output<string>;
112
91
  /**
@@ -122,9 +101,9 @@ export declare class FleetConfiguration extends pulumi.CustomResource {
122
101
  */
123
102
  readonly totalVersions: pulumi.Output<number>;
124
103
  /**
125
- * One or more version blocks. At least one is required. See Nested `version` blocks below.
104
+ * A list of entity GUIDs for all versions, sorted oldest-first. Use with the `newrelic.FleetConfiguration` data source to retrieve the content of a specific historical version.
126
105
  */
127
- readonly versions: pulumi.Output<outputs.FleetConfigurationVersion[]>;
106
+ readonly versionEntityIds: pulumi.Output<string[]>;
128
107
  /**
129
108
  * Create a FleetConfiguration resource with the given unique name, arguments, and options.
130
109
  *
@@ -142,6 +121,10 @@ export interface FleetConfigurationState {
142
121
  * The type of agent this configuration is for. Valid values: `NRInfra`, `NRDOT`, `FluentBit`, `NRPrometheusAgent`. **Cannot be changed after creation.**
143
122
  */
144
123
  agentType?: pulumi.Input<string | undefined>;
124
+ /**
125
+ * The YAML or JSON content for this configuration. Use `file()` to load content from a file. Each change to this field creates a new immutable version on the API; the resource ID remains constant.
126
+ */
127
+ configurationContent?: pulumi.Input<string | undefined>;
145
128
  /**
146
129
  * The entity GUID of the configuration.
147
130
  */
@@ -151,7 +134,7 @@ export interface FleetConfigurationState {
151
134
  */
152
135
  latestVersionEntityId?: pulumi.Input<string | undefined>;
153
136
  /**
154
- * The highest version number across all versions.
137
+ * The highest version number across all versions created so far.
155
138
  */
156
139
  latestVersionNumber?: pulumi.Input<number | undefined>;
157
140
  /**
@@ -159,7 +142,7 @@ export interface FleetConfigurationState {
159
142
  */
160
143
  managedEntityType?: pulumi.Input<string | undefined>;
161
144
  /**
162
- * The name of the configuration.
145
+ * The name of the configuration. **Changing this forces resource recreation** — the API does not support renaming a configuration in place.
163
146
  */
164
147
  name?: pulumi.Input<string | undefined>;
165
148
  /**
@@ -175,9 +158,9 @@ export interface FleetConfigurationState {
175
158
  */
176
159
  totalVersions?: pulumi.Input<number | undefined>;
177
160
  /**
178
- * One or more version blocks. At least one is required. See Nested `version` blocks below.
161
+ * A list of entity GUIDs for all versions, sorted oldest-first. Use with the `newrelic.FleetConfiguration` data source to retrieve the content of a specific historical version.
179
162
  */
180
- versions?: pulumi.Input<pulumi.Input<inputs.FleetConfigurationVersion>[] | undefined>;
163
+ versionEntityIds?: pulumi.Input<pulumi.Input<string>[] | undefined>;
181
164
  }
182
165
  /**
183
166
  * The set of arguments for constructing a FleetConfiguration resource.
@@ -187,12 +170,16 @@ export interface FleetConfigurationArgs {
187
170
  * The type of agent this configuration is for. Valid values: `NRInfra`, `NRDOT`, `FluentBit`, `NRPrometheusAgent`. **Cannot be changed after creation.**
188
171
  */
189
172
  agentType: pulumi.Input<string>;
173
+ /**
174
+ * The YAML or JSON content for this configuration. Use `file()` to load content from a file. Each change to this field creates a new immutable version on the API; the resource ID remains constant.
175
+ */
176
+ configurationContent: pulumi.Input<string>;
190
177
  /**
191
178
  * The type of entities this configuration manages. Valid values: `HOST`, `KUBERNETESCLUSTER`. **Cannot be changed after creation.**
192
179
  */
193
180
  managedEntityType: pulumi.Input<string>;
194
181
  /**
195
- * The name of the configuration.
182
+ * The name of the configuration. **Changing this forces resource recreation** — the API does not support renaming a configuration in place.
196
183
  */
197
184
  name?: pulumi.Input<string | undefined>;
198
185
  /**
@@ -203,9 +190,5 @@ export interface FleetConfigurationArgs {
203
190
  * The organization ID. Auto-fetched from the account when not provided. **Cannot be changed after creation.**
204
191
  */
205
192
  organizationId?: pulumi.Input<string | undefined>;
206
- /**
207
- * One or more version blocks. At least one is required. See Nested `version` blocks below.
208
- */
209
- versions: pulumi.Input<pulumi.Input<inputs.FleetConfigurationVersion>[]>;
210
193
  }
211
194
  //# sourceMappingURL=fleetConfiguration.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"fleetConfiguration.d.ts","sourceRoot":"","sources":["../fleetConfiguration.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,MAAM,MAAM,gBAAgB,CAAC;AACzC,OAAO,KAAK,MAAM,MAAM,eAAe,CAAC;AACxC,OAAO,KAAK,OAAO,MAAM,gBAAgB,CAAC;AAG1C;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAmEG;AACH,qBAAa,kBAAmB,SAAQ,MAAM,CAAC,cAAc;IACzD;;;;;;;;OAQG;WACW,GAAG,CAAC,IAAI,EAAE,MAAM,EAAE,EAAE,EAAE,MAAM,CAAC,KAAK,CAAC,MAAM,CAAC,EAAE,CAAC,EAAE,KAAK,CAAC,EAAE,uBAAuB,EAAE,IAAI,CAAC,EAAE,MAAM,CAAC,qBAAqB,GAAG,kBAAkB;IAOtJ;;;OAGG;WACW,UAAU,CAAC,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C;IACnD;;OAEG;IACH,cAAc,CAAC,EAAE,MAAM,CAAC,KAAK,CAAC,MAAM,GAAG,SAAS,CAAC,CAAC;IAClD;;OAEG;IACH,aAAa,CAAC,EAAE,MAAM,CAAC,KAAK,CAAC,MAAM,GAAG,SAAS,CAAC,CAAC;IACjD;;OAEG;IACH,gBAAgB,CAAC,EAAE,MAAM,CAAC,KAAK,CAAC,MAAM,CAAC,KAAK,CAAC,MAAM,CAAC,EAAE,GAAG,SAAS,CAAC,CAAC;CACvE;AAED;;GAEG;AACH,MAAM,WAAW,sBAAsB;IACnC;;OAEG;IACH,SAAS,EAAE,MAAM,CAAC,KAAK,CAAC,MAAM,CAAC,CAAC;IAChC;;OAEG;IACH,oBAAoB,EAAE,MAAM,CAAC,KAAK,CAAC,MAAM,CAAC,CAAC;IAC3C;;OAEG;IACH,iBAAiB,EAAE,MAAM,CAAC,KAAK,CAAC,MAAM,CAAC,CAAC;IACxC;;OAEG;IACH,IAAI,CAAC,EAAE,MAAM,CAAC,KAAK,CAAC,MAAM,GAAG,SAAS,CAAC,CAAC;IACxC;;OAEG;IACH,eAAe,CAAC,EAAE,MAAM,CAAC,KAAK,CAAC,MAAM,GAAG,SAAS,CAAC,CAAC;IACnD;;OAEG;IACH,cAAc,CAAC,EAAE,MAAM,CAAC,KAAK,CAAC,MAAM,GAAG,SAAS,CAAC,CAAC;CACrD"}
@@ -31,7 +31,7 @@ const utilities = __importStar(require("./utilities"));
31
31
  /**
32
32
  * Use this resource to create and manage New Relic fleet configurations for centralized agent management.
33
33
  *
34
- * A fleet configuration defines versioned agent settings deployable to your fleets. Each configuration is specific to an agent type and managed entity type. Versions are immutable - their content cannot be modified after creation. To add a new configuration, add a `version` block; to remove one, delete its block.
34
+ * A fleet configuration holds versioned agent settings. The configuration content is immutable each change to `configurationContent` creates a new version on the API automatically, similar to how AWS launch templates work. The resource ID (the configuration entity GUID) never changes across updates. Use the `newrelic.FleetConfiguration` data source to access the content of a specific historical version.
35
35
  *
36
36
  * ## Example Usage
37
37
  *
@@ -45,45 +45,22 @@ const utilities = __importStar(require("./utilities"));
45
45
  * name: "Production Infrastructure Config",
46
46
  * agentType: "NRInfra",
47
47
  * managedEntityType: "HOST",
48
- * versions: [{
49
- * configurationContent: `log:
48
+ * operatingSystem: "LINUX",
49
+ * configurationContent: `log:
50
50
  * level: info
51
51
  * file: /var/log/newrelic-infra/newrelic-infra.log
52
52
  * metrics:
53
53
  * enabled: true
54
54
  * system_sample_rate: 15
55
55
  * `,
56
- * }],
57
56
  * });
58
57
  * ```
59
58
  *
60
- * ### Version Immutability
59
+ * ## Out-of-band drift warnings
61
60
  *
62
- * Version content is **immutable** - the API does not support updating the content of an existing version. If you attempt to modify `configurationContent` of an already-applied `version` block, Terraform will catch this at plan time and surface an error before any API call is made:
61
+ * If a version is deleted outside of Terraform (UI, API, or another tool), the next `plan` or `refresh` will surface a warning so you understand why state changed:
63
62
  *
64
- * To update the configuration in use:
65
- * - **Add** a new `version` block with the updated content.
66
- * - **Remove** the old `version` block whose content you no longer need.
67
- *
68
- * Terraform applies removals (API deletes) before creates, so if you add and remove a block in the same `apply`, the old version is deleted first and the new one is created after.
69
- *
70
- * ### Unique Content Requirement
71
- *
72
- * All `version` blocks within a resource must have distinct `configurationContent` values. Duplicate content is caught at plan time before any changes are applied:
73
- *
74
- * This also applies to rollback scenarios. If you previously had versions A → B and want to roll back by reintroducing A's content as a new version, add a new `version` block with A's content rather than restoring an old block - the new version will get a new version number from the API.
75
- *
76
- * ### Version Numbering
77
- *
78
- * Version numbers are assigned sequentially by the API and are never reused or renumbered. When you remove a `version` block, the remaining versions keep their original numbers. For example, if you have versions 1, 2, and 3 and remove version 2, the configuration will have versions 1 and 3 - the API does not compact the sequence.
79
- *
80
- * `latestVersionNumber` and `latestVersionEntityId` always reflect the highest-numbered version, regardless of how many versions exist.
81
- *
82
- * ### Externally Deleted Versions
83
- *
84
- * If a version is deleted outside of Terraform (for example, via the API or the New Relic UI), the next `pulumi preview` will show a warning for the affected version:
85
- *
86
- * The warning indicates that Terraform will recreate the missing version on the next `apply`. If the deletion was intentional, remove the corresponding `version` block from your configuration before applying.
63
+ * If the previously-tracked **latest** version was the one deleted, an additional, stronger warning fires explaining that `configurationContent` has been refreshed from the new latest version on the API. If your declared content differs from that new latest, the next `apply` will create a new version restoring your declared content — this is the expected, self-healing behavior.
87
64
  *
88
65
  * ## Import
89
66
  *
@@ -94,7 +71,7 @@ const utilities = __importStar(require("./utilities"));
94
71
  * $ pulumi import newrelic:index/fleetConfiguration:FleetConfiguration infra <configuration_guid>:KUBERNETESCLUSTER
95
72
  * ```
96
73
  *
97
- * The `managedEntityType` portion is required because the New Relic API does not return it via the entity lookup query (a GraphQL schema constraint). All other attributes — `name`, `agentType`, `operatingSystem`, `organizationId` — are resolved automatically from the API.
74
+ * The `managedEntityType` portion is required because the New Relic API does not return it via the entity lookup query (a GraphQL schema constraint). All other attributes — `name`, `agentType`, `operatingSystem`, `organizationId`, `configurationContent` — are resolved automatically from the API.
98
75
  */
99
76
  class FleetConfiguration extends pulumi.CustomResource {
100
77
  /**
@@ -127,6 +104,7 @@ class FleetConfiguration extends pulumi.CustomResource {
127
104
  if (opts.id) {
128
105
  const state = argsOrState;
129
106
  resourceInputs["agentType"] = state?.agentType;
107
+ resourceInputs["configurationContent"] = state?.configurationContent;
130
108
  resourceInputs["configurationId"] = state?.configurationId;
131
109
  resourceInputs["latestVersionEntityId"] = state?.latestVersionEntityId;
132
110
  resourceInputs["latestVersionNumber"] = state?.latestVersionNumber;
@@ -135,29 +113,30 @@ class FleetConfiguration extends pulumi.CustomResource {
135
113
  resourceInputs["operatingSystem"] = state?.operatingSystem;
136
114
  resourceInputs["organizationId"] = state?.organizationId;
137
115
  resourceInputs["totalVersions"] = state?.totalVersions;
138
- resourceInputs["versions"] = state?.versions;
116
+ resourceInputs["versionEntityIds"] = state?.versionEntityIds;
139
117
  }
140
118
  else {
141
119
  const args = argsOrState;
142
120
  if (args?.agentType === undefined && !opts.urn) {
143
121
  throw new Error("Missing required property 'agentType'");
144
122
  }
123
+ if (args?.configurationContent === undefined && !opts.urn) {
124
+ throw new Error("Missing required property 'configurationContent'");
125
+ }
145
126
  if (args?.managedEntityType === undefined && !opts.urn) {
146
127
  throw new Error("Missing required property 'managedEntityType'");
147
128
  }
148
- if (args?.versions === undefined && !opts.urn) {
149
- throw new Error("Missing required property 'versions'");
150
- }
151
129
  resourceInputs["agentType"] = args?.agentType;
130
+ resourceInputs["configurationContent"] = args?.configurationContent;
152
131
  resourceInputs["managedEntityType"] = args?.managedEntityType;
153
132
  resourceInputs["name"] = args?.name;
154
133
  resourceInputs["operatingSystem"] = args?.operatingSystem;
155
134
  resourceInputs["organizationId"] = args?.organizationId;
156
- resourceInputs["versions"] = args?.versions;
157
135
  resourceInputs["configurationId"] = undefined /*out*/;
158
136
  resourceInputs["latestVersionEntityId"] = undefined /*out*/;
159
137
  resourceInputs["latestVersionNumber"] = undefined /*out*/;
160
138
  resourceInputs["totalVersions"] = undefined /*out*/;
139
+ resourceInputs["versionEntityIds"] = undefined /*out*/;
161
140
  }
162
141
  opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts);
163
142
  super(FleetConfiguration.__pulumiType, name, resourceInputs, opts);
@@ -1 +1 @@
1
- {"version":3,"file":"fleetConfiguration.js","sourceRoot":"","sources":["../fleetConfiguration.ts"],"names":[],"mappings":";AAAA,sEAAsE;AACtE,iFAAiF;;;;;;;;;;;;;;;;;;;;;;;;;;AAEjF,uDAAyC;AAGzC,uDAAyC;AAEzC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAmEG;AACH,MAAa,kBAAmB,SAAQ,MAAM,CAAC,cAAc;IACzD;;;;;;;;OAQG;IACI,MAAM,CAAC,GAAG,CAAC,IAAY,EAAE,EAA2B,EAAE,KAA+B,EAAE,IAAmC;QAC7H,OAAO,IAAI,kBAAkB,CAAC,IAAI,EAAO,KAAK,E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e,CAAC;YAC1D,cAAc,CAAC,gBAAgB,CAAC,GAAG,IAAI,EAAE,cAAc,CAAC;YACxD,cAAc,CAAC,iBAAiB,CAAC,GAAG,SAAS,CAAC,OAAO,CAAC;YACtD,cAAc,CAAC,uBAAuB,CAAC,GAAG,SAAS,CAAC,OAAO,CAAC;YAC5D,cAAc,CAAC,qBAAqB,CAAC,GAAG,SAAS,CAAC,OAAO,CAAC;YAC1D,cAAc,CAAC,eAAe,CAAC,GAAG,SAAS,CAAC,OAAO,CAAC;YACpD,cAAc,CAAC,kBAAkB,CAAC,GAAG,SAAS,CAAC,OAAO,CAAC;SAC1D;QACD,IAAI,GAAG,MAAM,CAAC,YAAY,CAAC,SAAS,CAAC,oBAAoB,EAAE,EAAE,IAAI,CAAC,CAAC;QACnE,KAAK,CAAC,kBAAkB,CAAC,YAAY,EAAE,IAAI,EAAE,cAAc,EAAE,IAAI,CAAC,CAAC;IACvE,CAAC;;AA1HL,gDA2HC"}
@@ -4,9 +4,9 @@ import * as outputs from "./types/output";
4
4
  /**
5
5
  * Use this resource to create and manage New Relic fleet deployments.
6
6
  *
7
- * A fleet deployment defines the agent versions and optional configuration versions to roll out to a fleet. Each deployment belongs to a fleet and contains one or more `agent` blocks describing which agent type and version to deploy, and optionally which configuration version (from `newrelic.FleetConfiguration`) to apply.
7
+ * A fleet deployment defines the agent versions and configuration versions to roll out to a fleet. Each deployment belongs to a fleet and may contain zero or more `agent` blocks describing which agent type and version to deploy and which configuration version (from `newrelic.FleetConfiguration`) to apply.
8
8
  *
9
- * > **Note:** Deployments can only be updated while in the `CREATED` phase. Once the fleet backend begins executing the deployment (phase advances to `IN_PROGRESS`, `FAILED`, or `COMPLETED`), any attempt to change `name`, `description`, `agent`, or `tags` will be **blocked at plan time** with an error. Run `terraform destroy` to remove the deployment from state and then re-create it with the desired configuration. If `terraform destroy` itself fails because the deployment is actively executing, the resource will be removed from Terraform state with a warning once the deployment reaches a terminal phase (`COMPLETED` or `FAILED`) you can clean it up manually in the New Relic UI.
9
+ * > **Note: Phase-gate immutability.** Deployments can only be modified while in the `CREATED` phase. Once the fleet backend begins executing the deployment (phase advances to `IN_PROGRESS`, `FAILED`, or `COMPLETED`), any attempt to change `name`, `description`, `agent`, or `tags` is **blocked at plan time** with a clear error. The recommended recovery path is `terraform state rm <resource_address>` (or a `removed` block) to drop the executed deployment from Terraform state, then re-declare a fresh deployment with the desired configuration. `terraform destroy` works only if you have no pending changes to the deployment in your HCLotherwise the same plan-time gate fires during the destroy plan.
10
10
  *
11
11
  * ## Example Usage
12
12
  *
@@ -16,32 +16,14 @@ import * as outputs from "./types/output";
16
16
  * import * as pulumi from "@pulumi/pulumi";
17
17
  * import * as newrelic from "@pulumi/newrelic";
18
18
  *
19
- * const infra = new newrelic.FleetDeployment("infra", {
20
- * fleetId: prod.id,
21
- * name: "Production Infra Deployment",
22
- * description: "Deploys NRInfra v1.58.0 to the production fleet",
23
- * agents: [{
24
- * agentType: "NRInfra",
25
- * version: "1.58.0",
26
- * }],
27
- * });
28
- * ```
29
- *
30
- * ### Deployment Linked to a Configuration Version
31
- *
32
- * ```typescript
33
- * import * as pulumi from "@pulumi/pulumi";
34
- * import * as newrelic from "@pulumi/newrelic";
35
- *
36
19
  * const infraCfg = new newrelic.FleetConfiguration("infra_cfg", {
37
20
  * name: "Production Infra Config",
38
21
  * agentType: "NRInfra",
39
22
  * managedEntityType: "HOST",
40
- * versions: [{
41
- * configurationContent: `log:
23
+ * operatingSystem: "LINUX",
24
+ * configurationContent: `log:
42
25
  * level: info
43
26
  * `,
44
- * }],
45
27
  * });
46
28
  * const infra = new newrelic.FleetDeployment("infra", {
47
29
  * fleetId: prod.id,
@@ -57,6 +39,8 @@ import * as outputs from "./types/output";
57
39
  *
58
40
  * ### Multiple Agents
59
41
  *
42
+ * Each `agentType` may appear at most once per deployment.
43
+ *
60
44
  * ```typescript
61
45
  * import * as pulumi from "@pulumi/pulumi";
62
46
  * import * as newrelic from "@pulumi/newrelic";
@@ -73,11 +57,47 @@ import * as outputs from "./types/output";
73
57
  * {
74
58
  * agentType: "FluentBit",
75
59
  * version: "3.2.0",
60
+ * configurationVersionId: fbCfg.latestVersionEntityId,
76
61
  * },
77
62
  * ],
78
63
  * });
79
64
  * ```
80
65
  *
66
+ * ### Zero-Agent Deployment
67
+ *
68
+ * A deployment can be created or updated with zero `agent` blocks — for example, to drain all agent assignments from an existing deployment, or to seed a deployment record that will have agents added later (while still in `CREATED` phase).
69
+ *
70
+ * ```typescript
71
+ * import * as pulumi from "@pulumi/pulumi";
72
+ * import * as newrelic from "@pulumi/newrelic";
73
+ *
74
+ * const drained = new newrelic.FleetDeployment("drained", {
75
+ * fleetId: prod.id,
76
+ * name: "Drained deployment",
77
+ * });
78
+ * ```
79
+ *
80
+ * ### Pinning to a Specific Configuration Version
81
+ *
82
+ * By default, referencing `newrelic_fleet_configuration.<name>.latest_version_entity_id` ties the deployment to whichever version is current at plan time. Updating the configuration's `configurationContent` will change `latestVersionEntityId`, which in turn proposes an update to any deployment referencing it. If the deployment has already left `CREATED`, that update will be **blocked by the phase-gate** — see the note above.
83
+ *
84
+ * For long-lived deployments that should remain stable, pin to a specific historical version instead:
85
+ *
86
+ * ```typescript
87
+ * import * as pulumi from "@pulumi/pulumi";
88
+ * import * as newrelic from "@pulumi/newrelic";
89
+ *
90
+ * const pinned = new newrelic.FleetDeployment("pinned", {
91
+ * fleetId: prod.id,
92
+ * name: "Stable v1 rollout",
93
+ * agents: [{
94
+ * agentType: "NRInfra",
95
+ * version: "1.58.0",
96
+ * configurationVersionId: infraCfg.versionEntityIds[0],
97
+ * }],
98
+ * });
99
+ * ```
100
+ *
81
101
  * ### With Tags
82
102
  *
83
103
  * ```typescript
@@ -90,6 +110,7 @@ import * as outputs from "./types/output";
90
110
  * agents: [{
91
111
  * agentType: "NRInfra",
92
112
  * version: "1.58.0",
113
+ * configurationVersionId: infraCfg.latestVersionEntityId,
93
114
  * }],
94
115
  * tags: [
95
116
  * "environment:production",
@@ -123,7 +144,7 @@ export declare class FleetDeployment extends pulumi.CustomResource {
123
144
  */
124
145
  static isInstance(obj: any): obj is FleetDeployment;
125
146
  /**
126
- * One or more agent blocks. At least one is required when creating a deployment. On update, the list may be set to empty (`agent = []`) to uninstall all agent assignments from the deployment. Each `agentType` may appear at most once per deployment. See Nested `agent` blocks below.
147
+ * Zero or more `agent` blocks. An empty list is accepted on both create and update useful to drain agent assignments. Each `agentType` may appear at most once per deployment. See Nested `agent` blocks below.
127
148
  */
128
149
  readonly agents: pulumi.Output<outputs.FleetDeploymentAgent[] | undefined>;
129
150
  /**
@@ -139,7 +160,7 @@ export declare class FleetDeployment extends pulumi.CustomResource {
139
160
  */
140
161
  readonly fleetId: pulumi.Output<string>;
141
162
  /**
142
- * The name of the deployment.
163
+ * The name of the deployment. Updatable while the deployment is in `CREATED` phase.
143
164
  */
144
165
  readonly name: pulumi.Output<string>;
145
166
  /**
@@ -168,7 +189,7 @@ export declare class FleetDeployment extends pulumi.CustomResource {
168
189
  */
169
190
  export interface FleetDeploymentState {
170
191
  /**
171
- * One or more agent blocks. At least one is required when creating a deployment. On update, the list may be set to empty (`agent = []`) to uninstall all agent assignments from the deployment. Each `agentType` may appear at most once per deployment. See Nested `agent` blocks below.
192
+ * Zero or more `agent` blocks. An empty list is accepted on both create and update useful to drain agent assignments. Each `agentType` may appear at most once per deployment. See Nested `agent` blocks below.
172
193
  */
173
194
  agents?: pulumi.Input<pulumi.Input<inputs.FleetDeploymentAgent>[] | undefined>;
174
195
  /**
@@ -184,7 +205,7 @@ export interface FleetDeploymentState {
184
205
  */
185
206
  fleetId?: pulumi.Input<string | undefined>;
186
207
  /**
187
- * The name of the deployment.
208
+ * The name of the deployment. Updatable while the deployment is in `CREATED` phase.
188
209
  */
189
210
  name?: pulumi.Input<string | undefined>;
190
211
  /**
@@ -205,7 +226,7 @@ export interface FleetDeploymentState {
205
226
  */
206
227
  export interface FleetDeploymentArgs {
207
228
  /**
208
- * One or more agent blocks. At least one is required when creating a deployment. On update, the list may be set to empty (`agent = []`) to uninstall all agent assignments from the deployment. Each `agentType` may appear at most once per deployment. See Nested `agent` blocks below.
229
+ * Zero or more `agent` blocks. An empty list is accepted on both create and update useful to drain agent assignments. Each `agentType` may appear at most once per deployment. See Nested `agent` blocks below.
209
230
  */
210
231
  agents?: pulumi.Input<pulumi.Input<inputs.FleetDeploymentAgent>[] | undefined>;
211
232
  /**
@@ -217,7 +238,7 @@ export interface FleetDeploymentArgs {
217
238
  */
218
239
  fleetId: pulumi.Input<string>;
219
240
  /**
220
- * The name of the deployment.
241
+ * The name of the deployment. Updatable while the deployment is in `CREATED` phase.
221
242
  */
222
243
  name?: pulumi.Input<string | undefined>;
223
244
  /**
@@ -1 +1 @@
1
- {"version":3,"file":"fleetDeployment.d.ts","sourceRoot":"","sources":["../fleetDeployment.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,MAAM,MAAM,gBAAgB,CAAC;AACzC,OAAO,KAAK,MAAM,MAAM,eAAe,CAAC;AACxC,OAAO,KAAK,OAAO,MAAM,gBAAgB,CAAC;AAG1C;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAwGG;AACH,qBAAa,eAAgB,SAAQ,MAAM,CAAC,cAAc;IACtD;;;;;;;;OAQG;WACW,GAAG,CAAC,IAAI,EAAE,MAAM,EAAE,EAAE,EAAE,MAAM,CAAC,KAAK,CAAC,MAAM,CAAC,EAAE,CAAC,EAAE,KAAK,CAAC,EAAE,oBAAoB,EAAE,IAAI,CAAC,EAAE,MAAM,CAAC,qBAAqB,GAAG,eAAe;IAOhJ;;;OAGG;WACW,UAAU,CAAC,GAAG,EAAE,GAAG,GAAG,GAAG,IAAI,eAAe;IAO1D;;OAEG;IACH,SAAwB,MAAM,EAAE,MAAM,CAAC,MAAM,CAAC,OAAO,CAAC,oBAAoB,EAAE,GAAG,SAAS,CAA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