Skip to content

Commit dff0e08

Browse files
committed
chore: update to clickhouse terraform provider 0.3.0
1 parent 5259360 commit dff0e08

File tree

7 files changed

+224
-48
lines changed

7 files changed

+224
-48
lines changed

Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ PROJECT := github.com/pulumiverse/pulumi-clickhouse
44
NODE_MODULE_NAME := @pulumiverse/clickhouse
55
TF_NAME := clickhouse
66
PROVIDER_PATH := provider
7-
PROVIDER_VERSION := 0.0.10
7+
PROVIDER_VERSION := 0.3.0
88
VERSION_PATH := ${PROVIDER_PATH}/pkg/version.Version
99

1010
JAVA_GEN := pulumi-java-gen

provider/cmd/pulumi-resource-clickhouse/schema.json

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -245,6 +245,7 @@
245245
}
246246
},
247247
"clickhouse:index/service:Service": {
248+
"description": "## Example Usage\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as clickhouse from \"@pulumiverse/clickhouse\";\n\nconst service = new clickhouse.Service(\"service\", {\n cloudProvider: \"aws\",\n idleScaling: true,\n idleTimeoutMinutes: 5,\n ipAccesses: [{\n description: \"Test IP\",\n source: \"192.168.2.63\",\n }],\n maxTotalMemoryGb: 360,\n minTotalMemoryGb: 24,\n passwordHash: \"n4bQgYhMfWWaL+qgxVrQFaO/TxsrC4Is0V1sFbDwCgg=\",\n region: \"us-east-1\",\n tier: \"production\",\n});\n```\n```python\nimport pulumi\nimport pulumiverse_clickhouse as clickhouse\n\nservice = clickhouse.Service(\"service\",\n cloud_provider=\"aws\",\n idle_scaling=True,\n idle_timeout_minutes=5,\n ip_accesses=[clickhouse.ServiceIpAccessArgs(\n description=\"Test IP\",\n source=\"192.168.2.63\",\n )],\n max_total_memory_gb=360,\n min_total_memory_gb=24,\n password_hash=\"n4bQgYhMfWWaL+qgxVrQFaO/TxsrC4Is0V1sFbDwCgg=\",\n region=\"us-east-1\",\n tier=\"production\")\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing Clickhouse = Pulumiverse.Clickhouse;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var service = new Clickhouse.Service(\"service\", new()\n {\n CloudProvider = \"aws\",\n IdleScaling = true,\n IdleTimeoutMinutes = 5,\n IpAccesses = new[]\n {\n new Clickhouse.Inputs.ServiceIpAccessArgs\n {\n Description = \"Test IP\",\n Source = \"192.168.2.63\",\n },\n },\n MaxTotalMemoryGb = 360,\n MinTotalMemoryGb = 24,\n PasswordHash = \"n4bQgYhMfWWaL+qgxVrQFaO/TxsrC4Is0V1sFbDwCgg=\",\n Region = \"us-east-1\",\n Tier = \"production\",\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n\t\"github.com/pulumiverse/pulumi-clickhouse/sdk/go/clickhouse\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := clickhouse.NewService(ctx, \"service\", \u0026clickhouse.ServiceArgs{\n\t\t\tCloudProvider: pulumi.String(\"aws\"),\n\t\t\tIdleScaling: pulumi.Bool(true),\n\t\t\tIdleTimeoutMinutes: pulumi.Int(5),\n\t\t\tIpAccesses: clickhouse.ServiceIpAccessArray{\n\t\t\t\t\u0026clickhouse.ServiceIpAccessArgs{\n\t\t\t\t\tDescription: pulumi.String(\"Test IP\"),\n\t\t\t\t\tSource: pulumi.String(\"192.168.2.63\"),\n\t\t\t\t},\n\t\t\t},\n\t\t\tMaxTotalMemoryGb: pulumi.Int(360),\n\t\t\tMinTotalMemoryGb: pulumi.Int(24),\n\t\t\tPasswordHash: pulumi.String(\"n4bQgYhMfWWaL+qgxVrQFaO/TxsrC4Is0V1sFbDwCgg=\"),\n\t\t\tRegion: pulumi.String(\"us-east-1\"),\n\t\t\tTier: pulumi.String(\"production\"),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\treturn nil\n\t})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.clickhouse.Service;\nimport com.pulumi.clickhouse.ServiceArgs;\nimport com.pulumi.clickhouse.inputs.ServiceIpAccessArgs;\nimport java.util.List;\nimport java.util.ArrayList;\nimport java.util.Map;\nimport java.io.File;\nimport java.nio.file.Files;\nimport java.nio.file.Paths;\n\npublic class App {\n public static void main(String[] args) {\n Pulumi.run(App::stack);\n }\n\n public static void stack(Context ctx) {\n var service = new Service(\"service\", ServiceArgs.builder()\n .cloudProvider(\"aws\")\n .idleScaling(true)\n .idleTimeoutMinutes(5)\n .ipAccesses(ServiceIpAccessArgs.builder()\n .description(\"Test IP\")\n .source(\"192.168.2.63\")\n .build())\n .maxTotalMemoryGb(360)\n .minTotalMemoryGb(24)\n .passwordHash(\"n4bQgYhMfWWaL+qgxVrQFaO/TxsrC4Is0V1sFbDwCgg=\")\n .region(\"us-east-1\")\n .tier(\"production\")\n .build());\n\n }\n}\n```\n```yaml\nresources:\n service:\n type: clickhouse:Service\n properties:\n cloudProvider: aws\n idleScaling: true\n idleTimeoutMinutes: 5\n ipAccesses:\n - description: Test IP\n source: 192.168.2.63\n maxTotalMemoryGb: 360\n minTotalMemoryGb: 24\n passwordHash: n4bQgYhMfWWaL+qgxVrQFaO/TxsrC4Is0V1sFbDwCgg=\n # base64 encoded sha256 hash of \"test\"\n region: us-east-1\n tier: production\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n## Import\n\nServices can be imported by specifying the UUID.\n\n```sh\n$ pulumi import clickhouse:index/service:Service example xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx\n```\n\n",
248249
"properties": {
249250
"cloudProvider": {
250251
"type": "string",
@@ -276,11 +277,11 @@
276277
},
277278
"idleScaling": {
278279
"type": "boolean",
279-
"description": "When set to true the service is allowed to scale down to zero when idle. Always true for development services. Configurable only for 'production' services.\n"
280+
"description": "When set to true the service is allowed to scale down to zero when idle.\n"
280281
},
281282
"idleTimeoutMinutes": {
282283
"type": "integer",
283-
"description": "Set minimum idling timeout (in minutes). Available only for 'production' services. Must be greater than or equal to 5 minutes.\n"
284+
"description": "Set minimum idling timeout (in minutes). Must be greater than or equal to 5 minutes. Must be set if idle_scaling is enabled\n"
284285
},
285286
"ipAccesses": {
286287
"type": "array",
@@ -367,11 +368,11 @@
367368
},
368369
"idleScaling": {
369370
"type": "boolean",
370-
"description": "When set to true the service is allowed to scale down to zero when idle. Always true for development services. Configurable only for 'production' services.\n"
371+
"description": "When set to true the service is allowed to scale down to zero when idle.\n"
371372
},
372373
"idleTimeoutMinutes": {
373374
"type": "integer",
374-
"description": "Set minimum idling timeout (in minutes). Available only for 'production' services. Must be greater than or equal to 5 minutes.\n"
375+
"description": "Set minimum idling timeout (in minutes). Must be greater than or equal to 5 minutes. Must be set if idle_scaling is enabled\n"
375376
},
376377
"ipAccesses": {
377378
"type": "array",
@@ -457,11 +458,11 @@
457458
},
458459
"idleScaling": {
459460
"type": "boolean",
460-
"description": "When set to true the service is allowed to scale down to zero when idle. Always true for development services. Configurable only for 'production' services.\n"
461+
"description": "When set to true the service is allowed to scale down to zero when idle.\n"
461462
},
462463
"idleTimeoutMinutes": {
463464
"type": "integer",
464-
"description": "Set minimum idling timeout (in minutes). Available only for 'production' services. Must be greater than or equal to 5 minutes.\n"
465+
"description": "Set minimum idling timeout (in minutes). Must be greater than or equal to 5 minutes. Must be set if idle_scaling is enabled\n"
465466
},
466467
"ipAccesses": {
467468
"type": "array",

sdk/dotnet/Service.cs

Lines changed: 48 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,48 @@
1010

1111
namespace Pulumiverse.Clickhouse
1212
{
13+
/// <summary>
14+
/// ## Example Usage
15+
///
16+
/// ```csharp
17+
/// using System.Collections.Generic;
18+
/// using System.Linq;
19+
/// using Pulumi;
20+
/// using Clickhouse = Pulumiverse.Clickhouse;
21+
///
22+
/// return await Deployment.RunAsync(() =&gt;
23+
/// {
24+
/// var service = new Clickhouse.Service("service", new()
25+
/// {
26+
/// CloudProvider = "aws",
27+
/// IdleScaling = true,
28+
/// IdleTimeoutMinutes = 5,
29+
/// IpAccesses = new[]
30+
/// {
31+
/// new Clickhouse.Inputs.ServiceIpAccessArgs
32+
/// {
33+
/// Description = "Test IP",
34+
/// Source = "192.168.2.63",
35+
/// },
36+
/// },
37+
/// MaxTotalMemoryGb = 360,
38+
/// MinTotalMemoryGb = 24,
39+
/// PasswordHash = "n4bQgYhMfWWaL+qgxVrQFaO/TxsrC4Is0V1sFbDwCgg=",
40+
/// Region = "us-east-1",
41+
/// Tier = "production",
42+
/// });
43+
///
44+
/// });
45+
/// ```
46+
///
47+
/// ## Import
48+
///
49+
/// Services can be imported by specifying the UUID.
50+
///
51+
/// ```sh
52+
/// $ pulumi import clickhouse:index/service:Service example xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx
53+
/// ```
54+
/// </summary>
1355
[ClickhouseResourceType("clickhouse:index/service:Service")]
1456
public partial class Service : global::Pulumi.CustomResource
1557
{
@@ -50,13 +92,13 @@ public partial class Service : global::Pulumi.CustomResource
5092
public Output<string> IamRole { get; private set; } = null!;
5193

5294
/// <summary>
53-
/// When set to true the service is allowed to scale down to zero when idle. Always true for development services. Configurable only for 'production' services.
95+
/// When set to true the service is allowed to scale down to zero when idle.
5496
/// </summary>
5597
[Output("idleScaling")]
5698
public Output<bool?> IdleScaling { get; private set; } = null!;
5799

58100
/// <summary>
59-
/// Set minimum idling timeout (in minutes). Available only for 'production' services. Must be greater than or equal to 5 minutes.
101+
/// Set minimum idling timeout (in minutes). Must be greater than or equal to 5 minutes. Must be set if idle_scaling is enabled
60102
/// </summary>
61103
[Output("idleTimeoutMinutes")]
62104
public Output<int?> IdleTimeoutMinutes { get; private set; } = null!;
@@ -212,13 +254,13 @@ public Input<string>? DoubleSha1PasswordHash
212254
public Input<string>? EncryptionKey { get; set; }
213255

214256
/// <summary>
215-
/// When set to true the service is allowed to scale down to zero when idle. Always true for development services. Configurable only for 'production' services.
257+
/// When set to true the service is allowed to scale down to zero when idle.
216258
/// </summary>
217259
[Input("idleScaling")]
218260
public Input<bool>? IdleScaling { get; set; }
219261

220262
/// <summary>
221-
/// Set minimum idling timeout (in minutes). Available only for 'production' services. Must be greater than or equal to 5 minutes.
263+
/// Set minimum idling timeout (in minutes). Must be greater than or equal to 5 minutes. Must be set if idle_scaling is enabled
222264
/// </summary>
223265
[Input("idleTimeoutMinutes")]
224266
public Input<int>? IdleTimeoutMinutes { get; set; }
@@ -370,13 +412,13 @@ public InputList<Inputs.ServiceEndpointGetArgs> Endpoints
370412
public Input<string>? IamRole { get; set; }
371413

372414
/// <summary>
373-
/// When set to true the service is allowed to scale down to zero when idle. Always true for development services. Configurable only for 'production' services.
415+
/// When set to true the service is allowed to scale down to zero when idle.
374416
/// </summary>
375417
[Input("idleScaling")]
376418
public Input<bool>? IdleScaling { get; set; }
377419

378420
/// <summary>
379-
/// Set minimum idling timeout (in minutes). Available only for 'production' services. Must be greater than or equal to 5 minutes.
421+
/// Set minimum idling timeout (in minutes). Must be greater than or equal to 5 minutes. Must be set if idle_scaling is enabled
380422
/// </summary>
381423
[Input("idleTimeoutMinutes")]
382424
public Input<int>? IdleTimeoutMinutes { get; set; }

sdk/go/clickhouse/service.go

Lines changed: 58 additions & 12 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)