From 620a880ddfd7ffb500085f26b50a96ff25ea4377 Mon Sep 17 00:00:00 2001 From: Bob Lee Date: Wed, 11 Dec 2024 17:09:38 -0500 Subject: [PATCH] make build_sdks --- .../cmd/pulumi-resource-twingate/schema.json | 2 +- sdk/dotnet/GetTwingateRemoteNetwork.cs | 9 +++- ...ingateRemoteNetworksRemoteNetworkResult.cs | 9 +++- sdk/dotnet/TwingateRemoteNetwork.cs | 18 +++++++ sdk/go/twingate/getTwingateRemoteNetwork.go | 7 +++ sdk/go/twingate/pulumiTypes.go | 9 ++++ sdk/go/twingate/twingateRemoteNetwork.go | 15 ++++++ sdk/nodejs/getTwingateRemoteNetwork.ts | 4 ++ sdk/nodejs/twingateRemoteNetwork.ts | 14 +++++ sdk/nodejs/types/output.ts | 4 ++ .../get_twingate_remote_network.py | 22 ++++++-- sdk/python/pulumi_twingate/outputs.py | 11 ++++ .../twingate_remote_network.py | 53 +++++++++++++++++-- 13 files changed, 167 insertions(+), 10 deletions(-) diff --git a/provider/cmd/pulumi-resource-twingate/schema.json b/provider/cmd/pulumi-resource-twingate/schema.json index 2ffba5c..bcaa2b7 100644 --- a/provider/cmd/pulumi-resource-twingate/schema.json +++ b/provider/cmd/pulumi-resource-twingate/schema.json @@ -1688,7 +1688,7 @@ } }, "twingate:index/twingateServiceAccountKey:TwingateServiceAccountKey": { - "description": "A Service Key authorizes access to all Resources assigned to a Service Account.\n\n## Example Usage\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as time from \"@pulumi/time\";\nimport * as twingate from \"@twingate/pulumi-twingate\";\n\nconst githubActionsProd = new twingate.TwingateServiceAccount(\"githubActionsProd\", {});\nconst githubKey = new twingate.TwingateServiceAccountKey(\"githubKey\", {serviceAccountId: githubActionsProd.id});\n// Key rotation using the time provider (see https://registry.terraform.io/providers/hashicorp/time/latest)\nconst keyRotationtime_rotating = new time.index.Time_rotating(\"keyRotationtime_rotating\", {rotationDays: 30});\nconst keyRotationtime_static = new time.index.Time_static(\"keyRotationtime_static\", {rfc3339: keyRotationtime_rotating.rfc3339});\nconst githubKeyWithRotation = new twingate.TwingateServiceAccountKey(\"githubKeyWithRotation\", {serviceAccountId: githubActionsProd.id});\n```\n```python\nimport pulumi\nimport pulumi_twingate as twingate\nimport pulumiverse_time as time\n\ngithub_actions_prod = twingate.TwingateServiceAccount(\"githubActionsProd\")\ngithub_key = twingate.TwingateServiceAccountKey(\"githubKey\", service_account_id=github_actions_prod.id)\n# Key rotation using the time provider (see https://registry.terraform.io/providers/hashicorp/time/latest)\nkey_rotation_rotating = time.Rotating(\"keyRotationRotating\", rotation_days=30)\nkey_rotation_static = time.Static(\"keyRotationStatic\", rfc3339=key_rotation_rotating.rfc3339)\ngithub_key_with_rotation = twingate.TwingateServiceAccountKey(\"githubKeyWithRotation\", service_account_id=github_actions_prod.id)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing Time = Pulumiverse.Time;\nusing Twingate = Twingate.Twingate;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var githubActionsProd = new Twingate.TwingateServiceAccount(\"githubActionsProd\");\n\n var githubKey = new Twingate.TwingateServiceAccountKey(\"githubKey\", new()\n {\n ServiceAccountId = githubActionsProd.Id,\n });\n\n // Key rotation using the time provider (see https://registry.terraform.io/providers/hashicorp/time/latest)\n var keyRotationRotating = new Time.Rotating(\"keyRotationRotating\", new()\n {\n RotationDays = 30,\n });\n\n var keyRotationStatic = new Time.Static(\"keyRotationStatic\", new()\n {\n Rfc3339 = keyRotationRotating.Rfc3339,\n });\n\n var githubKeyWithRotation = new Twingate.TwingateServiceAccountKey(\"githubKeyWithRotation\", new()\n {\n ServiceAccountId = githubActionsProd.Id,\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/Twingate/pulumi-twingate/sdk/v3/go/twingate\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n\t\"github.com/pulumiverse/pulumi-time/sdk/go/time\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tgithubActionsProd, err := twingate.NewTwingateServiceAccount(ctx, \"githubActionsProd\", nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = twingate.NewTwingateServiceAccountKey(ctx, \"githubKey\", \u0026twingate.TwingateServiceAccountKeyArgs{\n\t\t\tServiceAccountId: githubActionsProd.ID(),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tkeyRotationRotating, err := time.NewRotating(ctx, \"keyRotationRotating\", \u0026time.RotatingArgs{\n\t\t\tRotationDays: pulumi.Int(30),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = time.NewStatic(ctx, \"keyRotationStatic\", \u0026time.StaticArgs{\n\t\t\tRfc3339: keyRotationRotating.Rfc3339,\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = twingate.NewTwingateServiceAccountKey(ctx, \"githubKeyWithRotation\", \u0026twingate.TwingateServiceAccountKeyArgs{\n\t\t\tServiceAccountId: githubActionsProd.ID(),\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.twingate.TwingateServiceAccount;\nimport com.pulumi.twingate.TwingateServiceAccountKey;\nimport com.pulumi.twingate.TwingateServiceAccountKeyArgs;\nimport com.pulumi.time.Rotating;\nimport com.pulumi.time.RotatingArgs;\nimport com.pulumi.time.Static;\nimport com.pulumi.time.StaticArgs;\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 githubActionsProd = new TwingateServiceAccount(\"githubActionsProd\");\n\n var githubKey = new TwingateServiceAccountKey(\"githubKey\", TwingateServiceAccountKeyArgs.builder()\n .serviceAccountId(githubActionsProd.id())\n .build());\n\n // Key rotation using the time provider (see https://registry.terraform.io/providers/hashicorp/time/latest)\n var keyRotationRotating = new Rotating(\"keyRotationRotating\", RotatingArgs.builder()\n .rotationDays(30)\n .build());\n\n var keyRotationStatic = new Static(\"keyRotationStatic\", StaticArgs.builder()\n .rfc3339(keyRotationRotating.rfc3339())\n .build());\n\n var githubKeyWithRotation = new TwingateServiceAccountKey(\"githubKeyWithRotation\", TwingateServiceAccountKeyArgs.builder()\n .serviceAccountId(githubActionsProd.id())\n .build());\n\n }\n}\n```\n```yaml\nresources:\n githubActionsProd:\n type: twingate:TwingateServiceAccount\n githubKey: # Key rotation using the time provider (see https://registry.terraform.io/providers/hashicorp/time/latest)\n type: twingate:TwingateServiceAccountKey\n properties:\n serviceAccountId: ${githubActionsProd.id}\n keyRotationRotating:\n type: time:Rotating\n properties:\n rotationDays: 30\n keyRotationStatic:\n type: time:Static\n properties:\n rfc3339: ${keyRotationRotating.rfc3339}\n githubKeyWithRotation:\n type: twingate:TwingateServiceAccountKey\n properties:\n serviceAccountId: ${githubActionsProd.id}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n", + "description": "A Service Key authorizes access to all Resources assigned to a Service Account.\n\n## Example Usage\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as time from \"@pulumiverse/time\";\nimport * as twingate from \"@twingate/pulumi-twingate\";\n\nconst githubActionsProd = new twingate.TwingateServiceAccount(\"githubActionsProd\", {});\nconst githubKey = new twingate.TwingateServiceAccountKey(\"githubKey\", {serviceAccountId: githubActionsProd.id});\n// Key rotation using the time provider (see https://registry.terraform.io/providers/hashicorp/time/latest)\nconst keyRotationRotating = new time.Rotating(\"keyRotationRotating\", {rotationDays: 30});\nconst keyRotationStatic = new time.Static(\"keyRotationStatic\", {rfc3339: keyRotationRotating.rfc3339});\nconst githubKeyWithRotation = new twingate.TwingateServiceAccountKey(\"githubKeyWithRotation\", {serviceAccountId: githubActionsProd.id});\n```\n```python\nimport pulumi\nimport pulumi_twingate as twingate\nimport pulumiverse_time as time\n\ngithub_actions_prod = twingate.TwingateServiceAccount(\"githubActionsProd\")\ngithub_key = twingate.TwingateServiceAccountKey(\"githubKey\", service_account_id=github_actions_prod.id)\n# Key rotation using the time provider (see https://registry.terraform.io/providers/hashicorp/time/latest)\nkey_rotation_rotating = time.Rotating(\"keyRotationRotating\", rotation_days=30)\nkey_rotation_static = time.Static(\"keyRotationStatic\", rfc3339=key_rotation_rotating.rfc3339)\ngithub_key_with_rotation = twingate.TwingateServiceAccountKey(\"githubKeyWithRotation\", service_account_id=github_actions_prod.id)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing Time = Pulumiverse.Time;\nusing Twingate = Twingate.Twingate;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var githubActionsProd = new Twingate.TwingateServiceAccount(\"githubActionsProd\");\n\n var githubKey = new Twingate.TwingateServiceAccountKey(\"githubKey\", new()\n {\n ServiceAccountId = githubActionsProd.Id,\n });\n\n // Key rotation using the time provider (see https://registry.terraform.io/providers/hashicorp/time/latest)\n var keyRotationRotating = new Time.Rotating(\"keyRotationRotating\", new()\n {\n RotationDays = 30,\n });\n\n var keyRotationStatic = new Time.Static(\"keyRotationStatic\", new()\n {\n Rfc3339 = keyRotationRotating.Rfc3339,\n });\n\n var githubKeyWithRotation = new Twingate.TwingateServiceAccountKey(\"githubKeyWithRotation\", new()\n {\n ServiceAccountId = githubActionsProd.Id,\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/Twingate/pulumi-twingate/sdk/v3/go/twingate\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n\t\"github.com/pulumiverse/pulumi-time/sdk/go/time\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tgithubActionsProd, err := twingate.NewTwingateServiceAccount(ctx, \"githubActionsProd\", nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = twingate.NewTwingateServiceAccountKey(ctx, \"githubKey\", \u0026twingate.TwingateServiceAccountKeyArgs{\n\t\t\tServiceAccountId: githubActionsProd.ID(),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tkeyRotationRotating, err := time.NewRotating(ctx, \"keyRotationRotating\", \u0026time.RotatingArgs{\n\t\t\tRotationDays: pulumi.Int(30),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = time.NewStatic(ctx, \"keyRotationStatic\", \u0026time.StaticArgs{\n\t\t\tRfc3339: keyRotationRotating.Rfc3339,\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = twingate.NewTwingateServiceAccountKey(ctx, \"githubKeyWithRotation\", \u0026twingate.TwingateServiceAccountKeyArgs{\n\t\t\tServiceAccountId: githubActionsProd.ID(),\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.twingate.TwingateServiceAccount;\nimport com.pulumi.twingate.TwingateServiceAccountKey;\nimport com.pulumi.twingate.TwingateServiceAccountKeyArgs;\nimport com.pulumi.time.Rotating;\nimport com.pulumi.time.RotatingArgs;\nimport com.pulumi.time.Static;\nimport com.pulumi.time.StaticArgs;\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 githubActionsProd = new TwingateServiceAccount(\"githubActionsProd\");\n\n var githubKey = new TwingateServiceAccountKey(\"githubKey\", TwingateServiceAccountKeyArgs.builder()\n .serviceAccountId(githubActionsProd.id())\n .build());\n\n // Key rotation using the time provider (see https://registry.terraform.io/providers/hashicorp/time/latest)\n var keyRotationRotating = new Rotating(\"keyRotationRotating\", RotatingArgs.builder()\n .rotationDays(30)\n .build());\n\n var keyRotationStatic = new Static(\"keyRotationStatic\", StaticArgs.builder()\n .rfc3339(keyRotationRotating.rfc3339())\n .build());\n\n var githubKeyWithRotation = new TwingateServiceAccountKey(\"githubKeyWithRotation\", TwingateServiceAccountKeyArgs.builder()\n .serviceAccountId(githubActionsProd.id())\n .build());\n\n }\n}\n```\n```yaml\nresources:\n githubActionsProd:\n type: twingate:TwingateServiceAccount\n githubKey: # Key rotation using the time provider (see https://registry.terraform.io/providers/hashicorp/time/latest)\n type: twingate:TwingateServiceAccountKey\n properties:\n serviceAccountId: ${githubActionsProd.id}\n keyRotationRotating:\n type: time:Rotating\n properties:\n rotationDays: 30\n keyRotationStatic:\n type: time:Static\n properties:\n rfc3339: ${keyRotationRotating.rfc3339}\n githubKeyWithRotation:\n type: twingate:TwingateServiceAccountKey\n properties:\n serviceAccountId: ${githubActionsProd.id}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n", "properties": { "expirationTime": { "type": "integer", diff --git a/sdk/dotnet/GetTwingateRemoteNetwork.cs b/sdk/dotnet/GetTwingateRemoteNetwork.cs index 1e1638f..037fd99 100644 --- a/sdk/dotnet/GetTwingateRemoteNetwork.cs +++ b/sdk/dotnet/GetTwingateRemoteNetwork.cs @@ -118,6 +118,10 @@ public sealed class GetTwingateRemoteNetworkResult /// The name of the Remote Network /// public readonly string? Name; + /// + /// The type of the Remote Network. Must be one of the following: REGULAR, EXIT. + /// + public readonly string Type; [OutputConstructor] private GetTwingateRemoteNetworkResult( @@ -125,11 +129,14 @@ private GetTwingateRemoteNetworkResult( string location, - string? name) + string? name, + + string type) { Id = id; Location = location; Name = name; + Type = type; } } } diff --git a/sdk/dotnet/Outputs/GetTwingateRemoteNetworksRemoteNetworkResult.cs b/sdk/dotnet/Outputs/GetTwingateRemoteNetworksRemoteNetworkResult.cs index 1df27eb..11897bf 100644 --- a/sdk/dotnet/Outputs/GetTwingateRemoteNetworksRemoteNetworkResult.cs +++ b/sdk/dotnet/Outputs/GetTwingateRemoteNetworksRemoteNetworkResult.cs @@ -26,6 +26,10 @@ public sealed class GetTwingateRemoteNetworksRemoteNetworkResult /// The name of the Remote Network. /// public readonly string? Name; + /// + /// The type of the Remote Network. Must be one of the following: REGULAR, EXIT. + /// + public readonly string Type; [OutputConstructor] private GetTwingateRemoteNetworksRemoteNetworkResult( @@ -33,11 +37,14 @@ private GetTwingateRemoteNetworksRemoteNetworkResult( string location, - string? name) + string? name, + + string type) { Id = id; Location = location; Name = name; + Type = type; } } } diff --git a/sdk/dotnet/TwingateRemoteNetwork.cs b/sdk/dotnet/TwingateRemoteNetwork.cs index b54f272..d79cceb 100644 --- a/sdk/dotnet/TwingateRemoteNetwork.cs +++ b/sdk/dotnet/TwingateRemoteNetwork.cs @@ -49,6 +49,12 @@ public partial class TwingateRemoteNetwork : global::Pulumi.CustomResource [Output("name")] public Output Name { get; private set; } = null!; + /// + /// The type of the Remote Network. Must be one of the following: REGULAR, EXIT. Defaults to REGULAR. + /// + [Output("type")] + public Output Type { get; private set; } = null!; + /// /// Create a TwingateRemoteNetwork resource with the given unique name, arguments, and options. @@ -108,6 +114,12 @@ public sealed class TwingateRemoteNetworkArgs : global::Pulumi.ResourceArgs [Input("name")] public Input? Name { get; set; } + /// + /// The type of the Remote Network. Must be one of the following: REGULAR, EXIT. Defaults to REGULAR. + /// + [Input("type")] + public Input? Type { get; set; } + public TwingateRemoteNetworkArgs() { } @@ -128,6 +140,12 @@ public sealed class TwingateRemoteNetworkState : global::Pulumi.ResourceArgs [Input("name")] public Input? Name { get; set; } + /// + /// The type of the Remote Network. Must be one of the following: REGULAR, EXIT. Defaults to REGULAR. + /// + [Input("type")] + public Input? Type { get; set; } + public TwingateRemoteNetworkState() { } diff --git a/sdk/go/twingate/getTwingateRemoteNetwork.go b/sdk/go/twingate/getTwingateRemoteNetwork.go index 8292462..4976def 100644 --- a/sdk/go/twingate/getTwingateRemoteNetwork.go +++ b/sdk/go/twingate/getTwingateRemoteNetwork.go @@ -64,6 +64,8 @@ type LookupTwingateRemoteNetworkResult struct { Location string `pulumi:"location"` // The name of the Remote Network Name *string `pulumi:"name"` + // The type of the Remote Network. Must be one of the following: REGULAR, EXIT. + Type string `pulumi:"type"` } func LookupTwingateRemoteNetworkOutput(ctx *pulumi.Context, args LookupTwingateRemoteNetworkOutputArgs, opts ...pulumi.InvokeOption) LookupTwingateRemoteNetworkResultOutput { @@ -127,6 +129,11 @@ func (o LookupTwingateRemoteNetworkResultOutput) Name() pulumi.StringPtrOutput { return o.ApplyT(func(v LookupTwingateRemoteNetworkResult) *string { return v.Name }).(pulumi.StringPtrOutput) } +// The type of the Remote Network. Must be one of the following: REGULAR, EXIT. +func (o LookupTwingateRemoteNetworkResultOutput) Type() pulumi.StringOutput { + return o.ApplyT(func(v LookupTwingateRemoteNetworkResult) string { return v.Type }).(pulumi.StringOutput) +} + func init() { pulumi.RegisterOutputType(LookupTwingateRemoteNetworkResultOutput{}) } diff --git a/sdk/go/twingate/pulumiTypes.go b/sdk/go/twingate/pulumiTypes.go index 45bb3b4..b6c35ce 100644 --- a/sdk/go/twingate/pulumiTypes.go +++ b/sdk/go/twingate/pulumiTypes.go @@ -3099,6 +3099,8 @@ type GetTwingateRemoteNetworksRemoteNetwork struct { Location string `pulumi:"location"` // The name of the Remote Network. Name *string `pulumi:"name"` + // The type of the Remote Network. Must be one of the following: REGULAR, EXIT. + Type string `pulumi:"type"` } // GetTwingateRemoteNetworksRemoteNetworkInput is an input type that accepts GetTwingateRemoteNetworksRemoteNetworkArgs and GetTwingateRemoteNetworksRemoteNetworkOutput values. @@ -3119,6 +3121,8 @@ type GetTwingateRemoteNetworksRemoteNetworkArgs struct { Location pulumi.StringInput `pulumi:"location"` // The name of the Remote Network. Name pulumi.StringPtrInput `pulumi:"name"` + // The type of the Remote Network. Must be one of the following: REGULAR, EXIT. + Type pulumi.StringInput `pulumi:"type"` } func (GetTwingateRemoteNetworksRemoteNetworkArgs) ElementType() reflect.Type { @@ -3187,6 +3191,11 @@ func (o GetTwingateRemoteNetworksRemoteNetworkOutput) Name() pulumi.StringPtrOut return o.ApplyT(func(v GetTwingateRemoteNetworksRemoteNetwork) *string { return v.Name }).(pulumi.StringPtrOutput) } +// The type of the Remote Network. Must be one of the following: REGULAR, EXIT. +func (o GetTwingateRemoteNetworksRemoteNetworkOutput) Type() pulumi.StringOutput { + return o.ApplyT(func(v GetTwingateRemoteNetworksRemoteNetwork) string { return v.Type }).(pulumi.StringOutput) +} + type GetTwingateRemoteNetworksRemoteNetworkArrayOutput struct{ *pulumi.OutputState } func (GetTwingateRemoteNetworksRemoteNetworkArrayOutput) ElementType() reflect.Type { diff --git a/sdk/go/twingate/twingateRemoteNetwork.go b/sdk/go/twingate/twingateRemoteNetwork.go index 3e92235..9fd829c 100644 --- a/sdk/go/twingate/twingateRemoteNetwork.go +++ b/sdk/go/twingate/twingateRemoteNetwork.go @@ -49,6 +49,8 @@ type TwingateRemoteNetwork struct { Location pulumi.StringOutput `pulumi:"location"` // The name of the Remote Network Name pulumi.StringOutput `pulumi:"name"` + // The type of the Remote Network. Must be one of the following: REGULAR, EXIT. Defaults to REGULAR. + Type pulumi.StringOutput `pulumi:"type"` } // NewTwingateRemoteNetwork registers a new resource with the given unique name, arguments, and options. @@ -85,6 +87,8 @@ type twingateRemoteNetworkState struct { Location *string `pulumi:"location"` // The name of the Remote Network Name *string `pulumi:"name"` + // The type of the Remote Network. Must be one of the following: REGULAR, EXIT. Defaults to REGULAR. + Type *string `pulumi:"type"` } type TwingateRemoteNetworkState struct { @@ -92,6 +96,8 @@ type TwingateRemoteNetworkState struct { Location pulumi.StringPtrInput // The name of the Remote Network Name pulumi.StringPtrInput + // The type of the Remote Network. Must be one of the following: REGULAR, EXIT. Defaults to REGULAR. + Type pulumi.StringPtrInput } func (TwingateRemoteNetworkState) ElementType() reflect.Type { @@ -103,6 +109,8 @@ type twingateRemoteNetworkArgs struct { Location *string `pulumi:"location"` // The name of the Remote Network Name *string `pulumi:"name"` + // The type of the Remote Network. Must be one of the following: REGULAR, EXIT. Defaults to REGULAR. + Type *string `pulumi:"type"` } // The set of arguments for constructing a TwingateRemoteNetwork resource. @@ -111,6 +119,8 @@ type TwingateRemoteNetworkArgs struct { Location pulumi.StringPtrInput // The name of the Remote Network Name pulumi.StringPtrInput + // The type of the Remote Network. Must be one of the following: REGULAR, EXIT. Defaults to REGULAR. + Type pulumi.StringPtrInput } func (TwingateRemoteNetworkArgs) ElementType() reflect.Type { @@ -210,6 +220,11 @@ func (o TwingateRemoteNetworkOutput) Name() pulumi.StringOutput { return o.ApplyT(func(v *TwingateRemoteNetwork) pulumi.StringOutput { return v.Name }).(pulumi.StringOutput) } +// The type of the Remote Network. Must be one of the following: REGULAR, EXIT. Defaults to REGULAR. +func (o TwingateRemoteNetworkOutput) Type() pulumi.StringOutput { + return o.ApplyT(func(v *TwingateRemoteNetwork) pulumi.StringOutput { return v.Type }).(pulumi.StringOutput) +} + type TwingateRemoteNetworkArrayOutput struct{ *pulumi.OutputState } func (TwingateRemoteNetworkArrayOutput) ElementType() reflect.Type { diff --git a/sdk/nodejs/getTwingateRemoteNetwork.ts b/sdk/nodejs/getTwingateRemoteNetwork.ts index 5b07386..0f55011 100644 --- a/sdk/nodejs/getTwingateRemoteNetwork.ts +++ b/sdk/nodejs/getTwingateRemoteNetwork.ts @@ -57,6 +57,10 @@ export interface GetTwingateRemoteNetworkResult { * The name of the Remote Network */ readonly name?: string; + /** + * The type of the Remote Network. Must be one of the following: REGULAR, EXIT. + */ + readonly type: string; } /** * A Remote Network represents a single private network in Twingate that can have one or more Connectors and Resources assigned to it. You must create a Remote Network before creating Resources and Connectors that belong to it. For more information, see Twingate's [documentation](https://docs.twingate.com/docs/remote-networks). diff --git a/sdk/nodejs/twingateRemoteNetwork.ts b/sdk/nodejs/twingateRemoteNetwork.ts index 8c2364f..b44d00f 100644 --- a/sdk/nodejs/twingateRemoteNetwork.ts +++ b/sdk/nodejs/twingateRemoteNetwork.ts @@ -58,6 +58,10 @@ export class TwingateRemoteNetwork extends pulumi.CustomResource { * The name of the Remote Network */ public readonly name!: pulumi.Output; + /** + * The type of the Remote Network. Must be one of the following: REGULAR, EXIT. Defaults to REGULAR. + */ + public readonly type!: pulumi.Output; /** * Create a TwingateRemoteNetwork resource with the given unique name, arguments, and options. @@ -74,10 +78,12 @@ export class TwingateRemoteNetwork extends pulumi.CustomResource { const state = argsOrState as TwingateRemoteNetworkState | undefined; resourceInputs["location"] = state ? state.location : undefined; resourceInputs["name"] = state ? state.name : undefined; + resourceInputs["type"] = state ? state.type : undefined; } else { const args = argsOrState as TwingateRemoteNetworkArgs | undefined; resourceInputs["location"] = args ? args.location : undefined; resourceInputs["name"] = args ? args.name : undefined; + resourceInputs["type"] = args ? args.type : undefined; } opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts); super(TwingateRemoteNetwork.__pulumiType, name, resourceInputs, opts); @@ -96,6 +102,10 @@ export interface TwingateRemoteNetworkState { * The name of the Remote Network */ name?: pulumi.Input; + /** + * The type of the Remote Network. Must be one of the following: REGULAR, EXIT. Defaults to REGULAR. + */ + type?: pulumi.Input; } /** @@ -110,4 +120,8 @@ export interface TwingateRemoteNetworkArgs { * The name of the Remote Network */ name?: pulumi.Input; + /** + * The type of the Remote Network. Must be one of the following: REGULAR, EXIT. Defaults to REGULAR. + */ + type?: pulumi.Input; } diff --git a/sdk/nodejs/types/output.ts b/sdk/nodejs/types/output.ts index 1a06bb8..b0af517 100644 --- a/sdk/nodejs/types/output.ts +++ b/sdk/nodejs/types/output.ts @@ -187,6 +187,10 @@ export interface GetTwingateRemoteNetworksRemoteNetwork { * The name of the Remote Network. */ name?: string; + /** + * The type of the Remote Network. Must be one of the following: REGULAR, EXIT. + */ + type: string; } export interface GetTwingateResourceProtocols { diff --git a/sdk/python/pulumi_twingate/get_twingate_remote_network.py b/sdk/python/pulumi_twingate/get_twingate_remote_network.py index f55df88..b774206 100644 --- a/sdk/python/pulumi_twingate/get_twingate_remote_network.py +++ b/sdk/python/pulumi_twingate/get_twingate_remote_network.py @@ -26,7 +26,7 @@ class GetTwingateRemoteNetworkResult: """ A collection of values returned by getTwingateRemoteNetwork. """ - def __init__(__self__, id=None, location=None, name=None): + def __init__(__self__, id=None, location=None, name=None, type=None): if id and not isinstance(id, str): raise TypeError("Expected argument 'id' to be a str") pulumi.set(__self__, "id", id) @@ -36,6 +36,9 @@ def __init__(__self__, id=None, location=None, name=None): if name and not isinstance(name, str): raise TypeError("Expected argument 'name' to be a str") pulumi.set(__self__, "name", name) + if type and not isinstance(type, str): + raise TypeError("Expected argument 'type' to be a str") + pulumi.set(__self__, "type", type) @property @pulumi.getter @@ -61,6 +64,14 @@ def name(self) -> Optional[str]: """ return pulumi.get(self, "name") + @property + @pulumi.getter + def type(self) -> str: + """ + The type of the Remote Network. Must be one of the following: REGULAR, EXIT. + """ + return pulumi.get(self, "type") + class AwaitableGetTwingateRemoteNetworkResult(GetTwingateRemoteNetworkResult): # pylint: disable=using-constant-test @@ -70,7 +81,8 @@ def __await__(self): return GetTwingateRemoteNetworkResult( id=self.id, location=self.location, - name=self.name) + name=self.name, + type=self.type) def get_twingate_remote_network(id: Optional[str] = None, @@ -101,7 +113,8 @@ def get_twingate_remote_network(id: Optional[str] = None, return AwaitableGetTwingateRemoteNetworkResult( id=pulumi.get(__ret__, 'id'), location=pulumi.get(__ret__, 'location'), - name=pulumi.get(__ret__, 'name')) + name=pulumi.get(__ret__, 'name'), + type=pulumi.get(__ret__, 'type')) def get_twingate_remote_network_output(id: Optional[pulumi.Input[Optional[str]]] = None, name: Optional[pulumi.Input[Optional[str]]] = None, opts: Optional[pulumi.InvokeOptions] = None) -> pulumi.Output[GetTwingateRemoteNetworkResult]: @@ -129,4 +142,5 @@ def get_twingate_remote_network_output(id: Optional[pulumi.Input[Optional[str]]] return __ret__.apply(lambda __response__: GetTwingateRemoteNetworkResult( id=pulumi.get(__response__, 'id'), location=pulumi.get(__response__, 'location'), - name=pulumi.get(__response__, 'name'))) + name=pulumi.get(__response__, 'name'), + type=pulumi.get(__response__, 'type'))) diff --git a/sdk/python/pulumi_twingate/outputs.py b/sdk/python/pulumi_twingate/outputs.py index e98925d..daaeb2b 100644 --- a/sdk/python/pulumi_twingate/outputs.py +++ b/sdk/python/pulumi_twingate/outputs.py @@ -1169,14 +1169,17 @@ class GetTwingateRemoteNetworksRemoteNetworkResult(dict): def __init__(__self__, *, id: str, location: str, + type: str, name: Optional[str] = None): """ :param str id: The ID of the Remote Network. :param str location: The location of the Remote Network. Must be one of the following: AWS, AZURE, GOOGLE*CLOUD, ON*PREMISE, OTHER. + :param str type: The type of the Remote Network. Must be one of the following: REGULAR, EXIT. :param str name: The name of the Remote Network. """ pulumi.set(__self__, "id", id) pulumi.set(__self__, "location", location) + pulumi.set(__self__, "type", type) if name is not None: pulumi.set(__self__, "name", name) @@ -1196,6 +1199,14 @@ def location(self) -> str: """ return pulumi.get(self, "location") + @property + @pulumi.getter + def type(self) -> str: + """ + The type of the Remote Network. Must be one of the following: REGULAR, EXIT. + """ + return pulumi.get(self, "type") + @property @pulumi.getter def name(self) -> Optional[str]: diff --git a/sdk/python/pulumi_twingate/twingate_remote_network.py b/sdk/python/pulumi_twingate/twingate_remote_network.py index 1a33621..3229cde 100644 --- a/sdk/python/pulumi_twingate/twingate_remote_network.py +++ b/sdk/python/pulumi_twingate/twingate_remote_network.py @@ -20,16 +20,20 @@ class TwingateRemoteNetworkArgs: def __init__(__self__, *, location: Optional[pulumi.Input[str]] = None, - name: Optional[pulumi.Input[str]] = None): + name: Optional[pulumi.Input[str]] = None, + type: Optional[pulumi.Input[str]] = None): """ The set of arguments for constructing a TwingateRemoteNetwork resource. :param pulumi.Input[str] location: The location of the Remote Network. Must be one of the following: AWS, AZURE, GOOGLE*CLOUD, ON*PREMISE, OTHER. :param pulumi.Input[str] name: The name of the Remote Network + :param pulumi.Input[str] type: The type of the Remote Network. Must be one of the following: REGULAR, EXIT. Defaults to REGULAR. """ if location is not None: pulumi.set(__self__, "location", location) if name is not None: pulumi.set(__self__, "name", name) + if type is not None: + pulumi.set(__self__, "type", type) @property @pulumi.getter @@ -55,21 +59,37 @@ def name(self) -> Optional[pulumi.Input[str]]: def name(self, value: Optional[pulumi.Input[str]]): pulumi.set(self, "name", value) + @property + @pulumi.getter + def type(self) -> Optional[pulumi.Input[str]]: + """ + The type of the Remote Network. Must be one of the following: REGULAR, EXIT. Defaults to REGULAR. + """ + return pulumi.get(self, "type") + + @type.setter + def type(self, value: Optional[pulumi.Input[str]]): + pulumi.set(self, "type", value) + @pulumi.input_type class _TwingateRemoteNetworkState: def __init__(__self__, *, location: Optional[pulumi.Input[str]] = None, - name: Optional[pulumi.Input[str]] = None): + name: Optional[pulumi.Input[str]] = None, + type: Optional[pulumi.Input[str]] = None): """ Input properties used for looking up and filtering TwingateRemoteNetwork resources. :param pulumi.Input[str] location: The location of the Remote Network. Must be one of the following: AWS, AZURE, GOOGLE*CLOUD, ON*PREMISE, OTHER. :param pulumi.Input[str] name: The name of the Remote Network + :param pulumi.Input[str] type: The type of the Remote Network. Must be one of the following: REGULAR, EXIT. Defaults to REGULAR. """ if location is not None: pulumi.set(__self__, "location", location) if name is not None: pulumi.set(__self__, "name", name) + if type is not None: + pulumi.set(__self__, "type", type) @property @pulumi.getter @@ -95,6 +115,18 @@ def name(self) -> Optional[pulumi.Input[str]]: def name(self, value: Optional[pulumi.Input[str]]): pulumi.set(self, "name", value) + @property + @pulumi.getter + def type(self) -> Optional[pulumi.Input[str]]: + """ + The type of the Remote Network. Must be one of the following: REGULAR, EXIT. Defaults to REGULAR. + """ + return pulumi.get(self, "type") + + @type.setter + def type(self, value: Optional[pulumi.Input[str]]): + pulumi.set(self, "type", value) + class TwingateRemoteNetwork(pulumi.CustomResource): @overload @@ -103,6 +135,7 @@ def __init__(__self__, opts: Optional[pulumi.ResourceOptions] = None, location: Optional[pulumi.Input[str]] = None, name: Optional[pulumi.Input[str]] = None, + type: Optional[pulumi.Input[str]] = None, __props__=None): """ A Remote Network represents a single private network in Twingate that can have one or more Connectors and Resources assigned to it. You must create a Remote Network before creating Resources and Connectors that belong to it. For more information, see Twingate's [documentation](https://docs.twingate.com/docs/remote-networks). @@ -126,6 +159,7 @@ def __init__(__self__, :param pulumi.ResourceOptions opts: Options for the resource. :param pulumi.Input[str] location: The location of the Remote Network. Must be one of the following: AWS, AZURE, GOOGLE*CLOUD, ON*PREMISE, OTHER. :param pulumi.Input[str] name: The name of the Remote Network + :param pulumi.Input[str] type: The type of the Remote Network. Must be one of the following: REGULAR, EXIT. Defaults to REGULAR. """ ... @overload @@ -168,6 +202,7 @@ def _internal_init(__self__, opts: Optional[pulumi.ResourceOptions] = None, location: Optional[pulumi.Input[str]] = None, name: Optional[pulumi.Input[str]] = None, + type: Optional[pulumi.Input[str]] = None, __props__=None): opts = pulumi.ResourceOptions.merge(_utilities.get_resource_opts_defaults(), opts) if not isinstance(opts, pulumi.ResourceOptions): @@ -179,6 +214,7 @@ def _internal_init(__self__, __props__.__dict__["location"] = location __props__.__dict__["name"] = name + __props__.__dict__["type"] = type super(TwingateRemoteNetwork, __self__).__init__( 'twingate:index/twingateRemoteNetwork:TwingateRemoteNetwork', resource_name, @@ -190,7 +226,8 @@ def get(resource_name: str, id: pulumi.Input[str], opts: Optional[pulumi.ResourceOptions] = None, location: Optional[pulumi.Input[str]] = None, - name: Optional[pulumi.Input[str]] = None) -> 'TwingateRemoteNetwork': + name: Optional[pulumi.Input[str]] = None, + type: Optional[pulumi.Input[str]] = None) -> 'TwingateRemoteNetwork': """ Get an existing TwingateRemoteNetwork resource's state with the given name, id, and optional extra properties used to qualify the lookup. @@ -200,6 +237,7 @@ def get(resource_name: str, :param pulumi.ResourceOptions opts: Options for the resource. :param pulumi.Input[str] location: The location of the Remote Network. Must be one of the following: AWS, AZURE, GOOGLE*CLOUD, ON*PREMISE, OTHER. :param pulumi.Input[str] name: The name of the Remote Network + :param pulumi.Input[str] type: The type of the Remote Network. Must be one of the following: REGULAR, EXIT. Defaults to REGULAR. """ opts = pulumi.ResourceOptions.merge(opts, pulumi.ResourceOptions(id=id)) @@ -207,6 +245,7 @@ def get(resource_name: str, __props__.__dict__["location"] = location __props__.__dict__["name"] = name + __props__.__dict__["type"] = type return TwingateRemoteNetwork(resource_name, opts=opts, __props__=__props__) @property @@ -225,3 +264,11 @@ def name(self) -> pulumi.Output[str]: """ return pulumi.get(self, "name") + @property + @pulumi.getter + def type(self) -> pulumi.Output[str]: + """ + The type of the Remote Network. Must be one of the following: REGULAR, EXIT. Defaults to REGULAR. + """ + return pulumi.get(self, "type") +