diff --git a/.ci-mgmt.yaml b/.ci-mgmt.yaml index dfd2c846..38ddf0aa 100644 --- a/.ci-mgmt.yaml +++ b/.ci-mgmt.yaml @@ -4,6 +4,12 @@ env: DIGITALOCEAN_TOKEN: ${{ secrets.DIGITALOCEAN_TOKEN }} makeTemplate: bridged plugins: - - name: kubernetes - version: "3.10.0" + - name: kubernetes + version: "4.11.0" + - name: std + version: "1.6.2" + - name: terraform + version: "1.0.17" + kind: converter team: ecosystem +pulumiConvert: 1 diff --git a/.github/workflows/master.yml b/.github/workflows/master.yml index f43b77da..a3256ff4 100644 --- a/.github/workflows/master.yml +++ b/.github/workflows/master.yml @@ -325,6 +325,7 @@ jobs: uses: goreleaser/goreleaser-action@v5 env: GORELEASER_CURRENT_TAG: v${{ steps.version.outputs.version }} + PROVIDER_VERSION: ${{ steps.version.outputs.version }} with: args: -p 3 -f .goreleaser.prerelease.yml --rm-dist --skip-validate --timeout 60m0s diff --git a/.github/workflows/prerelease.yml b/.github/workflows/prerelease.yml index 1e6e8d36..46137eed 100644 --- a/.github/workflows/prerelease.yml +++ b/.github/workflows/prerelease.yml @@ -272,6 +272,7 @@ jobs: uses: goreleaser/goreleaser-action@v5 env: GORELEASER_CURRENT_TAG: v${{ steps.version.outputs.version }} + PROVIDER_VERSION: ${{ steps.version.outputs.version }} with: args: -p 3 -f .goreleaser.prerelease.yml --rm-dist --skip-validate --timeout 60m0s diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index efb3bc89..6b0a4128 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -286,6 +286,7 @@ jobs: uses: goreleaser/goreleaser-action@v5 env: GORELEASER_CURRENT_TAG: v${{ steps.version.outputs.version }} + PROVIDER_VERSION: ${{ steps.version.outputs.version }} with: args: -p 3 release --rm-dist --timeout 60m0s version: latest diff --git a/Makefile b/Makefile index 5c401bd3..14c21fa0 100644 --- a/Makefile +++ b/Makefile @@ -10,7 +10,7 @@ PROVIDER := pulumi-resource-$(PACK) JAVA_GEN := pulumi-java-gen TESTPARALLELISM := 10 WORKING_DIR := $(shell pwd) -PULUMI_CONVERT := 0 +PULUMI_CONVERT := 1 # Override during CI using `make [TARGET] PROVIDER_VERSION=""` or by setting a PROVIDER_VERSION environment variable # Local & branch builds will just used this fixed default version unless specified @@ -116,7 +116,9 @@ install_nodejs_sdk: install_plugins: export PULUMI_HOME := $(WORKING_DIR)/.pulumi install_plugins: export PATH := $(WORKING_DIR)/.pulumi/bin:$(PATH) install_plugins: .pulumi/bin/pulumi - .pulumi/bin/pulumi plugin install resource kubernetes 3.10.0 + .pulumi/bin/pulumi plugin install resource kubernetes 4.11.0 + .pulumi/bin/pulumi plugin install resource std 1.6.2 + .pulumi/bin/pulumi plugin install converter terraform 1.0.17 lint_provider: provider cd provider && golangci-lint run -c ../.golangci.yml diff --git a/provider/cmd/pulumi-resource-digitalocean/schema.json b/provider/cmd/pulumi-resource-digitalocean/schema.json index be49eb33..c053c915 100644 --- a/provider/cmd/pulumi-resource-digitalocean/schema.json +++ b/provider/cmd/pulumi-resource-digitalocean/schema.json @@ -7618,7 +7618,7 @@ }, "resources": { "digitalocean:index/app:App": { - "description": "Provides a DigitalOcean App resource.\n\n## Example Usage\n\nTo create an app, provide a [DigitalOcean app spec](https://docs.digitalocean.com/products/app-platform/reference/app-spec/) specifying the app's components.\n\n### Basic Example\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst golang_sample = new digitalocean.App(\"golang-sample\", {spec: {\n name: \"golang-sample\",\n region: \"ams\",\n services: [{\n environmentSlug: \"go\",\n git: {\n branch: \"main\",\n repoCloneUrl: \"https://github.com/digitalocean/sample-golang.git\",\n },\n instanceCount: 1,\n instanceSizeSlug: \"professional-xs\",\n name: \"go-service\",\n }],\n}});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\ngolang_sample = digitalocean.App(\"golang-sample\", spec=digitalocean.AppSpecArgs(\n name=\"golang-sample\",\n region=\"ams\",\n services=[digitalocean.AppSpecServiceArgs(\n environment_slug=\"go\",\n git=digitalocean.AppSpecServiceGitArgs(\n branch=\"main\",\n repo_clone_url=\"https://github.com/digitalocean/sample-golang.git\",\n ),\n instance_count=1,\n instance_size_slug=\"professional-xs\",\n name=\"go-service\",\n )],\n))\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var golang_sample = new DigitalOcean.App(\"golang-sample\", new()\n {\n Spec = new DigitalOcean.Inputs.AppSpecArgs\n {\n Name = \"golang-sample\",\n Region = \"ams\",\n Services = new[]\n {\n new DigitalOcean.Inputs.AppSpecServiceArgs\n {\n EnvironmentSlug = \"go\",\n Git = new DigitalOcean.Inputs.AppSpecServiceGitArgs\n {\n Branch = \"main\",\n RepoCloneUrl = \"https://github.com/digitalocean/sample-golang.git\",\n },\n InstanceCount = 1,\n InstanceSizeSlug = \"professional-xs\",\n Name = \"go-service\",\n },\n },\n },\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := digitalocean.NewApp(ctx, \"golang-sample\", \u0026digitalocean.AppArgs{\n\t\t\tSpec: \u0026digitalocean.AppSpecArgs{\n\t\t\t\tName: pulumi.String(\"golang-sample\"),\n\t\t\t\tRegion: pulumi.String(\"ams\"),\n\t\t\t\tServices: digitalocean.AppSpecServiceArray{\n\t\t\t\t\t\u0026digitalocean.AppSpecServiceArgs{\n\t\t\t\t\t\tEnvironmentSlug: pulumi.String(\"go\"),\n\t\t\t\t\t\tGit: \u0026digitalocean.AppSpecServiceGitArgs{\n\t\t\t\t\t\t\tBranch: pulumi.String(\"main\"),\n\t\t\t\t\t\t\tRepoCloneUrl: pulumi.String(\"https://github.com/digitalocean/sample-golang.git\"),\n\t\t\t\t\t\t},\n\t\t\t\t\t\tInstanceCount: pulumi.Int(1),\n\t\t\t\t\t\tInstanceSizeSlug: pulumi.String(\"professional-xs\"),\n\t\t\t\t\t\tName: pulumi.String(\"go-service\"),\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t},\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.digitalocean.App;\nimport com.pulumi.digitalocean.AppArgs;\nimport com.pulumi.digitalocean.inputs.AppSpecArgs;\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 golang_sample = new App(\"golang-sample\", AppArgs.builder() \n .spec(AppSpecArgs.builder()\n .name(\"golang-sample\")\n .region(\"ams\")\n .services(AppSpecServiceArgs.builder()\n .environmentSlug(\"go\")\n .git(AppSpecServiceGitArgs.builder()\n .branch(\"main\")\n .repoCloneUrl(\"https://github.com/digitalocean/sample-golang.git\")\n .build())\n .instanceCount(1)\n .instanceSizeSlug(\"professional-xs\")\n .name(\"go-service\")\n .build())\n .build())\n .build());\n\n }\n}\n```\n```yaml\nresources:\n golang-sample:\n type: digitalocean:App\n properties:\n spec:\n name: golang-sample\n region: ams\n services:\n - environmentSlug: go\n git:\n branch: main\n repoCloneUrl: https://github.com/digitalocean/sample-golang.git\n instanceCount: 1\n instanceSizeSlug: professional-xs\n name: go-service\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n### Static Site Example\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst static_site_example = new digitalocean.App(\"static-site-example\", {spec: {\n name: \"static-site-example\",\n region: \"ams\",\n staticSites: [{\n buildCommand: \"bundle exec jekyll build -d ./public\",\n git: {\n branch: \"main\",\n repoCloneUrl: \"https://github.com/digitalocean/sample-jekyll.git\",\n },\n name: \"sample-jekyll\",\n outputDir: \"/public\",\n }],\n}});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nstatic_site_example = digitalocean.App(\"static-site-example\", spec=digitalocean.AppSpecArgs(\n name=\"static-site-example\",\n region=\"ams\",\n static_sites=[digitalocean.AppSpecStaticSiteArgs(\n build_command=\"bundle exec jekyll build -d ./public\",\n git=digitalocean.AppSpecStaticSiteGitArgs(\n branch=\"main\",\n repo_clone_url=\"https://github.com/digitalocean/sample-jekyll.git\",\n ),\n name=\"sample-jekyll\",\n output_dir=\"/public\",\n )],\n))\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var static_site_example = new DigitalOcean.App(\"static-site-example\", new()\n {\n Spec = new DigitalOcean.Inputs.AppSpecArgs\n {\n Name = \"static-site-example\",\n Region = \"ams\",\n StaticSites = new[]\n {\n new DigitalOcean.Inputs.AppSpecStaticSiteArgs\n {\n BuildCommand = \"bundle exec jekyll build -d ./public\",\n Git = new DigitalOcean.Inputs.AppSpecStaticSiteGitArgs\n {\n Branch = \"main\",\n RepoCloneUrl = \"https://github.com/digitalocean/sample-jekyll.git\",\n },\n Name = \"sample-jekyll\",\n OutputDir = \"/public\",\n },\n },\n },\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := digitalocean.NewApp(ctx, \"static-site-example\", \u0026digitalocean.AppArgs{\n\t\t\tSpec: \u0026digitalocean.AppSpecArgs{\n\t\t\t\tName: pulumi.String(\"static-site-example\"),\n\t\t\t\tRegion: pulumi.String(\"ams\"),\n\t\t\t\tStaticSites: digitalocean.AppSpecStaticSiteArray{\n\t\t\t\t\t\u0026digitalocean.AppSpecStaticSiteArgs{\n\t\t\t\t\t\tBuildCommand: pulumi.String(\"bundle exec jekyll build -d ./public\"),\n\t\t\t\t\t\tGit: \u0026digitalocean.AppSpecStaticSiteGitArgs{\n\t\t\t\t\t\t\tBranch: pulumi.String(\"main\"),\n\t\t\t\t\t\t\tRepoCloneUrl: pulumi.String(\"https://github.com/digitalocean/sample-jekyll.git\"),\n\t\t\t\t\t\t},\n\t\t\t\t\t\tName: pulumi.String(\"sample-jekyll\"),\n\t\t\t\t\t\tOutputDir: pulumi.String(\"/public\"),\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t},\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.digitalocean.App;\nimport com.pulumi.digitalocean.AppArgs;\nimport com.pulumi.digitalocean.inputs.AppSpecArgs;\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 static_site_example = new App(\"static-site-example\", AppArgs.builder() \n .spec(AppSpecArgs.builder()\n .name(\"static-site-example\")\n .region(\"ams\")\n .staticSites(AppSpecStaticSiteArgs.builder()\n .buildCommand(\"bundle exec jekyll build -d ./public\")\n .git(AppSpecStaticSiteGitArgs.builder()\n .branch(\"main\")\n .repoCloneUrl(\"https://github.com/digitalocean/sample-jekyll.git\")\n .build())\n .name(\"sample-jekyll\")\n .outputDir(\"/public\")\n .build())\n .build())\n .build());\n\n }\n}\n```\n```yaml\nresources:\n static-site-example:\n type: digitalocean:App\n properties:\n spec:\n name: static-site-example\n region: ams\n staticSites:\n - buildCommand: bundle exec jekyll build -d ./public\n git:\n branch: main\n repoCloneUrl: https://github.com/digitalocean/sample-jekyll.git\n name: sample-jekyll\n outputDir: /public\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n### Multiple Components Example\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.digitalocean.App;\nimport com.pulumi.digitalocean.AppArgs;\nimport com.pulumi.digitalocean.inputs.AppSpecArgs;\nimport com.pulumi.digitalocean.inputs.AppSpecIngressArgs;\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 mono_repo_example = new App(\"mono-repo-example\", AppArgs.builder() \n .spec(AppSpecArgs.builder()\n .alerts(AppSpecAlertArgs.builder()\n .rule(\"DEPLOYMENT_FAILED\")\n .build())\n .databases(AppSpecDatabaseArgs.builder()\n .engine(\"PG\")\n .name(\"starter-db\")\n .production(false)\n .build())\n .domains(Map.of(\"name\", \"foo.example.com\"))\n .ingress(AppSpecIngressArgs.builder()\n .rule( \n %!v(PANIC=Format method: runtime error: invalid memory address or nil pointer dereference),\n %!v(PANIC=Format method: runtime error: invalid memory address or nil pointer dereference))\n .build())\n .name(\"mono-repo-example\")\n .region(\"ams\")\n .services(AppSpecServiceArgs.builder()\n .alert(%!v(PANIC=Format method: runtime error: invalid memory address or nil pointer dereference))\n .environmentSlug(\"go\")\n .github(AppSpecServiceGithubArgs.builder()\n .branch(\"main\")\n .deployOnPush(true)\n .repo(\"username/repo\")\n .build())\n .httpPort(3000)\n .instanceCount(2)\n .instanceSizeSlug(\"professional-xs\")\n .logDestination(%!v(PANIC=Format method: runtime error: invalid memory address or nil pointer dereference))\n .name(\"api\")\n .runCommand(\"bin/api\")\n .sourceDir(\"api/\")\n .build())\n .staticSites(AppSpecStaticSiteArgs.builder()\n .buildCommand(\"npm run build\")\n .github(AppSpecStaticSiteGithubArgs.builder()\n .branch(\"main\")\n .deployOnPush(true)\n .repo(\"username/repo\")\n .build())\n .name(\"web\")\n .build())\n .build())\n .build());\n\n }\n}\n```\n```yaml\nresources:\n mono-repo-example:\n type: digitalocean:App\n properties:\n spec:\n alerts:\n - rule: DEPLOYMENT_FAILED\n databases:\n - engine: PG\n name: starter-db\n production: false\n domains:\n - name: foo.example.com\n ingress:\n rule:\n - component:\n name: api\n match:\n path:\n prefix: /api\n - component:\n name: web\n match:\n path:\n prefix: /\n name: mono-repo-example\n region: ams\n services:\n - alert:\n - operator: GREATER_THAN\n rule: CPU_UTILIZATION\n value: 75\n window: TEN_MINUTES\n environmentSlug: go\n github:\n branch: main\n deployOnPush: true\n repo: username/repo\n httpPort: 3000\n instanceCount: 2\n instanceSizeSlug: professional-xs\n logDestination:\n - name: MyLogs\n papertrail:\n endpoint: syslog+tls://example.com:12345\n name: api\n runCommand: bin/api\n sourceDir: api/\n staticSites:\n - buildCommand: npm run build\n github:\n branch: main\n deployOnPush: true\n repo: username/repo\n name: web\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n## Import\n\nAn app can be imported using its `id`, e.g.\n\n```sh\n$ pulumi import digitalocean:index/app:App myapp fb06ad00-351f-45c8-b5eb-13523c438661\n```\n\n", + "description": "Provides a DigitalOcean App resource.\n\n## Example Usage\n\nTo create an app, provide a [DigitalOcean app spec](https://docs.digitalocean.com/products/app-platform/reference/app-spec/) specifying the app's components.\n\n### Basic Example\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst golang_sample = new digitalocean.App(\"golang-sample\", {spec: {\n name: \"golang-sample\",\n region: \"ams\",\n services: [{\n name: \"go-service\",\n environmentSlug: \"go\",\n instanceCount: 1,\n instanceSizeSlug: \"professional-xs\",\n git: {\n repoCloneUrl: \"https://github.com/digitalocean/sample-golang.git\",\n branch: \"main\",\n },\n }],\n}});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\ngolang_sample = digitalocean.App(\"golang-sample\", spec=digitalocean.AppSpecArgs(\n name=\"golang-sample\",\n region=\"ams\",\n services=[digitalocean.AppSpecServiceArgs(\n name=\"go-service\",\n environment_slug=\"go\",\n instance_count=1,\n instance_size_slug=\"professional-xs\",\n git=digitalocean.AppSpecServiceGitArgs(\n repo_clone_url=\"https://github.com/digitalocean/sample-golang.git\",\n branch=\"main\",\n ),\n )],\n))\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var golang_sample = new DigitalOcean.App(\"golang-sample\", new()\n {\n Spec = new DigitalOcean.Inputs.AppSpecArgs\n {\n Name = \"golang-sample\",\n Region = \"ams\",\n Services = new[]\n {\n new DigitalOcean.Inputs.AppSpecServiceArgs\n {\n Name = \"go-service\",\n EnvironmentSlug = \"go\",\n InstanceCount = 1,\n InstanceSizeSlug = \"professional-xs\",\n Git = new DigitalOcean.Inputs.AppSpecServiceGitArgs\n {\n RepoCloneUrl = \"https://github.com/digitalocean/sample-golang.git\",\n Branch = \"main\",\n },\n },\n },\n },\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := digitalocean.NewApp(ctx, \"golang-sample\", \u0026digitalocean.AppArgs{\n\t\t\tSpec: \u0026digitalocean.AppSpecArgs{\n\t\t\t\tName: pulumi.String(\"golang-sample\"),\n\t\t\t\tRegion: pulumi.String(\"ams\"),\n\t\t\t\tServices: digitalocean.AppSpecServiceArray{\n\t\t\t\t\t\u0026digitalocean.AppSpecServiceArgs{\n\t\t\t\t\t\tName: pulumi.String(\"go-service\"),\n\t\t\t\t\t\tEnvironmentSlug: pulumi.String(\"go\"),\n\t\t\t\t\t\tInstanceCount: pulumi.Int(1),\n\t\t\t\t\t\tInstanceSizeSlug: pulumi.String(\"professional-xs\"),\n\t\t\t\t\t\tGit: \u0026digitalocean.AppSpecServiceGitArgs{\n\t\t\t\t\t\t\tRepoCloneUrl: pulumi.String(\"https://github.com/digitalocean/sample-golang.git\"),\n\t\t\t\t\t\t\tBranch: pulumi.String(\"main\"),\n\t\t\t\t\t\t},\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t},\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.digitalocean.App;\nimport com.pulumi.digitalocean.AppArgs;\nimport com.pulumi.digitalocean.inputs.AppSpecArgs;\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 golang_sample = new App(\"golang-sample\", AppArgs.builder() \n .spec(AppSpecArgs.builder()\n .name(\"golang-sample\")\n .region(\"ams\")\n .services(AppSpecServiceArgs.builder()\n .name(\"go-service\")\n .environmentSlug(\"go\")\n .instanceCount(1)\n .instanceSizeSlug(\"professional-xs\")\n .git(AppSpecServiceGitArgs.builder()\n .repoCloneUrl(\"https://github.com/digitalocean/sample-golang.git\")\n .branch(\"main\")\n .build())\n .build())\n .build())\n .build());\n\n }\n}\n```\n```yaml\nresources:\n golang-sample:\n type: digitalocean:App\n properties:\n spec:\n name: golang-sample\n region: ams\n services:\n - name: go-service\n environmentSlug: go\n instanceCount: 1\n instanceSizeSlug: professional-xs\n git:\n repoCloneUrl: https://github.com/digitalocean/sample-golang.git\n branch: main\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n### Static Site Example\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst static_site_example = new digitalocean.App(\"static-site-example\", {spec: {\n name: \"static-site-example\",\n region: \"ams\",\n staticSites: [{\n name: \"sample-jekyll\",\n buildCommand: \"bundle exec jekyll build -d ./public\",\n outputDir: \"/public\",\n git: {\n repoCloneUrl: \"https://github.com/digitalocean/sample-jekyll.git\",\n branch: \"main\",\n },\n }],\n}});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nstatic_site_example = digitalocean.App(\"static-site-example\", spec=digitalocean.AppSpecArgs(\n name=\"static-site-example\",\n region=\"ams\",\n static_sites=[digitalocean.AppSpecStaticSiteArgs(\n name=\"sample-jekyll\",\n build_command=\"bundle exec jekyll build -d ./public\",\n output_dir=\"/public\",\n git=digitalocean.AppSpecStaticSiteGitArgs(\n repo_clone_url=\"https://github.com/digitalocean/sample-jekyll.git\",\n branch=\"main\",\n ),\n )],\n))\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var static_site_example = new DigitalOcean.App(\"static-site-example\", new()\n {\n Spec = new DigitalOcean.Inputs.AppSpecArgs\n {\n Name = \"static-site-example\",\n Region = \"ams\",\n StaticSites = new[]\n {\n new DigitalOcean.Inputs.AppSpecStaticSiteArgs\n {\n Name = \"sample-jekyll\",\n BuildCommand = \"bundle exec jekyll build -d ./public\",\n OutputDir = \"/public\",\n Git = new DigitalOcean.Inputs.AppSpecStaticSiteGitArgs\n {\n RepoCloneUrl = \"https://github.com/digitalocean/sample-jekyll.git\",\n Branch = \"main\",\n },\n },\n },\n },\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := digitalocean.NewApp(ctx, \"static-site-example\", \u0026digitalocean.AppArgs{\n\t\t\tSpec: \u0026digitalocean.AppSpecArgs{\n\t\t\t\tName: pulumi.String(\"static-site-example\"),\n\t\t\t\tRegion: pulumi.String(\"ams\"),\n\t\t\t\tStaticSites: digitalocean.AppSpecStaticSiteArray{\n\t\t\t\t\t\u0026digitalocean.AppSpecStaticSiteArgs{\n\t\t\t\t\t\tName: pulumi.String(\"sample-jekyll\"),\n\t\t\t\t\t\tBuildCommand: pulumi.String(\"bundle exec jekyll build -d ./public\"),\n\t\t\t\t\t\tOutputDir: pulumi.String(\"/public\"),\n\t\t\t\t\t\tGit: \u0026digitalocean.AppSpecStaticSiteGitArgs{\n\t\t\t\t\t\t\tRepoCloneUrl: pulumi.String(\"https://github.com/digitalocean/sample-jekyll.git\"),\n\t\t\t\t\t\t\tBranch: pulumi.String(\"main\"),\n\t\t\t\t\t\t},\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t},\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.digitalocean.App;\nimport com.pulumi.digitalocean.AppArgs;\nimport com.pulumi.digitalocean.inputs.AppSpecArgs;\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 static_site_example = new App(\"static-site-example\", AppArgs.builder() \n .spec(AppSpecArgs.builder()\n .name(\"static-site-example\")\n .region(\"ams\")\n .staticSites(AppSpecStaticSiteArgs.builder()\n .name(\"sample-jekyll\")\n .buildCommand(\"bundle exec jekyll build -d ./public\")\n .outputDir(\"/public\")\n .git(AppSpecStaticSiteGitArgs.builder()\n .repoCloneUrl(\"https://github.com/digitalocean/sample-jekyll.git\")\n .branch(\"main\")\n .build())\n .build())\n .build())\n .build());\n\n }\n}\n```\n```yaml\nresources:\n static-site-example:\n type: digitalocean:App\n properties:\n spec:\n name: static-site-example\n region: ams\n staticSites:\n - name: sample-jekyll\n buildCommand: bundle exec jekyll build -d ./public\n outputDir: /public\n git:\n repoCloneUrl: https://github.com/digitalocean/sample-jekyll.git\n branch: main\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n### Multiple Components Example\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.digitalocean.App;\nimport com.pulumi.digitalocean.AppArgs;\nimport com.pulumi.digitalocean.inputs.AppSpecArgs;\nimport com.pulumi.digitalocean.inputs.AppSpecIngressArgs;\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 mono_repo_example = new App(\"mono-repo-example\", AppArgs.builder() \n .spec(AppSpecArgs.builder()\n .name(\"mono-repo-example\")\n .region(\"ams\")\n .domains(Map.of(\"name\", \"foo.example.com\"))\n .alerts(AppSpecAlertArgs.builder()\n .rule(\"DEPLOYMENT_FAILED\")\n .build())\n .services(AppSpecServiceArgs.builder()\n .name(\"api\")\n .environmentSlug(\"go\")\n .instanceCount(2)\n .instanceSizeSlug(\"professional-xs\")\n .github(AppSpecServiceGithubArgs.builder()\n .branch(\"main\")\n .deployOnPush(true)\n .repo(\"username/repo\")\n .build())\n .sourceDir(\"api/\")\n .httpPort(3000)\n .alerts(AppSpecServiceAlertArgs.builder()\n .value(75)\n .operator(\"GREATER_THAN\")\n .window(\"TEN_MINUTES\")\n .rule(\"CPU_UTILIZATION\")\n .build())\n .logDestinations(AppSpecServiceLogDestinationArgs.builder()\n .name(\"MyLogs\")\n .papertrail(AppSpecServiceLogDestinationPapertrailArgs.builder()\n .endpoint(\"syslog+tls://example.com:12345\")\n .build())\n .build())\n .runCommand(\"bin/api\")\n .build())\n .staticSites(AppSpecStaticSiteArgs.builder()\n .name(\"web\")\n .buildCommand(\"npm run build\")\n .github(AppSpecStaticSiteGithubArgs.builder()\n .branch(\"main\")\n .deployOnPush(true)\n .repo(\"username/repo\")\n .build())\n .build())\n .databases(AppSpecDatabaseArgs.builder()\n .name(\"starter-db\")\n .engine(\"PG\")\n .production(false)\n .build())\n .ingress(AppSpecIngressArgs.builder()\n .rules( \n AppSpecIngressRuleArgs.builder()\n .component(AppSpecIngressRuleComponentArgs.builder()\n .name(\"api\")\n .build())\n .match(AppSpecIngressRuleMatchArgs.builder()\n .path(AppSpecIngressRuleMatchPathArgs.builder()\n .prefix(\"/api\")\n .build())\n .build())\n .build(),\n AppSpecIngressRuleArgs.builder()\n .component(AppSpecIngressRuleComponentArgs.builder()\n .name(\"web\")\n .build())\n .match(AppSpecIngressRuleMatchArgs.builder()\n .path(AppSpecIngressRuleMatchPathArgs.builder()\n .prefix(\"/\")\n .build())\n .build())\n .build())\n .build())\n .build())\n .build());\n\n }\n}\n```\n```yaml\nresources:\n mono-repo-example:\n type: digitalocean:App\n properties:\n spec:\n name: mono-repo-example\n region: ams\n domains:\n - name: foo.example.com\n alerts:\n - rule: DEPLOYMENT_FAILED\n services:\n - name: api\n environmentSlug: go\n instanceCount: 2\n instanceSizeSlug: professional-xs\n github:\n branch: main\n deployOnPush: true\n repo: username/repo\n sourceDir: api/\n httpPort: 3000\n alerts:\n - value: 75\n operator: GREATER_THAN\n window: TEN_MINUTES\n rule: CPU_UTILIZATION\n logDestinations:\n - name: MyLogs\n papertrail:\n endpoint: syslog+tls://example.com:12345\n runCommand: bin/api\n staticSites:\n - name: web\n buildCommand: npm run build\n github:\n branch: main\n deployOnPush: true\n repo: username/repo\n databases:\n - name: starter-db\n engine: PG\n production: false\n ingress:\n rules:\n - component:\n name: api\n match:\n path:\n prefix: /api\n - component:\n name: web\n match:\n path:\n prefix: /\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n## Import\n\nAn app can be imported using its `id`, e.g.\n\n```sh\n$ pulumi import digitalocean:index/app:App myapp fb06ad00-351f-45c8-b5eb-13523c438661\n```\n\n", "properties": { "activeDeploymentId": { "type": "string", @@ -7714,7 +7714,7 @@ } }, "digitalocean:index/cdn:Cdn": { - "description": "Provides a DigitalOcean CDN Endpoint resource for use with Spaces.\n\n## Example Usage\n\n### Basic Example\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\n// Create a new Spaces Bucket\nconst mybucket = new digitalocean.SpacesBucket(\"mybucket\", {\n region: digitalocean.Region.SFO2,\n acl: \"public-read\",\n});\n// Add a CDN endpoint to the Spaces Bucket\nconst mycdn = new digitalocean.Cdn(\"mycdn\", {origin: mybucket.bucketDomainName});\nexport const fqdn = mycdn.endpoint;\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\n# Create a new Spaces Bucket\nmybucket = digitalocean.SpacesBucket(\"mybucket\",\n region=digitalocean.Region.SFO2,\n acl=\"public-read\")\n# Add a CDN endpoint to the Spaces Bucket\nmycdn = digitalocean.Cdn(\"mycdn\", origin=mybucket.bucket_domain_name)\npulumi.export(\"fqdn\", mycdn.endpoint)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n // Create a new Spaces Bucket\n var mybucket = new DigitalOcean.SpacesBucket(\"mybucket\", new()\n {\n Region = DigitalOcean.Region.SFO2,\n Acl = \"public-read\",\n });\n\n // Add a CDN endpoint to the Spaces Bucket\n var mycdn = new DigitalOcean.Cdn(\"mycdn\", new()\n {\n Origin = mybucket.BucketDomainName,\n });\n\n return new Dictionary\u003cstring, object?\u003e\n {\n [\"fqdn\"] = mycdn.Endpoint,\n };\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t// Create a new Spaces Bucket\n\t\tmybucket, err := digitalocean.NewSpacesBucket(ctx, \"mybucket\", \u0026digitalocean.SpacesBucketArgs{\n\t\t\tRegion: pulumi.String(digitalocean.RegionSFO2),\n\t\t\tAcl: pulumi.String(\"public-read\"),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t// Add a CDN endpoint to the Spaces Bucket\n\t\tmycdn, err := digitalocean.NewCdn(ctx, \"mycdn\", \u0026digitalocean.CdnArgs{\n\t\t\tOrigin: mybucket.BucketDomainName,\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tctx.Export(\"fqdn\", mycdn.Endpoint)\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.digitalocean.SpacesBucket;\nimport com.pulumi.digitalocean.SpacesBucketArgs;\nimport com.pulumi.digitalocean.Cdn;\nimport com.pulumi.digitalocean.CdnArgs;\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 // Create a new Spaces Bucket\n var mybucket = new SpacesBucket(\"mybucket\", SpacesBucketArgs.builder() \n .region(\"sfo2\")\n .acl(\"public-read\")\n .build());\n\n // Add a CDN endpoint to the Spaces Bucket\n var mycdn = new Cdn(\"mycdn\", CdnArgs.builder() \n .origin(mybucket.bucketDomainName())\n .build());\n\n ctx.export(\"fqdn\", mycdn.endpoint());\n }\n}\n```\n```yaml\nresources:\n # Create a new Spaces Bucket\n mybucket:\n type: digitalocean:SpacesBucket\n properties:\n region: sfo2\n acl: public-read\n # Add a CDN endpoint to the Spaces Bucket\n mycdn:\n type: digitalocean:Cdn\n properties:\n origin: ${mybucket.bucketDomainName}\noutputs:\n # Output the endpoint for the CDN resource\n fqdn: ${mycdn.endpoint}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n### Custom Sub-Domain Example\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\n// Create a new Spaces Bucket\nconst mybucket = new digitalocean.SpacesBucket(\"mybucket\", {\n region: digitalocean.Region.SFO2,\n acl: \"public-read\",\n});\n// Create a DigitalOcean managed Let's Encrypt Certificate\nconst cert = new digitalocean.Certificate(\"cert\", {\n type: digitalocean.CertificateType.LetsEncrypt,\n domains: [\"static.example.com\"],\n});\n// Add a CDN endpoint with a custom sub-domain to the Spaces Bucket\nconst mycdn = new digitalocean.Cdn(\"mycdn\", {\n origin: mybucket.bucketDomainName,\n customDomain: \"static.example.com\",\n certificateName: cert.name,\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\n# Create a new Spaces Bucket\nmybucket = digitalocean.SpacesBucket(\"mybucket\",\n region=digitalocean.Region.SFO2,\n acl=\"public-read\")\n# Create a DigitalOcean managed Let's Encrypt Certificate\ncert = digitalocean.Certificate(\"cert\",\n type=digitalocean.CertificateType.LETS_ENCRYPT,\n domains=[\"static.example.com\"])\n# Add a CDN endpoint with a custom sub-domain to the Spaces Bucket\nmycdn = digitalocean.Cdn(\"mycdn\",\n origin=mybucket.bucket_domain_name,\n custom_domain=\"static.example.com\",\n certificate_name=cert.name)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n // Create a new Spaces Bucket\n var mybucket = new DigitalOcean.SpacesBucket(\"mybucket\", new()\n {\n Region = DigitalOcean.Region.SFO2,\n Acl = \"public-read\",\n });\n\n // Create a DigitalOcean managed Let's Encrypt Certificate\n var cert = new DigitalOcean.Certificate(\"cert\", new()\n {\n Type = DigitalOcean.CertificateType.LetsEncrypt,\n Domains = new[]\n {\n \"static.example.com\",\n },\n });\n\n // Add a CDN endpoint with a custom sub-domain to the Spaces Bucket\n var mycdn = new DigitalOcean.Cdn(\"mycdn\", new()\n {\n Origin = mybucket.BucketDomainName,\n CustomDomain = \"static.example.com\",\n CertificateName = cert.Name,\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t// Create a new Spaces Bucket\n\t\tmybucket, err := digitalocean.NewSpacesBucket(ctx, \"mybucket\", \u0026digitalocean.SpacesBucketArgs{\n\t\t\tRegion: pulumi.String(digitalocean.RegionSFO2),\n\t\t\tAcl: pulumi.String(\"public-read\"),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t// Create a DigitalOcean managed Let's Encrypt Certificate\n\t\tcert, err := digitalocean.NewCertificate(ctx, \"cert\", \u0026digitalocean.CertificateArgs{\n\t\t\tType: pulumi.String(digitalocean.CertificateTypeLetsEncrypt),\n\t\t\tDomains: pulumi.StringArray{\n\t\t\t\tpulumi.String(\"static.example.com\"),\n\t\t\t},\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t// Add a CDN endpoint with a custom sub-domain to the Spaces Bucket\n\t\t_, err = digitalocean.NewCdn(ctx, \"mycdn\", \u0026digitalocean.CdnArgs{\n\t\t\tOrigin: mybucket.BucketDomainName,\n\t\t\tCustomDomain: pulumi.String(\"static.example.com\"),\n\t\t\tCertificateName: cert.Name,\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.digitalocean.SpacesBucket;\nimport com.pulumi.digitalocean.SpacesBucketArgs;\nimport com.pulumi.digitalocean.Certificate;\nimport com.pulumi.digitalocean.CertificateArgs;\nimport com.pulumi.digitalocean.Cdn;\nimport com.pulumi.digitalocean.CdnArgs;\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 // Create a new Spaces Bucket\n var mybucket = new SpacesBucket(\"mybucket\", SpacesBucketArgs.builder() \n .region(\"sfo2\")\n .acl(\"public-read\")\n .build());\n\n // Create a DigitalOcean managed Let's Encrypt Certificate\n var cert = new Certificate(\"cert\", CertificateArgs.builder() \n .type(\"lets_encrypt\")\n .domains(\"static.example.com\")\n .build());\n\n // Add a CDN endpoint with a custom sub-domain to the Spaces Bucket\n var mycdn = new Cdn(\"mycdn\", CdnArgs.builder() \n .origin(mybucket.bucketDomainName())\n .customDomain(\"static.example.com\")\n .certificateName(cert.name())\n .build());\n\n }\n}\n```\n```yaml\nresources:\n # Create a new Spaces Bucket\n mybucket:\n type: digitalocean:SpacesBucket\n properties:\n region: sfo2\n acl: public-read\n # Create a DigitalOcean managed Let's Encrypt Certificate\n cert:\n type: digitalocean:Certificate\n properties:\n type: lets_encrypt\n domains:\n - static.example.com\n # Add a CDN endpoint with a custom sub-domain to the Spaces Bucket\n mycdn:\n type: digitalocean:Cdn\n properties:\n origin: ${mybucket.bucketDomainName}\n customDomain: static.example.com\n certificateName: ${cert.name}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n## Import\n\nCDN Endpoints can be imported using the CDN `id`, e.g.\n\n```sh\n$ pulumi import digitalocean:index/cdn:Cdn mycdn fb06ad00-351f-45c8-b5eb-13523c438661\n```\n\n", + "description": "Provides a DigitalOcean CDN Endpoint resource for use with Spaces.\n\n## Example Usage\n\n### Basic Example\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\n// Create a new Spaces Bucket\nconst mybucket = new digitalocean.SpacesBucket(\"mybucket\", {\n name: \"example\",\n region: digitalocean.Region.SFO2,\n acl: \"public-read\",\n});\n// Add a CDN endpoint to the Spaces Bucket\nconst mycdn = new digitalocean.Cdn(\"mycdn\", {origin: mybucket.bucketDomainName});\nexport const fqdn = mycdn.endpoint;\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\n# Create a new Spaces Bucket\nmybucket = digitalocean.SpacesBucket(\"mybucket\",\n name=\"example\",\n region=digitalocean.Region.SFO2,\n acl=\"public-read\")\n# Add a CDN endpoint to the Spaces Bucket\nmycdn = digitalocean.Cdn(\"mycdn\", origin=mybucket.bucket_domain_name)\npulumi.export(\"fqdn\", mycdn.endpoint)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n // Create a new Spaces Bucket\n var mybucket = new DigitalOcean.SpacesBucket(\"mybucket\", new()\n {\n Name = \"example\",\n Region = DigitalOcean.Region.SFO2,\n Acl = \"public-read\",\n });\n\n // Add a CDN endpoint to the Spaces Bucket\n var mycdn = new DigitalOcean.Cdn(\"mycdn\", new()\n {\n Origin = mybucket.BucketDomainName,\n });\n\n return new Dictionary\u003cstring, object?\u003e\n {\n [\"fqdn\"] = mycdn.Endpoint,\n };\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t// Create a new Spaces Bucket\n\t\tmybucket, err := digitalocean.NewSpacesBucket(ctx, \"mybucket\", \u0026digitalocean.SpacesBucketArgs{\n\t\t\tName: pulumi.String(\"example\"),\n\t\t\tRegion: pulumi.String(digitalocean.RegionSFO2),\n\t\t\tAcl: pulumi.String(\"public-read\"),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t// Add a CDN endpoint to the Spaces Bucket\n\t\tmycdn, err := digitalocean.NewCdn(ctx, \"mycdn\", \u0026digitalocean.CdnArgs{\n\t\t\tOrigin: mybucket.BucketDomainName,\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tctx.Export(\"fqdn\", mycdn.Endpoint)\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.digitalocean.SpacesBucket;\nimport com.pulumi.digitalocean.SpacesBucketArgs;\nimport com.pulumi.digitalocean.Cdn;\nimport com.pulumi.digitalocean.CdnArgs;\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 // Create a new Spaces Bucket\n var mybucket = new SpacesBucket(\"mybucket\", SpacesBucketArgs.builder() \n .name(\"example\")\n .region(\"sfo2\")\n .acl(\"public-read\")\n .build());\n\n // Add a CDN endpoint to the Spaces Bucket\n var mycdn = new Cdn(\"mycdn\", CdnArgs.builder() \n .origin(mybucket.bucketDomainName())\n .build());\n\n ctx.export(\"fqdn\", mycdn.endpoint());\n }\n}\n```\n```yaml\nresources:\n # Create a new Spaces Bucket\n mybucket:\n type: digitalocean:SpacesBucket\n properties:\n name: example\n region: sfo2\n acl: public-read\n # Add a CDN endpoint to the Spaces Bucket\n mycdn:\n type: digitalocean:Cdn\n properties:\n origin: ${mybucket.bucketDomainName}\noutputs:\n # Output the endpoint for the CDN resource\n fqdn: ${mycdn.endpoint}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n### Custom Sub-Domain Example\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\n// Create a new Spaces Bucket\nconst mybucket = new digitalocean.SpacesBucket(\"mybucket\", {\n name: \"example\",\n region: digitalocean.Region.SFO2,\n acl: \"public-read\",\n});\n// Create a DigitalOcean managed Let's Encrypt Certificate\nconst cert = new digitalocean.Certificate(\"cert\", {\n name: \"cdn-cert\",\n type: digitalocean.CertificateType.LetsEncrypt,\n domains: [\"static.example.com\"],\n});\n// Add a CDN endpoint with a custom sub-domain to the Spaces Bucket\nconst mycdn = new digitalocean.Cdn(\"mycdn\", {\n origin: mybucket.bucketDomainName,\n customDomain: \"static.example.com\",\n certificateName: cert.name,\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\n# Create a new Spaces Bucket\nmybucket = digitalocean.SpacesBucket(\"mybucket\",\n name=\"example\",\n region=digitalocean.Region.SFO2,\n acl=\"public-read\")\n# Create a DigitalOcean managed Let's Encrypt Certificate\ncert = digitalocean.Certificate(\"cert\",\n name=\"cdn-cert\",\n type=digitalocean.CertificateType.LETS_ENCRYPT,\n domains=[\"static.example.com\"])\n# Add a CDN endpoint with a custom sub-domain to the Spaces Bucket\nmycdn = digitalocean.Cdn(\"mycdn\",\n origin=mybucket.bucket_domain_name,\n custom_domain=\"static.example.com\",\n certificate_name=cert.name)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n // Create a new Spaces Bucket\n var mybucket = new DigitalOcean.SpacesBucket(\"mybucket\", new()\n {\n Name = \"example\",\n Region = DigitalOcean.Region.SFO2,\n Acl = \"public-read\",\n });\n\n // Create a DigitalOcean managed Let's Encrypt Certificate\n var cert = new DigitalOcean.Certificate(\"cert\", new()\n {\n Name = \"cdn-cert\",\n Type = DigitalOcean.CertificateType.LetsEncrypt,\n Domains = new[]\n {\n \"static.example.com\",\n },\n });\n\n // Add a CDN endpoint with a custom sub-domain to the Spaces Bucket\n var mycdn = new DigitalOcean.Cdn(\"mycdn\", new()\n {\n Origin = mybucket.BucketDomainName,\n CustomDomain = \"static.example.com\",\n CertificateName = cert.Name,\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t// Create a new Spaces Bucket\n\t\tmybucket, err := digitalocean.NewSpacesBucket(ctx, \"mybucket\", \u0026digitalocean.SpacesBucketArgs{\n\t\t\tName: pulumi.String(\"example\"),\n\t\t\tRegion: pulumi.String(digitalocean.RegionSFO2),\n\t\t\tAcl: pulumi.String(\"public-read\"),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t// Create a DigitalOcean managed Let's Encrypt Certificate\n\t\tcert, err := digitalocean.NewCertificate(ctx, \"cert\", \u0026digitalocean.CertificateArgs{\n\t\t\tName: pulumi.String(\"cdn-cert\"),\n\t\t\tType: pulumi.String(digitalocean.CertificateTypeLetsEncrypt),\n\t\t\tDomains: pulumi.StringArray{\n\t\t\t\tpulumi.String(\"static.example.com\"),\n\t\t\t},\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t// Add a CDN endpoint with a custom sub-domain to the Spaces Bucket\n\t\t_, err = digitalocean.NewCdn(ctx, \"mycdn\", \u0026digitalocean.CdnArgs{\n\t\t\tOrigin: mybucket.BucketDomainName,\n\t\t\tCustomDomain: pulumi.String(\"static.example.com\"),\n\t\t\tCertificateName: cert.Name,\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.digitalocean.SpacesBucket;\nimport com.pulumi.digitalocean.SpacesBucketArgs;\nimport com.pulumi.digitalocean.Certificate;\nimport com.pulumi.digitalocean.CertificateArgs;\nimport com.pulumi.digitalocean.Cdn;\nimport com.pulumi.digitalocean.CdnArgs;\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 // Create a new Spaces Bucket\n var mybucket = new SpacesBucket(\"mybucket\", SpacesBucketArgs.builder() \n .name(\"example\")\n .region(\"sfo2\")\n .acl(\"public-read\")\n .build());\n\n // Create a DigitalOcean managed Let's Encrypt Certificate\n var cert = new Certificate(\"cert\", CertificateArgs.builder() \n .name(\"cdn-cert\")\n .type(\"lets_encrypt\")\n .domains(\"static.example.com\")\n .build());\n\n // Add a CDN endpoint with a custom sub-domain to the Spaces Bucket\n var mycdn = new Cdn(\"mycdn\", CdnArgs.builder() \n .origin(mybucket.bucketDomainName())\n .customDomain(\"static.example.com\")\n .certificateName(cert.name())\n .build());\n\n }\n}\n```\n```yaml\nresources:\n # Create a new Spaces Bucket\n mybucket:\n type: digitalocean:SpacesBucket\n properties:\n name: example\n region: sfo2\n acl: public-read\n # Create a DigitalOcean managed Let's Encrypt Certificate\n cert:\n type: digitalocean:Certificate\n properties:\n name: cdn-cert\n type: lets_encrypt\n domains:\n - static.example.com\n # Add a CDN endpoint with a custom sub-domain to the Spaces Bucket\n mycdn:\n type: digitalocean:Cdn\n properties:\n origin: ${mybucket.bucketDomainName}\n customDomain: static.example.com\n certificateName: ${cert.name}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n## Import\n\nCDN Endpoints can be imported using the CDN `id`, e.g.\n\n```sh\n$ pulumi import digitalocean:index/cdn:Cdn mycdn fb06ad00-351f-45c8-b5eb-13523c438661\n```\n\n", "properties": { "certificateId": { "type": "string", @@ -7819,7 +7819,7 @@ } }, "digitalocean:index/certificate:Certificate": { - "description": "Provides a DigitalOcean Certificate resource that allows you to manage\ncertificates for configuring TLS termination in Load Balancers.\nCertificates created with this resource can be referenced in your\nLoad Balancer configuration via their ID. The certificate can either\nbe a custom one provided by you or automatically generated one with\nLet's Encrypt.\n\n## Example Usage\n\n### Custom Certificate\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\nimport * as fs from \"fs\";\n\nconst cert = new digitalocean.Certificate(\"cert\", {\n type: digitalocean.CertificateType.Custom,\n privateKey: fs.readFileSync(\"/Users/myuser/certs/privkey.pem\", \"utf8\"),\n leafCertificate: fs.readFileSync(\"/Users/myuser/certs/cert.pem\", \"utf8\"),\n certificateChain: fs.readFileSync(\"/Users/myuser/certs/fullchain.pem\", \"utf8\"),\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\ncert = digitalocean.Certificate(\"cert\",\n type=digitalocean.CertificateType.CUSTOM,\n private_key=(lambda path: open(path).read())(\"/Users/myuser/certs/privkey.pem\"),\n leaf_certificate=(lambda path: open(path).read())(\"/Users/myuser/certs/cert.pem\"),\n certificate_chain=(lambda path: open(path).read())(\"/Users/myuser/certs/fullchain.pem\"))\n```\n```csharp\nusing System.Collections.Generic;\nusing System.IO;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var cert = new DigitalOcean.Certificate(\"cert\", new()\n {\n Type = DigitalOcean.CertificateType.Custom,\n PrivateKey = File.ReadAllText(\"/Users/myuser/certs/privkey.pem\"),\n LeafCertificate = File.ReadAllText(\"/Users/myuser/certs/cert.pem\"),\n CertificateChain = File.ReadAllText(\"/Users/myuser/certs/fullchain.pem\"),\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"os\"\n\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc readFileOrPanic(path string) pulumi.StringPtrInput {\n\tdata, err := os.ReadFile(path)\n\tif err != nil {\n\t\tpanic(err.Error())\n\t}\n\treturn pulumi.String(string(data))\n}\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := digitalocean.NewCertificate(ctx, \"cert\", \u0026digitalocean.CertificateArgs{\n\t\t\tType: pulumi.String(digitalocean.CertificateTypeCustom),\n\t\t\tPrivateKey: readFileOrPanic(\"/Users/myuser/certs/privkey.pem\"),\n\t\t\tLeafCertificate: readFileOrPanic(\"/Users/myuser/certs/cert.pem\"),\n\t\t\tCertificateChain: readFileOrPanic(\"/Users/myuser/certs/fullchain.pem\"),\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.digitalocean.Certificate;\nimport com.pulumi.digitalocean.CertificateArgs;\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 cert = new Certificate(\"cert\", CertificateArgs.builder() \n .type(\"custom\")\n .privateKey(Files.readString(Paths.get(\"/Users/myuser/certs/privkey.pem\")))\n .leafCertificate(Files.readString(Paths.get(\"/Users/myuser/certs/cert.pem\")))\n .certificateChain(Files.readString(Paths.get(\"/Users/myuser/certs/fullchain.pem\")))\n .build());\n\n }\n}\n```\n```yaml\nresources:\n cert:\n type: digitalocean:Certificate\n properties:\n type: custom\n privateKey:\n fn::readFile: /Users/myuser/certs/privkey.pem\n leafCertificate:\n fn::readFile: /Users/myuser/certs/cert.pem\n certificateChain:\n fn::readFile: /Users/myuser/certs/fullchain.pem\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n### Let's Encrypt Certificate\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst cert = new digitalocean.Certificate(\"cert\", {\n domains: [\"example.com\"],\n type: digitalocean.CertificateType.LetsEncrypt,\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\ncert = digitalocean.Certificate(\"cert\",\n domains=[\"example.com\"],\n type=digitalocean.CertificateType.LETS_ENCRYPT)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var cert = new DigitalOcean.Certificate(\"cert\", new()\n {\n Domains = new[]\n {\n \"example.com\",\n },\n Type = DigitalOcean.CertificateType.LetsEncrypt,\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := digitalocean.NewCertificate(ctx, \"cert\", \u0026digitalocean.CertificateArgs{\n\t\t\tDomains: pulumi.StringArray{\n\t\t\t\tpulumi.String(\"example.com\"),\n\t\t\t},\n\t\t\tType: pulumi.String(digitalocean.CertificateTypeLetsEncrypt),\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.digitalocean.Certificate;\nimport com.pulumi.digitalocean.CertificateArgs;\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 cert = new Certificate(\"cert\", CertificateArgs.builder() \n .domains(\"example.com\")\n .type(\"lets_encrypt\")\n .build());\n\n }\n}\n```\n```yaml\nresources:\n cert:\n type: digitalocean:Certificate\n properties:\n domains:\n - example.com\n type: lets_encrypt\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n### Use with Other Resources\n\nBoth custom and Let's Encrypt certificates can be used with other resources\nincluding the `digitalocean.LoadBalancer` and `digitalocean.Cdn` resources.\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst cert = new digitalocean.Certificate(\"cert\", {\n type: digitalocean.CertificateType.LetsEncrypt,\n domains: [\"example.com\"],\n});\n// Create a new Load Balancer with TLS termination\nconst _public = new digitalocean.LoadBalancer(\"public\", {\n region: digitalocean.Region.NYC3,\n dropletTag: \"backend\",\n forwardingRules: [{\n entryPort: 443,\n entryProtocol: \"https\",\n targetPort: 80,\n targetProtocol: \"http\",\n certificateName: cert.name,\n }],\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\ncert = digitalocean.Certificate(\"cert\",\n type=digitalocean.CertificateType.LETS_ENCRYPT,\n domains=[\"example.com\"])\n# Create a new Load Balancer with TLS termination\npublic = digitalocean.LoadBalancer(\"public\",\n region=digitalocean.Region.NYC3,\n droplet_tag=\"backend\",\n forwarding_rules=[digitalocean.LoadBalancerForwardingRuleArgs(\n entry_port=443,\n entry_protocol=\"https\",\n target_port=80,\n target_protocol=\"http\",\n certificate_name=cert.name,\n )])\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var cert = new DigitalOcean.Certificate(\"cert\", new()\n {\n Type = DigitalOcean.CertificateType.LetsEncrypt,\n Domains = new[]\n {\n \"example.com\",\n },\n });\n\n // Create a new Load Balancer with TLS termination\n var @public = new DigitalOcean.LoadBalancer(\"public\", new()\n {\n Region = DigitalOcean.Region.NYC3,\n DropletTag = \"backend\",\n ForwardingRules = new[]\n {\n new DigitalOcean.Inputs.LoadBalancerForwardingRuleArgs\n {\n EntryPort = 443,\n EntryProtocol = \"https\",\n TargetPort = 80,\n TargetProtocol = \"http\",\n CertificateName = cert.Name,\n },\n },\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tcert, err := digitalocean.NewCertificate(ctx, \"cert\", \u0026digitalocean.CertificateArgs{\n\t\t\tType: pulumi.String(digitalocean.CertificateTypeLetsEncrypt),\n\t\t\tDomains: pulumi.StringArray{\n\t\t\t\tpulumi.String(\"example.com\"),\n\t\t\t},\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t// Create a new Load Balancer with TLS termination\n\t\t_, err = digitalocean.NewLoadBalancer(ctx, \"public\", \u0026digitalocean.LoadBalancerArgs{\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC3),\n\t\t\tDropletTag: pulumi.String(\"backend\"),\n\t\t\tForwardingRules: digitalocean.LoadBalancerForwardingRuleArray{\n\t\t\t\t\u0026digitalocean.LoadBalancerForwardingRuleArgs{\n\t\t\t\t\tEntryPort: pulumi.Int(443),\n\t\t\t\t\tEntryProtocol: pulumi.String(\"https\"),\n\t\t\t\t\tTargetPort: pulumi.Int(80),\n\t\t\t\t\tTargetProtocol: pulumi.String(\"http\"),\n\t\t\t\t\tCertificateName: cert.Name,\n\t\t\t\t},\n\t\t\t},\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.digitalocean.Certificate;\nimport com.pulumi.digitalocean.CertificateArgs;\nimport com.pulumi.digitalocean.LoadBalancer;\nimport com.pulumi.digitalocean.LoadBalancerArgs;\nimport com.pulumi.digitalocean.inputs.LoadBalancerForwardingRuleArgs;\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 cert = new Certificate(\"cert\", CertificateArgs.builder() \n .type(\"lets_encrypt\")\n .domains(\"example.com\")\n .build());\n\n // Create a new Load Balancer with TLS termination\n var public_ = new LoadBalancer(\"public\", LoadBalancerArgs.builder() \n .region(\"nyc3\")\n .dropletTag(\"backend\")\n .forwardingRules(LoadBalancerForwardingRuleArgs.builder()\n .entryPort(443)\n .entryProtocol(\"https\")\n .targetPort(80)\n .targetProtocol(\"http\")\n .certificateName(cert.name())\n .build())\n .build());\n\n }\n}\n```\n```yaml\nresources:\n cert:\n type: digitalocean:Certificate\n properties:\n type: lets_encrypt\n domains:\n - example.com\n # Create a new Load Balancer with TLS termination\n public:\n type: digitalocean:LoadBalancer\n properties:\n region: nyc3\n dropletTag: backend\n forwardingRules:\n - entryPort: 443\n entryProtocol: https\n targetPort: 80\n targetProtocol: http\n certificateName: ${cert.name}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n## Import\n\nCertificates can be imported using the certificate `name`, e.g.\n\n```sh\n$ pulumi import digitalocean:index/certificate:Certificate mycertificate cert-01\n```\n\n", + "description": "Provides a DigitalOcean Certificate resource that allows you to manage\ncertificates for configuring TLS termination in Load Balancers.\nCertificates created with this resource can be referenced in your\nLoad Balancer configuration via their ID. The certificate can either\nbe a custom one provided by you or automatically generated one with\nLet's Encrypt.\n\n## Example Usage\n\n### Custom Certificate\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\nimport * as std from \"@pulumi/std\";\n\nconst cert = new digitalocean.Certificate(\"cert\", {\n name: \"custom-example\",\n type: digitalocean.CertificateType.Custom,\n privateKey: std.file({\n input: \"/Users/myuser/certs/privkey.pem\",\n }).then(invoke =\u003e invoke.result),\n leafCertificate: std.file({\n input: \"/Users/myuser/certs/cert.pem\",\n }).then(invoke =\u003e invoke.result),\n certificateChain: std.file({\n input: \"/Users/myuser/certs/fullchain.pem\",\n }).then(invoke =\u003e invoke.result),\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\nimport pulumi_std as std\n\ncert = digitalocean.Certificate(\"cert\",\n name=\"custom-example\",\n type=digitalocean.CertificateType.CUSTOM,\n private_key=std.file(input=\"/Users/myuser/certs/privkey.pem\").result,\n leaf_certificate=std.file(input=\"/Users/myuser/certs/cert.pem\").result,\n certificate_chain=std.file(input=\"/Users/myuser/certs/fullchain.pem\").result)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\nusing Std = Pulumi.Std;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var cert = new DigitalOcean.Certificate(\"cert\", new()\n {\n Name = \"custom-example\",\n Type = DigitalOcean.CertificateType.Custom,\n PrivateKey = Std.File.Invoke(new()\n {\n Input = \"/Users/myuser/certs/privkey.pem\",\n }).Apply(invoke =\u003e invoke.Result),\n LeafCertificate = Std.File.Invoke(new()\n {\n Input = \"/Users/myuser/certs/cert.pem\",\n }).Apply(invoke =\u003e invoke.Result),\n CertificateChain = Std.File.Invoke(new()\n {\n Input = \"/Users/myuser/certs/fullchain.pem\",\n }).Apply(invoke =\u003e invoke.Result),\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi-std/sdk/go/std\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tinvokeFile, err := std.File(ctx, \u0026std.FileArgs{\n\t\t\tInput: \"/Users/myuser/certs/privkey.pem\",\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tinvokeFile1, err := std.File(ctx, \u0026std.FileArgs{\n\t\t\tInput: \"/Users/myuser/certs/cert.pem\",\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tinvokeFile2, err := std.File(ctx, \u0026std.FileArgs{\n\t\t\tInput: \"/Users/myuser/certs/fullchain.pem\",\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = digitalocean.NewCertificate(ctx, \"cert\", \u0026digitalocean.CertificateArgs{\n\t\t\tName: pulumi.String(\"custom-example\"),\n\t\t\tType: pulumi.String(digitalocean.CertificateTypeCustom),\n\t\t\tPrivateKey: invokeFile.Result,\n\t\t\tLeafCertificate: invokeFile1.Result,\n\t\t\tCertificateChain: invokeFile2.Result,\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.digitalocean.Certificate;\nimport com.pulumi.digitalocean.CertificateArgs;\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 cert = new Certificate(\"cert\", CertificateArgs.builder() \n .name(\"custom-example\")\n .type(\"custom\")\n .privateKey(StdFunctions.file(FileArgs.builder()\n .input(\"/Users/myuser/certs/privkey.pem\")\n .build()).result())\n .leafCertificate(StdFunctions.file(FileArgs.builder()\n .input(\"/Users/myuser/certs/cert.pem\")\n .build()).result())\n .certificateChain(StdFunctions.file(FileArgs.builder()\n .input(\"/Users/myuser/certs/fullchain.pem\")\n .build()).result())\n .build());\n\n }\n}\n```\n```yaml\nresources:\n cert:\n type: digitalocean:Certificate\n properties:\n name: custom-example\n type: custom\n privateKey:\n fn::invoke:\n Function: std:file\n Arguments:\n input: /Users/myuser/certs/privkey.pem\n Return: result\n leafCertificate:\n fn::invoke:\n Function: std:file\n Arguments:\n input: /Users/myuser/certs/cert.pem\n Return: result\n certificateChain:\n fn::invoke:\n Function: std:file\n Arguments:\n input: /Users/myuser/certs/fullchain.pem\n Return: result\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n### Let's Encrypt Certificate\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst cert = new digitalocean.Certificate(\"cert\", {\n name: \"le-example\",\n type: digitalocean.CertificateType.LetsEncrypt,\n domains: [\"example.com\"],\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\ncert = digitalocean.Certificate(\"cert\",\n name=\"le-example\",\n type=digitalocean.CertificateType.LETS_ENCRYPT,\n domains=[\"example.com\"])\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var cert = new DigitalOcean.Certificate(\"cert\", new()\n {\n Name = \"le-example\",\n Type = DigitalOcean.CertificateType.LetsEncrypt,\n Domains = new[]\n {\n \"example.com\",\n },\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := digitalocean.NewCertificate(ctx, \"cert\", \u0026digitalocean.CertificateArgs{\n\t\t\tName: pulumi.String(\"le-example\"),\n\t\t\tType: pulumi.String(digitalocean.CertificateTypeLetsEncrypt),\n\t\t\tDomains: pulumi.StringArray{\n\t\t\t\tpulumi.String(\"example.com\"),\n\t\t\t},\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.digitalocean.Certificate;\nimport com.pulumi.digitalocean.CertificateArgs;\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 cert = new Certificate(\"cert\", CertificateArgs.builder() \n .name(\"le-example\")\n .type(\"lets_encrypt\")\n .domains(\"example.com\")\n .build());\n\n }\n}\n```\n```yaml\nresources:\n cert:\n type: digitalocean:Certificate\n properties:\n name: le-example\n type: lets_encrypt\n domains:\n - example.com\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n### Use with Other Resources\n\nBoth custom and Let's Encrypt certificates can be used with other resources\nincluding the `digitalocean.LoadBalancer` and `digitalocean.Cdn` resources.\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst cert = new digitalocean.Certificate(\"cert\", {\n name: \"le-example\",\n type: digitalocean.CertificateType.LetsEncrypt,\n domains: [\"example.com\"],\n});\n// Create a new Load Balancer with TLS termination\nconst _public = new digitalocean.LoadBalancer(\"public\", {\n name: \"secure-loadbalancer-1\",\n region: digitalocean.Region.NYC3,\n dropletTag: \"backend\",\n forwardingRules: [{\n entryPort: 443,\n entryProtocol: \"https\",\n targetPort: 80,\n targetProtocol: \"http\",\n certificateName: cert.name,\n }],\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\ncert = digitalocean.Certificate(\"cert\",\n name=\"le-example\",\n type=digitalocean.CertificateType.LETS_ENCRYPT,\n domains=[\"example.com\"])\n# Create a new Load Balancer with TLS termination\npublic = digitalocean.LoadBalancer(\"public\",\n name=\"secure-loadbalancer-1\",\n region=digitalocean.Region.NYC3,\n droplet_tag=\"backend\",\n forwarding_rules=[digitalocean.LoadBalancerForwardingRuleArgs(\n entry_port=443,\n entry_protocol=\"https\",\n target_port=80,\n target_protocol=\"http\",\n certificate_name=cert.name,\n )])\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var cert = new DigitalOcean.Certificate(\"cert\", new()\n {\n Name = \"le-example\",\n Type = DigitalOcean.CertificateType.LetsEncrypt,\n Domains = new[]\n {\n \"example.com\",\n },\n });\n\n // Create a new Load Balancer with TLS termination\n var @public = new DigitalOcean.LoadBalancer(\"public\", new()\n {\n Name = \"secure-loadbalancer-1\",\n Region = DigitalOcean.Region.NYC3,\n DropletTag = \"backend\",\n ForwardingRules = new[]\n {\n new DigitalOcean.Inputs.LoadBalancerForwardingRuleArgs\n {\n EntryPort = 443,\n EntryProtocol = \"https\",\n TargetPort = 80,\n TargetProtocol = \"http\",\n CertificateName = cert.Name,\n },\n },\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tcert, err := digitalocean.NewCertificate(ctx, \"cert\", \u0026digitalocean.CertificateArgs{\n\t\t\tName: pulumi.String(\"le-example\"),\n\t\t\tType: pulumi.String(digitalocean.CertificateTypeLetsEncrypt),\n\t\t\tDomains: pulumi.StringArray{\n\t\t\t\tpulumi.String(\"example.com\"),\n\t\t\t},\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t// Create a new Load Balancer with TLS termination\n\t\t_, err = digitalocean.NewLoadBalancer(ctx, \"public\", \u0026digitalocean.LoadBalancerArgs{\n\t\t\tName: pulumi.String(\"secure-loadbalancer-1\"),\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC3),\n\t\t\tDropletTag: pulumi.String(\"backend\"),\n\t\t\tForwardingRules: digitalocean.LoadBalancerForwardingRuleArray{\n\t\t\t\t\u0026digitalocean.LoadBalancerForwardingRuleArgs{\n\t\t\t\t\tEntryPort: pulumi.Int(443),\n\t\t\t\t\tEntryProtocol: pulumi.String(\"https\"),\n\t\t\t\t\tTargetPort: pulumi.Int(80),\n\t\t\t\t\tTargetProtocol: pulumi.String(\"http\"),\n\t\t\t\t\tCertificateName: cert.Name,\n\t\t\t\t},\n\t\t\t},\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.digitalocean.Certificate;\nimport com.pulumi.digitalocean.CertificateArgs;\nimport com.pulumi.digitalocean.LoadBalancer;\nimport com.pulumi.digitalocean.LoadBalancerArgs;\nimport com.pulumi.digitalocean.inputs.LoadBalancerForwardingRuleArgs;\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 cert = new Certificate(\"cert\", CertificateArgs.builder() \n .name(\"le-example\")\n .type(\"lets_encrypt\")\n .domains(\"example.com\")\n .build());\n\n // Create a new Load Balancer with TLS termination\n var public_ = new LoadBalancer(\"public\", LoadBalancerArgs.builder() \n .name(\"secure-loadbalancer-1\")\n .region(\"nyc3\")\n .dropletTag(\"backend\")\n .forwardingRules(LoadBalancerForwardingRuleArgs.builder()\n .entryPort(443)\n .entryProtocol(\"https\")\n .targetPort(80)\n .targetProtocol(\"http\")\n .certificateName(cert.name())\n .build())\n .build());\n\n }\n}\n```\n```yaml\nresources:\n cert:\n type: digitalocean:Certificate\n properties:\n name: le-example\n type: lets_encrypt\n domains:\n - example.com\n # Create a new Load Balancer with TLS termination\n public:\n type: digitalocean:LoadBalancer\n properties:\n name: secure-loadbalancer-1\n region: nyc3\n dropletTag: backend\n forwardingRules:\n - entryPort: 443\n entryProtocol: https\n targetPort: 80\n targetProtocol: http\n certificateName: ${cert.name}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n## Import\n\nCertificates can be imported using the certificate `name`, e.g.\n\n```sh\n$ pulumi import digitalocean:index/certificate:Certificate mycertificate cert-01\n```\n\n", "properties": { "certificateChain": { "type": "string", @@ -7983,7 +7983,7 @@ } }, "digitalocean:index/containerRegistry:ContainerRegistry": { - "description": "Provides a DigitalOcean Container Registry resource. A Container Registry is\na secure, private location to store your containers for rapid deployment.\n\n## Example Usage\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\n// Create a new container registry\nconst foobar = new digitalocean.ContainerRegistry(\"foobar\", {subscriptionTierSlug: \"starter\"});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\n# Create a new container registry\nfoobar = digitalocean.ContainerRegistry(\"foobar\", subscription_tier_slug=\"starter\")\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n // Create a new container registry\n var foobar = new DigitalOcean.ContainerRegistry(\"foobar\", new()\n {\n SubscriptionTierSlug = \"starter\",\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t// Create a new container registry\n\t\t_, err := digitalocean.NewContainerRegistry(ctx, \"foobar\", \u0026digitalocean.ContainerRegistryArgs{\n\t\t\tSubscriptionTierSlug: pulumi.String(\"starter\"),\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.digitalocean.ContainerRegistry;\nimport com.pulumi.digitalocean.ContainerRegistryArgs;\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 // Create a new container registry\n var foobar = new ContainerRegistry(\"foobar\", ContainerRegistryArgs.builder() \n .subscriptionTierSlug(\"starter\")\n .build());\n\n }\n}\n```\n```yaml\nresources:\n # Create a new container registry\n foobar:\n type: digitalocean:ContainerRegistry\n properties:\n subscriptionTierSlug: starter\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n## Import\n\nContainer Registries can be imported using the `name`, e.g.\n\n```sh\n$ pulumi import digitalocean:index/containerRegistry:ContainerRegistry myregistry registryname\n```\n\n", + "description": "Provides a DigitalOcean Container Registry resource. A Container Registry is\na secure, private location to store your containers for rapid deployment.\n\n## Example Usage\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\n// Create a new container registry\nconst foobar = new digitalocean.ContainerRegistry(\"foobar\", {\n name: \"foobar\",\n subscriptionTierSlug: \"starter\",\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\n# Create a new container registry\nfoobar = digitalocean.ContainerRegistry(\"foobar\",\n name=\"foobar\",\n subscription_tier_slug=\"starter\")\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n // Create a new container registry\n var foobar = new DigitalOcean.ContainerRegistry(\"foobar\", new()\n {\n Name = \"foobar\",\n SubscriptionTierSlug = \"starter\",\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t// Create a new container registry\n\t\t_, err := digitalocean.NewContainerRegistry(ctx, \"foobar\", \u0026digitalocean.ContainerRegistryArgs{\n\t\t\tName: pulumi.String(\"foobar\"),\n\t\t\tSubscriptionTierSlug: pulumi.String(\"starter\"),\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.digitalocean.ContainerRegistry;\nimport com.pulumi.digitalocean.ContainerRegistryArgs;\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 // Create a new container registry\n var foobar = new ContainerRegistry(\"foobar\", ContainerRegistryArgs.builder() \n .name(\"foobar\")\n .subscriptionTierSlug(\"starter\")\n .build());\n\n }\n}\n```\n```yaml\nresources:\n # Create a new container registry\n foobar:\n type: digitalocean:ContainerRegistry\n properties:\n name: foobar\n subscriptionTierSlug: starter\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n## Import\n\nContainer Registries can be imported using the `name`, e.g.\n\n```sh\n$ pulumi import digitalocean:index/containerRegistry:ContainerRegistry myregistry registryname\n```\n\n", "properties": { "createdAt": { "type": "string", @@ -8080,7 +8080,7 @@ } }, "digitalocean:index/containerRegistryDockerCredentials:ContainerRegistryDockerCredentials": { - "description": "Get Docker credentials for your DigitalOcean container registry.\n\nAn error is triggered if the provided container registry name does not exist.\n\n## Example Usage\n\n### Basic Example\n\nGet the container registry:\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst example = new digitalocean.ContainerRegistryDockerCredentials(\"example\", {registryName: \"example\"});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nexample = digitalocean.ContainerRegistryDockerCredentials(\"example\", registry_name=\"example\")\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var example = new DigitalOcean.ContainerRegistryDockerCredentials(\"example\", new()\n {\n RegistryName = \"example\",\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := digitalocean.NewContainerRegistryDockerCredentials(ctx, \"example\", \u0026digitalocean.ContainerRegistryDockerCredentialsArgs{\n\t\t\tRegistryName: pulumi.String(\"example\"),\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.digitalocean.ContainerRegistryDockerCredentials;\nimport com.pulumi.digitalocean.ContainerRegistryDockerCredentialsArgs;\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 example = new ContainerRegistryDockerCredentials(\"example\", ContainerRegistryDockerCredentialsArgs.builder() \n .registryName(\"example\")\n .build());\n\n }\n}\n```\n```yaml\nresources:\n example:\n type: digitalocean:ContainerRegistryDockerCredentials\n properties:\n registryName: example\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n### Docker Provider Example\n\nUse the `endpoint` and `docker_credentials` with the Docker provider:\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst exampleContainerRegistry = digitalocean.getContainerRegistry({\n name: \"example\",\n});\nconst exampleContainerRegistryDockerCredentials = new digitalocean.ContainerRegistryDockerCredentials(\"exampleContainerRegistryDockerCredentials\", {registryName: \"example\"});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nexample_container_registry = digitalocean.get_container_registry(name=\"example\")\nexample_container_registry_docker_credentials = digitalocean.ContainerRegistryDockerCredentials(\"exampleContainerRegistryDockerCredentials\", registry_name=\"example\")\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var exampleContainerRegistry = DigitalOcean.GetContainerRegistry.Invoke(new()\n {\n Name = \"example\",\n });\n\n var exampleContainerRegistryDockerCredentials = new DigitalOcean.ContainerRegistryDockerCredentials(\"exampleContainerRegistryDockerCredentials\", new()\n {\n RegistryName = \"example\",\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := digitalocean.LookupContainerRegistry(ctx, \u0026digitalocean.LookupContainerRegistryArgs{\n\t\t\tName: \"example\",\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = digitalocean.NewContainerRegistryDockerCredentials(ctx, \"exampleContainerRegistryDockerCredentials\", \u0026digitalocean.ContainerRegistryDockerCredentialsArgs{\n\t\t\tRegistryName: pulumi.String(\"example\"),\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.digitalocean.DigitaloceanFunctions;\nimport com.pulumi.digitalocean.inputs.GetContainerRegistryArgs;\nimport com.pulumi.digitalocean.ContainerRegistryDockerCredentials;\nimport com.pulumi.digitalocean.ContainerRegistryDockerCredentialsArgs;\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 final var exampleContainerRegistry = DigitaloceanFunctions.getContainerRegistry(GetContainerRegistryArgs.builder()\n .name(\"example\")\n .build());\n\n var exampleContainerRegistryDockerCredentials = new ContainerRegistryDockerCredentials(\"exampleContainerRegistryDockerCredentials\", ContainerRegistryDockerCredentialsArgs.builder() \n .registryName(\"example\")\n .build());\n\n }\n}\n```\n```yaml\nresources:\n exampleContainerRegistryDockerCredentials:\n type: digitalocean:ContainerRegistryDockerCredentials\n properties:\n registryName: example\nvariables:\n exampleContainerRegistry:\n fn::invoke:\n Function: digitalocean:getContainerRegistry\n Arguments:\n name: example\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n", + "description": "Get Docker credentials for your DigitalOcean container registry.\n\nAn error is triggered if the provided container registry name does not exist.\n\n## Example Usage\n\n### Basic Example\n\nGet the container registry:\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst example = new digitalocean.ContainerRegistryDockerCredentials(\"example\", {registryName: \"example\"});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nexample = digitalocean.ContainerRegistryDockerCredentials(\"example\", registry_name=\"example\")\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var example = new DigitalOcean.ContainerRegistryDockerCredentials(\"example\", new()\n {\n RegistryName = \"example\",\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := digitalocean.NewContainerRegistryDockerCredentials(ctx, \"example\", \u0026digitalocean.ContainerRegistryDockerCredentialsArgs{\n\t\t\tRegistryName: pulumi.String(\"example\"),\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.digitalocean.ContainerRegistryDockerCredentials;\nimport com.pulumi.digitalocean.ContainerRegistryDockerCredentialsArgs;\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 example = new ContainerRegistryDockerCredentials(\"example\", ContainerRegistryDockerCredentialsArgs.builder() \n .registryName(\"example\")\n .build());\n\n }\n}\n```\n```yaml\nresources:\n example:\n type: digitalocean:ContainerRegistryDockerCredentials\n properties:\n registryName: example\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n### Docker Provider Example\n\nUse the `endpoint` and `docker_credentials` with the Docker provider:\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst example = digitalocean.getContainerRegistry({\n name: \"example\",\n});\nconst exampleContainerRegistryDockerCredentials = new digitalocean.ContainerRegistryDockerCredentials(\"example\", {registryName: \"example\"});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nexample = digitalocean.get_container_registry(name=\"example\")\nexample_container_registry_docker_credentials = digitalocean.ContainerRegistryDockerCredentials(\"example\", registry_name=\"example\")\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var example = DigitalOcean.GetContainerRegistry.Invoke(new()\n {\n Name = \"example\",\n });\n\n var exampleContainerRegistryDockerCredentials = new DigitalOcean.ContainerRegistryDockerCredentials(\"example\", new()\n {\n RegistryName = \"example\",\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := digitalocean.LookupContainerRegistry(ctx, \u0026digitalocean.LookupContainerRegistryArgs{\n\t\t\tName: \"example\",\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = digitalocean.NewContainerRegistryDockerCredentials(ctx, \"example\", \u0026digitalocean.ContainerRegistryDockerCredentialsArgs{\n\t\t\tRegistryName: pulumi.String(\"example\"),\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.digitalocean.DigitaloceanFunctions;\nimport com.pulumi.digitalocean.inputs.GetContainerRegistryArgs;\nimport com.pulumi.digitalocean.ContainerRegistryDockerCredentials;\nimport com.pulumi.digitalocean.ContainerRegistryDockerCredentialsArgs;\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 final var example = DigitaloceanFunctions.getContainerRegistry(GetContainerRegistryArgs.builder()\n .name(\"example\")\n .build());\n\n var exampleContainerRegistryDockerCredentials = new ContainerRegistryDockerCredentials(\"exampleContainerRegistryDockerCredentials\", ContainerRegistryDockerCredentialsArgs.builder() \n .registryName(\"example\")\n .build());\n\n }\n}\n```\n```yaml\nresources:\n exampleContainerRegistryDockerCredentials:\n type: digitalocean:ContainerRegistryDockerCredentials\n name: example\n properties:\n registryName: example\nvariables:\n example:\n fn::invoke:\n Function: digitalocean:getContainerRegistry\n Arguments:\n name: example\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n### Kubernetes Example\n\nCombined with the Kubernetes Provider's `kubernetes_secret` resource, you can\naccess the registry from inside your cluster:\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\nimport * as kubernetes from \"@pulumi/kubernetes\";\n\nconst exampleContainerRegistryDockerCredentials = new digitalocean.ContainerRegistryDockerCredentials(\"example\", {registryName: \"example\"});\nconst example = digitalocean.getKubernetesCluster({\n name: \"prod-cluster-01\",\n});\nconst exampleSecret = new kubernetes.core.v1.Secret(\"example\", {\n metadata: {\n name: \"docker-cfg\",\n },\n data: {\n \".dockerconfigjson\": exampleContainerRegistryDockerCredentials.dockerCredentials,\n },\n type: \"kubernetes.io/dockerconfigjson\",\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\nimport pulumi_kubernetes as kubernetes\n\nexample_container_registry_docker_credentials = digitalocean.ContainerRegistryDockerCredentials(\"example\", registry_name=\"example\")\nexample = digitalocean.get_kubernetes_cluster(name=\"prod-cluster-01\")\nexample_secret = kubernetes.core.v1.Secret(\"example\",\n metadata=kubernetes.meta.v1.ObjectMetaArgs(\n name=\"docker-cfg\",\n ),\n data={\n \".dockerconfigjson\": example_container_registry_docker_credentials.docker_credentials,\n },\n type=\"kubernetes.io/dockerconfigjson\")\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\nusing Kubernetes = Pulumi.Kubernetes;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var exampleContainerRegistryDockerCredentials = new DigitalOcean.ContainerRegistryDockerCredentials(\"example\", new()\n {\n RegistryName = \"example\",\n });\n\n var example = DigitalOcean.GetKubernetesCluster.Invoke(new()\n {\n Name = \"prod-cluster-01\",\n });\n\n var exampleSecret = new Kubernetes.Core.V1.Secret(\"example\", new()\n {\n Metadata = new Kubernetes.Types.Inputs.Meta.V1.ObjectMetaArgs\n {\n Name = \"docker-cfg\",\n },\n Data = \n {\n { \".dockerconfigjson\", exampleContainerRegistryDockerCredentials.DockerCredentials },\n },\n Type = \"kubernetes.io/dockerconfigjson\",\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\tcorev1 \"github.com/pulumi/pulumi-kubernetes/sdk/v4/go/kubernetes/core/v1\"\n\tmetav1 \"github.com/pulumi/pulumi-kubernetes/sdk/v4/go/kubernetes/meta/v1\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\texampleContainerRegistryDockerCredentials, err := digitalocean.NewContainerRegistryDockerCredentials(ctx, \"example\", \u0026digitalocean.ContainerRegistryDockerCredentialsArgs{\n\t\t\tRegistryName: pulumi.String(\"example\"),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = digitalocean.LookupKubernetesCluster(ctx, \u0026digitalocean.LookupKubernetesClusterArgs{\n\t\t\tName: \"prod-cluster-01\",\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = corev1.NewSecret(ctx, \"example\", \u0026corev1.SecretArgs{\n\t\t\tMetadata: \u0026metav1.ObjectMetaArgs{\n\t\t\t\tName: pulumi.String(\"docker-cfg\"),\n\t\t\t},\n\t\t\tData: pulumi.StringMap{\n\t\t\t\t\".dockerconfigjson\": exampleContainerRegistryDockerCredentials.DockerCredentials,\n\t\t\t},\n\t\t\tType: pulumi.String(\"kubernetes.io/dockerconfigjson\"),\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.digitalocean.ContainerRegistryDockerCredentials;\nimport com.pulumi.digitalocean.ContainerRegistryDockerCredentialsArgs;\nimport com.pulumi.digitalocean.DigitaloceanFunctions;\nimport com.pulumi.digitalocean.inputs.GetKubernetesClusterArgs;\nimport com.pulumi.kubernetes.core_v1.Secret;\nimport com.pulumi.kubernetes.core_v1.SecretArgs;\nimport com.pulumi.kubernetes.meta_v1.inputs.ObjectMetaArgs;\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 exampleContainerRegistryDockerCredentials = new ContainerRegistryDockerCredentials(\"exampleContainerRegistryDockerCredentials\", ContainerRegistryDockerCredentialsArgs.builder() \n .registryName(\"example\")\n .build());\n\n final var example = DigitaloceanFunctions.getKubernetesCluster(GetKubernetesClusterArgs.builder()\n .name(\"prod-cluster-01\")\n .build());\n\n var exampleSecret = new Secret(\"exampleSecret\", SecretArgs.builder() \n .metadata(ObjectMetaArgs.builder()\n .name(\"docker-cfg\")\n .build())\n .data(Map.of(\".dockerconfigjson\", exampleContainerRegistryDockerCredentials.dockerCredentials()))\n .type(\"kubernetes.io/dockerconfigjson\")\n .build());\n\n }\n}\n```\n```yaml\nresources:\n exampleContainerRegistryDockerCredentials:\n type: digitalocean:ContainerRegistryDockerCredentials\n name: example\n properties:\n registryName: example\n exampleSecret:\n type: kubernetes:core/v1:Secret\n name: example\n properties:\n metadata:\n name: docker-cfg\n data:\n .dockerconfigjson: ${exampleContainerRegistryDockerCredentials.dockerCredentials}\n type: kubernetes.io/dockerconfigjson\nvariables:\n example:\n fn::invoke:\n Function: digitalocean:getKubernetesCluster\n Arguments:\n name: prod-cluster-01\n```\n\u003c!--End PulumiCodeChooser --\u003e\n", "properties": { "credentialExpirationTime": { "type": "string", @@ -8157,7 +8157,7 @@ } }, "digitalocean:index/customImage:CustomImage": { - "description": "Provides a resource which can be used to create a [custom image](https://www.digitalocean.com/docs/images/custom-images/)\nfrom a URL. The URL must point to an image in one of the following file formats:\n\n- Raw (.img) with an MBR or GPT partition table\n- qcow2\n- VHDX\n- VDI\n- VMDK\n\nThe image may be compressed using gzip or bzip2. See the DigitalOcean Custom\nImage documentation for [additional requirements](https://www.digitalocean.com/docs/images/custom-images/#image-requirements).\n\n## Example Usage\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst flatcar = new digitalocean.CustomImage(\"flatcar\", {\n url: \"https://stable.release.flatcar-linux.net/amd64-usr/2605.7.0/flatcar_production_digitalocean_image.bin.bz2\",\n regions: [\"nyc3\"],\n});\nconst example = new digitalocean.Droplet(\"example\", {\n image: flatcar.id,\n region: digitalocean.Region.NYC3,\n size: digitalocean.DropletSlug.DropletS1VCPU1GB,\n sshKeys: [\"12345\"],\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nflatcar = digitalocean.CustomImage(\"flatcar\",\n url=\"https://stable.release.flatcar-linux.net/amd64-usr/2605.7.0/flatcar_production_digitalocean_image.bin.bz2\",\n regions=[\"nyc3\"])\nexample = digitalocean.Droplet(\"example\",\n image=flatcar.id,\n region=digitalocean.Region.NYC3,\n size=digitalocean.DropletSlug.DROPLET_S1_VCPU1_GB,\n ssh_keys=[\"12345\"])\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var flatcar = new DigitalOcean.CustomImage(\"flatcar\", new()\n {\n Url = \"https://stable.release.flatcar-linux.net/amd64-usr/2605.7.0/flatcar_production_digitalocean_image.bin.bz2\",\n Regions = new[]\n {\n \"nyc3\",\n },\n });\n\n var example = new DigitalOcean.Droplet(\"example\", new()\n {\n Image = flatcar.Id,\n Region = DigitalOcean.Region.NYC3,\n Size = DigitalOcean.DropletSlug.DropletS1VCPU1GB,\n SshKeys = new[]\n {\n \"12345\",\n },\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tflatcar, err := digitalocean.NewCustomImage(ctx, \"flatcar\", \u0026digitalocean.CustomImageArgs{\n\t\t\tUrl: pulumi.String(\"https://stable.release.flatcar-linux.net/amd64-usr/2605.7.0/flatcar_production_digitalocean_image.bin.bz2\"),\n\t\t\tRegions: pulumi.StringArray{\n\t\t\t\tpulumi.String(\"nyc3\"),\n\t\t\t},\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = digitalocean.NewDroplet(ctx, \"example\", \u0026digitalocean.DropletArgs{\n\t\t\tImage: flatcar.ID(),\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC3),\n\t\t\tSize: pulumi.String(digitalocean.DropletSlugDropletS1VCPU1GB),\n\t\t\tSshKeys: pulumi.StringArray{\n\t\t\t\tpulumi.String(\"12345\"),\n\t\t\t},\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.digitalocean.CustomImage;\nimport com.pulumi.digitalocean.CustomImageArgs;\nimport com.pulumi.digitalocean.Droplet;\nimport com.pulumi.digitalocean.DropletArgs;\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 flatcar = new CustomImage(\"flatcar\", CustomImageArgs.builder() \n .url(\"https://stable.release.flatcar-linux.net/amd64-usr/2605.7.0/flatcar_production_digitalocean_image.bin.bz2\")\n .regions(\"nyc3\")\n .build());\n\n var example = new Droplet(\"example\", DropletArgs.builder() \n .image(flatcar.id())\n .region(\"nyc3\")\n .size(\"s-1vcpu-1gb\")\n .sshKeys(12345)\n .build());\n\n }\n}\n```\n```yaml\nresources:\n flatcar:\n type: digitalocean:CustomImage\n properties:\n url: https://stable.release.flatcar-linux.net/amd64-usr/2605.7.0/flatcar_production_digitalocean_image.bin.bz2\n regions:\n - nyc3\n example:\n type: digitalocean:Droplet\n properties:\n image: ${flatcar.id}\n region: nyc3\n size: s-1vcpu-1gb\n sshKeys:\n - 12345\n```\n\u003c!--End PulumiCodeChooser --\u003e\n", + "description": "Provides a resource which can be used to create a [custom image](https://www.digitalocean.com/docs/images/custom-images/)\nfrom a URL. The URL must point to an image in one of the following file formats:\n\n- Raw (.img) with an MBR or GPT partition table\n- qcow2\n- VHDX\n- VDI\n- VMDK\n\nThe image may be compressed using gzip or bzip2. See the DigitalOcean Custom\nImage documentation for [additional requirements](https://www.digitalocean.com/docs/images/custom-images/#image-requirements).\n\n## Example Usage\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst flatcar = new digitalocean.CustomImage(\"flatcar\", {\n name: \"flatcar\",\n url: \"https://stable.release.flatcar-linux.net/amd64-usr/2605.7.0/flatcar_production_digitalocean_image.bin.bz2\",\n regions: [\"nyc3\"],\n});\nconst example = new digitalocean.Droplet(\"example\", {\n image: flatcar.id,\n name: \"example-01\",\n region: digitalocean.Region.NYC3,\n size: digitalocean.DropletSlug.DropletS1VCPU1GB,\n sshKeys: [\"12345\"],\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nflatcar = digitalocean.CustomImage(\"flatcar\",\n name=\"flatcar\",\n url=\"https://stable.release.flatcar-linux.net/amd64-usr/2605.7.0/flatcar_production_digitalocean_image.bin.bz2\",\n regions=[\"nyc3\"])\nexample = digitalocean.Droplet(\"example\",\n image=flatcar.id,\n name=\"example-01\",\n region=digitalocean.Region.NYC3,\n size=digitalocean.DropletSlug.DROPLET_S1_VCPU1_GB,\n ssh_keys=[\"12345\"])\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var flatcar = new DigitalOcean.CustomImage(\"flatcar\", new()\n {\n Name = \"flatcar\",\n Url = \"https://stable.release.flatcar-linux.net/amd64-usr/2605.7.0/flatcar_production_digitalocean_image.bin.bz2\",\n Regions = new[]\n {\n \"nyc3\",\n },\n });\n\n var example = new DigitalOcean.Droplet(\"example\", new()\n {\n Image = flatcar.Id,\n Name = \"example-01\",\n Region = DigitalOcean.Region.NYC3,\n Size = DigitalOcean.DropletSlug.DropletS1VCPU1GB,\n SshKeys = new[]\n {\n \"12345\",\n },\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tflatcar, err := digitalocean.NewCustomImage(ctx, \"flatcar\", \u0026digitalocean.CustomImageArgs{\n\t\t\tName: pulumi.String(\"flatcar\"),\n\t\t\tUrl: pulumi.String(\"https://stable.release.flatcar-linux.net/amd64-usr/2605.7.0/flatcar_production_digitalocean_image.bin.bz2\"),\n\t\t\tRegions: pulumi.StringArray{\n\t\t\t\tpulumi.String(\"nyc3\"),\n\t\t\t},\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = digitalocean.NewDroplet(ctx, \"example\", \u0026digitalocean.DropletArgs{\n\t\t\tImage: flatcar.ID(),\n\t\t\tName: pulumi.String(\"example-01\"),\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC3),\n\t\t\tSize: pulumi.String(digitalocean.DropletSlugDropletS1VCPU1GB),\n\t\t\tSshKeys: pulumi.StringArray{\n\t\t\t\tpulumi.String(\"12345\"),\n\t\t\t},\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.digitalocean.CustomImage;\nimport com.pulumi.digitalocean.CustomImageArgs;\nimport com.pulumi.digitalocean.Droplet;\nimport com.pulumi.digitalocean.DropletArgs;\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 flatcar = new CustomImage(\"flatcar\", CustomImageArgs.builder() \n .name(\"flatcar\")\n .url(\"https://stable.release.flatcar-linux.net/amd64-usr/2605.7.0/flatcar_production_digitalocean_image.bin.bz2\")\n .regions(\"nyc3\")\n .build());\n\n var example = new Droplet(\"example\", DropletArgs.builder() \n .image(flatcar.id())\n .name(\"example-01\")\n .region(\"nyc3\")\n .size(\"s-1vcpu-1gb\")\n .sshKeys(12345)\n .build());\n\n }\n}\n```\n```yaml\nresources:\n flatcar:\n type: digitalocean:CustomImage\n properties:\n name: flatcar\n url: https://stable.release.flatcar-linux.net/amd64-usr/2605.7.0/flatcar_production_digitalocean_image.bin.bz2\n regions:\n - nyc3\n example:\n type: digitalocean:Droplet\n properties:\n image: ${flatcar.id}\n name: example-01\n region: nyc3\n size: s-1vcpu-1gb\n sshKeys:\n - 12345\n```\n\u003c!--End PulumiCodeChooser --\u003e\n", "properties": { "createdAt": { "type": "string", @@ -8343,7 +8343,7 @@ } }, "digitalocean:index/databaseCluster:DatabaseCluster": { - "description": "Provides a DigitalOcean database cluster resource.\n\n## Example Usage\n\n### Create a new PostgreSQL database cluster\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst postgres_example = new digitalocean.DatabaseCluster(\"postgres-example\", {\n engine: \"pg\",\n nodeCount: 1,\n region: digitalocean.Region.NYC1,\n size: digitalocean.DatabaseSlug.DB_1VPCU1GB,\n version: \"15\",\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\npostgres_example = digitalocean.DatabaseCluster(\"postgres-example\",\n engine=\"pg\",\n node_count=1,\n region=digitalocean.Region.NYC1,\n size=digitalocean.DatabaseSlug.D_B_1_VPCU1_GB,\n version=\"15\")\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var postgres_example = new DigitalOcean.DatabaseCluster(\"postgres-example\", new()\n {\n Engine = \"pg\",\n NodeCount = 1,\n Region = DigitalOcean.Region.NYC1,\n Size = DigitalOcean.DatabaseSlug.DB_1VPCU1GB,\n Version = \"15\",\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := digitalocean.NewDatabaseCluster(ctx, \"postgres-example\", \u0026digitalocean.DatabaseClusterArgs{\n\t\t\tEngine: pulumi.String(\"pg\"),\n\t\t\tNodeCount: pulumi.Int(1),\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC1),\n\t\t\tSize: pulumi.String(digitalocean.DatabaseSlug_DB_1VPCU1GB),\n\t\t\tVersion: pulumi.String(\"15\"),\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.digitalocean.DatabaseCluster;\nimport com.pulumi.digitalocean.DatabaseClusterArgs;\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 postgres_example = new DatabaseCluster(\"postgres-example\", DatabaseClusterArgs.builder() \n .engine(\"pg\")\n .nodeCount(1)\n .region(\"nyc1\")\n .size(\"db-s-1vcpu-1gb\")\n .version(\"15\")\n .build());\n\n }\n}\n```\n```yaml\nresources:\n postgres-example:\n type: digitalocean:DatabaseCluster\n properties:\n engine: pg\n nodeCount: 1\n region: nyc1\n size: db-s-1vcpu-1gb\n version: '15'\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n### Create a new MySQL database cluster\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst mysql_example = new digitalocean.DatabaseCluster(\"mysql-example\", {\n engine: \"mysql\",\n nodeCount: 1,\n region: digitalocean.Region.NYC1,\n size: digitalocean.DatabaseSlug.DB_1VPCU1GB,\n version: \"8\",\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nmysql_example = digitalocean.DatabaseCluster(\"mysql-example\",\n engine=\"mysql\",\n node_count=1,\n region=digitalocean.Region.NYC1,\n size=digitalocean.DatabaseSlug.D_B_1_VPCU1_GB,\n version=\"8\")\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var mysql_example = new DigitalOcean.DatabaseCluster(\"mysql-example\", new()\n {\n Engine = \"mysql\",\n NodeCount = 1,\n Region = DigitalOcean.Region.NYC1,\n Size = DigitalOcean.DatabaseSlug.DB_1VPCU1GB,\n Version = \"8\",\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := digitalocean.NewDatabaseCluster(ctx, \"mysql-example\", \u0026digitalocean.DatabaseClusterArgs{\n\t\t\tEngine: pulumi.String(\"mysql\"),\n\t\t\tNodeCount: pulumi.Int(1),\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC1),\n\t\t\tSize: pulumi.String(digitalocean.DatabaseSlug_DB_1VPCU1GB),\n\t\t\tVersion: pulumi.String(\"8\"),\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.digitalocean.DatabaseCluster;\nimport com.pulumi.digitalocean.DatabaseClusterArgs;\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 mysql_example = new DatabaseCluster(\"mysql-example\", DatabaseClusterArgs.builder() \n .engine(\"mysql\")\n .nodeCount(1)\n .region(\"nyc1\")\n .size(\"db-s-1vcpu-1gb\")\n .version(\"8\")\n .build());\n\n }\n}\n```\n```yaml\nresources:\n mysql-example:\n type: digitalocean:DatabaseCluster\n properties:\n engine: mysql\n nodeCount: 1\n region: nyc1\n size: db-s-1vcpu-1gb\n version: '8'\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n### Create a new Redis database cluster\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst redis_example = new digitalocean.DatabaseCluster(\"redis-example\", {\n engine: \"redis\",\n nodeCount: 1,\n region: digitalocean.Region.NYC1,\n size: digitalocean.DatabaseSlug.DB_1VPCU1GB,\n version: \"7\",\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nredis_example = digitalocean.DatabaseCluster(\"redis-example\",\n engine=\"redis\",\n node_count=1,\n region=digitalocean.Region.NYC1,\n size=digitalocean.DatabaseSlug.D_B_1_VPCU1_GB,\n version=\"7\")\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var redis_example = new DigitalOcean.DatabaseCluster(\"redis-example\", new()\n {\n Engine = \"redis\",\n NodeCount = 1,\n Region = DigitalOcean.Region.NYC1,\n Size = DigitalOcean.DatabaseSlug.DB_1VPCU1GB,\n Version = \"7\",\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := digitalocean.NewDatabaseCluster(ctx, \"redis-example\", \u0026digitalocean.DatabaseClusterArgs{\n\t\t\tEngine: pulumi.String(\"redis\"),\n\t\t\tNodeCount: pulumi.Int(1),\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC1),\n\t\t\tSize: pulumi.String(digitalocean.DatabaseSlug_DB_1VPCU1GB),\n\t\t\tVersion: pulumi.String(\"7\"),\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.digitalocean.DatabaseCluster;\nimport com.pulumi.digitalocean.DatabaseClusterArgs;\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 redis_example = new DatabaseCluster(\"redis-example\", DatabaseClusterArgs.builder() \n .engine(\"redis\")\n .nodeCount(1)\n .region(\"nyc1\")\n .size(\"db-s-1vcpu-1gb\")\n .version(\"7\")\n .build());\n\n }\n}\n```\n```yaml\nresources:\n redis-example:\n type: digitalocean:DatabaseCluster\n properties:\n engine: redis\n nodeCount: 1\n region: nyc1\n size: db-s-1vcpu-1gb\n version: '7'\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n### Create a new Kafka database cluster\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst kafka_example = new digitalocean.DatabaseCluster(\"kafka-example\", {\n engine: \"kafka\",\n nodeCount: 3,\n region: digitalocean.Region.NYC1,\n size: \"db-s-2vcpu-2gb\",\n version: \"3.5\",\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nkafka_example = digitalocean.DatabaseCluster(\"kafka-example\",\n engine=\"kafka\",\n node_count=3,\n region=digitalocean.Region.NYC1,\n size=\"db-s-2vcpu-2gb\",\n version=\"3.5\")\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var kafka_example = new DigitalOcean.DatabaseCluster(\"kafka-example\", new()\n {\n Engine = \"kafka\",\n NodeCount = 3,\n Region = DigitalOcean.Region.NYC1,\n Size = \"db-s-2vcpu-2gb\",\n Version = \"3.5\",\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := digitalocean.NewDatabaseCluster(ctx, \"kafka-example\", \u0026digitalocean.DatabaseClusterArgs{\n\t\t\tEngine: pulumi.String(\"kafka\"),\n\t\t\tNodeCount: pulumi.Int(3),\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC1),\n\t\t\tSize: pulumi.String(\"db-s-2vcpu-2gb\"),\n\t\t\tVersion: pulumi.String(\"3.5\"),\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.digitalocean.DatabaseCluster;\nimport com.pulumi.digitalocean.DatabaseClusterArgs;\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 kafka_example = new DatabaseCluster(\"kafka-example\", DatabaseClusterArgs.builder() \n .engine(\"kafka\")\n .nodeCount(3)\n .region(\"nyc1\")\n .size(\"db-s-2vcpu-2gb\")\n .version(\"3.5\")\n .build());\n\n }\n}\n```\n```yaml\nresources:\n kafka-example:\n type: digitalocean:DatabaseCluster\n properties:\n engine: kafka\n nodeCount: 3\n region: nyc1\n size: db-s-2vcpu-2gb\n version: '3.5'\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n### Create a new MongoDB database cluster\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst mongodb_example = new digitalocean.DatabaseCluster(\"mongodb-example\", {\n engine: \"mongodb\",\n nodeCount: 1,\n region: digitalocean.Region.NYC3,\n size: digitalocean.DatabaseSlug.DB_1VPCU1GB,\n version: \"6\",\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nmongodb_example = digitalocean.DatabaseCluster(\"mongodb-example\",\n engine=\"mongodb\",\n node_count=1,\n region=digitalocean.Region.NYC3,\n size=digitalocean.DatabaseSlug.D_B_1_VPCU1_GB,\n version=\"6\")\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var mongodb_example = new DigitalOcean.DatabaseCluster(\"mongodb-example\", new()\n {\n Engine = \"mongodb\",\n NodeCount = 1,\n Region = DigitalOcean.Region.NYC3,\n Size = DigitalOcean.DatabaseSlug.DB_1VPCU1GB,\n Version = \"6\",\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := digitalocean.NewDatabaseCluster(ctx, \"mongodb-example\", \u0026digitalocean.DatabaseClusterArgs{\n\t\t\tEngine: pulumi.String(\"mongodb\"),\n\t\t\tNodeCount: pulumi.Int(1),\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC3),\n\t\t\tSize: pulumi.String(digitalocean.DatabaseSlug_DB_1VPCU1GB),\n\t\t\tVersion: pulumi.String(\"6\"),\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.digitalocean.DatabaseCluster;\nimport com.pulumi.digitalocean.DatabaseClusterArgs;\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 mongodb_example = new DatabaseCluster(\"mongodb-example\", DatabaseClusterArgs.builder() \n .engine(\"mongodb\")\n .nodeCount(1)\n .region(\"nyc3\")\n .size(\"db-s-1vcpu-1gb\")\n .version(\"6\")\n .build());\n\n }\n}\n```\n```yaml\nresources:\n mongodb-example:\n type: digitalocean:DatabaseCluster\n properties:\n engine: mongodb\n nodeCount: 1\n region: nyc3\n size: db-s-1vcpu-1gb\n version: '6'\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n## Create a new database cluster based on a backup of an existing cluster.\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst doby = new digitalocean.DatabaseCluster(\"doby\", {\n engine: \"pg\",\n version: \"15\",\n size: digitalocean.DatabaseSlug.DB_1VPCU2GB,\n region: digitalocean.Region.NYC1,\n nodeCount: 1,\n tags: [\"production\"],\n});\nconst dobyBackup = new digitalocean.DatabaseCluster(\"dobyBackup\", {\n engine: \"pg\",\n version: \"15\",\n size: digitalocean.DatabaseSlug.DB_1VPCU2GB,\n region: digitalocean.Region.NYC1,\n nodeCount: 1,\n tags: [\"production\"],\n backupRestore: {\n databaseName: \"dobydb\",\n },\n}, {\n dependsOn: [doby],\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\ndoby = digitalocean.DatabaseCluster(\"doby\",\n engine=\"pg\",\n version=\"15\",\n size=digitalocean.DatabaseSlug.D_B_1_VPCU2_GB,\n region=digitalocean.Region.NYC1,\n node_count=1,\n tags=[\"production\"])\ndoby_backup = digitalocean.DatabaseCluster(\"dobyBackup\",\n engine=\"pg\",\n version=\"15\",\n size=digitalocean.DatabaseSlug.D_B_1_VPCU2_GB,\n region=digitalocean.Region.NYC1,\n node_count=1,\n tags=[\"production\"],\n backup_restore=digitalocean.DatabaseClusterBackupRestoreArgs(\n database_name=\"dobydb\",\n ),\n opts=pulumi.ResourceOptions(depends_on=[doby]))\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var doby = new DigitalOcean.DatabaseCluster(\"doby\", new()\n {\n Engine = \"pg\",\n Version = \"15\",\n Size = DigitalOcean.DatabaseSlug.DB_1VPCU2GB,\n Region = DigitalOcean.Region.NYC1,\n NodeCount = 1,\n Tags = new[]\n {\n \"production\",\n },\n });\n\n var dobyBackup = new DigitalOcean.DatabaseCluster(\"dobyBackup\", new()\n {\n Engine = \"pg\",\n Version = \"15\",\n Size = DigitalOcean.DatabaseSlug.DB_1VPCU2GB,\n Region = DigitalOcean.Region.NYC1,\n NodeCount = 1,\n Tags = new[]\n {\n \"production\",\n },\n BackupRestore = new DigitalOcean.Inputs.DatabaseClusterBackupRestoreArgs\n {\n DatabaseName = \"dobydb\",\n },\n }, new CustomResourceOptions\n {\n DependsOn =\n {\n doby,\n },\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tdoby, err := digitalocean.NewDatabaseCluster(ctx, \"doby\", \u0026digitalocean.DatabaseClusterArgs{\n\t\t\tEngine: pulumi.String(\"pg\"),\n\t\t\tVersion: pulumi.String(\"15\"),\n\t\t\tSize: pulumi.String(digitalocean.DatabaseSlug_DB_1VPCU2GB),\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC1),\n\t\t\tNodeCount: pulumi.Int(1),\n\t\t\tTags: pulumi.StringArray{\n\t\t\t\tpulumi.String(\"production\"),\n\t\t\t},\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = digitalocean.NewDatabaseCluster(ctx, \"dobyBackup\", \u0026digitalocean.DatabaseClusterArgs{\n\t\t\tEngine: pulumi.String(\"pg\"),\n\t\t\tVersion: pulumi.String(\"15\"),\n\t\t\tSize: pulumi.String(digitalocean.DatabaseSlug_DB_1VPCU2GB),\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC1),\n\t\t\tNodeCount: pulumi.Int(1),\n\t\t\tTags: pulumi.StringArray{\n\t\t\t\tpulumi.String(\"production\"),\n\t\t\t},\n\t\t\tBackupRestore: \u0026digitalocean.DatabaseClusterBackupRestoreArgs{\n\t\t\t\tDatabaseName: pulumi.String(\"dobydb\"),\n\t\t\t},\n\t\t}, pulumi.DependsOn([]pulumi.Resource{\n\t\t\tdoby,\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.digitalocean.DatabaseCluster;\nimport com.pulumi.digitalocean.DatabaseClusterArgs;\nimport com.pulumi.digitalocean.inputs.DatabaseClusterBackupRestoreArgs;\nimport com.pulumi.resources.CustomResourceOptions;\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 doby = new DatabaseCluster(\"doby\", DatabaseClusterArgs.builder() \n .engine(\"pg\")\n .version(\"15\")\n .size(\"db-s-1vcpu-2gb\")\n .region(\"nyc1\")\n .nodeCount(1)\n .tags(\"production\")\n .build());\n\n var dobyBackup = new DatabaseCluster(\"dobyBackup\", DatabaseClusterArgs.builder() \n .engine(\"pg\")\n .version(\"15\")\n .size(\"db-s-1vcpu-2gb\")\n .region(\"nyc1\")\n .nodeCount(1)\n .tags(\"production\")\n .backupRestore(DatabaseClusterBackupRestoreArgs.builder()\n .databaseName(\"dobydb\")\n .build())\n .build(), CustomResourceOptions.builder()\n .dependsOn(doby)\n .build());\n\n }\n}\n```\n```yaml\nresources:\n doby:\n type: digitalocean:DatabaseCluster\n properties:\n engine: pg\n version: '15'\n size: db-s-1vcpu-2gb\n region: nyc1\n nodeCount: 1\n tags:\n - production\n dobyBackup:\n type: digitalocean:DatabaseCluster\n properties:\n engine: pg\n version: '15'\n size: db-s-1vcpu-2gb\n region: nyc1\n nodeCount: 1\n tags:\n - production\n backupRestore:\n databaseName: dobydb\n options:\n dependson:\n - ${doby}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n## Import\n\nDatabase clusters can be imported using the `id` returned from DigitalOcean, e.g.\n\n```sh\n$ pulumi import digitalocean:index/databaseCluster:DatabaseCluster mycluster 245bcfd0-7f31-4ce6-a2bc-475a116cca97\n```\n\n", + "description": "Provides a DigitalOcean database cluster resource.\n\n## Example Usage\n\n### Create a new PostgreSQL database cluster\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst postgres_example = new digitalocean.DatabaseCluster(\"postgres-example\", {\n name: \"example-postgres-cluster\",\n engine: \"pg\",\n version: \"15\",\n size: digitalocean.DatabaseSlug.DB_1VPCU1GB,\n region: digitalocean.Region.NYC1,\n nodeCount: 1,\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\npostgres_example = digitalocean.DatabaseCluster(\"postgres-example\",\n name=\"example-postgres-cluster\",\n engine=\"pg\",\n version=\"15\",\n size=digitalocean.DatabaseSlug.D_B_1_VPCU1_GB,\n region=digitalocean.Region.NYC1,\n node_count=1)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var postgres_example = new DigitalOcean.DatabaseCluster(\"postgres-example\", new()\n {\n Name = \"example-postgres-cluster\",\n Engine = \"pg\",\n Version = \"15\",\n Size = DigitalOcean.DatabaseSlug.DB_1VPCU1GB,\n Region = DigitalOcean.Region.NYC1,\n NodeCount = 1,\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := digitalocean.NewDatabaseCluster(ctx, \"postgres-example\", \u0026digitalocean.DatabaseClusterArgs{\n\t\t\tName: pulumi.String(\"example-postgres-cluster\"),\n\t\t\tEngine: pulumi.String(\"pg\"),\n\t\t\tVersion: pulumi.String(\"15\"),\n\t\t\tSize: pulumi.String(digitalocean.DatabaseSlug_DB_1VPCU1GB),\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC1),\n\t\t\tNodeCount: pulumi.Int(1),\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.digitalocean.DatabaseCluster;\nimport com.pulumi.digitalocean.DatabaseClusterArgs;\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 postgres_example = new DatabaseCluster(\"postgres-example\", DatabaseClusterArgs.builder() \n .name(\"example-postgres-cluster\")\n .engine(\"pg\")\n .version(\"15\")\n .size(\"db-s-1vcpu-1gb\")\n .region(\"nyc1\")\n .nodeCount(1)\n .build());\n\n }\n}\n```\n```yaml\nresources:\n postgres-example:\n type: digitalocean:DatabaseCluster\n properties:\n name: example-postgres-cluster\n engine: pg\n version: '15'\n size: db-s-1vcpu-1gb\n region: nyc1\n nodeCount: 1\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n### Create a new MySQL database cluster\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst mysql_example = new digitalocean.DatabaseCluster(\"mysql-example\", {\n name: \"example-mysql-cluster\",\n engine: \"mysql\",\n version: \"8\",\n size: digitalocean.DatabaseSlug.DB_1VPCU1GB,\n region: digitalocean.Region.NYC1,\n nodeCount: 1,\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nmysql_example = digitalocean.DatabaseCluster(\"mysql-example\",\n name=\"example-mysql-cluster\",\n engine=\"mysql\",\n version=\"8\",\n size=digitalocean.DatabaseSlug.D_B_1_VPCU1_GB,\n region=digitalocean.Region.NYC1,\n node_count=1)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var mysql_example = new DigitalOcean.DatabaseCluster(\"mysql-example\", new()\n {\n Name = \"example-mysql-cluster\",\n Engine = \"mysql\",\n Version = \"8\",\n Size = DigitalOcean.DatabaseSlug.DB_1VPCU1GB,\n Region = DigitalOcean.Region.NYC1,\n NodeCount = 1,\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := digitalocean.NewDatabaseCluster(ctx, \"mysql-example\", \u0026digitalocean.DatabaseClusterArgs{\n\t\t\tName: pulumi.String(\"example-mysql-cluster\"),\n\t\t\tEngine: pulumi.String(\"mysql\"),\n\t\t\tVersion: pulumi.String(\"8\"),\n\t\t\tSize: pulumi.String(digitalocean.DatabaseSlug_DB_1VPCU1GB),\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC1),\n\t\t\tNodeCount: pulumi.Int(1),\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.digitalocean.DatabaseCluster;\nimport com.pulumi.digitalocean.DatabaseClusterArgs;\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 mysql_example = new DatabaseCluster(\"mysql-example\", DatabaseClusterArgs.builder() \n .name(\"example-mysql-cluster\")\n .engine(\"mysql\")\n .version(\"8\")\n .size(\"db-s-1vcpu-1gb\")\n .region(\"nyc1\")\n .nodeCount(1)\n .build());\n\n }\n}\n```\n```yaml\nresources:\n mysql-example:\n type: digitalocean:DatabaseCluster\n properties:\n name: example-mysql-cluster\n engine: mysql\n version: '8'\n size: db-s-1vcpu-1gb\n region: nyc1\n nodeCount: 1\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n### Create a new Redis database cluster\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst redis_example = new digitalocean.DatabaseCluster(\"redis-example\", {\n name: \"example-redis-cluster\",\n engine: \"redis\",\n version: \"7\",\n size: digitalocean.DatabaseSlug.DB_1VPCU1GB,\n region: digitalocean.Region.NYC1,\n nodeCount: 1,\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nredis_example = digitalocean.DatabaseCluster(\"redis-example\",\n name=\"example-redis-cluster\",\n engine=\"redis\",\n version=\"7\",\n size=digitalocean.DatabaseSlug.D_B_1_VPCU1_GB,\n region=digitalocean.Region.NYC1,\n node_count=1)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var redis_example = new DigitalOcean.DatabaseCluster(\"redis-example\", new()\n {\n Name = \"example-redis-cluster\",\n Engine = \"redis\",\n Version = \"7\",\n Size = DigitalOcean.DatabaseSlug.DB_1VPCU1GB,\n Region = DigitalOcean.Region.NYC1,\n NodeCount = 1,\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := digitalocean.NewDatabaseCluster(ctx, \"redis-example\", \u0026digitalocean.DatabaseClusterArgs{\n\t\t\tName: pulumi.String(\"example-redis-cluster\"),\n\t\t\tEngine: pulumi.String(\"redis\"),\n\t\t\tVersion: pulumi.String(\"7\"),\n\t\t\tSize: pulumi.String(digitalocean.DatabaseSlug_DB_1VPCU1GB),\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC1),\n\t\t\tNodeCount: pulumi.Int(1),\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.digitalocean.DatabaseCluster;\nimport com.pulumi.digitalocean.DatabaseClusterArgs;\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 redis_example = new DatabaseCluster(\"redis-example\", DatabaseClusterArgs.builder() \n .name(\"example-redis-cluster\")\n .engine(\"redis\")\n .version(\"7\")\n .size(\"db-s-1vcpu-1gb\")\n .region(\"nyc1\")\n .nodeCount(1)\n .build());\n\n }\n}\n```\n```yaml\nresources:\n redis-example:\n type: digitalocean:DatabaseCluster\n properties:\n name: example-redis-cluster\n engine: redis\n version: '7'\n size: db-s-1vcpu-1gb\n region: nyc1\n nodeCount: 1\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n### Create a new Kafka database cluster\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst kafka_example = new digitalocean.DatabaseCluster(\"kafka-example\", {\n name: \"example-kafka-cluster\",\n engine: \"kafka\",\n version: \"3.5\",\n size: \"db-s-2vcpu-2gb\",\n region: digitalocean.Region.NYC1,\n nodeCount: 3,\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nkafka_example = digitalocean.DatabaseCluster(\"kafka-example\",\n name=\"example-kafka-cluster\",\n engine=\"kafka\",\n version=\"3.5\",\n size=\"db-s-2vcpu-2gb\",\n region=digitalocean.Region.NYC1,\n node_count=3)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var kafka_example = new DigitalOcean.DatabaseCluster(\"kafka-example\", new()\n {\n Name = \"example-kafka-cluster\",\n Engine = \"kafka\",\n Version = \"3.5\",\n Size = \"db-s-2vcpu-2gb\",\n Region = DigitalOcean.Region.NYC1,\n NodeCount = 3,\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := digitalocean.NewDatabaseCluster(ctx, \"kafka-example\", \u0026digitalocean.DatabaseClusterArgs{\n\t\t\tName: pulumi.String(\"example-kafka-cluster\"),\n\t\t\tEngine: pulumi.String(\"kafka\"),\n\t\t\tVersion: pulumi.String(\"3.5\"),\n\t\t\tSize: pulumi.String(\"db-s-2vcpu-2gb\"),\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC1),\n\t\t\tNodeCount: pulumi.Int(3),\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.digitalocean.DatabaseCluster;\nimport com.pulumi.digitalocean.DatabaseClusterArgs;\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 kafka_example = new DatabaseCluster(\"kafka-example\", DatabaseClusterArgs.builder() \n .name(\"example-kafka-cluster\")\n .engine(\"kafka\")\n .version(\"3.5\")\n .size(\"db-s-2vcpu-2gb\")\n .region(\"nyc1\")\n .nodeCount(3)\n .build());\n\n }\n}\n```\n```yaml\nresources:\n kafka-example:\n type: digitalocean:DatabaseCluster\n properties:\n name: example-kafka-cluster\n engine: kafka\n version: '3.5'\n size: db-s-2vcpu-2gb\n region: nyc1\n nodeCount: 3\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n### Create a new MongoDB database cluster\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst mongodb_example = new digitalocean.DatabaseCluster(\"mongodb-example\", {\n name: \"example-mongo-cluster\",\n engine: \"mongodb\",\n version: \"6\",\n size: digitalocean.DatabaseSlug.DB_1VPCU1GB,\n region: digitalocean.Region.NYC3,\n nodeCount: 1,\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nmongodb_example = digitalocean.DatabaseCluster(\"mongodb-example\",\n name=\"example-mongo-cluster\",\n engine=\"mongodb\",\n version=\"6\",\n size=digitalocean.DatabaseSlug.D_B_1_VPCU1_GB,\n region=digitalocean.Region.NYC3,\n node_count=1)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var mongodb_example = new DigitalOcean.DatabaseCluster(\"mongodb-example\", new()\n {\n Name = \"example-mongo-cluster\",\n Engine = \"mongodb\",\n Version = \"6\",\n Size = DigitalOcean.DatabaseSlug.DB_1VPCU1GB,\n Region = DigitalOcean.Region.NYC3,\n NodeCount = 1,\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := digitalocean.NewDatabaseCluster(ctx, \"mongodb-example\", \u0026digitalocean.DatabaseClusterArgs{\n\t\t\tName: pulumi.String(\"example-mongo-cluster\"),\n\t\t\tEngine: pulumi.String(\"mongodb\"),\n\t\t\tVersion: pulumi.String(\"6\"),\n\t\t\tSize: pulumi.String(digitalocean.DatabaseSlug_DB_1VPCU1GB),\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC3),\n\t\t\tNodeCount: pulumi.Int(1),\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.digitalocean.DatabaseCluster;\nimport com.pulumi.digitalocean.DatabaseClusterArgs;\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 mongodb_example = new DatabaseCluster(\"mongodb-example\", DatabaseClusterArgs.builder() \n .name(\"example-mongo-cluster\")\n .engine(\"mongodb\")\n .version(\"6\")\n .size(\"db-s-1vcpu-1gb\")\n .region(\"nyc3\")\n .nodeCount(1)\n .build());\n\n }\n}\n```\n```yaml\nresources:\n mongodb-example:\n type: digitalocean:DatabaseCluster\n properties:\n name: example-mongo-cluster\n engine: mongodb\n version: '6'\n size: db-s-1vcpu-1gb\n region: nyc3\n nodeCount: 1\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n## Create a new database cluster based on a backup of an existing cluster.\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst doby = new digitalocean.DatabaseCluster(\"doby\", {\n name: \"dobydb\",\n engine: \"pg\",\n version: \"15\",\n size: digitalocean.DatabaseSlug.DB_1VPCU2GB,\n region: digitalocean.Region.NYC1,\n nodeCount: 1,\n tags: [\"production\"],\n});\nconst dobyBackup = new digitalocean.DatabaseCluster(\"doby_backup\", {\n name: \"dobydupe\",\n engine: \"pg\",\n version: \"15\",\n size: digitalocean.DatabaseSlug.DB_1VPCU2GB,\n region: digitalocean.Region.NYC1,\n nodeCount: 1,\n tags: [\"production\"],\n backupRestore: {\n databaseName: \"dobydb\",\n },\n}, {\n dependsOn: [doby],\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\ndoby = digitalocean.DatabaseCluster(\"doby\",\n name=\"dobydb\",\n engine=\"pg\",\n version=\"15\",\n size=digitalocean.DatabaseSlug.D_B_1_VPCU2_GB,\n region=digitalocean.Region.NYC1,\n node_count=1,\n tags=[\"production\"])\ndoby_backup = digitalocean.DatabaseCluster(\"doby_backup\",\n name=\"dobydupe\",\n engine=\"pg\",\n version=\"15\",\n size=digitalocean.DatabaseSlug.D_B_1_VPCU2_GB,\n region=digitalocean.Region.NYC1,\n node_count=1,\n tags=[\"production\"],\n backup_restore=digitalocean.DatabaseClusterBackupRestoreArgs(\n database_name=\"dobydb\",\n ),\n opts=pulumi.ResourceOptions(depends_on=[doby]))\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var doby = new DigitalOcean.DatabaseCluster(\"doby\", new()\n {\n Name = \"dobydb\",\n Engine = \"pg\",\n Version = \"15\",\n Size = DigitalOcean.DatabaseSlug.DB_1VPCU2GB,\n Region = DigitalOcean.Region.NYC1,\n NodeCount = 1,\n Tags = new[]\n {\n \"production\",\n },\n });\n\n var dobyBackup = new DigitalOcean.DatabaseCluster(\"doby_backup\", new()\n {\n Name = \"dobydupe\",\n Engine = \"pg\",\n Version = \"15\",\n Size = DigitalOcean.DatabaseSlug.DB_1VPCU2GB,\n Region = DigitalOcean.Region.NYC1,\n NodeCount = 1,\n Tags = new[]\n {\n \"production\",\n },\n BackupRestore = new DigitalOcean.Inputs.DatabaseClusterBackupRestoreArgs\n {\n DatabaseName = \"dobydb\",\n },\n }, new CustomResourceOptions\n {\n DependsOn =\n {\n doby,\n },\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tdoby, err := digitalocean.NewDatabaseCluster(ctx, \"doby\", \u0026digitalocean.DatabaseClusterArgs{\n\t\t\tName: pulumi.String(\"dobydb\"),\n\t\t\tEngine: pulumi.String(\"pg\"),\n\t\t\tVersion: pulumi.String(\"15\"),\n\t\t\tSize: pulumi.String(digitalocean.DatabaseSlug_DB_1VPCU2GB),\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC1),\n\t\t\tNodeCount: pulumi.Int(1),\n\t\t\tTags: pulumi.StringArray{\n\t\t\t\tpulumi.String(\"production\"),\n\t\t\t},\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = digitalocean.NewDatabaseCluster(ctx, \"doby_backup\", \u0026digitalocean.DatabaseClusterArgs{\n\t\t\tName: pulumi.String(\"dobydupe\"),\n\t\t\tEngine: pulumi.String(\"pg\"),\n\t\t\tVersion: pulumi.String(\"15\"),\n\t\t\tSize: pulumi.String(digitalocean.DatabaseSlug_DB_1VPCU2GB),\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC1),\n\t\t\tNodeCount: pulumi.Int(1),\n\t\t\tTags: pulumi.StringArray{\n\t\t\t\tpulumi.String(\"production\"),\n\t\t\t},\n\t\t\tBackupRestore: \u0026digitalocean.DatabaseClusterBackupRestoreArgs{\n\t\t\t\tDatabaseName: pulumi.String(\"dobydb\"),\n\t\t\t},\n\t\t}, pulumi.DependsOn([]pulumi.Resource{\n\t\t\tdoby,\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.digitalocean.DatabaseCluster;\nimport com.pulumi.digitalocean.DatabaseClusterArgs;\nimport com.pulumi.digitalocean.inputs.DatabaseClusterBackupRestoreArgs;\nimport com.pulumi.resources.CustomResourceOptions;\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 doby = new DatabaseCluster(\"doby\", DatabaseClusterArgs.builder() \n .name(\"dobydb\")\n .engine(\"pg\")\n .version(\"15\")\n .size(\"db-s-1vcpu-2gb\")\n .region(\"nyc1\")\n .nodeCount(1)\n .tags(\"production\")\n .build());\n\n var dobyBackup = new DatabaseCluster(\"dobyBackup\", DatabaseClusterArgs.builder() \n .name(\"dobydupe\")\n .engine(\"pg\")\n .version(\"15\")\n .size(\"db-s-1vcpu-2gb\")\n .region(\"nyc1\")\n .nodeCount(1)\n .tags(\"production\")\n .backupRestore(DatabaseClusterBackupRestoreArgs.builder()\n .databaseName(\"dobydb\")\n .build())\n .build(), CustomResourceOptions.builder()\n .dependsOn(doby)\n .build());\n\n }\n}\n```\n```yaml\nresources:\n doby:\n type: digitalocean:DatabaseCluster\n properties:\n name: dobydb\n engine: pg\n version: '15'\n size: db-s-1vcpu-2gb\n region: nyc1\n nodeCount: 1\n tags:\n - production\n dobyBackup:\n type: digitalocean:DatabaseCluster\n name: doby_backup\n properties:\n name: dobydupe\n engine: pg\n version: '15'\n size: db-s-1vcpu-2gb\n region: nyc1\n nodeCount: 1\n tags:\n - production\n backupRestore:\n databaseName: dobydb\n options:\n dependson:\n - ${doby}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n## Import\n\nDatabase clusters can be imported using the `id` returned from DigitalOcean, e.g.\n\n```sh\n$ pulumi import digitalocean:index/databaseCluster:DatabaseCluster mycluster 245bcfd0-7f31-4ce6-a2bc-475a116cca97\n```\n\n", "properties": { "backupRestore": { "$ref": "#/types/digitalocean:index/DatabaseClusterBackupRestore:DatabaseClusterBackupRestore" @@ -8744,7 +8744,7 @@ } }, "digitalocean:index/databaseConnectionPool:DatabaseConnectionPool": { - "description": "Provides a DigitalOcean database connection pool resource.\n\n## Example Usage\n\n### Create a new PostgreSQL database connection pool\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst postgres_example = new digitalocean.DatabaseCluster(\"postgres-example\", {\n engine: \"pg\",\n version: \"15\",\n size: digitalocean.DatabaseSlug.DB_1VPCU1GB,\n region: digitalocean.Region.NYC1,\n nodeCount: 1,\n});\nconst pool_01 = new digitalocean.DatabaseConnectionPool(\"pool-01\", {\n clusterId: postgres_example.id,\n mode: \"transaction\",\n size: 20,\n dbName: \"defaultdb\",\n user: \"doadmin\",\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\npostgres_example = digitalocean.DatabaseCluster(\"postgres-example\",\n engine=\"pg\",\n version=\"15\",\n size=digitalocean.DatabaseSlug.D_B_1_VPCU1_GB,\n region=digitalocean.Region.NYC1,\n node_count=1)\npool_01 = digitalocean.DatabaseConnectionPool(\"pool-01\",\n cluster_id=postgres_example.id,\n mode=\"transaction\",\n size=20,\n db_name=\"defaultdb\",\n user=\"doadmin\")\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var postgres_example = new DigitalOcean.DatabaseCluster(\"postgres-example\", new()\n {\n Engine = \"pg\",\n Version = \"15\",\n Size = DigitalOcean.DatabaseSlug.DB_1VPCU1GB,\n Region = DigitalOcean.Region.NYC1,\n NodeCount = 1,\n });\n\n var pool_01 = new DigitalOcean.DatabaseConnectionPool(\"pool-01\", new()\n {\n ClusterId = postgres_example.Id,\n Mode = \"transaction\",\n Size = 20,\n DbName = \"defaultdb\",\n User = \"doadmin\",\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := digitalocean.NewDatabaseCluster(ctx, \"postgres-example\", \u0026digitalocean.DatabaseClusterArgs{\n\t\t\tEngine: pulumi.String(\"pg\"),\n\t\t\tVersion: pulumi.String(\"15\"),\n\t\t\tSize: pulumi.String(digitalocean.DatabaseSlug_DB_1VPCU1GB),\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC1),\n\t\t\tNodeCount: pulumi.Int(1),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = digitalocean.NewDatabaseConnectionPool(ctx, \"pool-01\", \u0026digitalocean.DatabaseConnectionPoolArgs{\n\t\t\tClusterId: postgres_example.ID(),\n\t\t\tMode: pulumi.String(\"transaction\"),\n\t\t\tSize: pulumi.Int(20),\n\t\t\tDbName: pulumi.String(\"defaultdb\"),\n\t\t\tUser: pulumi.String(\"doadmin\"),\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.digitalocean.DatabaseCluster;\nimport com.pulumi.digitalocean.DatabaseClusterArgs;\nimport com.pulumi.digitalocean.DatabaseConnectionPool;\nimport com.pulumi.digitalocean.DatabaseConnectionPoolArgs;\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 postgres_example = new DatabaseCluster(\"postgres-example\", DatabaseClusterArgs.builder() \n .engine(\"pg\")\n .version(\"15\")\n .size(\"db-s-1vcpu-1gb\")\n .region(\"nyc1\")\n .nodeCount(1)\n .build());\n\n var pool_01 = new DatabaseConnectionPool(\"pool-01\", DatabaseConnectionPoolArgs.builder() \n .clusterId(postgres_example.id())\n .mode(\"transaction\")\n .size(20)\n .dbName(\"defaultdb\")\n .user(\"doadmin\")\n .build());\n\n }\n}\n```\n```yaml\nresources:\n pool-01:\n type: digitalocean:DatabaseConnectionPool\n properties:\n clusterId: ${[\"postgres-example\"].id}\n mode: transaction\n size: 20\n dbName: defaultdb\n user: doadmin\n postgres-example:\n type: digitalocean:DatabaseCluster\n properties:\n engine: pg\n version: '15'\n size: db-s-1vcpu-1gb\n region: nyc1\n nodeCount: 1\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n## Import\n\nDatabase connection pools can be imported using the `id` of the source database cluster\n\nand the `name` of the connection pool joined with a comma. For example:\n\n```sh\n$ pulumi import digitalocean:index/databaseConnectionPool:DatabaseConnectionPool pool-01 245bcfd0-7f31-4ce6-a2bc-475a116cca97,pool-01\n```\n\n", + "description": "Provides a DigitalOcean database connection pool resource.\n\n## Example Usage\n\n### Create a new PostgreSQL database connection pool\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst postgres_example = new digitalocean.DatabaseCluster(\"postgres-example\", {\n name: \"example-postgres-cluster\",\n engine: \"pg\",\n version: \"15\",\n size: digitalocean.DatabaseSlug.DB_1VPCU1GB,\n region: digitalocean.Region.NYC1,\n nodeCount: 1,\n});\nconst pool_01 = new digitalocean.DatabaseConnectionPool(\"pool-01\", {\n clusterId: postgres_example.id,\n name: \"pool-01\",\n mode: \"transaction\",\n size: 20,\n dbName: \"defaultdb\",\n user: \"doadmin\",\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\npostgres_example = digitalocean.DatabaseCluster(\"postgres-example\",\n name=\"example-postgres-cluster\",\n engine=\"pg\",\n version=\"15\",\n size=digitalocean.DatabaseSlug.D_B_1_VPCU1_GB,\n region=digitalocean.Region.NYC1,\n node_count=1)\npool_01 = digitalocean.DatabaseConnectionPool(\"pool-01\",\n cluster_id=postgres_example.id,\n name=\"pool-01\",\n mode=\"transaction\",\n size=20,\n db_name=\"defaultdb\",\n user=\"doadmin\")\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var postgres_example = new DigitalOcean.DatabaseCluster(\"postgres-example\", new()\n {\n Name = \"example-postgres-cluster\",\n Engine = \"pg\",\n Version = \"15\",\n Size = DigitalOcean.DatabaseSlug.DB_1VPCU1GB,\n Region = DigitalOcean.Region.NYC1,\n NodeCount = 1,\n });\n\n var pool_01 = new DigitalOcean.DatabaseConnectionPool(\"pool-01\", new()\n {\n ClusterId = postgres_example.Id,\n Name = \"pool-01\",\n Mode = \"transaction\",\n Size = 20,\n DbName = \"defaultdb\",\n User = \"doadmin\",\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := digitalocean.NewDatabaseCluster(ctx, \"postgres-example\", \u0026digitalocean.DatabaseClusterArgs{\n\t\t\tName: pulumi.String(\"example-postgres-cluster\"),\n\t\t\tEngine: pulumi.String(\"pg\"),\n\t\t\tVersion: pulumi.String(\"15\"),\n\t\t\tSize: pulumi.String(digitalocean.DatabaseSlug_DB_1VPCU1GB),\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC1),\n\t\t\tNodeCount: pulumi.Int(1),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = digitalocean.NewDatabaseConnectionPool(ctx, \"pool-01\", \u0026digitalocean.DatabaseConnectionPoolArgs{\n\t\t\tClusterId: postgres_example.ID(),\n\t\t\tName: pulumi.String(\"pool-01\"),\n\t\t\tMode: pulumi.String(\"transaction\"),\n\t\t\tSize: pulumi.Int(20),\n\t\t\tDbName: pulumi.String(\"defaultdb\"),\n\t\t\tUser: pulumi.String(\"doadmin\"),\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.digitalocean.DatabaseCluster;\nimport com.pulumi.digitalocean.DatabaseClusterArgs;\nimport com.pulumi.digitalocean.DatabaseConnectionPool;\nimport com.pulumi.digitalocean.DatabaseConnectionPoolArgs;\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 postgres_example = new DatabaseCluster(\"postgres-example\", DatabaseClusterArgs.builder() \n .name(\"example-postgres-cluster\")\n .engine(\"pg\")\n .version(\"15\")\n .size(\"db-s-1vcpu-1gb\")\n .region(\"nyc1\")\n .nodeCount(1)\n .build());\n\n var pool_01 = new DatabaseConnectionPool(\"pool-01\", DatabaseConnectionPoolArgs.builder() \n .clusterId(postgres_example.id())\n .name(\"pool-01\")\n .mode(\"transaction\")\n .size(20)\n .dbName(\"defaultdb\")\n .user(\"doadmin\")\n .build());\n\n }\n}\n```\n```yaml\nresources:\n pool-01:\n type: digitalocean:DatabaseConnectionPool\n properties:\n clusterId: ${[\"postgres-example\"].id}\n name: pool-01\n mode: transaction\n size: 20\n dbName: defaultdb\n user: doadmin\n postgres-example:\n type: digitalocean:DatabaseCluster\n properties:\n name: example-postgres-cluster\n engine: pg\n version: '15'\n size: db-s-1vcpu-1gb\n region: nyc1\n nodeCount: 1\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n## Import\n\nDatabase connection pools can be imported using the `id` of the source database cluster\n\nand the `name` of the connection pool joined with a comma. For example:\n\n```sh\n$ pulumi import digitalocean:index/databaseConnectionPool:DatabaseConnectionPool pool-01 245bcfd0-7f31-4ce6-a2bc-475a116cca97,pool-01\n```\n\n", "properties": { "clusterId": { "type": "string", @@ -8914,7 +8914,7 @@ } }, "digitalocean:index/databaseDb:DatabaseDb": { - "description": "Provides a DigitalOcean database resource. When creating a new database cluster, a default database with name `defaultdb` will be created. Then, this resource can be used to provide additional database inside the cluster.\n\n## Example Usage\n\n### Create a new PostgreSQL database\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst postgres_example = new digitalocean.DatabaseCluster(\"postgres-example\", {\n engine: \"pg\",\n version: \"15\",\n size: digitalocean.DatabaseSlug.DB_1VPCU1GB,\n region: digitalocean.Region.NYC1,\n nodeCount: 1,\n});\nconst database_example = new digitalocean.DatabaseDb(\"database-example\", {clusterId: postgres_example.id});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\npostgres_example = digitalocean.DatabaseCluster(\"postgres-example\",\n engine=\"pg\",\n version=\"15\",\n size=digitalocean.DatabaseSlug.D_B_1_VPCU1_GB,\n region=digitalocean.Region.NYC1,\n node_count=1)\ndatabase_example = digitalocean.DatabaseDb(\"database-example\", cluster_id=postgres_example.id)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var postgres_example = new DigitalOcean.DatabaseCluster(\"postgres-example\", new()\n {\n Engine = \"pg\",\n Version = \"15\",\n Size = DigitalOcean.DatabaseSlug.DB_1VPCU1GB,\n Region = DigitalOcean.Region.NYC1,\n NodeCount = 1,\n });\n\n var database_example = new DigitalOcean.DatabaseDb(\"database-example\", new()\n {\n ClusterId = postgres_example.Id,\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := digitalocean.NewDatabaseCluster(ctx, \"postgres-example\", \u0026digitalocean.DatabaseClusterArgs{\n\t\t\tEngine: pulumi.String(\"pg\"),\n\t\t\tVersion: pulumi.String(\"15\"),\n\t\t\tSize: pulumi.String(digitalocean.DatabaseSlug_DB_1VPCU1GB),\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC1),\n\t\t\tNodeCount: pulumi.Int(1),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = digitalocean.NewDatabaseDb(ctx, \"database-example\", \u0026digitalocean.DatabaseDbArgs{\n\t\t\tClusterId: postgres_example.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.digitalocean.DatabaseCluster;\nimport com.pulumi.digitalocean.DatabaseClusterArgs;\nimport com.pulumi.digitalocean.DatabaseDb;\nimport com.pulumi.digitalocean.DatabaseDbArgs;\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 postgres_example = new DatabaseCluster(\"postgres-example\", DatabaseClusterArgs.builder() \n .engine(\"pg\")\n .version(\"15\")\n .size(\"db-s-1vcpu-1gb\")\n .region(\"nyc1\")\n .nodeCount(1)\n .build());\n\n var database_example = new DatabaseDb(\"database-example\", DatabaseDbArgs.builder() \n .clusterId(postgres_example.id())\n .build());\n\n }\n}\n```\n```yaml\nresources:\n database-example:\n type: digitalocean:DatabaseDb\n properties:\n clusterId: ${[\"postgres-example\"].id}\n postgres-example:\n type: digitalocean:DatabaseCluster\n properties:\n engine: pg\n version: '15'\n size: db-s-1vcpu-1gb\n region: nyc1\n nodeCount: 1\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n## Import\n\nDatabase can be imported using the `id` of the source database cluster\n\nand the `name` of the database joined with a comma. For example:\n\n```sh\n$ pulumi import digitalocean:index/databaseDb:DatabaseDb database-example 245bcfd0-7f31-4ce6-a2bc-475a116cca97,foobar\n```\n\n", + "description": "Provides a DigitalOcean database resource. When creating a new database cluster, a default database with name `defaultdb` will be created. Then, this resource can be used to provide additional database inside the cluster.\n\n## Example Usage\n\n### Create a new PostgreSQL database\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst postgres_example = new digitalocean.DatabaseCluster(\"postgres-example\", {\n name: \"example-postgres-cluster\",\n engine: \"pg\",\n version: \"15\",\n size: digitalocean.DatabaseSlug.DB_1VPCU1GB,\n region: digitalocean.Region.NYC1,\n nodeCount: 1,\n});\nconst database_example = new digitalocean.DatabaseDb(\"database-example\", {\n clusterId: postgres_example.id,\n name: \"foobar\",\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\npostgres_example = digitalocean.DatabaseCluster(\"postgres-example\",\n name=\"example-postgres-cluster\",\n engine=\"pg\",\n version=\"15\",\n size=digitalocean.DatabaseSlug.D_B_1_VPCU1_GB,\n region=digitalocean.Region.NYC1,\n node_count=1)\ndatabase_example = digitalocean.DatabaseDb(\"database-example\",\n cluster_id=postgres_example.id,\n name=\"foobar\")\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var postgres_example = new DigitalOcean.DatabaseCluster(\"postgres-example\", new()\n {\n Name = \"example-postgres-cluster\",\n Engine = \"pg\",\n Version = \"15\",\n Size = DigitalOcean.DatabaseSlug.DB_1VPCU1GB,\n Region = DigitalOcean.Region.NYC1,\n NodeCount = 1,\n });\n\n var database_example = new DigitalOcean.DatabaseDb(\"database-example\", new()\n {\n ClusterId = postgres_example.Id,\n Name = \"foobar\",\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := digitalocean.NewDatabaseCluster(ctx, \"postgres-example\", \u0026digitalocean.DatabaseClusterArgs{\n\t\t\tName: pulumi.String(\"example-postgres-cluster\"),\n\t\t\tEngine: pulumi.String(\"pg\"),\n\t\t\tVersion: pulumi.String(\"15\"),\n\t\t\tSize: pulumi.String(digitalocean.DatabaseSlug_DB_1VPCU1GB),\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC1),\n\t\t\tNodeCount: pulumi.Int(1),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = digitalocean.NewDatabaseDb(ctx, \"database-example\", \u0026digitalocean.DatabaseDbArgs{\n\t\t\tClusterId: postgres_example.ID(),\n\t\t\tName: pulumi.String(\"foobar\"),\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.digitalocean.DatabaseCluster;\nimport com.pulumi.digitalocean.DatabaseClusterArgs;\nimport com.pulumi.digitalocean.DatabaseDb;\nimport com.pulumi.digitalocean.DatabaseDbArgs;\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 postgres_example = new DatabaseCluster(\"postgres-example\", DatabaseClusterArgs.builder() \n .name(\"example-postgres-cluster\")\n .engine(\"pg\")\n .version(\"15\")\n .size(\"db-s-1vcpu-1gb\")\n .region(\"nyc1\")\n .nodeCount(1)\n .build());\n\n var database_example = new DatabaseDb(\"database-example\", DatabaseDbArgs.builder() \n .clusterId(postgres_example.id())\n .name(\"foobar\")\n .build());\n\n }\n}\n```\n```yaml\nresources:\n database-example:\n type: digitalocean:DatabaseDb\n properties:\n clusterId: ${[\"postgres-example\"].id}\n name: foobar\n postgres-example:\n type: digitalocean:DatabaseCluster\n properties:\n name: example-postgres-cluster\n engine: pg\n version: '15'\n size: db-s-1vcpu-1gb\n region: nyc1\n nodeCount: 1\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n## Import\n\nDatabase can be imported using the `id` of the source database cluster\n\nand the `name` of the database joined with a comma. For example:\n\n```sh\n$ pulumi import digitalocean:index/databaseDb:DatabaseDb database-example 245bcfd0-7f31-4ce6-a2bc-475a116cca97,foobar\n```\n\n", "properties": { "clusterId": { "type": "string", @@ -8962,7 +8962,7 @@ } }, "digitalocean:index/databaseFirewall:DatabaseFirewall": { - "description": "Provides a DigitalOcean database firewall resource allowing you to restrict\nconnections to your database to trusted sources. You may limit connections to\nspecific Droplets, Kubernetes clusters, or IP addresses.\n\n## Example Usage\n\n### Create a new database firewall allowing multiple IP addresses\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst postgres_example = new digitalocean.DatabaseCluster(\"postgres-example\", {\n engine: \"pg\",\n version: \"15\",\n size: digitalocean.DatabaseSlug.DB_1VPCU1GB,\n region: digitalocean.Region.NYC1,\n nodeCount: 1,\n});\nconst example_fw = new digitalocean.DatabaseFirewall(\"example-fw\", {\n clusterId: postgres_example.id,\n rules: [\n {\n type: \"ip_addr\",\n value: \"192.168.1.1\",\n },\n {\n type: \"ip_addr\",\n value: \"192.0.2.0\",\n },\n ],\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\npostgres_example = digitalocean.DatabaseCluster(\"postgres-example\",\n engine=\"pg\",\n version=\"15\",\n size=digitalocean.DatabaseSlug.D_B_1_VPCU1_GB,\n region=digitalocean.Region.NYC1,\n node_count=1)\nexample_fw = digitalocean.DatabaseFirewall(\"example-fw\",\n cluster_id=postgres_example.id,\n rules=[\n digitalocean.DatabaseFirewallRuleArgs(\n type=\"ip_addr\",\n value=\"192.168.1.1\",\n ),\n digitalocean.DatabaseFirewallRuleArgs(\n type=\"ip_addr\",\n value=\"192.0.2.0\",\n ),\n ])\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var postgres_example = new DigitalOcean.DatabaseCluster(\"postgres-example\", new()\n {\n Engine = \"pg\",\n Version = \"15\",\n Size = DigitalOcean.DatabaseSlug.DB_1VPCU1GB,\n Region = DigitalOcean.Region.NYC1,\n NodeCount = 1,\n });\n\n var example_fw = new DigitalOcean.DatabaseFirewall(\"example-fw\", new()\n {\n ClusterId = postgres_example.Id,\n Rules = new[]\n {\n new DigitalOcean.Inputs.DatabaseFirewallRuleArgs\n {\n Type = \"ip_addr\",\n Value = \"192.168.1.1\",\n },\n new DigitalOcean.Inputs.DatabaseFirewallRuleArgs\n {\n Type = \"ip_addr\",\n Value = \"192.0.2.0\",\n },\n },\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := digitalocean.NewDatabaseCluster(ctx, \"postgres-example\", \u0026digitalocean.DatabaseClusterArgs{\n\t\t\tEngine: pulumi.String(\"pg\"),\n\t\t\tVersion: pulumi.String(\"15\"),\n\t\t\tSize: pulumi.String(digitalocean.DatabaseSlug_DB_1VPCU1GB),\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC1),\n\t\t\tNodeCount: pulumi.Int(1),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = digitalocean.NewDatabaseFirewall(ctx, \"example-fw\", \u0026digitalocean.DatabaseFirewallArgs{\n\t\t\tClusterId: postgres_example.ID(),\n\t\t\tRules: digitalocean.DatabaseFirewallRuleArray{\n\t\t\t\t\u0026digitalocean.DatabaseFirewallRuleArgs{\n\t\t\t\t\tType: pulumi.String(\"ip_addr\"),\n\t\t\t\t\tValue: pulumi.String(\"192.168.1.1\"),\n\t\t\t\t},\n\t\t\t\t\u0026digitalocean.DatabaseFirewallRuleArgs{\n\t\t\t\t\tType: pulumi.String(\"ip_addr\"),\n\t\t\t\t\tValue: pulumi.String(\"192.0.2.0\"),\n\t\t\t\t},\n\t\t\t},\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.digitalocean.DatabaseCluster;\nimport com.pulumi.digitalocean.DatabaseClusterArgs;\nimport com.pulumi.digitalocean.DatabaseFirewall;\nimport com.pulumi.digitalocean.DatabaseFirewallArgs;\nimport com.pulumi.digitalocean.inputs.DatabaseFirewallRuleArgs;\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 postgres_example = new DatabaseCluster(\"postgres-example\", DatabaseClusterArgs.builder() \n .engine(\"pg\")\n .version(\"15\")\n .size(\"db-s-1vcpu-1gb\")\n .region(\"nyc1\")\n .nodeCount(1)\n .build());\n\n var example_fw = new DatabaseFirewall(\"example-fw\", DatabaseFirewallArgs.builder() \n .clusterId(postgres_example.id())\n .rules( \n DatabaseFirewallRuleArgs.builder()\n .type(\"ip_addr\")\n .value(\"192.168.1.1\")\n .build(),\n DatabaseFirewallRuleArgs.builder()\n .type(\"ip_addr\")\n .value(\"192.0.2.0\")\n .build())\n .build());\n\n }\n}\n```\n```yaml\nresources:\n example-fw:\n type: digitalocean:DatabaseFirewall\n properties:\n clusterId: ${[\"postgres-example\"].id}\n rules:\n - type: ip_addr\n value: 192.168.1.1\n - type: ip_addr\n value: 192.0.2.0\n postgres-example:\n type: digitalocean:DatabaseCluster\n properties:\n engine: pg\n version: '15'\n size: db-s-1vcpu-1gb\n region: nyc1\n nodeCount: 1\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n### Create a new database firewall allowing a Droplet\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst web = new digitalocean.Droplet(\"web\", {\n size: digitalocean.DropletSlug.DropletS1VCPU1GB,\n image: \"ubuntu-22-04-x64\",\n region: digitalocean.Region.NYC3,\n});\nconst postgres_example = new digitalocean.DatabaseCluster(\"postgres-example\", {\n engine: \"pg\",\n version: \"15\",\n size: digitalocean.DatabaseSlug.DB_1VPCU1GB,\n region: digitalocean.Region.NYC1,\n nodeCount: 1,\n});\nconst example_fw = new digitalocean.DatabaseFirewall(\"example-fw\", {\n clusterId: postgres_example.id,\n rules: [{\n type: \"droplet\",\n value: web.id,\n }],\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nweb = digitalocean.Droplet(\"web\",\n size=digitalocean.DropletSlug.DROPLET_S1_VCPU1_GB,\n image=\"ubuntu-22-04-x64\",\n region=digitalocean.Region.NYC3)\npostgres_example = digitalocean.DatabaseCluster(\"postgres-example\",\n engine=\"pg\",\n version=\"15\",\n size=digitalocean.DatabaseSlug.D_B_1_VPCU1_GB,\n region=digitalocean.Region.NYC1,\n node_count=1)\nexample_fw = digitalocean.DatabaseFirewall(\"example-fw\",\n cluster_id=postgres_example.id,\n rules=[digitalocean.DatabaseFirewallRuleArgs(\n type=\"droplet\",\n value=web.id,\n )])\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var web = new DigitalOcean.Droplet(\"web\", new()\n {\n Size = DigitalOcean.DropletSlug.DropletS1VCPU1GB,\n Image = \"ubuntu-22-04-x64\",\n Region = DigitalOcean.Region.NYC3,\n });\n\n var postgres_example = new DigitalOcean.DatabaseCluster(\"postgres-example\", new()\n {\n Engine = \"pg\",\n Version = \"15\",\n Size = DigitalOcean.DatabaseSlug.DB_1VPCU1GB,\n Region = DigitalOcean.Region.NYC1,\n NodeCount = 1,\n });\n\n var example_fw = new DigitalOcean.DatabaseFirewall(\"example-fw\", new()\n {\n ClusterId = postgres_example.Id,\n Rules = new[]\n {\n new DigitalOcean.Inputs.DatabaseFirewallRuleArgs\n {\n Type = \"droplet\",\n Value = web.Id,\n },\n },\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tweb, err := digitalocean.NewDroplet(ctx, \"web\", \u0026digitalocean.DropletArgs{\n\t\t\tSize: pulumi.String(digitalocean.DropletSlugDropletS1VCPU1GB),\n\t\t\tImage: pulumi.String(\"ubuntu-22-04-x64\"),\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC3),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = digitalocean.NewDatabaseCluster(ctx, \"postgres-example\", \u0026digitalocean.DatabaseClusterArgs{\n\t\t\tEngine: pulumi.String(\"pg\"),\n\t\t\tVersion: pulumi.String(\"15\"),\n\t\t\tSize: pulumi.String(digitalocean.DatabaseSlug_DB_1VPCU1GB),\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC1),\n\t\t\tNodeCount: pulumi.Int(1),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = digitalocean.NewDatabaseFirewall(ctx, \"example-fw\", \u0026digitalocean.DatabaseFirewallArgs{\n\t\t\tClusterId: postgres_example.ID(),\n\t\t\tRules: digitalocean.DatabaseFirewallRuleArray{\n\t\t\t\t\u0026digitalocean.DatabaseFirewallRuleArgs{\n\t\t\t\t\tType: pulumi.String(\"droplet\"),\n\t\t\t\t\tValue: web.ID(),\n\t\t\t\t},\n\t\t\t},\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.digitalocean.Droplet;\nimport com.pulumi.digitalocean.DropletArgs;\nimport com.pulumi.digitalocean.DatabaseCluster;\nimport com.pulumi.digitalocean.DatabaseClusterArgs;\nimport com.pulumi.digitalocean.DatabaseFirewall;\nimport com.pulumi.digitalocean.DatabaseFirewallArgs;\nimport com.pulumi.digitalocean.inputs.DatabaseFirewallRuleArgs;\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 web = new Droplet(\"web\", DropletArgs.builder() \n .size(\"s-1vcpu-1gb\")\n .image(\"ubuntu-22-04-x64\")\n .region(\"nyc3\")\n .build());\n\n var postgres_example = new DatabaseCluster(\"postgres-example\", DatabaseClusterArgs.builder() \n .engine(\"pg\")\n .version(\"15\")\n .size(\"db-s-1vcpu-1gb\")\n .region(\"nyc1\")\n .nodeCount(1)\n .build());\n\n var example_fw = new DatabaseFirewall(\"example-fw\", DatabaseFirewallArgs.builder() \n .clusterId(postgres_example.id())\n .rules(DatabaseFirewallRuleArgs.builder()\n .type(\"droplet\")\n .value(web.id())\n .build())\n .build());\n\n }\n}\n```\n```yaml\nresources:\n example-fw:\n type: digitalocean:DatabaseFirewall\n properties:\n clusterId: ${[\"postgres-example\"].id}\n rules:\n - type: droplet\n value: ${web.id}\n web:\n type: digitalocean:Droplet\n properties:\n size: s-1vcpu-1gb\n image: ubuntu-22-04-x64\n region: nyc3\n postgres-example:\n type: digitalocean:DatabaseCluster\n properties:\n engine: pg\n version: '15'\n size: db-s-1vcpu-1gb\n region: nyc1\n nodeCount: 1\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n### Create a new database firewall for a database replica\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst postgres_example = new digitalocean.DatabaseCluster(\"postgres-example\", {\n engine: \"pg\",\n version: \"15\",\n size: digitalocean.DatabaseSlug.DB_1VPCU1GB,\n region: digitalocean.Region.NYC1,\n nodeCount: 1,\n});\nconst replica_example = new digitalocean.DatabaseReplica(\"replica-example\", {\n clusterId: postgres_example.id,\n size: digitalocean.DatabaseSlug.DB_1VPCU1GB,\n region: digitalocean.Region.NYC1,\n});\n// Create firewall rule for database replica\nconst example_fw = new digitalocean.DatabaseFirewall(\"example-fw\", {\n clusterId: replica_example.uuid,\n rules: [{\n type: \"ip_addr\",\n value: \"192.168.1.1\",\n }],\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\npostgres_example = digitalocean.DatabaseCluster(\"postgres-example\",\n engine=\"pg\",\n version=\"15\",\n size=digitalocean.DatabaseSlug.D_B_1_VPCU1_GB,\n region=digitalocean.Region.NYC1,\n node_count=1)\nreplica_example = digitalocean.DatabaseReplica(\"replica-example\",\n cluster_id=postgres_example.id,\n size=digitalocean.DatabaseSlug.D_B_1_VPCU1_GB,\n region=digitalocean.Region.NYC1)\n# Create firewall rule for database replica\nexample_fw = digitalocean.DatabaseFirewall(\"example-fw\",\n cluster_id=replica_example.uuid,\n rules=[digitalocean.DatabaseFirewallRuleArgs(\n type=\"ip_addr\",\n value=\"192.168.1.1\",\n )])\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var postgres_example = new DigitalOcean.DatabaseCluster(\"postgres-example\", new()\n {\n Engine = \"pg\",\n Version = \"15\",\n Size = DigitalOcean.DatabaseSlug.DB_1VPCU1GB,\n Region = DigitalOcean.Region.NYC1,\n NodeCount = 1,\n });\n\n var replica_example = new DigitalOcean.DatabaseReplica(\"replica-example\", new()\n {\n ClusterId = postgres_example.Id,\n Size = DigitalOcean.DatabaseSlug.DB_1VPCU1GB,\n Region = DigitalOcean.Region.NYC1,\n });\n\n // Create firewall rule for database replica\n var example_fw = new DigitalOcean.DatabaseFirewall(\"example-fw\", new()\n {\n ClusterId = replica_example.Uuid,\n Rules = new[]\n {\n new DigitalOcean.Inputs.DatabaseFirewallRuleArgs\n {\n Type = \"ip_addr\",\n Value = \"192.168.1.1\",\n },\n },\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := digitalocean.NewDatabaseCluster(ctx, \"postgres-example\", \u0026digitalocean.DatabaseClusterArgs{\n\t\t\tEngine: pulumi.String(\"pg\"),\n\t\t\tVersion: pulumi.String(\"15\"),\n\t\t\tSize: pulumi.String(digitalocean.DatabaseSlug_DB_1VPCU1GB),\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC1),\n\t\t\tNodeCount: pulumi.Int(1),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = digitalocean.NewDatabaseReplica(ctx, \"replica-example\", \u0026digitalocean.DatabaseReplicaArgs{\n\t\t\tClusterId: postgres_example.ID(),\n\t\t\tSize: pulumi.String(digitalocean.DatabaseSlug_DB_1VPCU1GB),\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC1),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t// Create firewall rule for database replica\n\t\t_, err = digitalocean.NewDatabaseFirewall(ctx, \"example-fw\", \u0026digitalocean.DatabaseFirewallArgs{\n\t\t\tClusterId: replica_example.Uuid,\n\t\t\tRules: digitalocean.DatabaseFirewallRuleArray{\n\t\t\t\t\u0026digitalocean.DatabaseFirewallRuleArgs{\n\t\t\t\t\tType: pulumi.String(\"ip_addr\"),\n\t\t\t\t\tValue: pulumi.String(\"192.168.1.1\"),\n\t\t\t\t},\n\t\t\t},\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.digitalocean.DatabaseCluster;\nimport com.pulumi.digitalocean.DatabaseClusterArgs;\nimport com.pulumi.digitalocean.DatabaseReplica;\nimport com.pulumi.digitalocean.DatabaseReplicaArgs;\nimport com.pulumi.digitalocean.DatabaseFirewall;\nimport com.pulumi.digitalocean.DatabaseFirewallArgs;\nimport com.pulumi.digitalocean.inputs.DatabaseFirewallRuleArgs;\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 postgres_example = new DatabaseCluster(\"postgres-example\", DatabaseClusterArgs.builder() \n .engine(\"pg\")\n .version(\"15\")\n .size(\"db-s-1vcpu-1gb\")\n .region(\"nyc1\")\n .nodeCount(1)\n .build());\n\n var replica_example = new DatabaseReplica(\"replica-example\", DatabaseReplicaArgs.builder() \n .clusterId(postgres_example.id())\n .size(\"db-s-1vcpu-1gb\")\n .region(\"nyc1\")\n .build());\n\n // Create firewall rule for database replica\n var example_fw = new DatabaseFirewall(\"example-fw\", DatabaseFirewallArgs.builder() \n .clusterId(replica_example.uuid())\n .rules(DatabaseFirewallRuleArgs.builder()\n .type(\"ip_addr\")\n .value(\"192.168.1.1\")\n .build())\n .build());\n\n }\n}\n```\n```yaml\nresources:\n postgres-example:\n type: digitalocean:DatabaseCluster\n properties:\n engine: pg\n version: '15'\n size: db-s-1vcpu-1gb\n region: nyc1\n nodeCount: 1\n replica-example:\n type: digitalocean:DatabaseReplica\n properties:\n clusterId: ${[\"postgres-example\"].id}\n size: db-s-1vcpu-1gb\n region: nyc1\n # Create firewall rule for database replica\n example-fw:\n type: digitalocean:DatabaseFirewall\n properties:\n clusterId: ${[\"replica-example\"].uuid}\n rules:\n - type: ip_addr\n value: 192.168.1.1\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n## Import\n\nDatabase firewalls can be imported using the `id` of the target database cluster\n\nFor example:\n\n```sh\n$ pulumi import digitalocean:index/databaseFirewall:DatabaseFirewall example-fw 5f55c6cd-863b-4907-99b8-7e09b0275d54\n```\n\n", + "description": "Provides a DigitalOcean database firewall resource allowing you to restrict\nconnections to your database to trusted sources. You may limit connections to\nspecific Droplets, Kubernetes clusters, or IP addresses.\n\n## Example Usage\n\n### Create a new database firewall allowing multiple IP addresses\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst postgres_example = new digitalocean.DatabaseCluster(\"postgres-example\", {\n name: \"example-postgres-cluster\",\n engine: \"pg\",\n version: \"15\",\n size: digitalocean.DatabaseSlug.DB_1VPCU1GB,\n region: digitalocean.Region.NYC1,\n nodeCount: 1,\n});\nconst example_fw = new digitalocean.DatabaseFirewall(\"example-fw\", {\n clusterId: postgres_example.id,\n rules: [\n {\n type: \"ip_addr\",\n value: \"192.168.1.1\",\n },\n {\n type: \"ip_addr\",\n value: \"192.0.2.0\",\n },\n ],\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\npostgres_example = digitalocean.DatabaseCluster(\"postgres-example\",\n name=\"example-postgres-cluster\",\n engine=\"pg\",\n version=\"15\",\n size=digitalocean.DatabaseSlug.D_B_1_VPCU1_GB,\n region=digitalocean.Region.NYC1,\n node_count=1)\nexample_fw = digitalocean.DatabaseFirewall(\"example-fw\",\n cluster_id=postgres_example.id,\n rules=[\n digitalocean.DatabaseFirewallRuleArgs(\n type=\"ip_addr\",\n value=\"192.168.1.1\",\n ),\n digitalocean.DatabaseFirewallRuleArgs(\n type=\"ip_addr\",\n value=\"192.0.2.0\",\n ),\n ])\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var postgres_example = new DigitalOcean.DatabaseCluster(\"postgres-example\", new()\n {\n Name = \"example-postgres-cluster\",\n Engine = \"pg\",\n Version = \"15\",\n Size = DigitalOcean.DatabaseSlug.DB_1VPCU1GB,\n Region = DigitalOcean.Region.NYC1,\n NodeCount = 1,\n });\n\n var example_fw = new DigitalOcean.DatabaseFirewall(\"example-fw\", new()\n {\n ClusterId = postgres_example.Id,\n Rules = new[]\n {\n new DigitalOcean.Inputs.DatabaseFirewallRuleArgs\n {\n Type = \"ip_addr\",\n Value = \"192.168.1.1\",\n },\n new DigitalOcean.Inputs.DatabaseFirewallRuleArgs\n {\n Type = \"ip_addr\",\n Value = \"192.0.2.0\",\n },\n },\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := digitalocean.NewDatabaseCluster(ctx, \"postgres-example\", \u0026digitalocean.DatabaseClusterArgs{\n\t\t\tName: pulumi.String(\"example-postgres-cluster\"),\n\t\t\tEngine: pulumi.String(\"pg\"),\n\t\t\tVersion: pulumi.String(\"15\"),\n\t\t\tSize: pulumi.String(digitalocean.DatabaseSlug_DB_1VPCU1GB),\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC1),\n\t\t\tNodeCount: pulumi.Int(1),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = digitalocean.NewDatabaseFirewall(ctx, \"example-fw\", \u0026digitalocean.DatabaseFirewallArgs{\n\t\t\tClusterId: postgres_example.ID(),\n\t\t\tRules: digitalocean.DatabaseFirewallRuleArray{\n\t\t\t\t\u0026digitalocean.DatabaseFirewallRuleArgs{\n\t\t\t\t\tType: pulumi.String(\"ip_addr\"),\n\t\t\t\t\tValue: pulumi.String(\"192.168.1.1\"),\n\t\t\t\t},\n\t\t\t\t\u0026digitalocean.DatabaseFirewallRuleArgs{\n\t\t\t\t\tType: pulumi.String(\"ip_addr\"),\n\t\t\t\t\tValue: pulumi.String(\"192.0.2.0\"),\n\t\t\t\t},\n\t\t\t},\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.digitalocean.DatabaseCluster;\nimport com.pulumi.digitalocean.DatabaseClusterArgs;\nimport com.pulumi.digitalocean.DatabaseFirewall;\nimport com.pulumi.digitalocean.DatabaseFirewallArgs;\nimport com.pulumi.digitalocean.inputs.DatabaseFirewallRuleArgs;\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 postgres_example = new DatabaseCluster(\"postgres-example\", DatabaseClusterArgs.builder() \n .name(\"example-postgres-cluster\")\n .engine(\"pg\")\n .version(\"15\")\n .size(\"db-s-1vcpu-1gb\")\n .region(\"nyc1\")\n .nodeCount(1)\n .build());\n\n var example_fw = new DatabaseFirewall(\"example-fw\", DatabaseFirewallArgs.builder() \n .clusterId(postgres_example.id())\n .rules( \n DatabaseFirewallRuleArgs.builder()\n .type(\"ip_addr\")\n .value(\"192.168.1.1\")\n .build(),\n DatabaseFirewallRuleArgs.builder()\n .type(\"ip_addr\")\n .value(\"192.0.2.0\")\n .build())\n .build());\n\n }\n}\n```\n```yaml\nresources:\n example-fw:\n type: digitalocean:DatabaseFirewall\n properties:\n clusterId: ${[\"postgres-example\"].id}\n rules:\n - type: ip_addr\n value: 192.168.1.1\n - type: ip_addr\n value: 192.0.2.0\n postgres-example:\n type: digitalocean:DatabaseCluster\n properties:\n name: example-postgres-cluster\n engine: pg\n version: '15'\n size: db-s-1vcpu-1gb\n region: nyc1\n nodeCount: 1\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n### Create a new database firewall allowing a Droplet\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst web = new digitalocean.Droplet(\"web\", {\n name: \"web-01\",\n size: digitalocean.DropletSlug.DropletS1VCPU1GB,\n image: \"ubuntu-22-04-x64\",\n region: digitalocean.Region.NYC3,\n});\nconst postgres_example = new digitalocean.DatabaseCluster(\"postgres-example\", {\n name: \"example-postgres-cluster\",\n engine: \"pg\",\n version: \"15\",\n size: digitalocean.DatabaseSlug.DB_1VPCU1GB,\n region: digitalocean.Region.NYC1,\n nodeCount: 1,\n});\nconst example_fw = new digitalocean.DatabaseFirewall(\"example-fw\", {\n clusterId: postgres_example.id,\n rules: [{\n type: \"droplet\",\n value: web.id,\n }],\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nweb = digitalocean.Droplet(\"web\",\n name=\"web-01\",\n size=digitalocean.DropletSlug.DROPLET_S1_VCPU1_GB,\n image=\"ubuntu-22-04-x64\",\n region=digitalocean.Region.NYC3)\npostgres_example = digitalocean.DatabaseCluster(\"postgres-example\",\n name=\"example-postgres-cluster\",\n engine=\"pg\",\n version=\"15\",\n size=digitalocean.DatabaseSlug.D_B_1_VPCU1_GB,\n region=digitalocean.Region.NYC1,\n node_count=1)\nexample_fw = digitalocean.DatabaseFirewall(\"example-fw\",\n cluster_id=postgres_example.id,\n rules=[digitalocean.DatabaseFirewallRuleArgs(\n type=\"droplet\",\n value=web.id,\n )])\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var web = new DigitalOcean.Droplet(\"web\", new()\n {\n Name = \"web-01\",\n Size = DigitalOcean.DropletSlug.DropletS1VCPU1GB,\n Image = \"ubuntu-22-04-x64\",\n Region = DigitalOcean.Region.NYC3,\n });\n\n var postgres_example = new DigitalOcean.DatabaseCluster(\"postgres-example\", new()\n {\n Name = \"example-postgres-cluster\",\n Engine = \"pg\",\n Version = \"15\",\n Size = DigitalOcean.DatabaseSlug.DB_1VPCU1GB,\n Region = DigitalOcean.Region.NYC1,\n NodeCount = 1,\n });\n\n var example_fw = new DigitalOcean.DatabaseFirewall(\"example-fw\", new()\n {\n ClusterId = postgres_example.Id,\n Rules = new[]\n {\n new DigitalOcean.Inputs.DatabaseFirewallRuleArgs\n {\n Type = \"droplet\",\n Value = web.Id,\n },\n },\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tweb, err := digitalocean.NewDroplet(ctx, \"web\", \u0026digitalocean.DropletArgs{\n\t\t\tName: pulumi.String(\"web-01\"),\n\t\t\tSize: pulumi.String(digitalocean.DropletSlugDropletS1VCPU1GB),\n\t\t\tImage: pulumi.String(\"ubuntu-22-04-x64\"),\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC3),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = digitalocean.NewDatabaseCluster(ctx, \"postgres-example\", \u0026digitalocean.DatabaseClusterArgs{\n\t\t\tName: pulumi.String(\"example-postgres-cluster\"),\n\t\t\tEngine: pulumi.String(\"pg\"),\n\t\t\tVersion: pulumi.String(\"15\"),\n\t\t\tSize: pulumi.String(digitalocean.DatabaseSlug_DB_1VPCU1GB),\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC1),\n\t\t\tNodeCount: pulumi.Int(1),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = digitalocean.NewDatabaseFirewall(ctx, \"example-fw\", \u0026digitalocean.DatabaseFirewallArgs{\n\t\t\tClusterId: postgres_example.ID(),\n\t\t\tRules: digitalocean.DatabaseFirewallRuleArray{\n\t\t\t\t\u0026digitalocean.DatabaseFirewallRuleArgs{\n\t\t\t\t\tType: pulumi.String(\"droplet\"),\n\t\t\t\t\tValue: web.ID(),\n\t\t\t\t},\n\t\t\t},\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.digitalocean.Droplet;\nimport com.pulumi.digitalocean.DropletArgs;\nimport com.pulumi.digitalocean.DatabaseCluster;\nimport com.pulumi.digitalocean.DatabaseClusterArgs;\nimport com.pulumi.digitalocean.DatabaseFirewall;\nimport com.pulumi.digitalocean.DatabaseFirewallArgs;\nimport com.pulumi.digitalocean.inputs.DatabaseFirewallRuleArgs;\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 web = new Droplet(\"web\", DropletArgs.builder() \n .name(\"web-01\")\n .size(\"s-1vcpu-1gb\")\n .image(\"ubuntu-22-04-x64\")\n .region(\"nyc3\")\n .build());\n\n var postgres_example = new DatabaseCluster(\"postgres-example\", DatabaseClusterArgs.builder() \n .name(\"example-postgres-cluster\")\n .engine(\"pg\")\n .version(\"15\")\n .size(\"db-s-1vcpu-1gb\")\n .region(\"nyc1\")\n .nodeCount(1)\n .build());\n\n var example_fw = new DatabaseFirewall(\"example-fw\", DatabaseFirewallArgs.builder() \n .clusterId(postgres_example.id())\n .rules(DatabaseFirewallRuleArgs.builder()\n .type(\"droplet\")\n .value(web.id())\n .build())\n .build());\n\n }\n}\n```\n```yaml\nresources:\n example-fw:\n type: digitalocean:DatabaseFirewall\n properties:\n clusterId: ${[\"postgres-example\"].id}\n rules:\n - type: droplet\n value: ${web.id}\n web:\n type: digitalocean:Droplet\n properties:\n name: web-01\n size: s-1vcpu-1gb\n image: ubuntu-22-04-x64\n region: nyc3\n postgres-example:\n type: digitalocean:DatabaseCluster\n properties:\n name: example-postgres-cluster\n engine: pg\n version: '15'\n size: db-s-1vcpu-1gb\n region: nyc1\n nodeCount: 1\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n### Create a new database firewall for a database replica\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst postgres_example = new digitalocean.DatabaseCluster(\"postgres-example\", {\n name: \"example-postgres-cluster\",\n engine: \"pg\",\n version: \"15\",\n size: digitalocean.DatabaseSlug.DB_1VPCU1GB,\n region: digitalocean.Region.NYC1,\n nodeCount: 1,\n});\nconst replica_example = new digitalocean.DatabaseReplica(\"replica-example\", {\n clusterId: postgres_example.id,\n name: \"replica-example\",\n size: digitalocean.DatabaseSlug.DB_1VPCU1GB,\n region: digitalocean.Region.NYC1,\n});\n// Create firewall rule for database replica\nconst example_fw = new digitalocean.DatabaseFirewall(\"example-fw\", {\n clusterId: replica_example.uuid,\n rules: [{\n type: \"ip_addr\",\n value: \"192.168.1.1\",\n }],\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\npostgres_example = digitalocean.DatabaseCluster(\"postgres-example\",\n name=\"example-postgres-cluster\",\n engine=\"pg\",\n version=\"15\",\n size=digitalocean.DatabaseSlug.D_B_1_VPCU1_GB,\n region=digitalocean.Region.NYC1,\n node_count=1)\nreplica_example = digitalocean.DatabaseReplica(\"replica-example\",\n cluster_id=postgres_example.id,\n name=\"replica-example\",\n size=digitalocean.DatabaseSlug.D_B_1_VPCU1_GB,\n region=digitalocean.Region.NYC1)\n# Create firewall rule for database replica\nexample_fw = digitalocean.DatabaseFirewall(\"example-fw\",\n cluster_id=replica_example.uuid,\n rules=[digitalocean.DatabaseFirewallRuleArgs(\n type=\"ip_addr\",\n value=\"192.168.1.1\",\n )])\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var postgres_example = new DigitalOcean.DatabaseCluster(\"postgres-example\", new()\n {\n Name = \"example-postgres-cluster\",\n Engine = \"pg\",\n Version = \"15\",\n Size = DigitalOcean.DatabaseSlug.DB_1VPCU1GB,\n Region = DigitalOcean.Region.NYC1,\n NodeCount = 1,\n });\n\n var replica_example = new DigitalOcean.DatabaseReplica(\"replica-example\", new()\n {\n ClusterId = postgres_example.Id,\n Name = \"replica-example\",\n Size = DigitalOcean.DatabaseSlug.DB_1VPCU1GB,\n Region = DigitalOcean.Region.NYC1,\n });\n\n // Create firewall rule for database replica\n var example_fw = new DigitalOcean.DatabaseFirewall(\"example-fw\", new()\n {\n ClusterId = replica_example.Uuid,\n Rules = new[]\n {\n new DigitalOcean.Inputs.DatabaseFirewallRuleArgs\n {\n Type = \"ip_addr\",\n Value = \"192.168.1.1\",\n },\n },\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := digitalocean.NewDatabaseCluster(ctx, \"postgres-example\", \u0026digitalocean.DatabaseClusterArgs{\n\t\t\tName: pulumi.String(\"example-postgres-cluster\"),\n\t\t\tEngine: pulumi.String(\"pg\"),\n\t\t\tVersion: pulumi.String(\"15\"),\n\t\t\tSize: pulumi.String(digitalocean.DatabaseSlug_DB_1VPCU1GB),\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC1),\n\t\t\tNodeCount: pulumi.Int(1),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = digitalocean.NewDatabaseReplica(ctx, \"replica-example\", \u0026digitalocean.DatabaseReplicaArgs{\n\t\t\tClusterId: postgres_example.ID(),\n\t\t\tName: pulumi.String(\"replica-example\"),\n\t\t\tSize: pulumi.String(digitalocean.DatabaseSlug_DB_1VPCU1GB),\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC1),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t// Create firewall rule for database replica\n\t\t_, err = digitalocean.NewDatabaseFirewall(ctx, \"example-fw\", \u0026digitalocean.DatabaseFirewallArgs{\n\t\t\tClusterId: replica_example.Uuid,\n\t\t\tRules: digitalocean.DatabaseFirewallRuleArray{\n\t\t\t\t\u0026digitalocean.DatabaseFirewallRuleArgs{\n\t\t\t\t\tType: pulumi.String(\"ip_addr\"),\n\t\t\t\t\tValue: pulumi.String(\"192.168.1.1\"),\n\t\t\t\t},\n\t\t\t},\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.digitalocean.DatabaseCluster;\nimport com.pulumi.digitalocean.DatabaseClusterArgs;\nimport com.pulumi.digitalocean.DatabaseReplica;\nimport com.pulumi.digitalocean.DatabaseReplicaArgs;\nimport com.pulumi.digitalocean.DatabaseFirewall;\nimport com.pulumi.digitalocean.DatabaseFirewallArgs;\nimport com.pulumi.digitalocean.inputs.DatabaseFirewallRuleArgs;\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 postgres_example = new DatabaseCluster(\"postgres-example\", DatabaseClusterArgs.builder() \n .name(\"example-postgres-cluster\")\n .engine(\"pg\")\n .version(\"15\")\n .size(\"db-s-1vcpu-1gb\")\n .region(\"nyc1\")\n .nodeCount(1)\n .build());\n\n var replica_example = new DatabaseReplica(\"replica-example\", DatabaseReplicaArgs.builder() \n .clusterId(postgres_example.id())\n .name(\"replica-example\")\n .size(\"db-s-1vcpu-1gb\")\n .region(\"nyc1\")\n .build());\n\n // Create firewall rule for database replica\n var example_fw = new DatabaseFirewall(\"example-fw\", DatabaseFirewallArgs.builder() \n .clusterId(replica_example.uuid())\n .rules(DatabaseFirewallRuleArgs.builder()\n .type(\"ip_addr\")\n .value(\"192.168.1.1\")\n .build())\n .build());\n\n }\n}\n```\n```yaml\nresources:\n postgres-example:\n type: digitalocean:DatabaseCluster\n properties:\n name: example-postgres-cluster\n engine: pg\n version: '15'\n size: db-s-1vcpu-1gb\n region: nyc1\n nodeCount: 1\n replica-example:\n type: digitalocean:DatabaseReplica\n properties:\n clusterId: ${[\"postgres-example\"].id}\n name: replica-example\n size: db-s-1vcpu-1gb\n region: nyc1\n # Create firewall rule for database replica\n example-fw:\n type: digitalocean:DatabaseFirewall\n properties:\n clusterId: ${[\"replica-example\"].uuid}\n rules:\n - type: ip_addr\n value: 192.168.1.1\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n## Import\n\nDatabase firewalls can be imported using the `id` of the target database cluster\n\nFor example:\n\n```sh\n$ pulumi import digitalocean:index/databaseFirewall:DatabaseFirewall example-fw 5f55c6cd-863b-4907-99b8-7e09b0275d54\n```\n\n", "properties": { "clusterId": { "type": "string", @@ -9018,7 +9018,7 @@ } }, "digitalocean:index/databaseKafkaTopic:DatabaseKafkaTopic": { - "description": "Provides a DigitalOcean Kafka topic for Kafka clusters.\n\n## Example Usage\n\n### Create a new Kafka topic\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst kafka_example = new digitalocean.DatabaseCluster(\"kafka-example\", {\n engine: \"kafka\",\n version: \"3.5\",\n size: \"db-s-2vcpu-2gb\",\n region: digitalocean.Region.NYC1,\n nodeCount: 3,\n tags: [\"production\"],\n});\nconst topic_01 = new digitalocean.DatabaseKafkaTopic(\"topic-01\", {\n clusterId: kafka_example.id,\n partitionCount: 3,\n replicationFactor: 2,\n configs: [{\n cleanupPolicy: \"compact\",\n compressionType: \"uncompressed\",\n deleteRetentionMs: \"14000\",\n fileDeleteDelayMs: \"170000\",\n flushMessages: \"92233\",\n flushMs: \"92233720368\",\n indexIntervalBytes: \"40962\",\n maxCompactionLagMs: \"9223372036854775807\",\n maxMessageBytes: \"1048588\",\n messageDownConversionEnable: true,\n messageFormatVersion: \"3.0-IV1\",\n messageTimestampDifferenceMaxMs: \"9223372036854775807\",\n messageTimestampType: \"log_append_time\",\n minCleanableDirtyRatio: 0.5,\n minCompactionLagMs: \"20000\",\n minInsyncReplicas: 2,\n preallocate: false,\n retentionBytes: \"-1\",\n retentionMs: \"-1\",\n segmentBytes: \"209715200\",\n segmentIndexBytes: \"10485760\",\n segmentJitterMs: \"0\",\n segmentMs: \"604800000\",\n }],\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nkafka_example = digitalocean.DatabaseCluster(\"kafka-example\",\n engine=\"kafka\",\n version=\"3.5\",\n size=\"db-s-2vcpu-2gb\",\n region=digitalocean.Region.NYC1,\n node_count=3,\n tags=[\"production\"])\ntopic_01 = digitalocean.DatabaseKafkaTopic(\"topic-01\",\n cluster_id=kafka_example.id,\n partition_count=3,\n replication_factor=2,\n configs=[digitalocean.DatabaseKafkaTopicConfigArgs(\n cleanup_policy=\"compact\",\n compression_type=\"uncompressed\",\n delete_retention_ms=\"14000\",\n file_delete_delay_ms=\"170000\",\n flush_messages=\"92233\",\n flush_ms=\"92233720368\",\n index_interval_bytes=\"40962\",\n max_compaction_lag_ms=\"9223372036854775807\",\n max_message_bytes=\"1048588\",\n message_down_conversion_enable=True,\n message_format_version=\"3.0-IV1\",\n message_timestamp_difference_max_ms=\"9223372036854775807\",\n message_timestamp_type=\"log_append_time\",\n min_cleanable_dirty_ratio=0.5,\n min_compaction_lag_ms=\"20000\",\n min_insync_replicas=2,\n preallocate=False,\n retention_bytes=\"-1\",\n retention_ms=\"-1\",\n segment_bytes=\"209715200\",\n segment_index_bytes=\"10485760\",\n segment_jitter_ms=\"0\",\n segment_ms=\"604800000\",\n )])\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var kafka_example = new DigitalOcean.DatabaseCluster(\"kafka-example\", new()\n {\n Engine = \"kafka\",\n Version = \"3.5\",\n Size = \"db-s-2vcpu-2gb\",\n Region = DigitalOcean.Region.NYC1,\n NodeCount = 3,\n Tags = new[]\n {\n \"production\",\n },\n });\n\n var topic_01 = new DigitalOcean.DatabaseKafkaTopic(\"topic-01\", new()\n {\n ClusterId = kafka_example.Id,\n PartitionCount = 3,\n ReplicationFactor = 2,\n Configs = new[]\n {\n new DigitalOcean.Inputs.DatabaseKafkaTopicConfigArgs\n {\n CleanupPolicy = \"compact\",\n CompressionType = \"uncompressed\",\n DeleteRetentionMs = \"14000\",\n FileDeleteDelayMs = \"170000\",\n FlushMessages = \"92233\",\n FlushMs = \"92233720368\",\n IndexIntervalBytes = \"40962\",\n MaxCompactionLagMs = \"9223372036854775807\",\n MaxMessageBytes = \"1048588\",\n MessageDownConversionEnable = true,\n MessageFormatVersion = \"3.0-IV1\",\n MessageTimestampDifferenceMaxMs = \"9223372036854775807\",\n MessageTimestampType = \"log_append_time\",\n MinCleanableDirtyRatio = 0.5,\n MinCompactionLagMs = \"20000\",\n MinInsyncReplicas = 2,\n Preallocate = false,\n RetentionBytes = \"-1\",\n RetentionMs = \"-1\",\n SegmentBytes = \"209715200\",\n SegmentIndexBytes = \"10485760\",\n SegmentJitterMs = \"0\",\n SegmentMs = \"604800000\",\n },\n },\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := digitalocean.NewDatabaseCluster(ctx, \"kafka-example\", \u0026digitalocean.DatabaseClusterArgs{\n\t\t\tEngine: pulumi.String(\"kafka\"),\n\t\t\tVersion: pulumi.String(\"3.5\"),\n\t\t\tSize: pulumi.String(\"db-s-2vcpu-2gb\"),\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC1),\n\t\t\tNodeCount: pulumi.Int(3),\n\t\t\tTags: pulumi.StringArray{\n\t\t\t\tpulumi.String(\"production\"),\n\t\t\t},\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = digitalocean.NewDatabaseKafkaTopic(ctx, \"topic-01\", \u0026digitalocean.DatabaseKafkaTopicArgs{\n\t\t\tClusterId: kafka_example.ID(),\n\t\t\tPartitionCount: pulumi.Int(3),\n\t\t\tReplicationFactor: pulumi.Int(2),\n\t\t\tConfigs: digitalocean.DatabaseKafkaTopicConfigArray{\n\t\t\t\t\u0026digitalocean.DatabaseKafkaTopicConfigArgs{\n\t\t\t\t\tCleanupPolicy: pulumi.String(\"compact\"),\n\t\t\t\t\tCompressionType: pulumi.String(\"uncompressed\"),\n\t\t\t\t\tDeleteRetentionMs: pulumi.String(\"14000\"),\n\t\t\t\t\tFileDeleteDelayMs: pulumi.String(\"170000\"),\n\t\t\t\t\tFlushMessages: pulumi.String(\"92233\"),\n\t\t\t\t\tFlushMs: pulumi.String(\"92233720368\"),\n\t\t\t\t\tIndexIntervalBytes: pulumi.String(\"40962\"),\n\t\t\t\t\tMaxCompactionLagMs: pulumi.String(\"9223372036854775807\"),\n\t\t\t\t\tMaxMessageBytes: pulumi.String(\"1048588\"),\n\t\t\t\t\tMessageDownConversionEnable: pulumi.Bool(true),\n\t\t\t\t\tMessageFormatVersion: pulumi.String(\"3.0-IV1\"),\n\t\t\t\t\tMessageTimestampDifferenceMaxMs: pulumi.String(\"9223372036854775807\"),\n\t\t\t\t\tMessageTimestampType: pulumi.String(\"log_append_time\"),\n\t\t\t\t\tMinCleanableDirtyRatio: pulumi.Float64(0.5),\n\t\t\t\t\tMinCompactionLagMs: pulumi.String(\"20000\"),\n\t\t\t\t\tMinInsyncReplicas: pulumi.Int(2),\n\t\t\t\t\tPreallocate: pulumi.Bool(false),\n\t\t\t\t\tRetentionBytes: pulumi.String(\"-1\"),\n\t\t\t\t\tRetentionMs: pulumi.String(\"-1\"),\n\t\t\t\t\tSegmentBytes: pulumi.String(\"209715200\"),\n\t\t\t\t\tSegmentIndexBytes: pulumi.String(\"10485760\"),\n\t\t\t\t\tSegmentJitterMs: pulumi.String(\"0\"),\n\t\t\t\t\tSegmentMs: pulumi.String(\"604800000\"),\n\t\t\t\t},\n\t\t\t},\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.digitalocean.DatabaseCluster;\nimport com.pulumi.digitalocean.DatabaseClusterArgs;\nimport com.pulumi.digitalocean.DatabaseKafkaTopic;\nimport com.pulumi.digitalocean.DatabaseKafkaTopicArgs;\nimport com.pulumi.digitalocean.inputs.DatabaseKafkaTopicConfigArgs;\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 kafka_example = new DatabaseCluster(\"kafka-example\", DatabaseClusterArgs.builder() \n .engine(\"kafka\")\n .version(\"3.5\")\n .size(\"db-s-2vcpu-2gb\")\n .region(\"nyc1\")\n .nodeCount(3)\n .tags(\"production\")\n .build());\n\n var topic_01 = new DatabaseKafkaTopic(\"topic-01\", DatabaseKafkaTopicArgs.builder() \n .clusterId(kafka_example.id())\n .partitionCount(3)\n .replicationFactor(2)\n .configs(DatabaseKafkaTopicConfigArgs.builder()\n .cleanupPolicy(\"compact\")\n .compressionType(\"uncompressed\")\n .deleteRetentionMs(14000)\n .fileDeleteDelayMs(170000)\n .flushMessages(92233)\n .flushMs(92233720368)\n .indexIntervalBytes(40962)\n .maxCompactionLagMs(9223372036854775807)\n .maxMessageBytes(1048588)\n .messageDownConversionEnable(true)\n .messageFormatVersion(\"3.0-IV1\")\n .messageTimestampDifferenceMaxMs(9223372036854775807)\n .messageTimestampType(\"log_append_time\")\n .minCleanableDirtyRatio(0.5)\n .minCompactionLagMs(20000)\n .minInsyncReplicas(2)\n .preallocate(false)\n .retentionBytes(\"TODO: GenUnaryOpExpression\")\n .retentionMs(\"TODO: GenUnaryOpExpression\")\n .segmentBytes(209715200)\n .segmentIndexBytes(10485760)\n .segmentJitterMs(0)\n .segmentMs(604800000)\n .build())\n .build());\n\n }\n}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n## Import\n\nTopics can be imported using the `id` of the source cluster and the `name` of the topic joined with a comma. For example:\n\n```sh\n$ pulumi import digitalocean:index/databaseKafkaTopic:DatabaseKafkaTopic topic-01 245bcfd0-7f31-4ce6-a2bc-475a116cca97,topic-01\n```\n\n", + "description": "Provides a DigitalOcean Kafka topic for Kafka clusters.\n\n## Example Usage\n\n### Create a new Kafka topic\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst kafka_example = new digitalocean.DatabaseCluster(\"kafka-example\", {\n name: \"example-kafka-cluster\",\n engine: \"kafka\",\n version: \"3.5\",\n size: \"db-s-2vcpu-2gb\",\n region: digitalocean.Region.NYC1,\n nodeCount: 3,\n tags: [\"production\"],\n});\nconst topic_01 = new digitalocean.DatabaseKafkaTopic(\"topic-01\", {\n clusterId: kafka_example.id,\n name: \"topic-01\",\n partitionCount: 3,\n replicationFactor: 2,\n configs: [{\n cleanupPolicy: \"compact\",\n compressionType: \"uncompressed\",\n deleteRetentionMs: \"14000\",\n fileDeleteDelayMs: \"170000\",\n flushMessages: \"92233\",\n flushMs: \"92233720368\",\n indexIntervalBytes: \"40962\",\n maxCompactionLagMs: \"9223372036854775807\",\n maxMessageBytes: \"1048588\",\n messageDownConversionEnable: true,\n messageFormatVersion: \"3.0-IV1\",\n messageTimestampDifferenceMaxMs: \"9223372036854775807\",\n messageTimestampType: \"log_append_time\",\n minCleanableDirtyRatio: 0.5,\n minCompactionLagMs: \"20000\",\n minInsyncReplicas: 2,\n preallocate: false,\n retentionBytes: \"-1\",\n retentionMs: \"-1\",\n segmentBytes: \"209715200\",\n segmentIndexBytes: \"10485760\",\n segmentJitterMs: \"0\",\n segmentMs: \"604800000\",\n }],\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nkafka_example = digitalocean.DatabaseCluster(\"kafka-example\",\n name=\"example-kafka-cluster\",\n engine=\"kafka\",\n version=\"3.5\",\n size=\"db-s-2vcpu-2gb\",\n region=digitalocean.Region.NYC1,\n node_count=3,\n tags=[\"production\"])\ntopic_01 = digitalocean.DatabaseKafkaTopic(\"topic-01\",\n cluster_id=kafka_example.id,\n name=\"topic-01\",\n partition_count=3,\n replication_factor=2,\n configs=[digitalocean.DatabaseKafkaTopicConfigArgs(\n cleanup_policy=\"compact\",\n compression_type=\"uncompressed\",\n delete_retention_ms=\"14000\",\n file_delete_delay_ms=\"170000\",\n flush_messages=\"92233\",\n flush_ms=\"92233720368\",\n index_interval_bytes=\"40962\",\n max_compaction_lag_ms=\"9223372036854775807\",\n max_message_bytes=\"1048588\",\n message_down_conversion_enable=True,\n message_format_version=\"3.0-IV1\",\n message_timestamp_difference_max_ms=\"9223372036854775807\",\n message_timestamp_type=\"log_append_time\",\n min_cleanable_dirty_ratio=0.5,\n min_compaction_lag_ms=\"20000\",\n min_insync_replicas=2,\n preallocate=False,\n retention_bytes=\"-1\",\n retention_ms=\"-1\",\n segment_bytes=\"209715200\",\n segment_index_bytes=\"10485760\",\n segment_jitter_ms=\"0\",\n segment_ms=\"604800000\",\n )])\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var kafka_example = new DigitalOcean.DatabaseCluster(\"kafka-example\", new()\n {\n Name = \"example-kafka-cluster\",\n Engine = \"kafka\",\n Version = \"3.5\",\n Size = \"db-s-2vcpu-2gb\",\n Region = DigitalOcean.Region.NYC1,\n NodeCount = 3,\n Tags = new[]\n {\n \"production\",\n },\n });\n\n var topic_01 = new DigitalOcean.DatabaseKafkaTopic(\"topic-01\", new()\n {\n ClusterId = kafka_example.Id,\n Name = \"topic-01\",\n PartitionCount = 3,\n ReplicationFactor = 2,\n Configs = new[]\n {\n new DigitalOcean.Inputs.DatabaseKafkaTopicConfigArgs\n {\n CleanupPolicy = \"compact\",\n CompressionType = \"uncompressed\",\n DeleteRetentionMs = \"14000\",\n FileDeleteDelayMs = \"170000\",\n FlushMessages = \"92233\",\n FlushMs = \"92233720368\",\n IndexIntervalBytes = \"40962\",\n MaxCompactionLagMs = \"9223372036854775807\",\n MaxMessageBytes = \"1048588\",\n MessageDownConversionEnable = true,\n MessageFormatVersion = \"3.0-IV1\",\n MessageTimestampDifferenceMaxMs = \"9223372036854775807\",\n MessageTimestampType = \"log_append_time\",\n MinCleanableDirtyRatio = 0.5,\n MinCompactionLagMs = \"20000\",\n MinInsyncReplicas = 2,\n Preallocate = false,\n RetentionBytes = \"-1\",\n RetentionMs = \"-1\",\n SegmentBytes = \"209715200\",\n SegmentIndexBytes = \"10485760\",\n SegmentJitterMs = \"0\",\n SegmentMs = \"604800000\",\n },\n },\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := digitalocean.NewDatabaseCluster(ctx, \"kafka-example\", \u0026digitalocean.DatabaseClusterArgs{\n\t\t\tName: pulumi.String(\"example-kafka-cluster\"),\n\t\t\tEngine: pulumi.String(\"kafka\"),\n\t\t\tVersion: pulumi.String(\"3.5\"),\n\t\t\tSize: pulumi.String(\"db-s-2vcpu-2gb\"),\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC1),\n\t\t\tNodeCount: pulumi.Int(3),\n\t\t\tTags: pulumi.StringArray{\n\t\t\t\tpulumi.String(\"production\"),\n\t\t\t},\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = digitalocean.NewDatabaseKafkaTopic(ctx, \"topic-01\", \u0026digitalocean.DatabaseKafkaTopicArgs{\n\t\t\tClusterId: kafka_example.ID(),\n\t\t\tName: pulumi.String(\"topic-01\"),\n\t\t\tPartitionCount: pulumi.Int(3),\n\t\t\tReplicationFactor: pulumi.Int(2),\n\t\t\tConfigs: digitalocean.DatabaseKafkaTopicConfigArray{\n\t\t\t\t\u0026digitalocean.DatabaseKafkaTopicConfigArgs{\n\t\t\t\t\tCleanupPolicy: pulumi.String(\"compact\"),\n\t\t\t\t\tCompressionType: pulumi.String(\"uncompressed\"),\n\t\t\t\t\tDeleteRetentionMs: pulumi.String(\"14000\"),\n\t\t\t\t\tFileDeleteDelayMs: pulumi.String(\"170000\"),\n\t\t\t\t\tFlushMessages: pulumi.String(\"92233\"),\n\t\t\t\t\tFlushMs: pulumi.String(\"92233720368\"),\n\t\t\t\t\tIndexIntervalBytes: pulumi.String(\"40962\"),\n\t\t\t\t\tMaxCompactionLagMs: pulumi.String(\"9223372036854775807\"),\n\t\t\t\t\tMaxMessageBytes: pulumi.String(\"1048588\"),\n\t\t\t\t\tMessageDownConversionEnable: pulumi.Bool(true),\n\t\t\t\t\tMessageFormatVersion: pulumi.String(\"3.0-IV1\"),\n\t\t\t\t\tMessageTimestampDifferenceMaxMs: pulumi.String(\"9223372036854775807\"),\n\t\t\t\t\tMessageTimestampType: pulumi.String(\"log_append_time\"),\n\t\t\t\t\tMinCleanableDirtyRatio: pulumi.Float64(0.5),\n\t\t\t\t\tMinCompactionLagMs: pulumi.String(\"20000\"),\n\t\t\t\t\tMinInsyncReplicas: pulumi.Int(2),\n\t\t\t\t\tPreallocate: pulumi.Bool(false),\n\t\t\t\t\tRetentionBytes: pulumi.String(\"-1\"),\n\t\t\t\t\tRetentionMs: pulumi.String(\"-1\"),\n\t\t\t\t\tSegmentBytes: pulumi.String(\"209715200\"),\n\t\t\t\t\tSegmentIndexBytes: pulumi.String(\"10485760\"),\n\t\t\t\t\tSegmentJitterMs: pulumi.String(\"0\"),\n\t\t\t\t\tSegmentMs: pulumi.String(\"604800000\"),\n\t\t\t\t},\n\t\t\t},\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\u003c!--End PulumiCodeChooser --\u003e\n\n## Import\n\nTopics can be imported using the `id` of the source cluster and the `name` of the topic joined with a comma. For example:\n\n```sh\n$ pulumi import digitalocean:index/databaseKafkaTopic:DatabaseKafkaTopic topic-01 245bcfd0-7f31-4ce6-a2bc-475a116cca97,topic-01\n```\n\n", "properties": { "clusterId": { "type": "string", @@ -9121,7 +9121,7 @@ } }, "digitalocean:index/databaseMysqlConfig:DatabaseMysqlConfig": { - "description": "Provides a virtual resource that can be used to change advanced configuration\noptions for a DigitalOcean managed MySQL database cluster.\n\n\u003e **Note** MySQL configurations are only removed from state when destroyed. The remote configuration is not unset.\n\n## Example Usage\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst exampleDatabaseCluster = new digitalocean.DatabaseCluster(\"exampleDatabaseCluster\", {\n engine: \"mysql\",\n version: \"8\",\n size: digitalocean.DatabaseSlug.DB_1VPCU1GB,\n region: digitalocean.Region.NYC1,\n nodeCount: 1,\n});\nconst exampleDatabaseMysqlConfig = new digitalocean.DatabaseMysqlConfig(\"exampleDatabaseMysqlConfig\", {\n clusterId: exampleDatabaseCluster.id,\n connectTimeout: 10,\n defaultTimeZone: \"UTC\",\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nexample_database_cluster = digitalocean.DatabaseCluster(\"exampleDatabaseCluster\",\n engine=\"mysql\",\n version=\"8\",\n size=digitalocean.DatabaseSlug.D_B_1_VPCU1_GB,\n region=digitalocean.Region.NYC1,\n node_count=1)\nexample_database_mysql_config = digitalocean.DatabaseMysqlConfig(\"exampleDatabaseMysqlConfig\",\n cluster_id=example_database_cluster.id,\n connect_timeout=10,\n default_time_zone=\"UTC\")\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var exampleDatabaseCluster = new DigitalOcean.DatabaseCluster(\"exampleDatabaseCluster\", new()\n {\n Engine = \"mysql\",\n Version = \"8\",\n Size = DigitalOcean.DatabaseSlug.DB_1VPCU1GB,\n Region = DigitalOcean.Region.NYC1,\n NodeCount = 1,\n });\n\n var exampleDatabaseMysqlConfig = new DigitalOcean.DatabaseMysqlConfig(\"exampleDatabaseMysqlConfig\", new()\n {\n ClusterId = exampleDatabaseCluster.Id,\n ConnectTimeout = 10,\n DefaultTimeZone = \"UTC\",\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\texampleDatabaseCluster, err := digitalocean.NewDatabaseCluster(ctx, \"exampleDatabaseCluster\", \u0026digitalocean.DatabaseClusterArgs{\n\t\t\tEngine: pulumi.String(\"mysql\"),\n\t\t\tVersion: pulumi.String(\"8\"),\n\t\t\tSize: pulumi.String(digitalocean.DatabaseSlug_DB_1VPCU1GB),\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC1),\n\t\t\tNodeCount: pulumi.Int(1),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = digitalocean.NewDatabaseMysqlConfig(ctx, \"exampleDatabaseMysqlConfig\", \u0026digitalocean.DatabaseMysqlConfigArgs{\n\t\t\tClusterId: exampleDatabaseCluster.ID(),\n\t\t\tConnectTimeout: pulumi.Int(10),\n\t\t\tDefaultTimeZone: pulumi.String(\"UTC\"),\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.digitalocean.DatabaseCluster;\nimport com.pulumi.digitalocean.DatabaseClusterArgs;\nimport com.pulumi.digitalocean.DatabaseMysqlConfig;\nimport com.pulumi.digitalocean.DatabaseMysqlConfigArgs;\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 exampleDatabaseCluster = new DatabaseCluster(\"exampleDatabaseCluster\", DatabaseClusterArgs.builder() \n .engine(\"mysql\")\n .version(\"8\")\n .size(\"db-s-1vcpu-1gb\")\n .region(\"nyc1\")\n .nodeCount(1)\n .build());\n\n var exampleDatabaseMysqlConfig = new DatabaseMysqlConfig(\"exampleDatabaseMysqlConfig\", DatabaseMysqlConfigArgs.builder() \n .clusterId(exampleDatabaseCluster.id())\n .connectTimeout(10)\n .defaultTimeZone(\"UTC\")\n .build());\n\n }\n}\n```\n```yaml\nresources:\n exampleDatabaseMysqlConfig:\n type: digitalocean:DatabaseMysqlConfig\n properties:\n clusterId: ${exampleDatabaseCluster.id}\n connectTimeout: 10\n defaultTimeZone: UTC\n exampleDatabaseCluster:\n type: digitalocean:DatabaseCluster\n properties:\n engine: mysql\n version: '8'\n size: db-s-1vcpu-1gb\n region: nyc1\n nodeCount: 1\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n## Import\n\nA MySQL database cluster's configuration can be imported using the `id` the parent cluster, e.g.\n\n```sh\n$ pulumi import digitalocean:index/databaseMysqlConfig:DatabaseMysqlConfig example 4b62829a-9c42-465b-aaa3-84051048e712\n```\n\n", + "description": "Provides a virtual resource that can be used to change advanced configuration\noptions for a DigitalOcean managed MySQL database cluster.\n\n\u003e **Note** MySQL configurations are only removed from state when destroyed. The remote configuration is not unset.\n\n## Example Usage\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst exampleDatabaseCluster = new digitalocean.DatabaseCluster(\"example\", {\n name: \"example-mysql-cluster\",\n engine: \"mysql\",\n version: \"8\",\n size: digitalocean.DatabaseSlug.DB_1VPCU1GB,\n region: digitalocean.Region.NYC1,\n nodeCount: 1,\n});\nconst example = new digitalocean.DatabaseMysqlConfig(\"example\", {\n clusterId: exampleDatabaseCluster.id,\n connectTimeout: 10,\n defaultTimeZone: \"UTC\",\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nexample_database_cluster = digitalocean.DatabaseCluster(\"example\",\n name=\"example-mysql-cluster\",\n engine=\"mysql\",\n version=\"8\",\n size=digitalocean.DatabaseSlug.D_B_1_VPCU1_GB,\n region=digitalocean.Region.NYC1,\n node_count=1)\nexample = digitalocean.DatabaseMysqlConfig(\"example\",\n cluster_id=example_database_cluster.id,\n connect_timeout=10,\n default_time_zone=\"UTC\")\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var exampleDatabaseCluster = new DigitalOcean.DatabaseCluster(\"example\", new()\n {\n Name = \"example-mysql-cluster\",\n Engine = \"mysql\",\n Version = \"8\",\n Size = DigitalOcean.DatabaseSlug.DB_1VPCU1GB,\n Region = DigitalOcean.Region.NYC1,\n NodeCount = 1,\n });\n\n var example = new DigitalOcean.DatabaseMysqlConfig(\"example\", new()\n {\n ClusterId = exampleDatabaseCluster.Id,\n ConnectTimeout = 10,\n DefaultTimeZone = \"UTC\",\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\texampleDatabaseCluster, err := digitalocean.NewDatabaseCluster(ctx, \"example\", \u0026digitalocean.DatabaseClusterArgs{\n\t\t\tName: pulumi.String(\"example-mysql-cluster\"),\n\t\t\tEngine: pulumi.String(\"mysql\"),\n\t\t\tVersion: pulumi.String(\"8\"),\n\t\t\tSize: pulumi.String(digitalocean.DatabaseSlug_DB_1VPCU1GB),\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC1),\n\t\t\tNodeCount: pulumi.Int(1),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = digitalocean.NewDatabaseMysqlConfig(ctx, \"example\", \u0026digitalocean.DatabaseMysqlConfigArgs{\n\t\t\tClusterId: exampleDatabaseCluster.ID(),\n\t\t\tConnectTimeout: pulumi.Int(10),\n\t\t\tDefaultTimeZone: pulumi.String(\"UTC\"),\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.digitalocean.DatabaseCluster;\nimport com.pulumi.digitalocean.DatabaseClusterArgs;\nimport com.pulumi.digitalocean.DatabaseMysqlConfig;\nimport com.pulumi.digitalocean.DatabaseMysqlConfigArgs;\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 exampleDatabaseCluster = new DatabaseCluster(\"exampleDatabaseCluster\", DatabaseClusterArgs.builder() \n .name(\"example-mysql-cluster\")\n .engine(\"mysql\")\n .version(\"8\")\n .size(\"db-s-1vcpu-1gb\")\n .region(\"nyc1\")\n .nodeCount(1)\n .build());\n\n var example = new DatabaseMysqlConfig(\"example\", DatabaseMysqlConfigArgs.builder() \n .clusterId(exampleDatabaseCluster.id())\n .connectTimeout(10)\n .defaultTimeZone(\"UTC\")\n .build());\n\n }\n}\n```\n```yaml\nresources:\n example:\n type: digitalocean:DatabaseMysqlConfig\n properties:\n clusterId: ${exampleDatabaseCluster.id}\n connectTimeout: 10\n defaultTimeZone: UTC\n exampleDatabaseCluster:\n type: digitalocean:DatabaseCluster\n name: example\n properties:\n name: example-mysql-cluster\n engine: mysql\n version: '8'\n size: db-s-1vcpu-1gb\n region: nyc1\n nodeCount: 1\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n## Import\n\nA MySQL database cluster's configuration can be imported using the `id` the parent cluster, e.g.\n\n```sh\n$ pulumi import digitalocean:index/databaseMysqlConfig:DatabaseMysqlConfig example 4b62829a-9c42-465b-aaa3-84051048e712\n```\n\n", "properties": { "backupHour": { "type": "integer", @@ -9505,7 +9505,7 @@ } }, "digitalocean:index/databasePostgresqlConfig:DatabasePostgresqlConfig": { - "description": "Provides a virtual resource that can be used to change advanced configuration\noptions for a DigitalOcean managed PostgreSQL database cluster.\n\n\u003e **Note** PostgreSQL configurations are only removed from state when destroyed. The remote configuration is not unset.\n\n## Example Usage\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst exampleDatabaseCluster = new digitalocean.DatabaseCluster(\"exampleDatabaseCluster\", {\n engine: \"pg\",\n version: \"15\",\n size: digitalocean.DatabaseSlug.DB_1VPCU1GB,\n region: digitalocean.Region.NYC1,\n nodeCount: 1,\n});\nconst exampleDatabasePostgresqlConfig = new digitalocean.DatabasePostgresqlConfig(\"exampleDatabasePostgresqlConfig\", {\n clusterId: exampleDatabaseCluster.id,\n timezone: \"UTC\",\n workMem: 16,\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nexample_database_cluster = digitalocean.DatabaseCluster(\"exampleDatabaseCluster\",\n engine=\"pg\",\n version=\"15\",\n size=digitalocean.DatabaseSlug.D_B_1_VPCU1_GB,\n region=digitalocean.Region.NYC1,\n node_count=1)\nexample_database_postgresql_config = digitalocean.DatabasePostgresqlConfig(\"exampleDatabasePostgresqlConfig\",\n cluster_id=example_database_cluster.id,\n timezone=\"UTC\",\n work_mem=16)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var exampleDatabaseCluster = new DigitalOcean.DatabaseCluster(\"exampleDatabaseCluster\", new()\n {\n Engine = \"pg\",\n Version = \"15\",\n Size = DigitalOcean.DatabaseSlug.DB_1VPCU1GB,\n Region = DigitalOcean.Region.NYC1,\n NodeCount = 1,\n });\n\n var exampleDatabasePostgresqlConfig = new DigitalOcean.DatabasePostgresqlConfig(\"exampleDatabasePostgresqlConfig\", new()\n {\n ClusterId = exampleDatabaseCluster.Id,\n Timezone = \"UTC\",\n WorkMem = 16,\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\texampleDatabaseCluster, err := digitalocean.NewDatabaseCluster(ctx, \"exampleDatabaseCluster\", \u0026digitalocean.DatabaseClusterArgs{\n\t\t\tEngine: pulumi.String(\"pg\"),\n\t\t\tVersion: pulumi.String(\"15\"),\n\t\t\tSize: pulumi.String(digitalocean.DatabaseSlug_DB_1VPCU1GB),\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC1),\n\t\t\tNodeCount: pulumi.Int(1),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = digitalocean.NewDatabasePostgresqlConfig(ctx, \"exampleDatabasePostgresqlConfig\", \u0026digitalocean.DatabasePostgresqlConfigArgs{\n\t\t\tClusterId: exampleDatabaseCluster.ID(),\n\t\t\tTimezone: pulumi.String(\"UTC\"),\n\t\t\tWorkMem: pulumi.Int(16),\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.digitalocean.DatabaseCluster;\nimport com.pulumi.digitalocean.DatabaseClusterArgs;\nimport com.pulumi.digitalocean.DatabasePostgresqlConfig;\nimport com.pulumi.digitalocean.DatabasePostgresqlConfigArgs;\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 exampleDatabaseCluster = new DatabaseCluster(\"exampleDatabaseCluster\", DatabaseClusterArgs.builder() \n .engine(\"pg\")\n .version(\"15\")\n .size(\"db-s-1vcpu-1gb\")\n .region(\"nyc1\")\n .nodeCount(1)\n .build());\n\n var exampleDatabasePostgresqlConfig = new DatabasePostgresqlConfig(\"exampleDatabasePostgresqlConfig\", DatabasePostgresqlConfigArgs.builder() \n .clusterId(exampleDatabaseCluster.id())\n .timezone(\"UTC\")\n .workMem(16)\n .build());\n\n }\n}\n```\n```yaml\nresources:\n exampleDatabasePostgresqlConfig:\n type: digitalocean:DatabasePostgresqlConfig\n properties:\n clusterId: ${exampleDatabaseCluster.id}\n timezone: UTC\n workMem: 16\n exampleDatabaseCluster:\n type: digitalocean:DatabaseCluster\n properties:\n engine: pg\n version: '15'\n size: db-s-1vcpu-1gb\n region: nyc1\n nodeCount: 1\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n## Import\n\nA PostgreSQL database cluster's configuration can be imported using the `id` the parent cluster, e.g.\n\nbash\n\n```sh\n$ pulumi import digitalocean:index/databasePostgresqlConfig:DatabasePostgresqlConfig example 52556c07-788e-4d41-b8a7-c796432197d1\n```\n\n", + "description": "Provides a virtual resource that can be used to change advanced configuration\noptions for a DigitalOcean managed PostgreSQL database cluster.\n\n\u003e **Note** PostgreSQL configurations are only removed from state when destroyed. The remote configuration is not unset.\n\n## Example Usage\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst exampleDatabaseCluster = new digitalocean.DatabaseCluster(\"example\", {\n name: \"example-postgresql-cluster\",\n engine: \"pg\",\n version: \"15\",\n size: digitalocean.DatabaseSlug.DB_1VPCU1GB,\n region: digitalocean.Region.NYC1,\n nodeCount: 1,\n});\nconst example = new digitalocean.DatabasePostgresqlConfig(\"example\", {\n clusterId: exampleDatabaseCluster.id,\n timezone: \"UTC\",\n workMem: 16,\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nexample_database_cluster = digitalocean.DatabaseCluster(\"example\",\n name=\"example-postgresql-cluster\",\n engine=\"pg\",\n version=\"15\",\n size=digitalocean.DatabaseSlug.D_B_1_VPCU1_GB,\n region=digitalocean.Region.NYC1,\n node_count=1)\nexample = digitalocean.DatabasePostgresqlConfig(\"example\",\n cluster_id=example_database_cluster.id,\n timezone=\"UTC\",\n work_mem=16)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var exampleDatabaseCluster = new DigitalOcean.DatabaseCluster(\"example\", new()\n {\n Name = \"example-postgresql-cluster\",\n Engine = \"pg\",\n Version = \"15\",\n Size = DigitalOcean.DatabaseSlug.DB_1VPCU1GB,\n Region = DigitalOcean.Region.NYC1,\n NodeCount = 1,\n });\n\n var example = new DigitalOcean.DatabasePostgresqlConfig(\"example\", new()\n {\n ClusterId = exampleDatabaseCluster.Id,\n Timezone = \"UTC\",\n WorkMem = 16,\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\texampleDatabaseCluster, err := digitalocean.NewDatabaseCluster(ctx, \"example\", \u0026digitalocean.DatabaseClusterArgs{\n\t\t\tName: pulumi.String(\"example-postgresql-cluster\"),\n\t\t\tEngine: pulumi.String(\"pg\"),\n\t\t\tVersion: pulumi.String(\"15\"),\n\t\t\tSize: pulumi.String(digitalocean.DatabaseSlug_DB_1VPCU1GB),\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC1),\n\t\t\tNodeCount: pulumi.Int(1),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = digitalocean.NewDatabasePostgresqlConfig(ctx, \"example\", \u0026digitalocean.DatabasePostgresqlConfigArgs{\n\t\t\tClusterId: exampleDatabaseCluster.ID(),\n\t\t\tTimezone: pulumi.String(\"UTC\"),\n\t\t\tWorkMem: pulumi.Int(16),\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.digitalocean.DatabaseCluster;\nimport com.pulumi.digitalocean.DatabaseClusterArgs;\nimport com.pulumi.digitalocean.DatabasePostgresqlConfig;\nimport com.pulumi.digitalocean.DatabasePostgresqlConfigArgs;\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 exampleDatabaseCluster = new DatabaseCluster(\"exampleDatabaseCluster\", DatabaseClusterArgs.builder() \n .name(\"example-postgresql-cluster\")\n .engine(\"pg\")\n .version(\"15\")\n .size(\"db-s-1vcpu-1gb\")\n .region(\"nyc1\")\n .nodeCount(1)\n .build());\n\n var example = new DatabasePostgresqlConfig(\"example\", DatabasePostgresqlConfigArgs.builder() \n .clusterId(exampleDatabaseCluster.id())\n .timezone(\"UTC\")\n .workMem(16)\n .build());\n\n }\n}\n```\n```yaml\nresources:\n example:\n type: digitalocean:DatabasePostgresqlConfig\n properties:\n clusterId: ${exampleDatabaseCluster.id}\n timezone: UTC\n workMem: 16\n exampleDatabaseCluster:\n type: digitalocean:DatabaseCluster\n name: example\n properties:\n name: example-postgresql-cluster\n engine: pg\n version: '15'\n size: db-s-1vcpu-1gb\n region: nyc1\n nodeCount: 1\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n## Import\n\nA PostgreSQL database cluster's configuration can be imported using the `id` the parent cluster, e.g.\n\nbash\n\n```sh\n$ pulumi import digitalocean:index/databasePostgresqlConfig:DatabasePostgresqlConfig example 52556c07-788e-4d41-b8a7-c796432197d1\n```\n\n", "properties": { "autovacuumAnalyzeScaleFactor": { "type": "number", @@ -10219,7 +10219,7 @@ } }, "digitalocean:index/databaseRedisConfig:DatabaseRedisConfig": { - "description": "Provides a virtual resource that can be used to change advanced configuration\noptions for a DigitalOcean managed Redis database cluster.\n\n\u003e **Note** Redis configurations are only removed from state when destroyed. The remote configuration is not unset.\n\n## Example Usage\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst exampleDatabaseCluster = new digitalocean.DatabaseCluster(\"exampleDatabaseCluster\", {\n engine: \"redis\",\n version: \"7\",\n size: digitalocean.DatabaseSlug.DB_1VPCU1GB,\n region: digitalocean.Region.NYC1,\n nodeCount: 1,\n});\nconst exampleDatabaseRedisConfig = new digitalocean.DatabaseRedisConfig(\"exampleDatabaseRedisConfig\", {\n clusterId: exampleDatabaseCluster.id,\n maxmemoryPolicy: \"allkeys-lru\",\n notifyKeyspaceEvents: \"KEA\",\n timeout: 90,\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nexample_database_cluster = digitalocean.DatabaseCluster(\"exampleDatabaseCluster\",\n engine=\"redis\",\n version=\"7\",\n size=digitalocean.DatabaseSlug.D_B_1_VPCU1_GB,\n region=digitalocean.Region.NYC1,\n node_count=1)\nexample_database_redis_config = digitalocean.DatabaseRedisConfig(\"exampleDatabaseRedisConfig\",\n cluster_id=example_database_cluster.id,\n maxmemory_policy=\"allkeys-lru\",\n notify_keyspace_events=\"KEA\",\n timeout=90)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var exampleDatabaseCluster = new DigitalOcean.DatabaseCluster(\"exampleDatabaseCluster\", new()\n {\n Engine = \"redis\",\n Version = \"7\",\n Size = DigitalOcean.DatabaseSlug.DB_1VPCU1GB,\n Region = DigitalOcean.Region.NYC1,\n NodeCount = 1,\n });\n\n var exampleDatabaseRedisConfig = new DigitalOcean.DatabaseRedisConfig(\"exampleDatabaseRedisConfig\", new()\n {\n ClusterId = exampleDatabaseCluster.Id,\n MaxmemoryPolicy = \"allkeys-lru\",\n NotifyKeyspaceEvents = \"KEA\",\n Timeout = 90,\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\texampleDatabaseCluster, err := digitalocean.NewDatabaseCluster(ctx, \"exampleDatabaseCluster\", \u0026digitalocean.DatabaseClusterArgs{\n\t\t\tEngine: pulumi.String(\"redis\"),\n\t\t\tVersion: pulumi.String(\"7\"),\n\t\t\tSize: pulumi.String(digitalocean.DatabaseSlug_DB_1VPCU1GB),\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC1),\n\t\t\tNodeCount: pulumi.Int(1),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = digitalocean.NewDatabaseRedisConfig(ctx, \"exampleDatabaseRedisConfig\", \u0026digitalocean.DatabaseRedisConfigArgs{\n\t\t\tClusterId: exampleDatabaseCluster.ID(),\n\t\t\tMaxmemoryPolicy: pulumi.String(\"allkeys-lru\"),\n\t\t\tNotifyKeyspaceEvents: pulumi.String(\"KEA\"),\n\t\t\tTimeout: pulumi.Int(90),\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.digitalocean.DatabaseCluster;\nimport com.pulumi.digitalocean.DatabaseClusterArgs;\nimport com.pulumi.digitalocean.DatabaseRedisConfig;\nimport com.pulumi.digitalocean.DatabaseRedisConfigArgs;\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 exampleDatabaseCluster = new DatabaseCluster(\"exampleDatabaseCluster\", DatabaseClusterArgs.builder() \n .engine(\"redis\")\n .version(\"7\")\n .size(\"db-s-1vcpu-1gb\")\n .region(\"nyc1\")\n .nodeCount(1)\n .build());\n\n var exampleDatabaseRedisConfig = new DatabaseRedisConfig(\"exampleDatabaseRedisConfig\", DatabaseRedisConfigArgs.builder() \n .clusterId(exampleDatabaseCluster.id())\n .maxmemoryPolicy(\"allkeys-lru\")\n .notifyKeyspaceEvents(\"KEA\")\n .timeout(90)\n .build());\n\n }\n}\n```\n```yaml\nresources:\n exampleDatabaseRedisConfig:\n type: digitalocean:DatabaseRedisConfig\n properties:\n clusterId: ${exampleDatabaseCluster.id}\n maxmemoryPolicy: allkeys-lru\n notifyKeyspaceEvents: KEA\n timeout: 90\n exampleDatabaseCluster:\n type: digitalocean:DatabaseCluster\n properties:\n engine: redis\n version: '7'\n size: db-s-1vcpu-1gb\n region: nyc1\n nodeCount: 1\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n## Import\n\nA Redis database cluster's configuration can be imported using the `id` the parent cluster, e.g.\n\n```sh\n$ pulumi import digitalocean:index/databaseRedisConfig:DatabaseRedisConfig example 245bcfd0-7f31-4ce6-a2bc-475a116cca97\n```\n\n", + "description": "Provides a virtual resource that can be used to change advanced configuration\noptions for a DigitalOcean managed Redis database cluster.\n\n\u003e **Note** Redis configurations are only removed from state when destroyed. The remote configuration is not unset.\n\n## Example Usage\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst exampleDatabaseCluster = new digitalocean.DatabaseCluster(\"example\", {\n name: \"example-redis-cluster\",\n engine: \"redis\",\n version: \"7\",\n size: digitalocean.DatabaseSlug.DB_1VPCU1GB,\n region: digitalocean.Region.NYC1,\n nodeCount: 1,\n});\nconst example = new digitalocean.DatabaseRedisConfig(\"example\", {\n clusterId: exampleDatabaseCluster.id,\n maxmemoryPolicy: \"allkeys-lru\",\n notifyKeyspaceEvents: \"KEA\",\n timeout: 90,\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nexample_database_cluster = digitalocean.DatabaseCluster(\"example\",\n name=\"example-redis-cluster\",\n engine=\"redis\",\n version=\"7\",\n size=digitalocean.DatabaseSlug.D_B_1_VPCU1_GB,\n region=digitalocean.Region.NYC1,\n node_count=1)\nexample = digitalocean.DatabaseRedisConfig(\"example\",\n cluster_id=example_database_cluster.id,\n maxmemory_policy=\"allkeys-lru\",\n notify_keyspace_events=\"KEA\",\n timeout=90)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var exampleDatabaseCluster = new DigitalOcean.DatabaseCluster(\"example\", new()\n {\n Name = \"example-redis-cluster\",\n Engine = \"redis\",\n Version = \"7\",\n Size = DigitalOcean.DatabaseSlug.DB_1VPCU1GB,\n Region = DigitalOcean.Region.NYC1,\n NodeCount = 1,\n });\n\n var example = new DigitalOcean.DatabaseRedisConfig(\"example\", new()\n {\n ClusterId = exampleDatabaseCluster.Id,\n MaxmemoryPolicy = \"allkeys-lru\",\n NotifyKeyspaceEvents = \"KEA\",\n Timeout = 90,\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\texampleDatabaseCluster, err := digitalocean.NewDatabaseCluster(ctx, \"example\", \u0026digitalocean.DatabaseClusterArgs{\n\t\t\tName: pulumi.String(\"example-redis-cluster\"),\n\t\t\tEngine: pulumi.String(\"redis\"),\n\t\t\tVersion: pulumi.String(\"7\"),\n\t\t\tSize: pulumi.String(digitalocean.DatabaseSlug_DB_1VPCU1GB),\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC1),\n\t\t\tNodeCount: pulumi.Int(1),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = digitalocean.NewDatabaseRedisConfig(ctx, \"example\", \u0026digitalocean.DatabaseRedisConfigArgs{\n\t\t\tClusterId: exampleDatabaseCluster.ID(),\n\t\t\tMaxmemoryPolicy: pulumi.String(\"allkeys-lru\"),\n\t\t\tNotifyKeyspaceEvents: pulumi.String(\"KEA\"),\n\t\t\tTimeout: pulumi.Int(90),\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.digitalocean.DatabaseCluster;\nimport com.pulumi.digitalocean.DatabaseClusterArgs;\nimport com.pulumi.digitalocean.DatabaseRedisConfig;\nimport com.pulumi.digitalocean.DatabaseRedisConfigArgs;\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 exampleDatabaseCluster = new DatabaseCluster(\"exampleDatabaseCluster\", DatabaseClusterArgs.builder() \n .name(\"example-redis-cluster\")\n .engine(\"redis\")\n .version(\"7\")\n .size(\"db-s-1vcpu-1gb\")\n .region(\"nyc1\")\n .nodeCount(1)\n .build());\n\n var example = new DatabaseRedisConfig(\"example\", DatabaseRedisConfigArgs.builder() \n .clusterId(exampleDatabaseCluster.id())\n .maxmemoryPolicy(\"allkeys-lru\")\n .notifyKeyspaceEvents(\"KEA\")\n .timeout(90)\n .build());\n\n }\n}\n```\n```yaml\nresources:\n example:\n type: digitalocean:DatabaseRedisConfig\n properties:\n clusterId: ${exampleDatabaseCluster.id}\n maxmemoryPolicy: allkeys-lru\n notifyKeyspaceEvents: KEA\n timeout: 90\n exampleDatabaseCluster:\n type: digitalocean:DatabaseCluster\n name: example\n properties:\n name: example-redis-cluster\n engine: redis\n version: '7'\n size: db-s-1vcpu-1gb\n region: nyc1\n nodeCount: 1\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n## Import\n\nA Redis database cluster's configuration can be imported using the `id` the parent cluster, e.g.\n\n```sh\n$ pulumi import digitalocean:index/databaseRedisConfig:DatabaseRedisConfig example 245bcfd0-7f31-4ce6-a2bc-475a116cca97\n```\n\n", "properties": { "aclChannelsDefault": { "type": "string", @@ -10395,7 +10395,7 @@ } }, "digitalocean:index/databaseReplica:DatabaseReplica": { - "description": "Provides a DigitalOcean database replica resource.\n\n## Example Usage\n\n### Create a new PostgreSQL database replica\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst postgres_example = new digitalocean.DatabaseCluster(\"postgres-example\", {\n engine: \"pg\",\n version: \"15\",\n size: digitalocean.DatabaseSlug.DB_1VPCU1GB,\n region: digitalocean.Region.NYC1,\n nodeCount: 1,\n});\nconst replica_example = new digitalocean.DatabaseReplica(\"replica-example\", {\n clusterId: postgres_example.id,\n size: digitalocean.DatabaseSlug.DB_1VPCU1GB,\n region: digitalocean.Region.NYC1,\n});\nexport const uUID = replica_example.uuid;\n// Create firewall rule for database replica\nconst example_fw = new digitalocean.DatabaseFirewall(\"example-fw\", {\n clusterId: replica_example.uuid,\n rules: [{\n type: \"ip_addr\",\n value: \"192.168.1.1\",\n }],\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\npostgres_example = digitalocean.DatabaseCluster(\"postgres-example\",\n engine=\"pg\",\n version=\"15\",\n size=digitalocean.DatabaseSlug.D_B_1_VPCU1_GB,\n region=digitalocean.Region.NYC1,\n node_count=1)\nreplica_example = digitalocean.DatabaseReplica(\"replica-example\",\n cluster_id=postgres_example.id,\n size=digitalocean.DatabaseSlug.D_B_1_VPCU1_GB,\n region=digitalocean.Region.NYC1)\npulumi.export(\"uUID\", replica_example.uuid)\n# Create firewall rule for database replica\nexample_fw = digitalocean.DatabaseFirewall(\"example-fw\",\n cluster_id=replica_example.uuid,\n rules=[digitalocean.DatabaseFirewallRuleArgs(\n type=\"ip_addr\",\n value=\"192.168.1.1\",\n )])\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var postgres_example = new DigitalOcean.DatabaseCluster(\"postgres-example\", new()\n {\n Engine = \"pg\",\n Version = \"15\",\n Size = DigitalOcean.DatabaseSlug.DB_1VPCU1GB,\n Region = DigitalOcean.Region.NYC1,\n NodeCount = 1,\n });\n\n var replica_example = new DigitalOcean.DatabaseReplica(\"replica-example\", new()\n {\n ClusterId = postgres_example.Id,\n Size = DigitalOcean.DatabaseSlug.DB_1VPCU1GB,\n Region = DigitalOcean.Region.NYC1,\n });\n\n // Create firewall rule for database replica\n var example_fw = new DigitalOcean.DatabaseFirewall(\"example-fw\", new()\n {\n ClusterId = replica_example.Uuid,\n Rules = new[]\n {\n new DigitalOcean.Inputs.DatabaseFirewallRuleArgs\n {\n Type = \"ip_addr\",\n Value = \"192.168.1.1\",\n },\n },\n });\n\n return new Dictionary\u003cstring, object?\u003e\n {\n [\"uUID\"] = replica_example.Uuid,\n };\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := digitalocean.NewDatabaseCluster(ctx, \"postgres-example\", \u0026digitalocean.DatabaseClusterArgs{\n\t\t\tEngine: pulumi.String(\"pg\"),\n\t\t\tVersion: pulumi.String(\"15\"),\n\t\t\tSize: pulumi.String(digitalocean.DatabaseSlug_DB_1VPCU1GB),\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC1),\n\t\t\tNodeCount: pulumi.Int(1),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = digitalocean.NewDatabaseReplica(ctx, \"replica-example\", \u0026digitalocean.DatabaseReplicaArgs{\n\t\t\tClusterId: postgres_example.ID(),\n\t\t\tSize: pulumi.String(digitalocean.DatabaseSlug_DB_1VPCU1GB),\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC1),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tctx.Export(\"uUID\", replica_example.Uuid)\n\t\t// Create firewall rule for database replica\n\t\t_, err = digitalocean.NewDatabaseFirewall(ctx, \"example-fw\", \u0026digitalocean.DatabaseFirewallArgs{\n\t\t\tClusterId: replica_example.Uuid,\n\t\t\tRules: digitalocean.DatabaseFirewallRuleArray{\n\t\t\t\t\u0026digitalocean.DatabaseFirewallRuleArgs{\n\t\t\t\t\tType: pulumi.String(\"ip_addr\"),\n\t\t\t\t\tValue: pulumi.String(\"192.168.1.1\"),\n\t\t\t\t},\n\t\t\t},\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.digitalocean.DatabaseCluster;\nimport com.pulumi.digitalocean.DatabaseClusterArgs;\nimport com.pulumi.digitalocean.DatabaseReplica;\nimport com.pulumi.digitalocean.DatabaseReplicaArgs;\nimport com.pulumi.digitalocean.DatabaseFirewall;\nimport com.pulumi.digitalocean.DatabaseFirewallArgs;\nimport com.pulumi.digitalocean.inputs.DatabaseFirewallRuleArgs;\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 postgres_example = new DatabaseCluster(\"postgres-example\", DatabaseClusterArgs.builder() \n .engine(\"pg\")\n .version(\"15\")\n .size(\"db-s-1vcpu-1gb\")\n .region(\"nyc1\")\n .nodeCount(1)\n .build());\n\n var replica_example = new DatabaseReplica(\"replica-example\", DatabaseReplicaArgs.builder() \n .clusterId(postgres_example.id())\n .size(\"db-s-1vcpu-1gb\")\n .region(\"nyc1\")\n .build());\n\n ctx.export(\"uUID\", replica_example.uuid());\n // Create firewall rule for database replica\n var example_fw = new DatabaseFirewall(\"example-fw\", DatabaseFirewallArgs.builder() \n .clusterId(replica_example.uuid())\n .rules(DatabaseFirewallRuleArgs.builder()\n .type(\"ip_addr\")\n .value(\"192.168.1.1\")\n .build())\n .build());\n\n }\n}\n```\n```yaml\nresources:\n postgres-example:\n type: digitalocean:DatabaseCluster\n properties:\n engine: pg\n version: '15'\n size: db-s-1vcpu-1gb\n region: nyc1\n nodeCount: 1\n replica-example:\n type: digitalocean:DatabaseReplica\n properties:\n clusterId: ${[\"postgres-example\"].id}\n size: db-s-1vcpu-1gb\n region: nyc1\n # Create firewall rule for database replica\n example-fw:\n type: digitalocean:DatabaseFirewall\n properties:\n clusterId: ${[\"replica-example\"].uuid}\n rules:\n - type: ip_addr\n value: 192.168.1.1\noutputs:\n uUID: ${[\"replica-example\"].uuid}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n## Import\n\nDatabase replicas can be imported using the `id` of the source database cluster\n\nand the `name` of the replica joined with a comma. For example:\n\n```sh\n$ pulumi import digitalocean:index/databaseReplica:DatabaseReplica read-replica 245bcfd0-7f31-4ce6-a2bc-475a116cca97,read-replica\n```\n\n", + "description": "Provides a DigitalOcean database replica resource.\n\n## Example Usage\n\n### Create a new PostgreSQL database replica\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst postgres_example = new digitalocean.DatabaseCluster(\"postgres-example\", {\n name: \"example-postgres-cluster\",\n engine: \"pg\",\n version: \"15\",\n size: digitalocean.DatabaseSlug.DB_1VPCU1GB,\n region: digitalocean.Region.NYC1,\n nodeCount: 1,\n});\nconst replica_example = new digitalocean.DatabaseReplica(\"replica-example\", {\n clusterId: postgres_example.id,\n name: \"replica-example\",\n size: digitalocean.DatabaseSlug.DB_1VPCU1GB,\n region: digitalocean.Region.NYC1,\n});\nexport const UUID = replica_example.uuid;\n// Create firewall rule for database replica\nconst example_fw = new digitalocean.DatabaseFirewall(\"example-fw\", {\n clusterId: replica_example.uuid,\n rules: [{\n type: \"ip_addr\",\n value: \"192.168.1.1\",\n }],\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\npostgres_example = digitalocean.DatabaseCluster(\"postgres-example\",\n name=\"example-postgres-cluster\",\n engine=\"pg\",\n version=\"15\",\n size=digitalocean.DatabaseSlug.D_B_1_VPCU1_GB,\n region=digitalocean.Region.NYC1,\n node_count=1)\nreplica_example = digitalocean.DatabaseReplica(\"replica-example\",\n cluster_id=postgres_example.id,\n name=\"replica-example\",\n size=digitalocean.DatabaseSlug.D_B_1_VPCU1_GB,\n region=digitalocean.Region.NYC1)\npulumi.export(\"UUID\", replica_example.uuid)\n# Create firewall rule for database replica\nexample_fw = digitalocean.DatabaseFirewall(\"example-fw\",\n cluster_id=replica_example.uuid,\n rules=[digitalocean.DatabaseFirewallRuleArgs(\n type=\"ip_addr\",\n value=\"192.168.1.1\",\n )])\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var postgres_example = new DigitalOcean.DatabaseCluster(\"postgres-example\", new()\n {\n Name = \"example-postgres-cluster\",\n Engine = \"pg\",\n Version = \"15\",\n Size = DigitalOcean.DatabaseSlug.DB_1VPCU1GB,\n Region = DigitalOcean.Region.NYC1,\n NodeCount = 1,\n });\n\n var replica_example = new DigitalOcean.DatabaseReplica(\"replica-example\", new()\n {\n ClusterId = postgres_example.Id,\n Name = \"replica-example\",\n Size = DigitalOcean.DatabaseSlug.DB_1VPCU1GB,\n Region = DigitalOcean.Region.NYC1,\n });\n\n // Create firewall rule for database replica\n var example_fw = new DigitalOcean.DatabaseFirewall(\"example-fw\", new()\n {\n ClusterId = replica_example.Uuid,\n Rules = new[]\n {\n new DigitalOcean.Inputs.DatabaseFirewallRuleArgs\n {\n Type = \"ip_addr\",\n Value = \"192.168.1.1\",\n },\n },\n });\n\n return new Dictionary\u003cstring, object?\u003e\n {\n [\"UUID\"] = replica_example.Uuid,\n };\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := digitalocean.NewDatabaseCluster(ctx, \"postgres-example\", \u0026digitalocean.DatabaseClusterArgs{\n\t\t\tName: pulumi.String(\"example-postgres-cluster\"),\n\t\t\tEngine: pulumi.String(\"pg\"),\n\t\t\tVersion: pulumi.String(\"15\"),\n\t\t\tSize: pulumi.String(digitalocean.DatabaseSlug_DB_1VPCU1GB),\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC1),\n\t\t\tNodeCount: pulumi.Int(1),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = digitalocean.NewDatabaseReplica(ctx, \"replica-example\", \u0026digitalocean.DatabaseReplicaArgs{\n\t\t\tClusterId: postgres_example.ID(),\n\t\t\tName: pulumi.String(\"replica-example\"),\n\t\t\tSize: pulumi.String(digitalocean.DatabaseSlug_DB_1VPCU1GB),\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC1),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tctx.Export(\"UUID\", replica_example.Uuid)\n\t\t// Create firewall rule for database replica\n\t\t_, err = digitalocean.NewDatabaseFirewall(ctx, \"example-fw\", \u0026digitalocean.DatabaseFirewallArgs{\n\t\t\tClusterId: replica_example.Uuid,\n\t\t\tRules: digitalocean.DatabaseFirewallRuleArray{\n\t\t\t\t\u0026digitalocean.DatabaseFirewallRuleArgs{\n\t\t\t\t\tType: pulumi.String(\"ip_addr\"),\n\t\t\t\t\tValue: pulumi.String(\"192.168.1.1\"),\n\t\t\t\t},\n\t\t\t},\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.digitalocean.DatabaseCluster;\nimport com.pulumi.digitalocean.DatabaseClusterArgs;\nimport com.pulumi.digitalocean.DatabaseReplica;\nimport com.pulumi.digitalocean.DatabaseReplicaArgs;\nimport com.pulumi.digitalocean.DatabaseFirewall;\nimport com.pulumi.digitalocean.DatabaseFirewallArgs;\nimport com.pulumi.digitalocean.inputs.DatabaseFirewallRuleArgs;\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 postgres_example = new DatabaseCluster(\"postgres-example\", DatabaseClusterArgs.builder() \n .name(\"example-postgres-cluster\")\n .engine(\"pg\")\n .version(\"15\")\n .size(\"db-s-1vcpu-1gb\")\n .region(\"nyc1\")\n .nodeCount(1)\n .build());\n\n var replica_example = new DatabaseReplica(\"replica-example\", DatabaseReplicaArgs.builder() \n .clusterId(postgres_example.id())\n .name(\"replica-example\")\n .size(\"db-s-1vcpu-1gb\")\n .region(\"nyc1\")\n .build());\n\n ctx.export(\"UUID\", replica_example.uuid());\n // Create firewall rule for database replica\n var example_fw = new DatabaseFirewall(\"example-fw\", DatabaseFirewallArgs.builder() \n .clusterId(replica_example.uuid())\n .rules(DatabaseFirewallRuleArgs.builder()\n .type(\"ip_addr\")\n .value(\"192.168.1.1\")\n .build())\n .build());\n\n }\n}\n```\n```yaml\nresources:\n postgres-example:\n type: digitalocean:DatabaseCluster\n properties:\n name: example-postgres-cluster\n engine: pg\n version: '15'\n size: db-s-1vcpu-1gb\n region: nyc1\n nodeCount: 1\n replica-example:\n type: digitalocean:DatabaseReplica\n properties:\n clusterId: ${[\"postgres-example\"].id}\n name: replica-example\n size: db-s-1vcpu-1gb\n region: nyc1\n # Create firewall rule for database replica\n example-fw:\n type: digitalocean:DatabaseFirewall\n properties:\n clusterId: ${[\"replica-example\"].uuid}\n rules:\n - type: ip_addr\n value: 192.168.1.1\noutputs:\n UUID: ${[\"replica-example\"].uuid}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n## Import\n\nDatabase replicas can be imported using the `id` of the source database cluster\n\nand the `name` of the replica joined with a comma. For example:\n\n```sh\n$ pulumi import digitalocean:index/databaseReplica:DatabaseReplica read-replica 245bcfd0-7f31-4ce6-a2bc-475a116cca97,read-replica\n```\n\n", "properties": { "clusterId": { "type": "string", @@ -10641,7 +10641,7 @@ } }, "digitalocean:index/databaseUser:DatabaseUser": { - "description": "Provides a DigitalOcean database user resource. When creating a new database cluster, a default admin user with name `doadmin` will be created. Then, this resource can be used to provide additional normal users inside the cluster.\n\n\u003e **NOTE:** Any new users created will always have `normal` role, only the default user that comes with database cluster creation has `primary` role. Additional permissions must be managed manually.\n\n## Example Usage\n\n### Create a new PostgreSQL database user\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst postgres_example = new digitalocean.DatabaseCluster(\"postgres-example\", {\n engine: \"pg\",\n version: \"15\",\n size: digitalocean.DatabaseSlug.DB_1VPCU1GB,\n region: digitalocean.Region.NYC1,\n nodeCount: 1,\n});\nconst user_example = new digitalocean.DatabaseUser(\"user-example\", {clusterId: postgres_example.id});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\npostgres_example = digitalocean.DatabaseCluster(\"postgres-example\",\n engine=\"pg\",\n version=\"15\",\n size=digitalocean.DatabaseSlug.D_B_1_VPCU1_GB,\n region=digitalocean.Region.NYC1,\n node_count=1)\nuser_example = digitalocean.DatabaseUser(\"user-example\", cluster_id=postgres_example.id)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var postgres_example = new DigitalOcean.DatabaseCluster(\"postgres-example\", new()\n {\n Engine = \"pg\",\n Version = \"15\",\n Size = DigitalOcean.DatabaseSlug.DB_1VPCU1GB,\n Region = DigitalOcean.Region.NYC1,\n NodeCount = 1,\n });\n\n var user_example = new DigitalOcean.DatabaseUser(\"user-example\", new()\n {\n ClusterId = postgres_example.Id,\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := digitalocean.NewDatabaseCluster(ctx, \"postgres-example\", \u0026digitalocean.DatabaseClusterArgs{\n\t\t\tEngine: pulumi.String(\"pg\"),\n\t\t\tVersion: pulumi.String(\"15\"),\n\t\t\tSize: pulumi.String(digitalocean.DatabaseSlug_DB_1VPCU1GB),\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC1),\n\t\t\tNodeCount: pulumi.Int(1),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = digitalocean.NewDatabaseUser(ctx, \"user-example\", \u0026digitalocean.DatabaseUserArgs{\n\t\t\tClusterId: postgres_example.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.digitalocean.DatabaseCluster;\nimport com.pulumi.digitalocean.DatabaseClusterArgs;\nimport com.pulumi.digitalocean.DatabaseUser;\nimport com.pulumi.digitalocean.DatabaseUserArgs;\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 postgres_example = new DatabaseCluster(\"postgres-example\", DatabaseClusterArgs.builder() \n .engine(\"pg\")\n .version(\"15\")\n .size(\"db-s-1vcpu-1gb\")\n .region(\"nyc1\")\n .nodeCount(1)\n .build());\n\n var user_example = new DatabaseUser(\"user-example\", DatabaseUserArgs.builder() \n .clusterId(postgres_example.id())\n .build());\n\n }\n}\n```\n```yaml\nresources:\n user-example:\n type: digitalocean:DatabaseUser\n properties:\n clusterId: ${[\"postgres-example\"].id}\n postgres-example:\n type: digitalocean:DatabaseCluster\n properties:\n engine: pg\n version: '15'\n size: db-s-1vcpu-1gb\n region: nyc1\n nodeCount: 1\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n### Create a new user for a PostgreSQL database replica \n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst postgres_example = new digitalocean.DatabaseCluster(\"postgres-example\", {\n engine: \"pg\",\n version: \"15\",\n size: digitalocean.DatabaseSlug.DB_1VPCU1GB,\n region: digitalocean.Region.NYC1,\n nodeCount: 1,\n});\nconst replica_example = new digitalocean.DatabaseReplica(\"replica-example\", {\n clusterId: postgres_example.id,\n size: digitalocean.DatabaseSlug.DB_1VPCU1GB,\n region: digitalocean.Region.NYC1,\n});\nconst user_example = new digitalocean.DatabaseUser(\"user-example\", {clusterId: replica_example.uuid});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\npostgres_example = digitalocean.DatabaseCluster(\"postgres-example\",\n engine=\"pg\",\n version=\"15\",\n size=digitalocean.DatabaseSlug.D_B_1_VPCU1_GB,\n region=digitalocean.Region.NYC1,\n node_count=1)\nreplica_example = digitalocean.DatabaseReplica(\"replica-example\",\n cluster_id=postgres_example.id,\n size=digitalocean.DatabaseSlug.D_B_1_VPCU1_GB,\n region=digitalocean.Region.NYC1)\nuser_example = digitalocean.DatabaseUser(\"user-example\", cluster_id=replica_example.uuid)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var postgres_example = new DigitalOcean.DatabaseCluster(\"postgres-example\", new()\n {\n Engine = \"pg\",\n Version = \"15\",\n Size = DigitalOcean.DatabaseSlug.DB_1VPCU1GB,\n Region = DigitalOcean.Region.NYC1,\n NodeCount = 1,\n });\n\n var replica_example = new DigitalOcean.DatabaseReplica(\"replica-example\", new()\n {\n ClusterId = postgres_example.Id,\n Size = DigitalOcean.DatabaseSlug.DB_1VPCU1GB,\n Region = DigitalOcean.Region.NYC1,\n });\n\n var user_example = new DigitalOcean.DatabaseUser(\"user-example\", new()\n {\n ClusterId = replica_example.Uuid,\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := digitalocean.NewDatabaseCluster(ctx, \"postgres-example\", \u0026digitalocean.DatabaseClusterArgs{\n\t\t\tEngine: pulumi.String(\"pg\"),\n\t\t\tVersion: pulumi.String(\"15\"),\n\t\t\tSize: pulumi.String(digitalocean.DatabaseSlug_DB_1VPCU1GB),\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC1),\n\t\t\tNodeCount: pulumi.Int(1),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = digitalocean.NewDatabaseReplica(ctx, \"replica-example\", \u0026digitalocean.DatabaseReplicaArgs{\n\t\t\tClusterId: postgres_example.ID(),\n\t\t\tSize: pulumi.String(digitalocean.DatabaseSlug_DB_1VPCU1GB),\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC1),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = digitalocean.NewDatabaseUser(ctx, \"user-example\", \u0026digitalocean.DatabaseUserArgs{\n\t\t\tClusterId: replica_example.Uuid,\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.digitalocean.DatabaseCluster;\nimport com.pulumi.digitalocean.DatabaseClusterArgs;\nimport com.pulumi.digitalocean.DatabaseReplica;\nimport com.pulumi.digitalocean.DatabaseReplicaArgs;\nimport com.pulumi.digitalocean.DatabaseUser;\nimport com.pulumi.digitalocean.DatabaseUserArgs;\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 postgres_example = new DatabaseCluster(\"postgres-example\", DatabaseClusterArgs.builder() \n .engine(\"pg\")\n .version(\"15\")\n .size(\"db-s-1vcpu-1gb\")\n .region(\"nyc1\")\n .nodeCount(1)\n .build());\n\n var replica_example = new DatabaseReplica(\"replica-example\", DatabaseReplicaArgs.builder() \n .clusterId(postgres_example.id())\n .size(\"db-s-1vcpu-1gb\")\n .region(\"nyc1\")\n .build());\n\n var user_example = new DatabaseUser(\"user-example\", DatabaseUserArgs.builder() \n .clusterId(replica_example.uuid())\n .build());\n\n }\n}\n```\n```yaml\nresources:\n postgres-example:\n type: digitalocean:DatabaseCluster\n properties:\n engine: pg\n version: '15'\n size: db-s-1vcpu-1gb\n region: nyc1\n nodeCount: 1\n replica-example:\n type: digitalocean:DatabaseReplica\n properties:\n clusterId: ${[\"postgres-example\"].id}\n size: db-s-1vcpu-1gb\n region: nyc1\n user-example:\n type: digitalocean:DatabaseUser\n properties:\n clusterId: ${[\"replica-example\"].uuid}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n### Create a new user for a Kafka database cluster \n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst kafka_example = new digitalocean.DatabaseCluster(\"kafka-example\", {\n engine: \"kafka\",\n version: \"3.5\",\n size: \"db-s-2vcpu-2gb\",\n region: digitalocean.Region.NYC1,\n nodeCount: 3,\n});\nconst foobarTopic = new digitalocean.DatabaseKafkaTopic(\"foobarTopic\", {clusterId: digitalocean_database_cluster.foobar.id});\nconst foobarUser = new digitalocean.DatabaseUser(\"foobarUser\", {\n clusterId: digitalocean_database_cluster.foobar.id,\n settings: [{\n acls: [\n {\n topic: \"topic-1\",\n permission: \"produce\",\n },\n {\n topic: \"topic-2\",\n permission: \"produceconsume\",\n },\n {\n topic: \"topic-*\",\n permission: \"consume\",\n },\n ],\n }],\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nkafka_example = digitalocean.DatabaseCluster(\"kafka-example\",\n engine=\"kafka\",\n version=\"3.5\",\n size=\"db-s-2vcpu-2gb\",\n region=digitalocean.Region.NYC1,\n node_count=3)\nfoobar_topic = digitalocean.DatabaseKafkaTopic(\"foobarTopic\", cluster_id=digitalocean_database_cluster[\"foobar\"][\"id\"])\nfoobar_user = digitalocean.DatabaseUser(\"foobarUser\",\n cluster_id=digitalocean_database_cluster[\"foobar\"][\"id\"],\n settings=[digitalocean.DatabaseUserSettingArgs(\n acls=[\n digitalocean.DatabaseUserSettingAclArgs(\n topic=\"topic-1\",\n permission=\"produce\",\n ),\n digitalocean.DatabaseUserSettingAclArgs(\n topic=\"topic-2\",\n permission=\"produceconsume\",\n ),\n digitalocean.DatabaseUserSettingAclArgs(\n topic=\"topic-*\",\n permission=\"consume\",\n ),\n ],\n )])\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var kafka_example = new DigitalOcean.DatabaseCluster(\"kafka-example\", new()\n {\n Engine = \"kafka\",\n Version = \"3.5\",\n Size = \"db-s-2vcpu-2gb\",\n Region = DigitalOcean.Region.NYC1,\n NodeCount = 3,\n });\n\n var foobarTopic = new DigitalOcean.DatabaseKafkaTopic(\"foobarTopic\", new()\n {\n ClusterId = digitalocean_database_cluster.Foobar.Id,\n });\n\n var foobarUser = new DigitalOcean.DatabaseUser(\"foobarUser\", new()\n {\n ClusterId = digitalocean_database_cluster.Foobar.Id,\n Settings = new[]\n {\n new DigitalOcean.Inputs.DatabaseUserSettingArgs\n {\n Acls = new[]\n {\n new DigitalOcean.Inputs.DatabaseUserSettingAclArgs\n {\n Topic = \"topic-1\",\n Permission = \"produce\",\n },\n new DigitalOcean.Inputs.DatabaseUserSettingAclArgs\n {\n Topic = \"topic-2\",\n Permission = \"produceconsume\",\n },\n new DigitalOcean.Inputs.DatabaseUserSettingAclArgs\n {\n Topic = \"topic-*\",\n Permission = \"consume\",\n },\n },\n },\n },\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := digitalocean.NewDatabaseCluster(ctx, \"kafka-example\", \u0026digitalocean.DatabaseClusterArgs{\n\t\t\tEngine: pulumi.String(\"kafka\"),\n\t\t\tVersion: pulumi.String(\"3.5\"),\n\t\t\tSize: pulumi.String(\"db-s-2vcpu-2gb\"),\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC1),\n\t\t\tNodeCount: pulumi.Int(3),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = digitalocean.NewDatabaseKafkaTopic(ctx, \"foobarTopic\", \u0026digitalocean.DatabaseKafkaTopicArgs{\n\t\t\tClusterId: pulumi.Any(digitalocean_database_cluster.Foobar.Id),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = digitalocean.NewDatabaseUser(ctx, \"foobarUser\", \u0026digitalocean.DatabaseUserArgs{\n\t\t\tClusterId: pulumi.Any(digitalocean_database_cluster.Foobar.Id),\n\t\t\tSettings: digitalocean.DatabaseUserSettingArray{\n\t\t\t\t\u0026digitalocean.DatabaseUserSettingArgs{\n\t\t\t\t\tAcls: digitalocean.DatabaseUserSettingAclArray{\n\t\t\t\t\t\t\u0026digitalocean.DatabaseUserSettingAclArgs{\n\t\t\t\t\t\t\tTopic: pulumi.String(\"topic-1\"),\n\t\t\t\t\t\t\tPermission: pulumi.String(\"produce\"),\n\t\t\t\t\t\t},\n\t\t\t\t\t\t\u0026digitalocean.DatabaseUserSettingAclArgs{\n\t\t\t\t\t\t\tTopic: pulumi.String(\"topic-2\"),\n\t\t\t\t\t\t\tPermission: pulumi.String(\"produceconsume\"),\n\t\t\t\t\t\t},\n\t\t\t\t\t\t\u0026digitalocean.DatabaseUserSettingAclArgs{\n\t\t\t\t\t\t\tTopic: pulumi.String(\"topic-*\"),\n\t\t\t\t\t\t\tPermission: pulumi.String(\"consume\"),\n\t\t\t\t\t\t},\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t},\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.digitalocean.DatabaseCluster;\nimport com.pulumi.digitalocean.DatabaseClusterArgs;\nimport com.pulumi.digitalocean.DatabaseKafkaTopic;\nimport com.pulumi.digitalocean.DatabaseKafkaTopicArgs;\nimport com.pulumi.digitalocean.DatabaseUser;\nimport com.pulumi.digitalocean.DatabaseUserArgs;\nimport com.pulumi.digitalocean.inputs.DatabaseUserSettingArgs;\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 kafka_example = new DatabaseCluster(\"kafka-example\", DatabaseClusterArgs.builder() \n .engine(\"kafka\")\n .version(\"3.5\")\n .size(\"db-s-2vcpu-2gb\")\n .region(\"nyc1\")\n .nodeCount(3)\n .build());\n\n var foobarTopic = new DatabaseKafkaTopic(\"foobarTopic\", DatabaseKafkaTopicArgs.builder() \n .clusterId(digitalocean_database_cluster.foobar().id())\n .build());\n\n var foobarUser = new DatabaseUser(\"foobarUser\", DatabaseUserArgs.builder() \n .clusterId(digitalocean_database_cluster.foobar().id())\n .settings(DatabaseUserSettingArgs.builder()\n .acls( \n DatabaseUserSettingAclArgs.builder()\n .topic(\"topic-1\")\n .permission(\"produce\")\n .build(),\n DatabaseUserSettingAclArgs.builder()\n .topic(\"topic-2\")\n .permission(\"produceconsume\")\n .build(),\n DatabaseUserSettingAclArgs.builder()\n .topic(\"topic-*\")\n .permission(\"consume\")\n .build())\n .build())\n .build());\n\n }\n}\n```\n```yaml\nresources:\n kafka-example:\n type: digitalocean:DatabaseCluster\n properties:\n engine: kafka\n version: '3.5'\n size: db-s-2vcpu-2gb\n region: nyc1\n nodeCount: 3\n foobarTopic:\n type: digitalocean:DatabaseKafkaTopic\n properties:\n clusterId: ${digitalocean_database_cluster.foobar.id}\n foobarUser:\n type: digitalocean:DatabaseUser\n properties:\n clusterId: ${digitalocean_database_cluster.foobar.id}\n settings:\n - acls:\n - topic: topic-1\n permission: produce\n - topic: topic-2\n permission: produceconsume\n - topic: topic-*\n permission: consume\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n## Import\n\nDatabase user can be imported using the `id` of the source database cluster\n\nand the `name` of the user joined with a comma. For example:\n\n```sh\n$ pulumi import digitalocean:index/databaseUser:DatabaseUser user-example 245bcfd0-7f31-4ce6-a2bc-475a116cca97,foobar\n```\n\n", + "description": "Provides a DigitalOcean database user resource. When creating a new database cluster, a default admin user with name `doadmin` will be created. Then, this resource can be used to provide additional normal users inside the cluster.\n\n\u003e **NOTE:** Any new users created will always have `normal` role, only the default user that comes with database cluster creation has `primary` role. Additional permissions must be managed manually.\n\n## Example Usage\n\n### Create a new PostgreSQL database user\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst postgres_example = new digitalocean.DatabaseCluster(\"postgres-example\", {\n name: \"example-postgres-cluster\",\n engine: \"pg\",\n version: \"15\",\n size: digitalocean.DatabaseSlug.DB_1VPCU1GB,\n region: digitalocean.Region.NYC1,\n nodeCount: 1,\n});\nconst user_example = new digitalocean.DatabaseUser(\"user-example\", {\n clusterId: postgres_example.id,\n name: \"foobar\",\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\npostgres_example = digitalocean.DatabaseCluster(\"postgres-example\",\n name=\"example-postgres-cluster\",\n engine=\"pg\",\n version=\"15\",\n size=digitalocean.DatabaseSlug.D_B_1_VPCU1_GB,\n region=digitalocean.Region.NYC1,\n node_count=1)\nuser_example = digitalocean.DatabaseUser(\"user-example\",\n cluster_id=postgres_example.id,\n name=\"foobar\")\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var postgres_example = new DigitalOcean.DatabaseCluster(\"postgres-example\", new()\n {\n Name = \"example-postgres-cluster\",\n Engine = \"pg\",\n Version = \"15\",\n Size = DigitalOcean.DatabaseSlug.DB_1VPCU1GB,\n Region = DigitalOcean.Region.NYC1,\n NodeCount = 1,\n });\n\n var user_example = new DigitalOcean.DatabaseUser(\"user-example\", new()\n {\n ClusterId = postgres_example.Id,\n Name = \"foobar\",\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := digitalocean.NewDatabaseCluster(ctx, \"postgres-example\", \u0026digitalocean.DatabaseClusterArgs{\n\t\t\tName: pulumi.String(\"example-postgres-cluster\"),\n\t\t\tEngine: pulumi.String(\"pg\"),\n\t\t\tVersion: pulumi.String(\"15\"),\n\t\t\tSize: pulumi.String(digitalocean.DatabaseSlug_DB_1VPCU1GB),\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC1),\n\t\t\tNodeCount: pulumi.Int(1),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = digitalocean.NewDatabaseUser(ctx, \"user-example\", \u0026digitalocean.DatabaseUserArgs{\n\t\t\tClusterId: postgres_example.ID(),\n\t\t\tName: pulumi.String(\"foobar\"),\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.digitalocean.DatabaseCluster;\nimport com.pulumi.digitalocean.DatabaseClusterArgs;\nimport com.pulumi.digitalocean.DatabaseUser;\nimport com.pulumi.digitalocean.DatabaseUserArgs;\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 postgres_example = new DatabaseCluster(\"postgres-example\", DatabaseClusterArgs.builder() \n .name(\"example-postgres-cluster\")\n .engine(\"pg\")\n .version(\"15\")\n .size(\"db-s-1vcpu-1gb\")\n .region(\"nyc1\")\n .nodeCount(1)\n .build());\n\n var user_example = new DatabaseUser(\"user-example\", DatabaseUserArgs.builder() \n .clusterId(postgres_example.id())\n .name(\"foobar\")\n .build());\n\n }\n}\n```\n```yaml\nresources:\n user-example:\n type: digitalocean:DatabaseUser\n properties:\n clusterId: ${[\"postgres-example\"].id}\n name: foobar\n postgres-example:\n type: digitalocean:DatabaseCluster\n properties:\n name: example-postgres-cluster\n engine: pg\n version: '15'\n size: db-s-1vcpu-1gb\n region: nyc1\n nodeCount: 1\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n### Create a new user for a PostgreSQL database replica \n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst postgres_example = new digitalocean.DatabaseCluster(\"postgres-example\", {\n name: \"example-postgres-cluster\",\n engine: \"pg\",\n version: \"15\",\n size: digitalocean.DatabaseSlug.DB_1VPCU1GB,\n region: digitalocean.Region.NYC1,\n nodeCount: 1,\n});\nconst replica_example = new digitalocean.DatabaseReplica(\"replica-example\", {\n clusterId: postgres_example.id,\n name: \"replica-example\",\n size: digitalocean.DatabaseSlug.DB_1VPCU1GB,\n region: digitalocean.Region.NYC1,\n});\nconst user_example = new digitalocean.DatabaseUser(\"user-example\", {\n clusterId: replica_example.uuid,\n name: \"foobar\",\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\npostgres_example = digitalocean.DatabaseCluster(\"postgres-example\",\n name=\"example-postgres-cluster\",\n engine=\"pg\",\n version=\"15\",\n size=digitalocean.DatabaseSlug.D_B_1_VPCU1_GB,\n region=digitalocean.Region.NYC1,\n node_count=1)\nreplica_example = digitalocean.DatabaseReplica(\"replica-example\",\n cluster_id=postgres_example.id,\n name=\"replica-example\",\n size=digitalocean.DatabaseSlug.D_B_1_VPCU1_GB,\n region=digitalocean.Region.NYC1)\nuser_example = digitalocean.DatabaseUser(\"user-example\",\n cluster_id=replica_example.uuid,\n name=\"foobar\")\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var postgres_example = new DigitalOcean.DatabaseCluster(\"postgres-example\", new()\n {\n Name = \"example-postgres-cluster\",\n Engine = \"pg\",\n Version = \"15\",\n Size = DigitalOcean.DatabaseSlug.DB_1VPCU1GB,\n Region = DigitalOcean.Region.NYC1,\n NodeCount = 1,\n });\n\n var replica_example = new DigitalOcean.DatabaseReplica(\"replica-example\", new()\n {\n ClusterId = postgres_example.Id,\n Name = \"replica-example\",\n Size = DigitalOcean.DatabaseSlug.DB_1VPCU1GB,\n Region = DigitalOcean.Region.NYC1,\n });\n\n var user_example = new DigitalOcean.DatabaseUser(\"user-example\", new()\n {\n ClusterId = replica_example.Uuid,\n Name = \"foobar\",\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := digitalocean.NewDatabaseCluster(ctx, \"postgres-example\", \u0026digitalocean.DatabaseClusterArgs{\n\t\t\tName: pulumi.String(\"example-postgres-cluster\"),\n\t\t\tEngine: pulumi.String(\"pg\"),\n\t\t\tVersion: pulumi.String(\"15\"),\n\t\t\tSize: pulumi.String(digitalocean.DatabaseSlug_DB_1VPCU1GB),\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC1),\n\t\t\tNodeCount: pulumi.Int(1),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = digitalocean.NewDatabaseReplica(ctx, \"replica-example\", \u0026digitalocean.DatabaseReplicaArgs{\n\t\t\tClusterId: postgres_example.ID(),\n\t\t\tName: pulumi.String(\"replica-example\"),\n\t\t\tSize: pulumi.String(digitalocean.DatabaseSlug_DB_1VPCU1GB),\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC1),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = digitalocean.NewDatabaseUser(ctx, \"user-example\", \u0026digitalocean.DatabaseUserArgs{\n\t\t\tClusterId: replica_example.Uuid,\n\t\t\tName: pulumi.String(\"foobar\"),\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.digitalocean.DatabaseCluster;\nimport com.pulumi.digitalocean.DatabaseClusterArgs;\nimport com.pulumi.digitalocean.DatabaseReplica;\nimport com.pulumi.digitalocean.DatabaseReplicaArgs;\nimport com.pulumi.digitalocean.DatabaseUser;\nimport com.pulumi.digitalocean.DatabaseUserArgs;\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 postgres_example = new DatabaseCluster(\"postgres-example\", DatabaseClusterArgs.builder() \n .name(\"example-postgres-cluster\")\n .engine(\"pg\")\n .version(\"15\")\n .size(\"db-s-1vcpu-1gb\")\n .region(\"nyc1\")\n .nodeCount(1)\n .build());\n\n var replica_example = new DatabaseReplica(\"replica-example\", DatabaseReplicaArgs.builder() \n .clusterId(postgres_example.id())\n .name(\"replica-example\")\n .size(\"db-s-1vcpu-1gb\")\n .region(\"nyc1\")\n .build());\n\n var user_example = new DatabaseUser(\"user-example\", DatabaseUserArgs.builder() \n .clusterId(replica_example.uuid())\n .name(\"foobar\")\n .build());\n\n }\n}\n```\n```yaml\nresources:\n postgres-example:\n type: digitalocean:DatabaseCluster\n properties:\n name: example-postgres-cluster\n engine: pg\n version: '15'\n size: db-s-1vcpu-1gb\n region: nyc1\n nodeCount: 1\n replica-example:\n type: digitalocean:DatabaseReplica\n properties:\n clusterId: ${[\"postgres-example\"].id}\n name: replica-example\n size: db-s-1vcpu-1gb\n region: nyc1\n user-example:\n type: digitalocean:DatabaseUser\n properties:\n clusterId: ${[\"replica-example\"].uuid}\n name: foobar\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n### Create a new user for a Kafka database cluster \n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst kafka_example = new digitalocean.DatabaseCluster(\"kafka-example\", {\n name: \"example-kafka-cluster\",\n engine: \"kafka\",\n version: \"3.5\",\n size: \"db-s-2vcpu-2gb\",\n region: digitalocean.Region.NYC1,\n nodeCount: 3,\n});\nconst foobarTopic = new digitalocean.DatabaseKafkaTopic(\"foobar_topic\", {\n clusterId: foobar.id,\n name: \"topic-1\",\n});\nconst foobarUser = new digitalocean.DatabaseUser(\"foobar_user\", {\n clusterId: foobar.id,\n name: \"example-user\",\n settings: [{\n acls: [\n {\n topic: \"topic-1\",\n permission: \"produce\",\n },\n {\n topic: \"topic-2\",\n permission: \"produceconsume\",\n },\n {\n topic: \"topic-*\",\n permission: \"consume\",\n },\n ],\n }],\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nkafka_example = digitalocean.DatabaseCluster(\"kafka-example\",\n name=\"example-kafka-cluster\",\n engine=\"kafka\",\n version=\"3.5\",\n size=\"db-s-2vcpu-2gb\",\n region=digitalocean.Region.NYC1,\n node_count=3)\nfoobar_topic = digitalocean.DatabaseKafkaTopic(\"foobar_topic\",\n cluster_id=foobar[\"id\"],\n name=\"topic-1\")\nfoobar_user = digitalocean.DatabaseUser(\"foobar_user\",\n cluster_id=foobar[\"id\"],\n name=\"example-user\",\n settings=[digitalocean.DatabaseUserSettingArgs(\n acls=[\n digitalocean.DatabaseUserSettingAclArgs(\n topic=\"topic-1\",\n permission=\"produce\",\n ),\n digitalocean.DatabaseUserSettingAclArgs(\n topic=\"topic-2\",\n permission=\"produceconsume\",\n ),\n digitalocean.DatabaseUserSettingAclArgs(\n topic=\"topic-*\",\n permission=\"consume\",\n ),\n ],\n )])\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var kafka_example = new DigitalOcean.DatabaseCluster(\"kafka-example\", new()\n {\n Name = \"example-kafka-cluster\",\n Engine = \"kafka\",\n Version = \"3.5\",\n Size = \"db-s-2vcpu-2gb\",\n Region = DigitalOcean.Region.NYC1,\n NodeCount = 3,\n });\n\n var foobarTopic = new DigitalOcean.DatabaseKafkaTopic(\"foobar_topic\", new()\n {\n ClusterId = foobar.Id,\n Name = \"topic-1\",\n });\n\n var foobarUser = new DigitalOcean.DatabaseUser(\"foobar_user\", new()\n {\n ClusterId = foobar.Id,\n Name = \"example-user\",\n Settings = new[]\n {\n new DigitalOcean.Inputs.DatabaseUserSettingArgs\n {\n Acls = new[]\n {\n new DigitalOcean.Inputs.DatabaseUserSettingAclArgs\n {\n Topic = \"topic-1\",\n Permission = \"produce\",\n },\n new DigitalOcean.Inputs.DatabaseUserSettingAclArgs\n {\n Topic = \"topic-2\",\n Permission = \"produceconsume\",\n },\n new DigitalOcean.Inputs.DatabaseUserSettingAclArgs\n {\n Topic = \"topic-*\",\n Permission = \"consume\",\n },\n },\n },\n },\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := digitalocean.NewDatabaseCluster(ctx, \"kafka-example\", \u0026digitalocean.DatabaseClusterArgs{\n\t\t\tName: pulumi.String(\"example-kafka-cluster\"),\n\t\t\tEngine: pulumi.String(\"kafka\"),\n\t\t\tVersion: pulumi.String(\"3.5\"),\n\t\t\tSize: pulumi.String(\"db-s-2vcpu-2gb\"),\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC1),\n\t\t\tNodeCount: pulumi.Int(3),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = digitalocean.NewDatabaseKafkaTopic(ctx, \"foobar_topic\", \u0026digitalocean.DatabaseKafkaTopicArgs{\n\t\t\tClusterId: pulumi.Any(foobar.Id),\n\t\t\tName: pulumi.String(\"topic-1\"),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = digitalocean.NewDatabaseUser(ctx, \"foobar_user\", \u0026digitalocean.DatabaseUserArgs{\n\t\t\tClusterId: pulumi.Any(foobar.Id),\n\t\t\tName: pulumi.String(\"example-user\"),\n\t\t\tSettings: digitalocean.DatabaseUserSettingArray{\n\t\t\t\t\u0026digitalocean.DatabaseUserSettingArgs{\n\t\t\t\t\tAcls: digitalocean.DatabaseUserSettingAclArray{\n\t\t\t\t\t\t\u0026digitalocean.DatabaseUserSettingAclArgs{\n\t\t\t\t\t\t\tTopic: pulumi.String(\"topic-1\"),\n\t\t\t\t\t\t\tPermission: pulumi.String(\"produce\"),\n\t\t\t\t\t\t},\n\t\t\t\t\t\t\u0026digitalocean.DatabaseUserSettingAclArgs{\n\t\t\t\t\t\t\tTopic: pulumi.String(\"topic-2\"),\n\t\t\t\t\t\t\tPermission: pulumi.String(\"produceconsume\"),\n\t\t\t\t\t\t},\n\t\t\t\t\t\t\u0026digitalocean.DatabaseUserSettingAclArgs{\n\t\t\t\t\t\t\tTopic: pulumi.String(\"topic-*\"),\n\t\t\t\t\t\t\tPermission: pulumi.String(\"consume\"),\n\t\t\t\t\t\t},\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t},\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.digitalocean.DatabaseCluster;\nimport com.pulumi.digitalocean.DatabaseClusterArgs;\nimport com.pulumi.digitalocean.DatabaseKafkaTopic;\nimport com.pulumi.digitalocean.DatabaseKafkaTopicArgs;\nimport com.pulumi.digitalocean.DatabaseUser;\nimport com.pulumi.digitalocean.DatabaseUserArgs;\nimport com.pulumi.digitalocean.inputs.DatabaseUserSettingArgs;\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 kafka_example = new DatabaseCluster(\"kafka-example\", DatabaseClusterArgs.builder() \n .name(\"example-kafka-cluster\")\n .engine(\"kafka\")\n .version(\"3.5\")\n .size(\"db-s-2vcpu-2gb\")\n .region(\"nyc1\")\n .nodeCount(3)\n .build());\n\n var foobarTopic = new DatabaseKafkaTopic(\"foobarTopic\", DatabaseKafkaTopicArgs.builder() \n .clusterId(foobar.id())\n .name(\"topic-1\")\n .build());\n\n var foobarUser = new DatabaseUser(\"foobarUser\", DatabaseUserArgs.builder() \n .clusterId(foobar.id())\n .name(\"example-user\")\n .settings(DatabaseUserSettingArgs.builder()\n .acls( \n DatabaseUserSettingAclArgs.builder()\n .topic(\"topic-1\")\n .permission(\"produce\")\n .build(),\n DatabaseUserSettingAclArgs.builder()\n .topic(\"topic-2\")\n .permission(\"produceconsume\")\n .build(),\n DatabaseUserSettingAclArgs.builder()\n .topic(\"topic-*\")\n .permission(\"consume\")\n .build())\n .build())\n .build());\n\n }\n}\n```\n```yaml\nresources:\n kafka-example:\n type: digitalocean:DatabaseCluster\n properties:\n name: example-kafka-cluster\n engine: kafka\n version: '3.5'\n size: db-s-2vcpu-2gb\n region: nyc1\n nodeCount: 3\n foobarTopic:\n type: digitalocean:DatabaseKafkaTopic\n name: foobar_topic\n properties:\n clusterId: ${foobar.id}\n name: topic-1\n foobarUser:\n type: digitalocean:DatabaseUser\n name: foobar_user\n properties:\n clusterId: ${foobar.id}\n name: example-user\n settings:\n - acls:\n - topic: topic-1\n permission: produce\n - topic: topic-2\n permission: produceconsume\n - topic: topic-*\n permission: consume\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n## Import\n\nDatabase user can be imported using the `id` of the source database cluster\n\nand the `name` of the user joined with a comma. For example:\n\n```sh\n$ pulumi import digitalocean:index/databaseUser:DatabaseUser user-example 245bcfd0-7f31-4ce6-a2bc-475a116cca97,foobar\n```\n\n", "properties": { "accessCert": { "type": "string", @@ -10764,7 +10764,7 @@ } }, "digitalocean:index/dnsRecord:DnsRecord": { - "description": "Provides a DigitalOcean DNS record resource.\n\n## Example Usage\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst _default = new digitalocean.Domain(\"default\", {name: \"example.com\"});\n// Add an A record to the domain for www.example.com.\nconst www = new digitalocean.DnsRecord(\"www\", {\n domain: _default.id,\n type: digitalocean.RecordType.A,\n value: \"192.168.0.11\",\n});\n// Add a MX record for the example.com domain itself.\nconst mx = new digitalocean.DnsRecord(\"mx\", {\n domain: _default.id,\n type: digitalocean.RecordType.MX,\n priority: 10,\n value: \"mail.example.com.\",\n});\nexport const wwwFqdn = www.fqdn;\nexport const mxFqdn = mx.fqdn;\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\ndefault = digitalocean.Domain(\"default\", name=\"example.com\")\n# Add an A record to the domain for www.example.com.\nwww = digitalocean.DnsRecord(\"www\",\n domain=default.id,\n type=digitalocean.RecordType.A,\n value=\"192.168.0.11\")\n# Add a MX record for the example.com domain itself.\nmx = digitalocean.DnsRecord(\"mx\",\n domain=default.id,\n type=digitalocean.RecordType.MX,\n priority=10,\n value=\"mail.example.com.\")\npulumi.export(\"wwwFqdn\", www.fqdn)\npulumi.export(\"mxFqdn\", mx.fqdn)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var @default = new DigitalOcean.Domain(\"default\", new()\n {\n Name = \"example.com\",\n });\n\n // Add an A record to the domain for www.example.com.\n var www = new DigitalOcean.DnsRecord(\"www\", new()\n {\n Domain = @default.Id,\n Type = DigitalOcean.RecordType.A,\n Value = \"192.168.0.11\",\n });\n\n // Add a MX record for the example.com domain itself.\n var mx = new DigitalOcean.DnsRecord(\"mx\", new()\n {\n Domain = @default.Id,\n Type = DigitalOcean.RecordType.MX,\n Priority = 10,\n Value = \"mail.example.com.\",\n });\n\n return new Dictionary\u003cstring, object?\u003e\n {\n [\"wwwFqdn\"] = www.Fqdn,\n [\"mxFqdn\"] = mx.Fqdn,\n };\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := digitalocean.NewDomain(ctx, \"default\", \u0026digitalocean.DomainArgs{\n\t\t\tName: pulumi.String(\"example.com\"),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t// Add an A record to the domain for www.example.com.\n\t\twww, err := digitalocean.NewDnsRecord(ctx, \"www\", \u0026digitalocean.DnsRecordArgs{\n\t\t\tDomain: _default.ID(),\n\t\t\tType: pulumi.String(digitalocean.RecordTypeA),\n\t\t\tValue: pulumi.String(\"192.168.0.11\"),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t// Add a MX record for the example.com domain itself.\n\t\tmx, err := digitalocean.NewDnsRecord(ctx, \"mx\", \u0026digitalocean.DnsRecordArgs{\n\t\t\tDomain: _default.ID(),\n\t\t\tType: pulumi.String(digitalocean.RecordTypeMX),\n\t\t\tPriority: pulumi.Int(10),\n\t\t\tValue: pulumi.String(\"mail.example.com.\"),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tctx.Export(\"wwwFqdn\", www.Fqdn)\n\t\tctx.Export(\"mxFqdn\", mx.Fqdn)\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.digitalocean.Domain;\nimport com.pulumi.digitalocean.DomainArgs;\nimport com.pulumi.digitalocean.DnsRecord;\nimport com.pulumi.digitalocean.DnsRecordArgs;\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 default_ = new Domain(\"default\", DomainArgs.builder() \n .name(\"example.com\")\n .build());\n\n // Add an A record to the domain for www.example.com.\n var www = new DnsRecord(\"www\", DnsRecordArgs.builder() \n .domain(default_.id())\n .type(\"A\")\n .value(\"192.168.0.11\")\n .build());\n\n // Add a MX record for the example.com domain itself.\n var mx = new DnsRecord(\"mx\", DnsRecordArgs.builder() \n .domain(default_.id())\n .type(\"MX\")\n .priority(10)\n .value(\"mail.example.com.\")\n .build());\n\n ctx.export(\"wwwFqdn\", www.fqdn());\n ctx.export(\"mxFqdn\", mx.fqdn());\n }\n}\n```\n```yaml\nresources:\n default:\n type: digitalocean:Domain\n properties:\n name: example.com\n # Add an A record to the domain for www.example.com.\n www:\n type: digitalocean:DnsRecord\n properties:\n domain: ${default.id}\n type: A\n value: 192.168.0.11\n # Add a MX record for the example.com domain itself.\n mx:\n type: digitalocean:DnsRecord\n properties:\n domain: ${default.id}\n type: MX\n priority: 10\n value: mail.example.com.\noutputs:\n # Output the FQDN for the www A record.\n wwwFqdn: ${www.fqdn}\n # Output the FQDN for the MX record.\n mxFqdn: ${mx.fqdn}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n## Import\n\nRecords can be imported using the domain name and record `id` when joined with a comma. See the following example:\n\n```sh\n$ pulumi import digitalocean:index/dnsRecord:DnsRecord example_record example.com,12345678\n```\n\n~\u003e You find the `id` of the records [using the DigitalOcean API](https://docs.digitalocean.com/reference/api/api-reference/#operation/domains_list_records) or CLI. Run the follow command to list the IDs for all DNS records on a domain: `doctl compute domain records list \u003cdomain.name\u003e`\n\n", + "description": "Provides a DigitalOcean DNS record resource.\n\n## Example Usage\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst _default = new digitalocean.Domain(\"default\", {name: \"example.com\"});\n// Add an A record to the domain for www.example.com.\nconst www = new digitalocean.DnsRecord(\"www\", {\n domain: _default.id,\n type: digitalocean.RecordType.A,\n name: \"www\",\n value: \"192.168.0.11\",\n});\n// Add a MX record for the example.com domain itself.\nconst mx = new digitalocean.DnsRecord(\"mx\", {\n domain: _default.id,\n type: digitalocean.RecordType.MX,\n name: \"@\",\n priority: 10,\n value: \"mail.example.com.\",\n});\nexport const wwwFqdn = www.fqdn;\nexport const mxFqdn = mx.fqdn;\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\ndefault = digitalocean.Domain(\"default\", name=\"example.com\")\n# Add an A record to the domain for www.example.com.\nwww = digitalocean.DnsRecord(\"www\",\n domain=default.id,\n type=digitalocean.RecordType.A,\n name=\"www\",\n value=\"192.168.0.11\")\n# Add a MX record for the example.com domain itself.\nmx = digitalocean.DnsRecord(\"mx\",\n domain=default.id,\n type=digitalocean.RecordType.MX,\n name=\"@\",\n priority=10,\n value=\"mail.example.com.\")\npulumi.export(\"wwwFqdn\", www.fqdn)\npulumi.export(\"mxFqdn\", mx.fqdn)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var @default = new DigitalOcean.Domain(\"default\", new()\n {\n Name = \"example.com\",\n });\n\n // Add an A record to the domain for www.example.com.\n var www = new DigitalOcean.DnsRecord(\"www\", new()\n {\n Domain = @default.Id,\n Type = DigitalOcean.RecordType.A,\n Name = \"www\",\n Value = \"192.168.0.11\",\n });\n\n // Add a MX record for the example.com domain itself.\n var mx = new DigitalOcean.DnsRecord(\"mx\", new()\n {\n Domain = @default.Id,\n Type = DigitalOcean.RecordType.MX,\n Name = \"@\",\n Priority = 10,\n Value = \"mail.example.com.\",\n });\n\n return new Dictionary\u003cstring, object?\u003e\n {\n [\"wwwFqdn\"] = www.Fqdn,\n [\"mxFqdn\"] = mx.Fqdn,\n };\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := digitalocean.NewDomain(ctx, \"default\", \u0026digitalocean.DomainArgs{\n\t\t\tName: pulumi.String(\"example.com\"),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t// Add an A record to the domain for www.example.com.\n\t\twww, err := digitalocean.NewDnsRecord(ctx, \"www\", \u0026digitalocean.DnsRecordArgs{\n\t\t\tDomain: _default.ID(),\n\t\t\tType: pulumi.String(digitalocean.RecordTypeA),\n\t\t\tName: pulumi.String(\"www\"),\n\t\t\tValue: pulumi.String(\"192.168.0.11\"),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t// Add a MX record for the example.com domain itself.\n\t\tmx, err := digitalocean.NewDnsRecord(ctx, \"mx\", \u0026digitalocean.DnsRecordArgs{\n\t\t\tDomain: _default.ID(),\n\t\t\tType: pulumi.String(digitalocean.RecordTypeMX),\n\t\t\tName: pulumi.String(\"@\"),\n\t\t\tPriority: pulumi.Int(10),\n\t\t\tValue: pulumi.String(\"mail.example.com.\"),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tctx.Export(\"wwwFqdn\", www.Fqdn)\n\t\tctx.Export(\"mxFqdn\", mx.Fqdn)\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.digitalocean.Domain;\nimport com.pulumi.digitalocean.DomainArgs;\nimport com.pulumi.digitalocean.DnsRecord;\nimport com.pulumi.digitalocean.DnsRecordArgs;\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 default_ = new Domain(\"default\", DomainArgs.builder() \n .name(\"example.com\")\n .build());\n\n // Add an A record to the domain for www.example.com.\n var www = new DnsRecord(\"www\", DnsRecordArgs.builder() \n .domain(default_.id())\n .type(\"A\")\n .name(\"www\")\n .value(\"192.168.0.11\")\n .build());\n\n // Add a MX record for the example.com domain itself.\n var mx = new DnsRecord(\"mx\", DnsRecordArgs.builder() \n .domain(default_.id())\n .type(\"MX\")\n .name(\"@\")\n .priority(10)\n .value(\"mail.example.com.\")\n .build());\n\n ctx.export(\"wwwFqdn\", www.fqdn());\n ctx.export(\"mxFqdn\", mx.fqdn());\n }\n}\n```\n```yaml\nresources:\n default:\n type: digitalocean:Domain\n properties:\n name: example.com\n # Add an A record to the domain for www.example.com.\n www:\n type: digitalocean:DnsRecord\n properties:\n domain: ${default.id}\n type: A\n name: www\n value: 192.168.0.11\n # Add a MX record for the example.com domain itself.\n mx:\n type: digitalocean:DnsRecord\n properties:\n domain: ${default.id}\n type: MX\n name: '@'\n priority: 10\n value: mail.example.com.\noutputs:\n # Output the FQDN for the www A record.\n wwwFqdn: ${www.fqdn}\n # Output the FQDN for the MX record.\n mxFqdn: ${mx.fqdn}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n## Import\n\nRecords can be imported using the domain name and record `id` when joined with a comma. See the following example:\n\n```sh\n$ pulumi import digitalocean:index/dnsRecord:DnsRecord example_record example.com,12345678\n```\n\n~\u003e You find the `id` of the records [using the DigitalOcean API](https://docs.digitalocean.com/reference/api/api-reference/#operation/domains_list_records) or CLI. Run the follow command to list the IDs for all DNS records on a domain: `doctl compute domain records list \u003cdomain.name\u003e`\n\n", "properties": { "domain": { "type": "string", @@ -10940,7 +10940,7 @@ } }, "digitalocean:index/domain:Domain": { - "description": "Provides a DigitalOcean domain resource.\n\n## Example Usage\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\n// Create a new domain\nconst _default = new digitalocean.Domain(\"default\", {\n name: \"example.com\",\n ipAddress: digitalocean_droplet.foo.ipv4_address,\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\n# Create a new domain\ndefault = digitalocean.Domain(\"default\",\n name=\"example.com\",\n ip_address=digitalocean_droplet[\"foo\"][\"ipv4_address\"])\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n // Create a new domain\n var @default = new DigitalOcean.Domain(\"default\", new()\n {\n Name = \"example.com\",\n IpAddress = digitalocean_droplet.Foo.Ipv4_address,\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t// Create a new domain\n\t\t_, err := digitalocean.NewDomain(ctx, \"default\", \u0026digitalocean.DomainArgs{\n\t\t\tName: pulumi.String(\"example.com\"),\n\t\t\tIpAddress: pulumi.Any(digitalocean_droplet.Foo.Ipv4_address),\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.digitalocean.Domain;\nimport com.pulumi.digitalocean.DomainArgs;\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 // Create a new domain\n var default_ = new Domain(\"default\", DomainArgs.builder() \n .name(\"example.com\")\n .ipAddress(digitalocean_droplet.foo().ipv4_address())\n .build());\n\n }\n}\n```\n```yaml\nresources:\n # Create a new domain\n default:\n type: digitalocean:Domain\n properties:\n name: example.com\n ipAddress: ${digitalocean_droplet.foo.ipv4_address}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n## Import\n\nDomains can be imported using the `domain name`, e.g.\n\n```sh\n$ pulumi import digitalocean:index/domain:Domain mydomain mytestdomain.com\n```\n\n", + "description": "Provides a DigitalOcean domain resource.\n\n## Example Usage\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\n// Create a new domain\nconst _default = new digitalocean.Domain(\"default\", {\n name: \"example.com\",\n ipAddress: foo.ipv4Address,\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\n# Create a new domain\ndefault = digitalocean.Domain(\"default\",\n name=\"example.com\",\n ip_address=foo[\"ipv4Address\"])\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n // Create a new domain\n var @default = new DigitalOcean.Domain(\"default\", new()\n {\n Name = \"example.com\",\n IpAddress = foo.Ipv4Address,\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t// Create a new domain\n\t\t_, err := digitalocean.NewDomain(ctx, \"default\", \u0026digitalocean.DomainArgs{\n\t\t\tName: pulumi.String(\"example.com\"),\n\t\t\tIpAddress: pulumi.Any(foo.Ipv4Address),\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.digitalocean.Domain;\nimport com.pulumi.digitalocean.DomainArgs;\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 // Create a new domain\n var default_ = new Domain(\"default\", DomainArgs.builder() \n .name(\"example.com\")\n .ipAddress(foo.ipv4Address())\n .build());\n\n }\n}\n```\n```yaml\nresources:\n # Create a new domain\n default:\n type: digitalocean:Domain\n properties:\n name: example.com\n ipAddress: ${foo.ipv4Address}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n## Import\n\nDomains can be imported using the `domain name`, e.g.\n\n```sh\n$ pulumi import digitalocean:index/domain:Domain mydomain mytestdomain.com\n```\n\n", "properties": { "domainUrn": { "type": "string", @@ -11005,7 +11005,7 @@ } }, "digitalocean:index/droplet:Droplet": { - "description": "Provides a DigitalOcean Droplet resource. This can be used to create,\nmodify, and delete Droplets.\n\n## Example Usage\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\n// Create a new Web Droplet in the nyc2 region\nconst web = new digitalocean.Droplet(\"web\", {\n image: \"ubuntu-20-04-x64\",\n region: digitalocean.Region.NYC2,\n size: digitalocean.DropletSlug.DropletS1VCPU1GB,\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\n# Create a new Web Droplet in the nyc2 region\nweb = digitalocean.Droplet(\"web\",\n image=\"ubuntu-20-04-x64\",\n region=digitalocean.Region.NYC2,\n size=digitalocean.DropletSlug.DROPLET_S1_VCPU1_GB)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n // Create a new Web Droplet in the nyc2 region\n var web = new DigitalOcean.Droplet(\"web\", new()\n {\n Image = \"ubuntu-20-04-x64\",\n Region = DigitalOcean.Region.NYC2,\n Size = DigitalOcean.DropletSlug.DropletS1VCPU1GB,\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t// Create a new Web Droplet in the nyc2 region\n\t\t_, err := digitalocean.NewDroplet(ctx, \"web\", \u0026digitalocean.DropletArgs{\n\t\t\tImage: pulumi.String(\"ubuntu-20-04-x64\"),\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC2),\n\t\t\tSize: pulumi.String(digitalocean.DropletSlugDropletS1VCPU1GB),\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.digitalocean.Droplet;\nimport com.pulumi.digitalocean.DropletArgs;\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 // Create a new Web Droplet in the nyc2 region\n var web = new Droplet(\"web\", DropletArgs.builder() \n .image(\"ubuntu-20-04-x64\")\n .region(\"nyc2\")\n .size(\"s-1vcpu-1gb\")\n .build());\n\n }\n}\n```\n```yaml\nresources:\n # Create a new Web Droplet in the nyc2 region\n web:\n type: digitalocean:Droplet\n properties:\n image: ubuntu-20-04-x64\n region: nyc2\n size: s-1vcpu-1gb\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n## Import\n\nDroplets can be imported using the Droplet `id`, e.g.\n\n```sh\n$ pulumi import digitalocean:index/droplet:Droplet mydroplet 100823\n```\n\n", + "description": "Provides a DigitalOcean Droplet resource. This can be used to create,\nmodify, and delete Droplets.\n\n## Example Usage\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\n// Create a new Web Droplet in the nyc2 region\nconst web = new digitalocean.Droplet(\"web\", {\n image: \"ubuntu-20-04-x64\",\n name: \"web-1\",\n region: digitalocean.Region.NYC2,\n size: digitalocean.DropletSlug.DropletS1VCPU1GB,\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\n# Create a new Web Droplet in the nyc2 region\nweb = digitalocean.Droplet(\"web\",\n image=\"ubuntu-20-04-x64\",\n name=\"web-1\",\n region=digitalocean.Region.NYC2,\n size=digitalocean.DropletSlug.DROPLET_S1_VCPU1_GB)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n // Create a new Web Droplet in the nyc2 region\n var web = new DigitalOcean.Droplet(\"web\", new()\n {\n Image = \"ubuntu-20-04-x64\",\n Name = \"web-1\",\n Region = DigitalOcean.Region.NYC2,\n Size = DigitalOcean.DropletSlug.DropletS1VCPU1GB,\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t// Create a new Web Droplet in the nyc2 region\n\t\t_, err := digitalocean.NewDroplet(ctx, \"web\", \u0026digitalocean.DropletArgs{\n\t\t\tImage: pulumi.String(\"ubuntu-20-04-x64\"),\n\t\t\tName: pulumi.String(\"web-1\"),\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC2),\n\t\t\tSize: pulumi.String(digitalocean.DropletSlugDropletS1VCPU1GB),\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.digitalocean.Droplet;\nimport com.pulumi.digitalocean.DropletArgs;\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 // Create a new Web Droplet in the nyc2 region\n var web = new Droplet(\"web\", DropletArgs.builder() \n .image(\"ubuntu-20-04-x64\")\n .name(\"web-1\")\n .region(\"nyc2\")\n .size(\"s-1vcpu-1gb\")\n .build());\n\n }\n}\n```\n```yaml\nresources:\n # Create a new Web Droplet in the nyc2 region\n web:\n type: digitalocean:Droplet\n properties:\n image: ubuntu-20-04-x64\n name: web-1\n region: nyc2\n size: s-1vcpu-1gb\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n## Import\n\nDroplets can be imported using the Droplet `id`, e.g.\n\n```sh\n$ pulumi import digitalocean:index/droplet:Droplet mydroplet 100823\n```\n\n", "properties": { "backups": { "type": "boolean", @@ -11411,7 +11411,7 @@ } }, "digitalocean:index/dropletSnapshot:DropletSnapshot": { - "description": "Provides a resource which can be used to create a snapshot from an existing DigitalOcean Droplet.\n\n## Example Usage\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst web = new digitalocean.Droplet(\"web\", {\n size: digitalocean.DropletSlug.DropletS1VCPU1GB,\n image: \"ubuntu-22-04-x64\",\n region: digitalocean.Region.NYC3,\n});\nconst web_snapshot = new digitalocean.DropletSnapshot(\"web-snapshot\", {dropletId: web.id});\nconst from_snapshot = new digitalocean.Droplet(\"from-snapshot\", {\n image: web_snapshot.id,\n region: digitalocean.Region.NYC3,\n size: digitalocean.DropletSlug.DropletS2VCPU4GB,\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nweb = digitalocean.Droplet(\"web\",\n size=digitalocean.DropletSlug.DROPLET_S1_VCPU1_GB,\n image=\"ubuntu-22-04-x64\",\n region=digitalocean.Region.NYC3)\nweb_snapshot = digitalocean.DropletSnapshot(\"web-snapshot\", droplet_id=web.id)\nfrom_snapshot = digitalocean.Droplet(\"from-snapshot\",\n image=web_snapshot.id,\n region=digitalocean.Region.NYC3,\n size=digitalocean.DropletSlug.DROPLET_S2_VCPU4_GB)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var web = new DigitalOcean.Droplet(\"web\", new()\n {\n Size = DigitalOcean.DropletSlug.DropletS1VCPU1GB,\n Image = \"ubuntu-22-04-x64\",\n Region = DigitalOcean.Region.NYC3,\n });\n\n var web_snapshot = new DigitalOcean.DropletSnapshot(\"web-snapshot\", new()\n {\n DropletId = web.Id,\n });\n\n var from_snapshot = new DigitalOcean.Droplet(\"from-snapshot\", new()\n {\n Image = web_snapshot.Id,\n Region = DigitalOcean.Region.NYC3,\n Size = DigitalOcean.DropletSlug.DropletS2VCPU4GB,\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tweb, err := digitalocean.NewDroplet(ctx, \"web\", \u0026digitalocean.DropletArgs{\n\t\t\tSize: pulumi.String(digitalocean.DropletSlugDropletS1VCPU1GB),\n\t\t\tImage: pulumi.String(\"ubuntu-22-04-x64\"),\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC3),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = digitalocean.NewDropletSnapshot(ctx, \"web-snapshot\", \u0026digitalocean.DropletSnapshotArgs{\n\t\t\tDropletId: web.ID(),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = digitalocean.NewDroplet(ctx, \"from-snapshot\", \u0026digitalocean.DropletArgs{\n\t\t\tImage: web_snapshot.ID(),\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC3),\n\t\t\tSize: pulumi.String(digitalocean.DropletSlugDropletS2VCPU4GB),\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.digitalocean.Droplet;\nimport com.pulumi.digitalocean.DropletArgs;\nimport com.pulumi.digitalocean.DropletSnapshot;\nimport com.pulumi.digitalocean.DropletSnapshotArgs;\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 web = new Droplet(\"web\", DropletArgs.builder() \n .size(\"s-1vcpu-1gb\")\n .image(\"ubuntu-22-04-x64\")\n .region(\"nyc3\")\n .build());\n\n var web_snapshot = new DropletSnapshot(\"web-snapshot\", DropletSnapshotArgs.builder() \n .dropletId(web.id())\n .build());\n\n var from_snapshot = new Droplet(\"from-snapshot\", DropletArgs.builder() \n .image(web_snapshot.id())\n .region(\"nyc3\")\n .size(\"s-2vcpu-4gb\")\n .build());\n\n }\n}\n```\n```yaml\nresources:\n web:\n type: digitalocean:Droplet\n properties:\n size: s-1vcpu-1gb\n image: ubuntu-22-04-x64\n region: nyc3\n web-snapshot:\n type: digitalocean:DropletSnapshot\n properties:\n dropletId: ${web.id}\n from-snapshot:\n type: digitalocean:Droplet\n properties:\n image: ${[\"web-snapshot\"].id}\n region: nyc3\n size: s-2vcpu-4gb\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n## Import\n\nDroplet Snapshots can be imported using the `snapshot id`, e.g.\n\n```sh\n$ pulumi import digitalocean:index/dropletSnapshot:DropletSnapshot mysnapshot 123456\n```\n\n", + "description": "Provides a resource which can be used to create a snapshot from an existing DigitalOcean Droplet.\n\n## Example Usage\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst web = new digitalocean.Droplet(\"web\", {\n name: \"web-01\",\n size: digitalocean.DropletSlug.DropletS1VCPU1GB,\n image: \"ubuntu-22-04-x64\",\n region: digitalocean.Region.NYC3,\n});\nconst web_snapshot = new digitalocean.DropletSnapshot(\"web-snapshot\", {\n dropletId: web.id,\n name: \"web-snapshot-01\",\n});\nconst from_snapshot = new digitalocean.Droplet(\"from-snapshot\", {\n image: web_snapshot.id,\n name: \"web-02\",\n region: digitalocean.Region.NYC3,\n size: digitalocean.DropletSlug.DropletS2VCPU4GB,\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nweb = digitalocean.Droplet(\"web\",\n name=\"web-01\",\n size=digitalocean.DropletSlug.DROPLET_S1_VCPU1_GB,\n image=\"ubuntu-22-04-x64\",\n region=digitalocean.Region.NYC3)\nweb_snapshot = digitalocean.DropletSnapshot(\"web-snapshot\",\n droplet_id=web.id,\n name=\"web-snapshot-01\")\nfrom_snapshot = digitalocean.Droplet(\"from-snapshot\",\n image=web_snapshot.id,\n name=\"web-02\",\n region=digitalocean.Region.NYC3,\n size=digitalocean.DropletSlug.DROPLET_S2_VCPU4_GB)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var web = new DigitalOcean.Droplet(\"web\", new()\n {\n Name = \"web-01\",\n Size = DigitalOcean.DropletSlug.DropletS1VCPU1GB,\n Image = \"ubuntu-22-04-x64\",\n Region = DigitalOcean.Region.NYC3,\n });\n\n var web_snapshot = new DigitalOcean.DropletSnapshot(\"web-snapshot\", new()\n {\n DropletId = web.Id,\n Name = \"web-snapshot-01\",\n });\n\n var from_snapshot = new DigitalOcean.Droplet(\"from-snapshot\", new()\n {\n Image = web_snapshot.Id,\n Name = \"web-02\",\n Region = DigitalOcean.Region.NYC3,\n Size = DigitalOcean.DropletSlug.DropletS2VCPU4GB,\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tweb, err := digitalocean.NewDroplet(ctx, \"web\", \u0026digitalocean.DropletArgs{\n\t\t\tName: pulumi.String(\"web-01\"),\n\t\t\tSize: pulumi.String(digitalocean.DropletSlugDropletS1VCPU1GB),\n\t\t\tImage: pulumi.String(\"ubuntu-22-04-x64\"),\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC3),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = digitalocean.NewDropletSnapshot(ctx, \"web-snapshot\", \u0026digitalocean.DropletSnapshotArgs{\n\t\t\tDropletId: web.ID(),\n\t\t\tName: pulumi.String(\"web-snapshot-01\"),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = digitalocean.NewDroplet(ctx, \"from-snapshot\", \u0026digitalocean.DropletArgs{\n\t\t\tImage: web_snapshot.ID(),\n\t\t\tName: pulumi.String(\"web-02\"),\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC3),\n\t\t\tSize: pulumi.String(digitalocean.DropletSlugDropletS2VCPU4GB),\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.digitalocean.Droplet;\nimport com.pulumi.digitalocean.DropletArgs;\nimport com.pulumi.digitalocean.DropletSnapshot;\nimport com.pulumi.digitalocean.DropletSnapshotArgs;\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 web = new Droplet(\"web\", DropletArgs.builder() \n .name(\"web-01\")\n .size(\"s-1vcpu-1gb\")\n .image(\"ubuntu-22-04-x64\")\n .region(\"nyc3\")\n .build());\n\n var web_snapshot = new DropletSnapshot(\"web-snapshot\", DropletSnapshotArgs.builder() \n .dropletId(web.id())\n .name(\"web-snapshot-01\")\n .build());\n\n var from_snapshot = new Droplet(\"from-snapshot\", DropletArgs.builder() \n .image(web_snapshot.id())\n .name(\"web-02\")\n .region(\"nyc3\")\n .size(\"s-2vcpu-4gb\")\n .build());\n\n }\n}\n```\n```yaml\nresources:\n web:\n type: digitalocean:Droplet\n properties:\n name: web-01\n size: s-1vcpu-1gb\n image: ubuntu-22-04-x64\n region: nyc3\n web-snapshot:\n type: digitalocean:DropletSnapshot\n properties:\n dropletId: ${web.id}\n name: web-snapshot-01\n from-snapshot:\n type: digitalocean:Droplet\n properties:\n image: ${[\"web-snapshot\"].id}\n name: web-02\n region: nyc3\n size: s-2vcpu-4gb\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n## Import\n\nDroplet Snapshots can be imported using the `snapshot id`, e.g.\n\n```sh\n$ pulumi import digitalocean:index/dropletSnapshot:DropletSnapshot mysnapshot 123456\n```\n\n", "properties": { "createdAt": { "type": "string", @@ -11501,7 +11501,7 @@ } }, "digitalocean:index/firewall:Firewall": { - "description": "Provides a DigitalOcean Cloud Firewall resource. This can be used to create,\nmodify, and delete Firewalls.\n\n## Example Usage\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst webDroplet = new digitalocean.Droplet(\"webDroplet\", {\n size: digitalocean.DropletSlug.DropletS1VCPU1GB,\n image: \"ubuntu-18-04-x64\",\n region: digitalocean.Region.NYC3,\n});\nconst webFirewall = new digitalocean.Firewall(\"webFirewall\", {\n dropletIds: [webDroplet.id],\n inboundRules: [\n {\n protocol: \"tcp\",\n portRange: \"22\",\n sourceAddresses: [\n \"192.168.1.0/24\",\n \"2002:1:2::/48\",\n ],\n },\n {\n protocol: \"tcp\",\n portRange: \"80\",\n sourceAddresses: [\n \"0.0.0.0/0\",\n \"::/0\",\n ],\n },\n {\n protocol: \"tcp\",\n portRange: \"443\",\n sourceAddresses: [\n \"0.0.0.0/0\",\n \"::/0\",\n ],\n },\n {\n protocol: \"icmp\",\n sourceAddresses: [\n \"0.0.0.0/0\",\n \"::/0\",\n ],\n },\n ],\n outboundRules: [\n {\n protocol: \"tcp\",\n portRange: \"53\",\n destinationAddresses: [\n \"0.0.0.0/0\",\n \"::/0\",\n ],\n },\n {\n protocol: \"udp\",\n portRange: \"53\",\n destinationAddresses: [\n \"0.0.0.0/0\",\n \"::/0\",\n ],\n },\n {\n protocol: \"icmp\",\n destinationAddresses: [\n \"0.0.0.0/0\",\n \"::/0\",\n ],\n },\n ],\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nweb_droplet = digitalocean.Droplet(\"webDroplet\",\n size=digitalocean.DropletSlug.DROPLET_S1_VCPU1_GB,\n image=\"ubuntu-18-04-x64\",\n region=digitalocean.Region.NYC3)\nweb_firewall = digitalocean.Firewall(\"webFirewall\",\n droplet_ids=[web_droplet.id],\n inbound_rules=[\n digitalocean.FirewallInboundRuleArgs(\n protocol=\"tcp\",\n port_range=\"22\",\n source_addresses=[\n \"192.168.1.0/24\",\n \"2002:1:2::/48\",\n ],\n ),\n digitalocean.FirewallInboundRuleArgs(\n protocol=\"tcp\",\n port_range=\"80\",\n source_addresses=[\n \"0.0.0.0/0\",\n \"::/0\",\n ],\n ),\n digitalocean.FirewallInboundRuleArgs(\n protocol=\"tcp\",\n port_range=\"443\",\n source_addresses=[\n \"0.0.0.0/0\",\n \"::/0\",\n ],\n ),\n digitalocean.FirewallInboundRuleArgs(\n protocol=\"icmp\",\n source_addresses=[\n \"0.0.0.0/0\",\n \"::/0\",\n ],\n ),\n ],\n outbound_rules=[\n digitalocean.FirewallOutboundRuleArgs(\n protocol=\"tcp\",\n port_range=\"53\",\n destination_addresses=[\n \"0.0.0.0/0\",\n \"::/0\",\n ],\n ),\n digitalocean.FirewallOutboundRuleArgs(\n protocol=\"udp\",\n port_range=\"53\",\n destination_addresses=[\n \"0.0.0.0/0\",\n \"::/0\",\n ],\n ),\n digitalocean.FirewallOutboundRuleArgs(\n protocol=\"icmp\",\n destination_addresses=[\n \"0.0.0.0/0\",\n \"::/0\",\n ],\n ),\n ])\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var webDroplet = new DigitalOcean.Droplet(\"webDroplet\", new()\n {\n Size = DigitalOcean.DropletSlug.DropletS1VCPU1GB,\n Image = \"ubuntu-18-04-x64\",\n Region = DigitalOcean.Region.NYC3,\n });\n\n var webFirewall = new DigitalOcean.Firewall(\"webFirewall\", new()\n {\n DropletIds = new[]\n {\n webDroplet.Id,\n },\n InboundRules = new[]\n {\n new DigitalOcean.Inputs.FirewallInboundRuleArgs\n {\n Protocol = \"tcp\",\n PortRange = \"22\",\n SourceAddresses = new[]\n {\n \"192.168.1.0/24\",\n \"2002:1:2::/48\",\n },\n },\n new DigitalOcean.Inputs.FirewallInboundRuleArgs\n {\n Protocol = \"tcp\",\n PortRange = \"80\",\n SourceAddresses = new[]\n {\n \"0.0.0.0/0\",\n \"::/0\",\n },\n },\n new DigitalOcean.Inputs.FirewallInboundRuleArgs\n {\n Protocol = \"tcp\",\n PortRange = \"443\",\n SourceAddresses = new[]\n {\n \"0.0.0.0/0\",\n \"::/0\",\n },\n },\n new DigitalOcean.Inputs.FirewallInboundRuleArgs\n {\n Protocol = \"icmp\",\n SourceAddresses = new[]\n {\n \"0.0.0.0/0\",\n \"::/0\",\n },\n },\n },\n OutboundRules = new[]\n {\n new DigitalOcean.Inputs.FirewallOutboundRuleArgs\n {\n Protocol = \"tcp\",\n PortRange = \"53\",\n DestinationAddresses = new[]\n {\n \"0.0.0.0/0\",\n \"::/0\",\n },\n },\n new DigitalOcean.Inputs.FirewallOutboundRuleArgs\n {\n Protocol = \"udp\",\n PortRange = \"53\",\n DestinationAddresses = new[]\n {\n \"0.0.0.0/0\",\n \"::/0\",\n },\n },\n new DigitalOcean.Inputs.FirewallOutboundRuleArgs\n {\n Protocol = \"icmp\",\n DestinationAddresses = new[]\n {\n \"0.0.0.0/0\",\n \"::/0\",\n },\n },\n },\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\twebDroplet, err := digitalocean.NewDroplet(ctx, \"webDroplet\", \u0026digitalocean.DropletArgs{\n\t\t\tSize: pulumi.String(digitalocean.DropletSlugDropletS1VCPU1GB),\n\t\t\tImage: pulumi.String(\"ubuntu-18-04-x64\"),\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC3),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = digitalocean.NewFirewall(ctx, \"webFirewall\", \u0026digitalocean.FirewallArgs{\n\t\t\tDropletIds: pulumi.IntArray{\n\t\t\t\twebDroplet.ID(),\n\t\t\t},\n\t\t\tInboundRules: digitalocean.FirewallInboundRuleArray{\n\t\t\t\t\u0026digitalocean.FirewallInboundRuleArgs{\n\t\t\t\t\tProtocol: pulumi.String(\"tcp\"),\n\t\t\t\t\tPortRange: pulumi.String(\"22\"),\n\t\t\t\t\tSourceAddresses: pulumi.StringArray{\n\t\t\t\t\t\tpulumi.String(\"192.168.1.0/24\"),\n\t\t\t\t\t\tpulumi.String(\"2002:1:2::/48\"),\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t\t\u0026digitalocean.FirewallInboundRuleArgs{\n\t\t\t\t\tProtocol: pulumi.String(\"tcp\"),\n\t\t\t\t\tPortRange: pulumi.String(\"80\"),\n\t\t\t\t\tSourceAddresses: pulumi.StringArray{\n\t\t\t\t\t\tpulumi.String(\"0.0.0.0/0\"),\n\t\t\t\t\t\tpulumi.String(\"::/0\"),\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t\t\u0026digitalocean.FirewallInboundRuleArgs{\n\t\t\t\t\tProtocol: pulumi.String(\"tcp\"),\n\t\t\t\t\tPortRange: pulumi.String(\"443\"),\n\t\t\t\t\tSourceAddresses: pulumi.StringArray{\n\t\t\t\t\t\tpulumi.String(\"0.0.0.0/0\"),\n\t\t\t\t\t\tpulumi.String(\"::/0\"),\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t\t\u0026digitalocean.FirewallInboundRuleArgs{\n\t\t\t\t\tProtocol: pulumi.String(\"icmp\"),\n\t\t\t\t\tSourceAddresses: pulumi.StringArray{\n\t\t\t\t\t\tpulumi.String(\"0.0.0.0/0\"),\n\t\t\t\t\t\tpulumi.String(\"::/0\"),\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t},\n\t\t\tOutboundRules: digitalocean.FirewallOutboundRuleArray{\n\t\t\t\t\u0026digitalocean.FirewallOutboundRuleArgs{\n\t\t\t\t\tProtocol: pulumi.String(\"tcp\"),\n\t\t\t\t\tPortRange: pulumi.String(\"53\"),\n\t\t\t\t\tDestinationAddresses: pulumi.StringArray{\n\t\t\t\t\t\tpulumi.String(\"0.0.0.0/0\"),\n\t\t\t\t\t\tpulumi.String(\"::/0\"),\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t\t\u0026digitalocean.FirewallOutboundRuleArgs{\n\t\t\t\t\tProtocol: pulumi.String(\"udp\"),\n\t\t\t\t\tPortRange: pulumi.String(\"53\"),\n\t\t\t\t\tDestinationAddresses: pulumi.StringArray{\n\t\t\t\t\t\tpulumi.String(\"0.0.0.0/0\"),\n\t\t\t\t\t\tpulumi.String(\"::/0\"),\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t\t\u0026digitalocean.FirewallOutboundRuleArgs{\n\t\t\t\t\tProtocol: pulumi.String(\"icmp\"),\n\t\t\t\t\tDestinationAddresses: pulumi.StringArray{\n\t\t\t\t\t\tpulumi.String(\"0.0.0.0/0\"),\n\t\t\t\t\t\tpulumi.String(\"::/0\"),\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t},\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.digitalocean.Droplet;\nimport com.pulumi.digitalocean.DropletArgs;\nimport com.pulumi.digitalocean.Firewall;\nimport com.pulumi.digitalocean.FirewallArgs;\nimport com.pulumi.digitalocean.inputs.FirewallInboundRuleArgs;\nimport com.pulumi.digitalocean.inputs.FirewallOutboundRuleArgs;\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 webDroplet = new Droplet(\"webDroplet\", DropletArgs.builder() \n .size(\"s-1vcpu-1gb\")\n .image(\"ubuntu-18-04-x64\")\n .region(\"nyc3\")\n .build());\n\n var webFirewall = new Firewall(\"webFirewall\", FirewallArgs.builder() \n .dropletIds(webDroplet.id())\n .inboundRules( \n FirewallInboundRuleArgs.builder()\n .protocol(\"tcp\")\n .portRange(\"22\")\n .sourceAddresses( \n \"192.168.1.0/24\",\n \"2002:1:2::/48\")\n .build(),\n FirewallInboundRuleArgs.builder()\n .protocol(\"tcp\")\n .portRange(\"80\")\n .sourceAddresses( \n \"0.0.0.0/0\",\n \"::/0\")\n .build(),\n FirewallInboundRuleArgs.builder()\n .protocol(\"tcp\")\n .portRange(\"443\")\n .sourceAddresses( \n \"0.0.0.0/0\",\n \"::/0\")\n .build(),\n FirewallInboundRuleArgs.builder()\n .protocol(\"icmp\")\n .sourceAddresses( \n \"0.0.0.0/0\",\n \"::/0\")\n .build())\n .outboundRules( \n FirewallOutboundRuleArgs.builder()\n .protocol(\"tcp\")\n .portRange(\"53\")\n .destinationAddresses( \n \"0.0.0.0/0\",\n \"::/0\")\n .build(),\n FirewallOutboundRuleArgs.builder()\n .protocol(\"udp\")\n .portRange(\"53\")\n .destinationAddresses( \n \"0.0.0.0/0\",\n \"::/0\")\n .build(),\n FirewallOutboundRuleArgs.builder()\n .protocol(\"icmp\")\n .destinationAddresses( \n \"0.0.0.0/0\",\n \"::/0\")\n .build())\n .build());\n\n }\n}\n```\n```yaml\nresources:\n webDroplet:\n type: digitalocean:Droplet\n properties:\n size: s-1vcpu-1gb\n image: ubuntu-18-04-x64\n region: nyc3\n webFirewall:\n type: digitalocean:Firewall\n properties:\n dropletIds:\n - ${webDroplet.id}\n inboundRules:\n - protocol: tcp\n portRange: '22'\n sourceAddresses:\n - 192.168.1.0/24\n - 2002:1:2::/48\n - protocol: tcp\n portRange: '80'\n sourceAddresses:\n - 0.0.0.0/0\n - ::/0\n - protocol: tcp\n portRange: '443'\n sourceAddresses:\n - 0.0.0.0/0\n - ::/0\n - protocol: icmp\n sourceAddresses:\n - 0.0.0.0/0\n - ::/0\n outboundRules:\n - protocol: tcp\n portRange: '53'\n destinationAddresses:\n - 0.0.0.0/0\n - ::/0\n - protocol: udp\n portRange: '53'\n destinationAddresses:\n - 0.0.0.0/0\n - ::/0\n - protocol: icmp\n destinationAddresses:\n - 0.0.0.0/0\n - ::/0\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n## Import\n\nFirewalls can be imported using the firewall `id`, e.g.\n\n```sh\n$ pulumi import digitalocean:index/firewall:Firewall myfirewall b8ecd2ab-2267-4a5e-8692-cbf1d32583e3\n```\n\n", + "description": "Provides a DigitalOcean Cloud Firewall resource. This can be used to create,\nmodify, and delete Firewalls.\n\n## Example Usage\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst web = new digitalocean.Droplet(\"web\", {\n name: \"web-1\",\n size: digitalocean.DropletSlug.DropletS1VCPU1GB,\n image: \"ubuntu-18-04-x64\",\n region: digitalocean.Region.NYC3,\n});\nconst webFirewall = new digitalocean.Firewall(\"web\", {\n name: \"only-22-80-and-443\",\n dropletIds: [web.id],\n inboundRules: [\n {\n protocol: \"tcp\",\n portRange: \"22\",\n sourceAddresses: [\n \"192.168.1.0/24\",\n \"2002:1:2::/48\",\n ],\n },\n {\n protocol: \"tcp\",\n portRange: \"80\",\n sourceAddresses: [\n \"0.0.0.0/0\",\n \"::/0\",\n ],\n },\n {\n protocol: \"tcp\",\n portRange: \"443\",\n sourceAddresses: [\n \"0.0.0.0/0\",\n \"::/0\",\n ],\n },\n {\n protocol: \"icmp\",\n sourceAddresses: [\n \"0.0.0.0/0\",\n \"::/0\",\n ],\n },\n ],\n outboundRules: [\n {\n protocol: \"tcp\",\n portRange: \"53\",\n destinationAddresses: [\n \"0.0.0.0/0\",\n \"::/0\",\n ],\n },\n {\n protocol: \"udp\",\n portRange: \"53\",\n destinationAddresses: [\n \"0.0.0.0/0\",\n \"::/0\",\n ],\n },\n {\n protocol: \"icmp\",\n destinationAddresses: [\n \"0.0.0.0/0\",\n \"::/0\",\n ],\n },\n ],\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nweb = digitalocean.Droplet(\"web\",\n name=\"web-1\",\n size=digitalocean.DropletSlug.DROPLET_S1_VCPU1_GB,\n image=\"ubuntu-18-04-x64\",\n region=digitalocean.Region.NYC3)\nweb_firewall = digitalocean.Firewall(\"web\",\n name=\"only-22-80-and-443\",\n droplet_ids=[web.id],\n inbound_rules=[\n digitalocean.FirewallInboundRuleArgs(\n protocol=\"tcp\",\n port_range=\"22\",\n source_addresses=[\n \"192.168.1.0/24\",\n \"2002:1:2::/48\",\n ],\n ),\n digitalocean.FirewallInboundRuleArgs(\n protocol=\"tcp\",\n port_range=\"80\",\n source_addresses=[\n \"0.0.0.0/0\",\n \"::/0\",\n ],\n ),\n digitalocean.FirewallInboundRuleArgs(\n protocol=\"tcp\",\n port_range=\"443\",\n source_addresses=[\n \"0.0.0.0/0\",\n \"::/0\",\n ],\n ),\n digitalocean.FirewallInboundRuleArgs(\n protocol=\"icmp\",\n source_addresses=[\n \"0.0.0.0/0\",\n \"::/0\",\n ],\n ),\n ],\n outbound_rules=[\n digitalocean.FirewallOutboundRuleArgs(\n protocol=\"tcp\",\n port_range=\"53\",\n destination_addresses=[\n \"0.0.0.0/0\",\n \"::/0\",\n ],\n ),\n digitalocean.FirewallOutboundRuleArgs(\n protocol=\"udp\",\n port_range=\"53\",\n destination_addresses=[\n \"0.0.0.0/0\",\n \"::/0\",\n ],\n ),\n digitalocean.FirewallOutboundRuleArgs(\n protocol=\"icmp\",\n destination_addresses=[\n \"0.0.0.0/0\",\n \"::/0\",\n ],\n ),\n ])\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var web = new DigitalOcean.Droplet(\"web\", new()\n {\n Name = \"web-1\",\n Size = DigitalOcean.DropletSlug.DropletS1VCPU1GB,\n Image = \"ubuntu-18-04-x64\",\n Region = DigitalOcean.Region.NYC3,\n });\n\n var webFirewall = new DigitalOcean.Firewall(\"web\", new()\n {\n Name = \"only-22-80-and-443\",\n DropletIds = new[]\n {\n web.Id,\n },\n InboundRules = new[]\n {\n new DigitalOcean.Inputs.FirewallInboundRuleArgs\n {\n Protocol = \"tcp\",\n PortRange = \"22\",\n SourceAddresses = new[]\n {\n \"192.168.1.0/24\",\n \"2002:1:2::/48\",\n },\n },\n new DigitalOcean.Inputs.FirewallInboundRuleArgs\n {\n Protocol = \"tcp\",\n PortRange = \"80\",\n SourceAddresses = new[]\n {\n \"0.0.0.0/0\",\n \"::/0\",\n },\n },\n new DigitalOcean.Inputs.FirewallInboundRuleArgs\n {\n Protocol = \"tcp\",\n PortRange = \"443\",\n SourceAddresses = new[]\n {\n \"0.0.0.0/0\",\n \"::/0\",\n },\n },\n new DigitalOcean.Inputs.FirewallInboundRuleArgs\n {\n Protocol = \"icmp\",\n SourceAddresses = new[]\n {\n \"0.0.0.0/0\",\n \"::/0\",\n },\n },\n },\n OutboundRules = new[]\n {\n new DigitalOcean.Inputs.FirewallOutboundRuleArgs\n {\n Protocol = \"tcp\",\n PortRange = \"53\",\n DestinationAddresses = new[]\n {\n \"0.0.0.0/0\",\n \"::/0\",\n },\n },\n new DigitalOcean.Inputs.FirewallOutboundRuleArgs\n {\n Protocol = \"udp\",\n PortRange = \"53\",\n DestinationAddresses = new[]\n {\n \"0.0.0.0/0\",\n \"::/0\",\n },\n },\n new DigitalOcean.Inputs.FirewallOutboundRuleArgs\n {\n Protocol = \"icmp\",\n DestinationAddresses = new[]\n {\n \"0.0.0.0/0\",\n \"::/0\",\n },\n },\n },\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tweb, err := digitalocean.NewDroplet(ctx, \"web\", \u0026digitalocean.DropletArgs{\n\t\t\tName: pulumi.String(\"web-1\"),\n\t\t\tSize: pulumi.String(digitalocean.DropletSlugDropletS1VCPU1GB),\n\t\t\tImage: pulumi.String(\"ubuntu-18-04-x64\"),\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC3),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = digitalocean.NewFirewall(ctx, \"web\", \u0026digitalocean.FirewallArgs{\n\t\t\tName: pulumi.String(\"only-22-80-and-443\"),\n\t\t\tDropletIds: pulumi.IntArray{\n\t\t\t\tweb.ID(),\n\t\t\t},\n\t\t\tInboundRules: digitalocean.FirewallInboundRuleArray{\n\t\t\t\t\u0026digitalocean.FirewallInboundRuleArgs{\n\t\t\t\t\tProtocol: pulumi.String(\"tcp\"),\n\t\t\t\t\tPortRange: pulumi.String(\"22\"),\n\t\t\t\t\tSourceAddresses: pulumi.StringArray{\n\t\t\t\t\t\tpulumi.String(\"192.168.1.0/24\"),\n\t\t\t\t\t\tpulumi.String(\"2002:1:2::/48\"),\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t\t\u0026digitalocean.FirewallInboundRuleArgs{\n\t\t\t\t\tProtocol: pulumi.String(\"tcp\"),\n\t\t\t\t\tPortRange: pulumi.String(\"80\"),\n\t\t\t\t\tSourceAddresses: pulumi.StringArray{\n\t\t\t\t\t\tpulumi.String(\"0.0.0.0/0\"),\n\t\t\t\t\t\tpulumi.String(\"::/0\"),\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t\t\u0026digitalocean.FirewallInboundRuleArgs{\n\t\t\t\t\tProtocol: pulumi.String(\"tcp\"),\n\t\t\t\t\tPortRange: pulumi.String(\"443\"),\n\t\t\t\t\tSourceAddresses: pulumi.StringArray{\n\t\t\t\t\t\tpulumi.String(\"0.0.0.0/0\"),\n\t\t\t\t\t\tpulumi.String(\"::/0\"),\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t\t\u0026digitalocean.FirewallInboundRuleArgs{\n\t\t\t\t\tProtocol: pulumi.String(\"icmp\"),\n\t\t\t\t\tSourceAddresses: pulumi.StringArray{\n\t\t\t\t\t\tpulumi.String(\"0.0.0.0/0\"),\n\t\t\t\t\t\tpulumi.String(\"::/0\"),\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t},\n\t\t\tOutboundRules: digitalocean.FirewallOutboundRuleArray{\n\t\t\t\t\u0026digitalocean.FirewallOutboundRuleArgs{\n\t\t\t\t\tProtocol: pulumi.String(\"tcp\"),\n\t\t\t\t\tPortRange: pulumi.String(\"53\"),\n\t\t\t\t\tDestinationAddresses: pulumi.StringArray{\n\t\t\t\t\t\tpulumi.String(\"0.0.0.0/0\"),\n\t\t\t\t\t\tpulumi.String(\"::/0\"),\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t\t\u0026digitalocean.FirewallOutboundRuleArgs{\n\t\t\t\t\tProtocol: pulumi.String(\"udp\"),\n\t\t\t\t\tPortRange: pulumi.String(\"53\"),\n\t\t\t\t\tDestinationAddresses: pulumi.StringArray{\n\t\t\t\t\t\tpulumi.String(\"0.0.0.0/0\"),\n\t\t\t\t\t\tpulumi.String(\"::/0\"),\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t\t\u0026digitalocean.FirewallOutboundRuleArgs{\n\t\t\t\t\tProtocol: pulumi.String(\"icmp\"),\n\t\t\t\t\tDestinationAddresses: pulumi.StringArray{\n\t\t\t\t\t\tpulumi.String(\"0.0.0.0/0\"),\n\t\t\t\t\t\tpulumi.String(\"::/0\"),\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t},\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.digitalocean.Droplet;\nimport com.pulumi.digitalocean.DropletArgs;\nimport com.pulumi.digitalocean.Firewall;\nimport com.pulumi.digitalocean.FirewallArgs;\nimport com.pulumi.digitalocean.inputs.FirewallInboundRuleArgs;\nimport com.pulumi.digitalocean.inputs.FirewallOutboundRuleArgs;\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 web = new Droplet(\"web\", DropletArgs.builder() \n .name(\"web-1\")\n .size(\"s-1vcpu-1gb\")\n .image(\"ubuntu-18-04-x64\")\n .region(\"nyc3\")\n .build());\n\n var webFirewall = new Firewall(\"webFirewall\", FirewallArgs.builder() \n .name(\"only-22-80-and-443\")\n .dropletIds(web.id())\n .inboundRules( \n FirewallInboundRuleArgs.builder()\n .protocol(\"tcp\")\n .portRange(\"22\")\n .sourceAddresses( \n \"192.168.1.0/24\",\n \"2002:1:2::/48\")\n .build(),\n FirewallInboundRuleArgs.builder()\n .protocol(\"tcp\")\n .portRange(\"80\")\n .sourceAddresses( \n \"0.0.0.0/0\",\n \"::/0\")\n .build(),\n FirewallInboundRuleArgs.builder()\n .protocol(\"tcp\")\n .portRange(\"443\")\n .sourceAddresses( \n \"0.0.0.0/0\",\n \"::/0\")\n .build(),\n FirewallInboundRuleArgs.builder()\n .protocol(\"icmp\")\n .sourceAddresses( \n \"0.0.0.0/0\",\n \"::/0\")\n .build())\n .outboundRules( \n FirewallOutboundRuleArgs.builder()\n .protocol(\"tcp\")\n .portRange(\"53\")\n .destinationAddresses( \n \"0.0.0.0/0\",\n \"::/0\")\n .build(),\n FirewallOutboundRuleArgs.builder()\n .protocol(\"udp\")\n .portRange(\"53\")\n .destinationAddresses( \n \"0.0.0.0/0\",\n \"::/0\")\n .build(),\n FirewallOutboundRuleArgs.builder()\n .protocol(\"icmp\")\n .destinationAddresses( \n \"0.0.0.0/0\",\n \"::/0\")\n .build())\n .build());\n\n }\n}\n```\n```yaml\nresources:\n web:\n type: digitalocean:Droplet\n properties:\n name: web-1\n size: s-1vcpu-1gb\n image: ubuntu-18-04-x64\n region: nyc3\n webFirewall:\n type: digitalocean:Firewall\n name: web\n properties:\n name: only-22-80-and-443\n dropletIds:\n - ${web.id}\n inboundRules:\n - protocol: tcp\n portRange: '22'\n sourceAddresses:\n - 192.168.1.0/24\n - 2002:1:2::/48\n - protocol: tcp\n portRange: '80'\n sourceAddresses:\n - 0.0.0.0/0\n - ::/0\n - protocol: tcp\n portRange: '443'\n sourceAddresses:\n - 0.0.0.0/0\n - ::/0\n - protocol: icmp\n sourceAddresses:\n - 0.0.0.0/0\n - ::/0\n outboundRules:\n - protocol: tcp\n portRange: '53'\n destinationAddresses:\n - 0.0.0.0/0\n - ::/0\n - protocol: udp\n portRange: '53'\n destinationAddresses:\n - 0.0.0.0/0\n - ::/0\n - protocol: icmp\n destinationAddresses:\n - 0.0.0.0/0\n - ::/0\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n## Import\n\nFirewalls can be imported using the firewall `id`, e.g.\n\n```sh\n$ pulumi import digitalocean:index/firewall:Firewall myfirewall b8ecd2ab-2267-4a5e-8692-cbf1d32583e3\n```\n\n", "properties": { "createdAt": { "type": "string", @@ -11646,7 +11646,7 @@ } }, "digitalocean:index/floatingIp:FloatingIp": { - "description": "\u003e **Deprecated:** DigitalOcean Floating IPs have been renamed reserved IPs. This resource will be removed in a future release. Please use `digitalocean.ReservedIp` instead.\n\nProvides a DigitalOcean Floating IP to represent a publicly-accessible static IP addresses that can be mapped to one of your Droplets.\n\n\u003e **NOTE:** Floating IPs can be assigned to a Droplet either directly on the `digitalocean.FloatingIp` resource by setting a `droplet_id` or using the `digitalocean.FloatingIpAssignment` resource, but the two cannot be used together.\n\n## Example Usage\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst foobarDroplet = new digitalocean.Droplet(\"foobarDroplet\", {\n size: digitalocean.DropletSlug.DropletS1VCPU1GB,\n image: \"ubuntu-18-04-x64\",\n region: digitalocean.Region.SGP1,\n ipv6: true,\n privateNetworking: true,\n});\nconst foobarFloatingIp = new digitalocean.FloatingIp(\"foobarFloatingIp\", {\n dropletId: foobarDroplet.id,\n region: foobarDroplet.region,\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nfoobar_droplet = digitalocean.Droplet(\"foobarDroplet\",\n size=digitalocean.DropletSlug.DROPLET_S1_VCPU1_GB,\n image=\"ubuntu-18-04-x64\",\n region=digitalocean.Region.SGP1,\n ipv6=True,\n private_networking=True)\nfoobar_floating_ip = digitalocean.FloatingIp(\"foobarFloatingIp\",\n droplet_id=foobar_droplet.id,\n region=foobar_droplet.region)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var foobarDroplet = new DigitalOcean.Droplet(\"foobarDroplet\", new()\n {\n Size = DigitalOcean.DropletSlug.DropletS1VCPU1GB,\n Image = \"ubuntu-18-04-x64\",\n Region = DigitalOcean.Region.SGP1,\n Ipv6 = true,\n PrivateNetworking = true,\n });\n\n var foobarFloatingIp = new DigitalOcean.FloatingIp(\"foobarFloatingIp\", new()\n {\n DropletId = foobarDroplet.Id,\n Region = foobarDroplet.Region,\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tfoobarDroplet, err := digitalocean.NewDroplet(ctx, \"foobarDroplet\", \u0026digitalocean.DropletArgs{\n\t\t\tSize: pulumi.String(digitalocean.DropletSlugDropletS1VCPU1GB),\n\t\t\tImage: pulumi.String(\"ubuntu-18-04-x64\"),\n\t\t\tRegion: pulumi.String(digitalocean.RegionSGP1),\n\t\t\tIpv6: pulumi.Bool(true),\n\t\t\tPrivateNetworking: pulumi.Bool(true),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = digitalocean.NewFloatingIp(ctx, \"foobarFloatingIp\", \u0026digitalocean.FloatingIpArgs{\n\t\t\tDropletId: foobarDroplet.ID(),\n\t\t\tRegion: foobarDroplet.Region,\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.digitalocean.Droplet;\nimport com.pulumi.digitalocean.DropletArgs;\nimport com.pulumi.digitalocean.FloatingIp;\nimport com.pulumi.digitalocean.FloatingIpArgs;\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 foobarDroplet = new Droplet(\"foobarDroplet\", DropletArgs.builder() \n .size(\"s-1vcpu-1gb\")\n .image(\"ubuntu-18-04-x64\")\n .region(\"sgp1\")\n .ipv6(true)\n .privateNetworking(true)\n .build());\n\n var foobarFloatingIp = new FloatingIp(\"foobarFloatingIp\", FloatingIpArgs.builder() \n .dropletId(foobarDroplet.id())\n .region(foobarDroplet.region())\n .build());\n\n }\n}\n```\n```yaml\nresources:\n foobarDroplet:\n type: digitalocean:Droplet\n properties:\n size: s-1vcpu-1gb\n image: ubuntu-18-04-x64\n region: sgp1\n ipv6: true\n privateNetworking: true\n foobarFloatingIp:\n type: digitalocean:FloatingIp\n properties:\n dropletId: ${foobarDroplet.id}\n region: ${foobarDroplet.region}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n## Import\n\nFloating IPs can be imported using the `ip`, e.g.\n\n```sh\n$ pulumi import digitalocean:index/floatingIp:FloatingIp myip 192.168.0.1\n```\n\n", + "description": "\u003e **Deprecated:** DigitalOcean Floating IPs have been renamed reserved IPs. This resource will be removed in a future release. Please use `digitalocean.ReservedIp` instead.\n\nProvides a DigitalOcean Floating IP to represent a publicly-accessible static IP addresses that can be mapped to one of your Droplets.\n\n\u003e **NOTE:** Floating IPs can be assigned to a Droplet either directly on the `digitalocean.FloatingIp` resource by setting a `droplet_id` or using the `digitalocean.FloatingIpAssignment` resource, but the two cannot be used together.\n\n## Example Usage\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst foobar = new digitalocean.Droplet(\"foobar\", {\n name: \"baz\",\n size: digitalocean.DropletSlug.DropletS1VCPU1GB,\n image: \"ubuntu-18-04-x64\",\n region: digitalocean.Region.SGP1,\n ipv6: true,\n privateNetworking: true,\n});\nconst foobarFloatingIp = new digitalocean.FloatingIp(\"foobar\", {\n dropletId: foobar.id,\n region: foobar.region,\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nfoobar = digitalocean.Droplet(\"foobar\",\n name=\"baz\",\n size=digitalocean.DropletSlug.DROPLET_S1_VCPU1_GB,\n image=\"ubuntu-18-04-x64\",\n region=digitalocean.Region.SGP1,\n ipv6=True,\n private_networking=True)\nfoobar_floating_ip = digitalocean.FloatingIp(\"foobar\",\n droplet_id=foobar.id,\n region=foobar.region)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var foobar = new DigitalOcean.Droplet(\"foobar\", new()\n {\n Name = \"baz\",\n Size = DigitalOcean.DropletSlug.DropletS1VCPU1GB,\n Image = \"ubuntu-18-04-x64\",\n Region = DigitalOcean.Region.SGP1,\n Ipv6 = true,\n PrivateNetworking = true,\n });\n\n var foobarFloatingIp = new DigitalOcean.FloatingIp(\"foobar\", new()\n {\n DropletId = foobar.Id,\n Region = foobar.Region,\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tfoobar, err := digitalocean.NewDroplet(ctx, \"foobar\", \u0026digitalocean.DropletArgs{\n\t\t\tName: pulumi.String(\"baz\"),\n\t\t\tSize: pulumi.String(digitalocean.DropletSlugDropletS1VCPU1GB),\n\t\t\tImage: pulumi.String(\"ubuntu-18-04-x64\"),\n\t\t\tRegion: pulumi.String(digitalocean.RegionSGP1),\n\t\t\tIpv6: pulumi.Bool(true),\n\t\t\tPrivateNetworking: pulumi.Bool(true),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = digitalocean.NewFloatingIp(ctx, \"foobar\", \u0026digitalocean.FloatingIpArgs{\n\t\t\tDropletId: foobar.ID(),\n\t\t\tRegion: foobar.Region,\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.digitalocean.Droplet;\nimport com.pulumi.digitalocean.DropletArgs;\nimport com.pulumi.digitalocean.FloatingIp;\nimport com.pulumi.digitalocean.FloatingIpArgs;\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 foobar = new Droplet(\"foobar\", DropletArgs.builder() \n .name(\"baz\")\n .size(\"s-1vcpu-1gb\")\n .image(\"ubuntu-18-04-x64\")\n .region(\"sgp1\")\n .ipv6(true)\n .privateNetworking(true)\n .build());\n\n var foobarFloatingIp = new FloatingIp(\"foobarFloatingIp\", FloatingIpArgs.builder() \n .dropletId(foobar.id())\n .region(foobar.region())\n .build());\n\n }\n}\n```\n```yaml\nresources:\n foobar:\n type: digitalocean:Droplet\n properties:\n name: baz\n size: s-1vcpu-1gb\n image: ubuntu-18-04-x64\n region: sgp1\n ipv6: true\n privateNetworking: true\n foobarFloatingIp:\n type: digitalocean:FloatingIp\n name: foobar\n properties:\n dropletId: ${foobar.id}\n region: ${foobar.region}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n## Import\n\nFloating IPs can be imported using the `ip`, e.g.\n\n```sh\n$ pulumi import digitalocean:index/floatingIp:FloatingIp myip 192.168.0.1\n```\n\n", "properties": { "dropletId": { "type": "integer", @@ -11713,7 +11713,7 @@ } }, "digitalocean:index/floatingIpAssignment:FloatingIpAssignment": { - "description": "\u003e **Deprecated:** DigitalOcean Floating IPs have been renamed reserved IPs. This resource will be removed in a future release. Please use `digitalocean.ReservedIpAssignment` instead.\n\nProvides a resource for assigning an existing DigitalOcean Floating IP to a Droplet. This\nmakes it easy to provision floating IP addresses that are not tied to the lifecycle of your\nDroplet.\n\n## Example Usage\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst foobarFloatingIp = new digitalocean.FloatingIp(\"foobarFloatingIp\", {region: \"sgp1\"});\nconst foobarDroplet = new digitalocean.Droplet(\"foobarDroplet\", {\n size: digitalocean.DropletSlug.DropletS1VCPU1GB,\n image: \"ubuntu-18-04-x64\",\n region: digitalocean.Region.SGP1,\n ipv6: true,\n privateNetworking: true,\n});\nconst foobarFloatingIpAssignment = new digitalocean.FloatingIpAssignment(\"foobarFloatingIpAssignment\", {\n ipAddress: foobarFloatingIp.ipAddress,\n dropletId: foobarDroplet.id,\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nfoobar_floating_ip = digitalocean.FloatingIp(\"foobarFloatingIp\", region=\"sgp1\")\nfoobar_droplet = digitalocean.Droplet(\"foobarDroplet\",\n size=digitalocean.DropletSlug.DROPLET_S1_VCPU1_GB,\n image=\"ubuntu-18-04-x64\",\n region=digitalocean.Region.SGP1,\n ipv6=True,\n private_networking=True)\nfoobar_floating_ip_assignment = digitalocean.FloatingIpAssignment(\"foobarFloatingIpAssignment\",\n ip_address=foobar_floating_ip.ip_address,\n droplet_id=foobar_droplet.id)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var foobarFloatingIp = new DigitalOcean.FloatingIp(\"foobarFloatingIp\", new()\n {\n Region = \"sgp1\",\n });\n\n var foobarDroplet = new DigitalOcean.Droplet(\"foobarDroplet\", new()\n {\n Size = DigitalOcean.DropletSlug.DropletS1VCPU1GB,\n Image = \"ubuntu-18-04-x64\",\n Region = DigitalOcean.Region.SGP1,\n Ipv6 = true,\n PrivateNetworking = true,\n });\n\n var foobarFloatingIpAssignment = new DigitalOcean.FloatingIpAssignment(\"foobarFloatingIpAssignment\", new()\n {\n IpAddress = foobarFloatingIp.IpAddress,\n DropletId = foobarDroplet.Id,\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tfoobarFloatingIp, err := digitalocean.NewFloatingIp(ctx, \"foobarFloatingIp\", \u0026digitalocean.FloatingIpArgs{\n\t\t\tRegion: pulumi.String(\"sgp1\"),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tfoobarDroplet, err := digitalocean.NewDroplet(ctx, \"foobarDroplet\", \u0026digitalocean.DropletArgs{\n\t\t\tSize: pulumi.String(digitalocean.DropletSlugDropletS1VCPU1GB),\n\t\t\tImage: pulumi.String(\"ubuntu-18-04-x64\"),\n\t\t\tRegion: pulumi.String(digitalocean.RegionSGP1),\n\t\t\tIpv6: pulumi.Bool(true),\n\t\t\tPrivateNetworking: pulumi.Bool(true),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = digitalocean.NewFloatingIpAssignment(ctx, \"foobarFloatingIpAssignment\", \u0026digitalocean.FloatingIpAssignmentArgs{\n\t\t\tIpAddress: foobarFloatingIp.IpAddress,\n\t\t\tDropletId: foobarDroplet.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.digitalocean.FloatingIp;\nimport com.pulumi.digitalocean.FloatingIpArgs;\nimport com.pulumi.digitalocean.Droplet;\nimport com.pulumi.digitalocean.DropletArgs;\nimport com.pulumi.digitalocean.FloatingIpAssignment;\nimport com.pulumi.digitalocean.FloatingIpAssignmentArgs;\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 foobarFloatingIp = new FloatingIp(\"foobarFloatingIp\", FloatingIpArgs.builder() \n .region(\"sgp1\")\n .build());\n\n var foobarDroplet = new Droplet(\"foobarDroplet\", DropletArgs.builder() \n .size(\"s-1vcpu-1gb\")\n .image(\"ubuntu-18-04-x64\")\n .region(\"sgp1\")\n .ipv6(true)\n .privateNetworking(true)\n .build());\n\n var foobarFloatingIpAssignment = new FloatingIpAssignment(\"foobarFloatingIpAssignment\", FloatingIpAssignmentArgs.builder() \n .ipAddress(foobarFloatingIp.ipAddress())\n .dropletId(foobarDroplet.id())\n .build());\n\n }\n}\n```\n```yaml\nresources:\n foobarFloatingIp:\n type: digitalocean:FloatingIp\n properties:\n region: sgp1\n foobarDroplet:\n type: digitalocean:Droplet\n properties:\n size: s-1vcpu-1gb\n image: ubuntu-18-04-x64\n region: sgp1\n ipv6: true\n privateNetworking: true\n foobarFloatingIpAssignment:\n type: digitalocean:FloatingIpAssignment\n properties:\n ipAddress: ${foobarFloatingIp.ipAddress}\n dropletId: ${foobarDroplet.id}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n## Import\n\nFloating IP assignments can be imported using the Floating IP itself and the `id` of\n\nthe Droplet joined with a comma. For example:\n\n```sh\n$ pulumi import digitalocean:index/floatingIpAssignment:FloatingIpAssignment foobar 192.0.2.1,123456\n```\n\n", + "description": "\u003e **Deprecated:** DigitalOcean Floating IPs have been renamed reserved IPs. This resource will be removed in a future release. Please use `digitalocean.ReservedIpAssignment` instead.\n\nProvides a resource for assigning an existing DigitalOcean Floating IP to a Droplet. This\nmakes it easy to provision floating IP addresses that are not tied to the lifecycle of your\nDroplet.\n\n## Example Usage\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst foobar = new digitalocean.FloatingIp(\"foobar\", {region: \"sgp1\"});\nconst foobarDroplet = new digitalocean.Droplet(\"foobar\", {\n name: \"baz\",\n size: digitalocean.DropletSlug.DropletS1VCPU1GB,\n image: \"ubuntu-18-04-x64\",\n region: digitalocean.Region.SGP1,\n ipv6: true,\n privateNetworking: true,\n});\nconst foobarFloatingIpAssignment = new digitalocean.FloatingIpAssignment(\"foobar\", {\n ipAddress: foobar.ipAddress,\n dropletId: foobarDroplet.id,\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nfoobar = digitalocean.FloatingIp(\"foobar\", region=\"sgp1\")\nfoobar_droplet = digitalocean.Droplet(\"foobar\",\n name=\"baz\",\n size=digitalocean.DropletSlug.DROPLET_S1_VCPU1_GB,\n image=\"ubuntu-18-04-x64\",\n region=digitalocean.Region.SGP1,\n ipv6=True,\n private_networking=True)\nfoobar_floating_ip_assignment = digitalocean.FloatingIpAssignment(\"foobar\",\n ip_address=foobar.ip_address,\n droplet_id=foobar_droplet.id)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var foobar = new DigitalOcean.FloatingIp(\"foobar\", new()\n {\n Region = \"sgp1\",\n });\n\n var foobarDroplet = new DigitalOcean.Droplet(\"foobar\", new()\n {\n Name = \"baz\",\n Size = DigitalOcean.DropletSlug.DropletS1VCPU1GB,\n Image = \"ubuntu-18-04-x64\",\n Region = DigitalOcean.Region.SGP1,\n Ipv6 = true,\n PrivateNetworking = true,\n });\n\n var foobarFloatingIpAssignment = new DigitalOcean.FloatingIpAssignment(\"foobar\", new()\n {\n IpAddress = foobar.IpAddress,\n DropletId = foobarDroplet.Id,\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tfoobar, err := digitalocean.NewFloatingIp(ctx, \"foobar\", \u0026digitalocean.FloatingIpArgs{\n\t\t\tRegion: pulumi.String(\"sgp1\"),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tfoobarDroplet, err := digitalocean.NewDroplet(ctx, \"foobar\", \u0026digitalocean.DropletArgs{\n\t\t\tName: pulumi.String(\"baz\"),\n\t\t\tSize: pulumi.String(digitalocean.DropletSlugDropletS1VCPU1GB),\n\t\t\tImage: pulumi.String(\"ubuntu-18-04-x64\"),\n\t\t\tRegion: pulumi.String(digitalocean.RegionSGP1),\n\t\t\tIpv6: pulumi.Bool(true),\n\t\t\tPrivateNetworking: pulumi.Bool(true),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = digitalocean.NewFloatingIpAssignment(ctx, \"foobar\", \u0026digitalocean.FloatingIpAssignmentArgs{\n\t\t\tIpAddress: foobar.IpAddress,\n\t\t\tDropletId: foobarDroplet.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.digitalocean.FloatingIp;\nimport com.pulumi.digitalocean.FloatingIpArgs;\nimport com.pulumi.digitalocean.Droplet;\nimport com.pulumi.digitalocean.DropletArgs;\nimport com.pulumi.digitalocean.FloatingIpAssignment;\nimport com.pulumi.digitalocean.FloatingIpAssignmentArgs;\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 foobar = new FloatingIp(\"foobar\", FloatingIpArgs.builder() \n .region(\"sgp1\")\n .build());\n\n var foobarDroplet = new Droplet(\"foobarDroplet\", DropletArgs.builder() \n .name(\"baz\")\n .size(\"s-1vcpu-1gb\")\n .image(\"ubuntu-18-04-x64\")\n .region(\"sgp1\")\n .ipv6(true)\n .privateNetworking(true)\n .build());\n\n var foobarFloatingIpAssignment = new FloatingIpAssignment(\"foobarFloatingIpAssignment\", FloatingIpAssignmentArgs.builder() \n .ipAddress(foobar.ipAddress())\n .dropletId(foobarDroplet.id())\n .build());\n\n }\n}\n```\n```yaml\nresources:\n foobar:\n type: digitalocean:FloatingIp\n properties:\n region: sgp1\n foobarDroplet:\n type: digitalocean:Droplet\n name: foobar\n properties:\n name: baz\n size: s-1vcpu-1gb\n image: ubuntu-18-04-x64\n region: sgp1\n ipv6: true\n privateNetworking: true\n foobarFloatingIpAssignment:\n type: digitalocean:FloatingIpAssignment\n name: foobar\n properties:\n ipAddress: ${foobar.ipAddress}\n dropletId: ${foobarDroplet.id}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n## Import\n\nFloating IP assignments can be imported using the Floating IP itself and the `id` of\n\nthe Droplet joined with a comma. For example:\n\n```sh\n$ pulumi import digitalocean:index/floatingIpAssignment:FloatingIpAssignment foobar 192.0.2.1,123456\n```\n\n", "properties": { "dropletId": { "type": "integer", @@ -12052,7 +12052,7 @@ } }, "digitalocean:index/kubernetesNodePool:KubernetesNodePool": { - "description": "Provides a DigitalOcean Kubernetes node pool resource. While the default node pool must be defined in the `digitalocean.KubernetesCluster` resource, this resource can be used to add additional ones to a cluster.\n\n## Example Usage\n\n### Basic Example\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst foo = new digitalocean.KubernetesCluster(\"foo\", {\n region: digitalocean.Region.NYC1,\n version: \"1.22.8-do.1\",\n nodePool: {\n name: \"front-end-pool\",\n size: \"s-2vcpu-2gb\",\n nodeCount: 3,\n },\n});\nconst bar = new digitalocean.KubernetesNodePool(\"bar\", {\n clusterId: foo.id,\n size: digitalocean.DropletSlug.DropletC2,\n nodeCount: 2,\n tags: [\"backend\"],\n labels: {\n service: \"backend\",\n priority: \"high\",\n },\n taints: [{\n key: \"workloadKind\",\n value: \"database\",\n effect: \"NoSchedule\",\n }],\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nfoo = digitalocean.KubernetesCluster(\"foo\",\n region=digitalocean.Region.NYC1,\n version=\"1.22.8-do.1\",\n node_pool=digitalocean.KubernetesClusterNodePoolArgs(\n name=\"front-end-pool\",\n size=\"s-2vcpu-2gb\",\n node_count=3,\n ))\nbar = digitalocean.KubernetesNodePool(\"bar\",\n cluster_id=foo.id,\n size=digitalocean.DropletSlug.DROPLET_C2,\n node_count=2,\n tags=[\"backend\"],\n labels={\n \"service\": \"backend\",\n \"priority\": \"high\",\n },\n taints=[digitalocean.KubernetesNodePoolTaintArgs(\n key=\"workloadKind\",\n value=\"database\",\n effect=\"NoSchedule\",\n )])\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var foo = new DigitalOcean.KubernetesCluster(\"foo\", new()\n {\n Region = DigitalOcean.Region.NYC1,\n Version = \"1.22.8-do.1\",\n NodePool = new DigitalOcean.Inputs.KubernetesClusterNodePoolArgs\n {\n Name = \"front-end-pool\",\n Size = \"s-2vcpu-2gb\",\n NodeCount = 3,\n },\n });\n\n var bar = new DigitalOcean.KubernetesNodePool(\"bar\", new()\n {\n ClusterId = foo.Id,\n Size = DigitalOcean.DropletSlug.DropletC2,\n NodeCount = 2,\n Tags = new[]\n {\n \"backend\",\n },\n Labels = \n {\n { \"service\", \"backend\" },\n { \"priority\", \"high\" },\n },\n Taints = new[]\n {\n new DigitalOcean.Inputs.KubernetesNodePoolTaintArgs\n {\n Key = \"workloadKind\",\n Value = \"database\",\n Effect = \"NoSchedule\",\n },\n },\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tfoo, err := digitalocean.NewKubernetesCluster(ctx, \"foo\", \u0026digitalocean.KubernetesClusterArgs{\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC1),\n\t\t\tVersion: pulumi.String(\"1.22.8-do.1\"),\n\t\t\tNodePool: \u0026digitalocean.KubernetesClusterNodePoolArgs{\n\t\t\t\tName: pulumi.String(\"front-end-pool\"),\n\t\t\t\tSize: pulumi.String(\"s-2vcpu-2gb\"),\n\t\t\t\tNodeCount: pulumi.Int(3),\n\t\t\t},\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = digitalocean.NewKubernetesNodePool(ctx, \"bar\", \u0026digitalocean.KubernetesNodePoolArgs{\n\t\t\tClusterId: foo.ID(),\n\t\t\tSize: pulumi.String(digitalocean.DropletSlugDropletC2),\n\t\t\tNodeCount: pulumi.Int(2),\n\t\t\tTags: pulumi.StringArray{\n\t\t\t\tpulumi.String(\"backend\"),\n\t\t\t},\n\t\t\tLabels: pulumi.StringMap{\n\t\t\t\t\"service\": pulumi.String(\"backend\"),\n\t\t\t\t\"priority\": pulumi.String(\"high\"),\n\t\t\t},\n\t\t\tTaints: digitalocean.KubernetesNodePoolTaintArray{\n\t\t\t\t\u0026digitalocean.KubernetesNodePoolTaintArgs{\n\t\t\t\t\tKey: pulumi.String(\"workloadKind\"),\n\t\t\t\t\tValue: pulumi.String(\"database\"),\n\t\t\t\t\tEffect: pulumi.String(\"NoSchedule\"),\n\t\t\t\t},\n\t\t\t},\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.digitalocean.KubernetesCluster;\nimport com.pulumi.digitalocean.KubernetesClusterArgs;\nimport com.pulumi.digitalocean.inputs.KubernetesClusterNodePoolArgs;\nimport com.pulumi.digitalocean.KubernetesNodePool;\nimport com.pulumi.digitalocean.KubernetesNodePoolArgs;\nimport com.pulumi.digitalocean.inputs.KubernetesNodePoolTaintArgs;\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 foo = new KubernetesCluster(\"foo\", KubernetesClusterArgs.builder() \n .region(\"nyc1\")\n .version(\"1.22.8-do.1\")\n .nodePool(KubernetesClusterNodePoolArgs.builder()\n .name(\"front-end-pool\")\n .size(\"s-2vcpu-2gb\")\n .nodeCount(3)\n .build())\n .build());\n\n var bar = new KubernetesNodePool(\"bar\", KubernetesNodePoolArgs.builder() \n .clusterId(foo.id())\n .size(\"c-2\")\n .nodeCount(2)\n .tags(\"backend\")\n .labels(Map.ofEntries(\n Map.entry(\"service\", \"backend\"),\n Map.entry(\"priority\", \"high\")\n ))\n .taints(KubernetesNodePoolTaintArgs.builder()\n .key(\"workloadKind\")\n .value(\"database\")\n .effect(\"NoSchedule\")\n .build())\n .build());\n\n }\n}\n```\n```yaml\nresources:\n foo:\n type: digitalocean:KubernetesCluster\n properties:\n region: nyc1\n version: 1.22.8-do.1\n nodePool:\n name: front-end-pool\n size: s-2vcpu-2gb\n nodeCount: 3\n bar:\n type: digitalocean:KubernetesNodePool\n properties:\n clusterId: ${foo.id}\n size: c-2\n nodeCount: 2\n tags:\n - backend\n labels:\n service: backend\n priority: high\n taints:\n - key: workloadKind\n value: database\n effect: NoSchedule\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n### Autoscaling Example\n\nNode pools may also be configured to [autoscale](https://www.digitalocean.com/docs/kubernetes/how-to/autoscale/).\nFor example:\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst autoscale_pool_01 = new digitalocean.KubernetesNodePool(\"autoscale-pool-01\", {\n clusterId: digitalocean_kubernetes_cluster.foo.id,\n size: digitalocean.DropletSlug.DropletS1VCPU2GB,\n autoScale: true,\n minNodes: 1,\n maxNodes: 5,\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nautoscale_pool_01 = digitalocean.KubernetesNodePool(\"autoscale-pool-01\",\n cluster_id=digitalocean_kubernetes_cluster[\"foo\"][\"id\"],\n size=digitalocean.DropletSlug.DROPLET_S1_VCPU2_GB,\n auto_scale=True,\n min_nodes=1,\n max_nodes=5)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var autoscale_pool_01 = new DigitalOcean.KubernetesNodePool(\"autoscale-pool-01\", new()\n {\n ClusterId = digitalocean_kubernetes_cluster.Foo.Id,\n Size = DigitalOcean.DropletSlug.DropletS1VCPU2GB,\n AutoScale = true,\n MinNodes = 1,\n MaxNodes = 5,\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := digitalocean.NewKubernetesNodePool(ctx, \"autoscale-pool-01\", \u0026digitalocean.KubernetesNodePoolArgs{\n\t\t\tClusterId: pulumi.Any(digitalocean_kubernetes_cluster.Foo.Id),\n\t\t\tSize: pulumi.String(digitalocean.DropletSlugDropletS1VCPU2GB),\n\t\t\tAutoScale: pulumi.Bool(true),\n\t\t\tMinNodes: pulumi.Int(1),\n\t\t\tMaxNodes: pulumi.Int(5),\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.digitalocean.KubernetesNodePool;\nimport com.pulumi.digitalocean.KubernetesNodePoolArgs;\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 autoscale_pool_01 = new KubernetesNodePool(\"autoscale-pool-01\", KubernetesNodePoolArgs.builder() \n .clusterId(digitalocean_kubernetes_cluster.foo().id())\n .size(\"s-1vcpu-2gb\")\n .autoScale(true)\n .minNodes(1)\n .maxNodes(5)\n .build());\n\n }\n}\n```\n```yaml\nresources:\n autoscale-pool-01:\n type: digitalocean:KubernetesNodePool\n properties:\n clusterId: ${digitalocean_kubernetes_cluster.foo.id}\n size: s-1vcpu-2gb\n autoScale: true\n minNodes: 1\n maxNodes: 5\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n## Import\n\nIf you are importing an existing Kubernetes cluster with a single node pool, just\n\nimport the cluster. Additional node pools can be imported by using their `id`, e.g.\n\n```sh\n$ pulumi import digitalocean:index/kubernetesNodePool:KubernetesNodePool mynodepool 9d76f410-9284-4436-9633-4066852442c8\n```\n\nNote: If the node pool has the `terraform:default-node-pool` tag, then it is a default node pool for an\n\nexisting cluster. The provider will refuse to import the node pool in that case because the node pool\n\nis managed by the `digitalocean_kubernetes_cluster` resource and not by this\n\n`digitalocean_kubernetes_node_pool` resource.\n\n", + "description": "Provides a DigitalOcean Kubernetes node pool resource. While the default node pool must be defined in the `digitalocean.KubernetesCluster` resource, this resource can be used to add additional ones to a cluster.\n\n## Example Usage\n\n### Basic Example\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst foo = new digitalocean.KubernetesCluster(\"foo\", {\n name: \"foo\",\n region: digitalocean.Region.NYC1,\n version: \"1.22.8-do.1\",\n nodePool: {\n name: \"front-end-pool\",\n size: \"s-2vcpu-2gb\",\n nodeCount: 3,\n },\n});\nconst bar = new digitalocean.KubernetesNodePool(\"bar\", {\n clusterId: foo.id,\n name: \"backend-pool\",\n size: digitalocean.DropletSlug.DropletC2,\n nodeCount: 2,\n tags: [\"backend\"],\n labels: {\n service: \"backend\",\n priority: \"high\",\n },\n taints: [{\n key: \"workloadKind\",\n value: \"database\",\n effect: \"NoSchedule\",\n }],\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nfoo = digitalocean.KubernetesCluster(\"foo\",\n name=\"foo\",\n region=digitalocean.Region.NYC1,\n version=\"1.22.8-do.1\",\n node_pool=digitalocean.KubernetesClusterNodePoolArgs(\n name=\"front-end-pool\",\n size=\"s-2vcpu-2gb\",\n node_count=3,\n ))\nbar = digitalocean.KubernetesNodePool(\"bar\",\n cluster_id=foo.id,\n name=\"backend-pool\",\n size=digitalocean.DropletSlug.DROPLET_C2,\n node_count=2,\n tags=[\"backend\"],\n labels={\n \"service\": \"backend\",\n \"priority\": \"high\",\n },\n taints=[digitalocean.KubernetesNodePoolTaintArgs(\n key=\"workloadKind\",\n value=\"database\",\n effect=\"NoSchedule\",\n )])\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var foo = new DigitalOcean.KubernetesCluster(\"foo\", new()\n {\n Name = \"foo\",\n Region = DigitalOcean.Region.NYC1,\n Version = \"1.22.8-do.1\",\n NodePool = new DigitalOcean.Inputs.KubernetesClusterNodePoolArgs\n {\n Name = \"front-end-pool\",\n Size = \"s-2vcpu-2gb\",\n NodeCount = 3,\n },\n });\n\n var bar = new DigitalOcean.KubernetesNodePool(\"bar\", new()\n {\n ClusterId = foo.Id,\n Name = \"backend-pool\",\n Size = DigitalOcean.DropletSlug.DropletC2,\n NodeCount = 2,\n Tags = new[]\n {\n \"backend\",\n },\n Labels = \n {\n { \"service\", \"backend\" },\n { \"priority\", \"high\" },\n },\n Taints = new[]\n {\n new DigitalOcean.Inputs.KubernetesNodePoolTaintArgs\n {\n Key = \"workloadKind\",\n Value = \"database\",\n Effect = \"NoSchedule\",\n },\n },\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tfoo, err := digitalocean.NewKubernetesCluster(ctx, \"foo\", \u0026digitalocean.KubernetesClusterArgs{\n\t\t\tName: pulumi.String(\"foo\"),\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC1),\n\t\t\tVersion: pulumi.String(\"1.22.8-do.1\"),\n\t\t\tNodePool: \u0026digitalocean.KubernetesClusterNodePoolArgs{\n\t\t\t\tName: pulumi.String(\"front-end-pool\"),\n\t\t\t\tSize: pulumi.String(\"s-2vcpu-2gb\"),\n\t\t\t\tNodeCount: pulumi.Int(3),\n\t\t\t},\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = digitalocean.NewKubernetesNodePool(ctx, \"bar\", \u0026digitalocean.KubernetesNodePoolArgs{\n\t\t\tClusterId: foo.ID(),\n\t\t\tName: pulumi.String(\"backend-pool\"),\n\t\t\tSize: pulumi.String(digitalocean.DropletSlugDropletC2),\n\t\t\tNodeCount: pulumi.Int(2),\n\t\t\tTags: pulumi.StringArray{\n\t\t\t\tpulumi.String(\"backend\"),\n\t\t\t},\n\t\t\tLabels: pulumi.StringMap{\n\t\t\t\t\"service\": pulumi.String(\"backend\"),\n\t\t\t\t\"priority\": pulumi.String(\"high\"),\n\t\t\t},\n\t\t\tTaints: digitalocean.KubernetesNodePoolTaintArray{\n\t\t\t\t\u0026digitalocean.KubernetesNodePoolTaintArgs{\n\t\t\t\t\tKey: pulumi.String(\"workloadKind\"),\n\t\t\t\t\tValue: pulumi.String(\"database\"),\n\t\t\t\t\tEffect: pulumi.String(\"NoSchedule\"),\n\t\t\t\t},\n\t\t\t},\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.digitalocean.KubernetesCluster;\nimport com.pulumi.digitalocean.KubernetesClusterArgs;\nimport com.pulumi.digitalocean.inputs.KubernetesClusterNodePoolArgs;\nimport com.pulumi.digitalocean.KubernetesNodePool;\nimport com.pulumi.digitalocean.KubernetesNodePoolArgs;\nimport com.pulumi.digitalocean.inputs.KubernetesNodePoolTaintArgs;\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 foo = new KubernetesCluster(\"foo\", KubernetesClusterArgs.builder() \n .name(\"foo\")\n .region(\"nyc1\")\n .version(\"1.22.8-do.1\")\n .nodePool(KubernetesClusterNodePoolArgs.builder()\n .name(\"front-end-pool\")\n .size(\"s-2vcpu-2gb\")\n .nodeCount(3)\n .build())\n .build());\n\n var bar = new KubernetesNodePool(\"bar\", KubernetesNodePoolArgs.builder() \n .clusterId(foo.id())\n .name(\"backend-pool\")\n .size(\"c-2\")\n .nodeCount(2)\n .tags(\"backend\")\n .labels(Map.ofEntries(\n Map.entry(\"service\", \"backend\"),\n Map.entry(\"priority\", \"high\")\n ))\n .taints(KubernetesNodePoolTaintArgs.builder()\n .key(\"workloadKind\")\n .value(\"database\")\n .effect(\"NoSchedule\")\n .build())\n .build());\n\n }\n}\n```\n```yaml\nresources:\n foo:\n type: digitalocean:KubernetesCluster\n properties:\n name: foo\n region: nyc1\n version: 1.22.8-do.1\n nodePool:\n name: front-end-pool\n size: s-2vcpu-2gb\n nodeCount: 3\n bar:\n type: digitalocean:KubernetesNodePool\n properties:\n clusterId: ${foo.id}\n name: backend-pool\n size: c-2\n nodeCount: 2\n tags:\n - backend\n labels:\n service: backend\n priority: high\n taints:\n - key: workloadKind\n value: database\n effect: NoSchedule\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n### Autoscaling Example\n\nNode pools may also be configured to [autoscale](https://www.digitalocean.com/docs/kubernetes/how-to/autoscale/).\nFor example:\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst autoscale_pool_01 = new digitalocean.KubernetesNodePool(\"autoscale-pool-01\", {\n clusterId: foo.id,\n name: \"autoscale-pool-01\",\n size: digitalocean.DropletSlug.DropletS1VCPU2GB,\n autoScale: true,\n minNodes: 1,\n maxNodes: 5,\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nautoscale_pool_01 = digitalocean.KubernetesNodePool(\"autoscale-pool-01\",\n cluster_id=foo[\"id\"],\n name=\"autoscale-pool-01\",\n size=digitalocean.DropletSlug.DROPLET_S1_VCPU2_GB,\n auto_scale=True,\n min_nodes=1,\n max_nodes=5)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var autoscale_pool_01 = new DigitalOcean.KubernetesNodePool(\"autoscale-pool-01\", new()\n {\n ClusterId = foo.Id,\n Name = \"autoscale-pool-01\",\n Size = DigitalOcean.DropletSlug.DropletS1VCPU2GB,\n AutoScale = true,\n MinNodes = 1,\n MaxNodes = 5,\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := digitalocean.NewKubernetesNodePool(ctx, \"autoscale-pool-01\", \u0026digitalocean.KubernetesNodePoolArgs{\n\t\t\tClusterId: pulumi.Any(foo.Id),\n\t\t\tName: pulumi.String(\"autoscale-pool-01\"),\n\t\t\tSize: pulumi.String(digitalocean.DropletSlugDropletS1VCPU2GB),\n\t\t\tAutoScale: pulumi.Bool(true),\n\t\t\tMinNodes: pulumi.Int(1),\n\t\t\tMaxNodes: pulumi.Int(5),\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.digitalocean.KubernetesNodePool;\nimport com.pulumi.digitalocean.KubernetesNodePoolArgs;\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 autoscale_pool_01 = new KubernetesNodePool(\"autoscale-pool-01\", KubernetesNodePoolArgs.builder() \n .clusterId(foo.id())\n .name(\"autoscale-pool-01\")\n .size(\"s-1vcpu-2gb\")\n .autoScale(true)\n .minNodes(1)\n .maxNodes(5)\n .build());\n\n }\n}\n```\n```yaml\nresources:\n autoscale-pool-01:\n type: digitalocean:KubernetesNodePool\n properties:\n clusterId: ${foo.id}\n name: autoscale-pool-01\n size: s-1vcpu-2gb\n autoScale: true\n minNodes: 1\n maxNodes: 5\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n## Import\n\nIf you are importing an existing Kubernetes cluster with a single node pool, just\n\nimport the cluster. Additional node pools can be imported by using their `id`, e.g.\n\n```sh\n$ pulumi import digitalocean:index/kubernetesNodePool:KubernetesNodePool mynodepool 9d76f410-9284-4436-9633-4066852442c8\n```\n\nNote: If the node pool has the `terraform:default-node-pool` tag, then it is a default node pool for an\n\nexisting cluster. The provider will refuse to import the node pool in that case because the node pool\n\nis managed by the `digitalocean_kubernetes_cluster` resource and not by this\n\n`digitalocean_kubernetes_node_pool` resource.\n\n", "properties": { "actualNodeCount": { "type": "integer", @@ -12267,7 +12267,7 @@ } }, "digitalocean:index/loadBalancer:LoadBalancer": { - "description": "Provides a DigitalOcean Load Balancer resource. This can be used to create,\nmodify, and delete Load Balancers.\n\n## Example Usage\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst web = new digitalocean.Droplet(\"web\", {\n size: digitalocean.DropletSlug.DropletS1VCPU1GB,\n image: \"ubuntu-18-04-x64\",\n region: digitalocean.Region.NYC3,\n});\nconst _public = new digitalocean.LoadBalancer(\"public\", {\n region: digitalocean.Region.NYC3,\n forwardingRules: [{\n entryPort: 80,\n entryProtocol: \"http\",\n targetPort: 80,\n targetProtocol: \"http\",\n }],\n healthcheck: {\n port: 22,\n protocol: \"tcp\",\n },\n dropletIds: [web.id],\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nweb = digitalocean.Droplet(\"web\",\n size=digitalocean.DropletSlug.DROPLET_S1_VCPU1_GB,\n image=\"ubuntu-18-04-x64\",\n region=digitalocean.Region.NYC3)\npublic = digitalocean.LoadBalancer(\"public\",\n region=digitalocean.Region.NYC3,\n forwarding_rules=[digitalocean.LoadBalancerForwardingRuleArgs(\n entry_port=80,\n entry_protocol=\"http\",\n target_port=80,\n target_protocol=\"http\",\n )],\n healthcheck=digitalocean.LoadBalancerHealthcheckArgs(\n port=22,\n protocol=\"tcp\",\n ),\n droplet_ids=[web.id])\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var web = new DigitalOcean.Droplet(\"web\", new()\n {\n Size = DigitalOcean.DropletSlug.DropletS1VCPU1GB,\n Image = \"ubuntu-18-04-x64\",\n Region = DigitalOcean.Region.NYC3,\n });\n\n var @public = new DigitalOcean.LoadBalancer(\"public\", new()\n {\n Region = DigitalOcean.Region.NYC3,\n ForwardingRules = new[]\n {\n new DigitalOcean.Inputs.LoadBalancerForwardingRuleArgs\n {\n EntryPort = 80,\n EntryProtocol = \"http\",\n TargetPort = 80,\n TargetProtocol = \"http\",\n },\n },\n Healthcheck = new DigitalOcean.Inputs.LoadBalancerHealthcheckArgs\n {\n Port = 22,\n Protocol = \"tcp\",\n },\n DropletIds = new[]\n {\n web.Id,\n },\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tweb, err := digitalocean.NewDroplet(ctx, \"web\", \u0026digitalocean.DropletArgs{\n\t\t\tSize: pulumi.String(digitalocean.DropletSlugDropletS1VCPU1GB),\n\t\t\tImage: pulumi.String(\"ubuntu-18-04-x64\"),\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC3),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = digitalocean.NewLoadBalancer(ctx, \"public\", \u0026digitalocean.LoadBalancerArgs{\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC3),\n\t\t\tForwardingRules: digitalocean.LoadBalancerForwardingRuleArray{\n\t\t\t\t\u0026digitalocean.LoadBalancerForwardingRuleArgs{\n\t\t\t\t\tEntryPort: pulumi.Int(80),\n\t\t\t\t\tEntryProtocol: pulumi.String(\"http\"),\n\t\t\t\t\tTargetPort: pulumi.Int(80),\n\t\t\t\t\tTargetProtocol: pulumi.String(\"http\"),\n\t\t\t\t},\n\t\t\t},\n\t\t\tHealthcheck: \u0026digitalocean.LoadBalancerHealthcheckArgs{\n\t\t\t\tPort: pulumi.Int(22),\n\t\t\t\tProtocol: pulumi.String(\"tcp\"),\n\t\t\t},\n\t\t\tDropletIds: pulumi.IntArray{\n\t\t\t\tweb.ID(),\n\t\t\t},\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.digitalocean.Droplet;\nimport com.pulumi.digitalocean.DropletArgs;\nimport com.pulumi.digitalocean.LoadBalancer;\nimport com.pulumi.digitalocean.LoadBalancerArgs;\nimport com.pulumi.digitalocean.inputs.LoadBalancerForwardingRuleArgs;\nimport com.pulumi.digitalocean.inputs.LoadBalancerHealthcheckArgs;\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 web = new Droplet(\"web\", DropletArgs.builder() \n .size(\"s-1vcpu-1gb\")\n .image(\"ubuntu-18-04-x64\")\n .region(\"nyc3\")\n .build());\n\n var public_ = new LoadBalancer(\"public\", LoadBalancerArgs.builder() \n .region(\"nyc3\")\n .forwardingRules(LoadBalancerForwardingRuleArgs.builder()\n .entryPort(80)\n .entryProtocol(\"http\")\n .targetPort(80)\n .targetProtocol(\"http\")\n .build())\n .healthcheck(LoadBalancerHealthcheckArgs.builder()\n .port(22)\n .protocol(\"tcp\")\n .build())\n .dropletIds(web.id())\n .build());\n\n }\n}\n```\n```yaml\nresources:\n web:\n type: digitalocean:Droplet\n properties:\n size: s-1vcpu-1gb\n image: ubuntu-18-04-x64\n region: nyc3\n public:\n type: digitalocean:LoadBalancer\n properties:\n region: nyc3\n forwardingRules:\n - entryPort: 80\n entryProtocol: http\n targetPort: 80\n targetProtocol: http\n healthcheck:\n port: 22\n protocol: tcp\n dropletIds:\n - ${web.id}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\nWhen managing certificates attached to the load balancer, make sure to add the `create_before_destroy`\nlifecycle property in order to ensure the certificate is correctly updated when changed. The order of\noperations will then be: `Create new certificate` \u003e `Update loadbalancer with new certificate` -\u003e\n`Delete old certificate`. When doing so, you must also change the name of the certificate,\nas there cannot be multiple certificates with the same name in an account.\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst cert = new digitalocean.Certificate(\"cert\", {\n privateKey: \"file('key.pem')\",\n leafCertificate: \"file('cert.pem')\",\n});\nconst web = new digitalocean.Droplet(\"web\", {\n size: digitalocean.DropletSlug.DropletS1VCPU1GB,\n image: \"ubuntu-18-04-x64\",\n region: digitalocean.Region.NYC3,\n});\nconst _public = new digitalocean.LoadBalancer(\"public\", {\n region: digitalocean.Region.NYC3,\n forwardingRules: [{\n entryPort: 443,\n entryProtocol: \"https\",\n targetPort: 80,\n targetProtocol: \"http\",\n certificateName: cert.name,\n }],\n healthcheck: {\n port: 22,\n protocol: \"tcp\",\n },\n dropletIds: [web.id],\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\ncert = digitalocean.Certificate(\"cert\",\n private_key=\"file('key.pem')\",\n leaf_certificate=\"file('cert.pem')\")\nweb = digitalocean.Droplet(\"web\",\n size=digitalocean.DropletSlug.DROPLET_S1_VCPU1_GB,\n image=\"ubuntu-18-04-x64\",\n region=digitalocean.Region.NYC3)\npublic = digitalocean.LoadBalancer(\"public\",\n region=digitalocean.Region.NYC3,\n forwarding_rules=[digitalocean.LoadBalancerForwardingRuleArgs(\n entry_port=443,\n entry_protocol=\"https\",\n target_port=80,\n target_protocol=\"http\",\n certificate_name=cert.name,\n )],\n healthcheck=digitalocean.LoadBalancerHealthcheckArgs(\n port=22,\n protocol=\"tcp\",\n ),\n droplet_ids=[web.id])\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var cert = new DigitalOcean.Certificate(\"cert\", new()\n {\n PrivateKey = \"file('key.pem')\",\n LeafCertificate = \"file('cert.pem')\",\n });\n\n var web = new DigitalOcean.Droplet(\"web\", new()\n {\n Size = DigitalOcean.DropletSlug.DropletS1VCPU1GB,\n Image = \"ubuntu-18-04-x64\",\n Region = DigitalOcean.Region.NYC3,\n });\n\n var @public = new DigitalOcean.LoadBalancer(\"public\", new()\n {\n Region = DigitalOcean.Region.NYC3,\n ForwardingRules = new[]\n {\n new DigitalOcean.Inputs.LoadBalancerForwardingRuleArgs\n {\n EntryPort = 443,\n EntryProtocol = \"https\",\n TargetPort = 80,\n TargetProtocol = \"http\",\n CertificateName = cert.Name,\n },\n },\n Healthcheck = new DigitalOcean.Inputs.LoadBalancerHealthcheckArgs\n {\n Port = 22,\n Protocol = \"tcp\",\n },\n DropletIds = new[]\n {\n web.Id,\n },\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tcert, err := digitalocean.NewCertificate(ctx, \"cert\", \u0026digitalocean.CertificateArgs{\n\t\t\tPrivateKey: pulumi.String(\"file('key.pem')\"),\n\t\t\tLeafCertificate: pulumi.String(\"file('cert.pem')\"),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tweb, err := digitalocean.NewDroplet(ctx, \"web\", \u0026digitalocean.DropletArgs{\n\t\t\tSize: pulumi.String(digitalocean.DropletSlugDropletS1VCPU1GB),\n\t\t\tImage: pulumi.String(\"ubuntu-18-04-x64\"),\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC3),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = digitalocean.NewLoadBalancer(ctx, \"public\", \u0026digitalocean.LoadBalancerArgs{\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC3),\n\t\t\tForwardingRules: digitalocean.LoadBalancerForwardingRuleArray{\n\t\t\t\t\u0026digitalocean.LoadBalancerForwardingRuleArgs{\n\t\t\t\t\tEntryPort: pulumi.Int(443),\n\t\t\t\t\tEntryProtocol: pulumi.String(\"https\"),\n\t\t\t\t\tTargetPort: pulumi.Int(80),\n\t\t\t\t\tTargetProtocol: pulumi.String(\"http\"),\n\t\t\t\t\tCertificateName: cert.Name,\n\t\t\t\t},\n\t\t\t},\n\t\t\tHealthcheck: \u0026digitalocean.LoadBalancerHealthcheckArgs{\n\t\t\t\tPort: pulumi.Int(22),\n\t\t\t\tProtocol: pulumi.String(\"tcp\"),\n\t\t\t},\n\t\t\tDropletIds: pulumi.IntArray{\n\t\t\t\tweb.ID(),\n\t\t\t},\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.digitalocean.Certificate;\nimport com.pulumi.digitalocean.CertificateArgs;\nimport com.pulumi.digitalocean.Droplet;\nimport com.pulumi.digitalocean.DropletArgs;\nimport com.pulumi.digitalocean.LoadBalancer;\nimport com.pulumi.digitalocean.LoadBalancerArgs;\nimport com.pulumi.digitalocean.inputs.LoadBalancerForwardingRuleArgs;\nimport com.pulumi.digitalocean.inputs.LoadBalancerHealthcheckArgs;\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 cert = new Certificate(\"cert\", CertificateArgs.builder() \n .privateKey(\"file('key.pem')\")\n .leafCertificate(\"file('cert.pem')\")\n .build());\n\n var web = new Droplet(\"web\", DropletArgs.builder() \n .size(\"s-1vcpu-1gb\")\n .image(\"ubuntu-18-04-x64\")\n .region(\"nyc3\")\n .build());\n\n var public_ = new LoadBalancer(\"public\", LoadBalancerArgs.builder() \n .region(\"nyc3\")\n .forwardingRules(LoadBalancerForwardingRuleArgs.builder()\n .entryPort(443)\n .entryProtocol(\"https\")\n .targetPort(80)\n .targetProtocol(\"http\")\n .certificateName(cert.name())\n .build())\n .healthcheck(LoadBalancerHealthcheckArgs.builder()\n .port(22)\n .protocol(\"tcp\")\n .build())\n .dropletIds(web.id())\n .build());\n\n }\n}\n```\n```yaml\nresources:\n cert:\n type: digitalocean:Certificate\n properties:\n privateKey: file('key.pem')\n leafCertificate: file('cert.pem')\n web:\n type: digitalocean:Droplet\n properties:\n size: s-1vcpu-1gb\n image: ubuntu-18-04-x64\n region: nyc3\n public:\n type: digitalocean:LoadBalancer\n properties:\n region: nyc3\n forwardingRules:\n - entryPort: 443\n entryProtocol: https\n targetPort: 80\n targetProtocol: http\n certificateName: ${cert.name}\n healthcheck:\n port: 22\n protocol: tcp\n dropletIds:\n - ${web.id}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n## Import\n\nLoad Balancers can be imported using the `id`, e.g.\n\n```sh\n$ pulumi import digitalocean:index/loadBalancer:LoadBalancer myloadbalancer 4de7ac8b-495b-4884-9a69-1050c6793cd6\n```\n\n", + "description": "Provides a DigitalOcean Load Balancer resource. This can be used to create,\nmodify, and delete Load Balancers.\n\n## Example Usage\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst web = new digitalocean.Droplet(\"web\", {\n name: \"web-1\",\n size: digitalocean.DropletSlug.DropletS1VCPU1GB,\n image: \"ubuntu-18-04-x64\",\n region: digitalocean.Region.NYC3,\n});\nconst _public = new digitalocean.LoadBalancer(\"public\", {\n name: \"loadbalancer-1\",\n region: digitalocean.Region.NYC3,\n forwardingRules: [{\n entryPort: 80,\n entryProtocol: \"http\",\n targetPort: 80,\n targetProtocol: \"http\",\n }],\n healthcheck: {\n port: 22,\n protocol: \"tcp\",\n },\n dropletIds: [web.id],\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nweb = digitalocean.Droplet(\"web\",\n name=\"web-1\",\n size=digitalocean.DropletSlug.DROPLET_S1_VCPU1_GB,\n image=\"ubuntu-18-04-x64\",\n region=digitalocean.Region.NYC3)\npublic = digitalocean.LoadBalancer(\"public\",\n name=\"loadbalancer-1\",\n region=digitalocean.Region.NYC3,\n forwarding_rules=[digitalocean.LoadBalancerForwardingRuleArgs(\n entry_port=80,\n entry_protocol=\"http\",\n target_port=80,\n target_protocol=\"http\",\n )],\n healthcheck=digitalocean.LoadBalancerHealthcheckArgs(\n port=22,\n protocol=\"tcp\",\n ),\n droplet_ids=[web.id])\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var web = new DigitalOcean.Droplet(\"web\", new()\n {\n Name = \"web-1\",\n Size = DigitalOcean.DropletSlug.DropletS1VCPU1GB,\n Image = \"ubuntu-18-04-x64\",\n Region = DigitalOcean.Region.NYC3,\n });\n\n var @public = new DigitalOcean.LoadBalancer(\"public\", new()\n {\n Name = \"loadbalancer-1\",\n Region = DigitalOcean.Region.NYC3,\n ForwardingRules = new[]\n {\n new DigitalOcean.Inputs.LoadBalancerForwardingRuleArgs\n {\n EntryPort = 80,\n EntryProtocol = \"http\",\n TargetPort = 80,\n TargetProtocol = \"http\",\n },\n },\n Healthcheck = new DigitalOcean.Inputs.LoadBalancerHealthcheckArgs\n {\n Port = 22,\n Protocol = \"tcp\",\n },\n DropletIds = new[]\n {\n web.Id,\n },\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tweb, err := digitalocean.NewDroplet(ctx, \"web\", \u0026digitalocean.DropletArgs{\n\t\t\tName: pulumi.String(\"web-1\"),\n\t\t\tSize: pulumi.String(digitalocean.DropletSlugDropletS1VCPU1GB),\n\t\t\tImage: pulumi.String(\"ubuntu-18-04-x64\"),\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC3),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = digitalocean.NewLoadBalancer(ctx, \"public\", \u0026digitalocean.LoadBalancerArgs{\n\t\t\tName: pulumi.String(\"loadbalancer-1\"),\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC3),\n\t\t\tForwardingRules: digitalocean.LoadBalancerForwardingRuleArray{\n\t\t\t\t\u0026digitalocean.LoadBalancerForwardingRuleArgs{\n\t\t\t\t\tEntryPort: pulumi.Int(80),\n\t\t\t\t\tEntryProtocol: pulumi.String(\"http\"),\n\t\t\t\t\tTargetPort: pulumi.Int(80),\n\t\t\t\t\tTargetProtocol: pulumi.String(\"http\"),\n\t\t\t\t},\n\t\t\t},\n\t\t\tHealthcheck: \u0026digitalocean.LoadBalancerHealthcheckArgs{\n\t\t\t\tPort: pulumi.Int(22),\n\t\t\t\tProtocol: pulumi.String(\"tcp\"),\n\t\t\t},\n\t\t\tDropletIds: pulumi.IntArray{\n\t\t\t\tweb.ID(),\n\t\t\t},\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.digitalocean.Droplet;\nimport com.pulumi.digitalocean.DropletArgs;\nimport com.pulumi.digitalocean.LoadBalancer;\nimport com.pulumi.digitalocean.LoadBalancerArgs;\nimport com.pulumi.digitalocean.inputs.LoadBalancerForwardingRuleArgs;\nimport com.pulumi.digitalocean.inputs.LoadBalancerHealthcheckArgs;\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 web = new Droplet(\"web\", DropletArgs.builder() \n .name(\"web-1\")\n .size(\"s-1vcpu-1gb\")\n .image(\"ubuntu-18-04-x64\")\n .region(\"nyc3\")\n .build());\n\n var public_ = new LoadBalancer(\"public\", LoadBalancerArgs.builder() \n .name(\"loadbalancer-1\")\n .region(\"nyc3\")\n .forwardingRules(LoadBalancerForwardingRuleArgs.builder()\n .entryPort(80)\n .entryProtocol(\"http\")\n .targetPort(80)\n .targetProtocol(\"http\")\n .build())\n .healthcheck(LoadBalancerHealthcheckArgs.builder()\n .port(22)\n .protocol(\"tcp\")\n .build())\n .dropletIds(web.id())\n .build());\n\n }\n}\n```\n```yaml\nresources:\n web:\n type: digitalocean:Droplet\n properties:\n name: web-1\n size: s-1vcpu-1gb\n image: ubuntu-18-04-x64\n region: nyc3\n public:\n type: digitalocean:LoadBalancer\n properties:\n name: loadbalancer-1\n region: nyc3\n forwardingRules:\n - entryPort: 80\n entryProtocol: http\n targetPort: 80\n targetProtocol: http\n healthcheck:\n port: 22\n protocol: tcp\n dropletIds:\n - ${web.id}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\nWhen managing certificates attached to the load balancer, make sure to add the `create_before_destroy`\nlifecycle property in order to ensure the certificate is correctly updated when changed. The order of\noperations will then be: `Create new certificate` \u003e `Update loadbalancer with new certificate` -\u003e\n`Delete old certificate`. When doing so, you must also change the name of the certificate,\nas there cannot be multiple certificates with the same name in an account.\n\n## Import\n\nLoad Balancers can be imported using the `id`, e.g.\n\n```sh\n$ pulumi import digitalocean:index/loadBalancer:LoadBalancer myloadbalancer 4de7ac8b-495b-4884-9a69-1050c6793cd6\n```\n\n", "properties": { "algorithm": { "type": "string", @@ -12828,7 +12828,7 @@ } }, "digitalocean:index/project:Project": { - "description": "Provides a DigitalOcean Project resource.\n\nProjects allow you to organize your resources into groups that fit the way you work.\nYou can group resources (like Droplets, Spaces, Load Balancers, domains, and Floating IPs)\nin ways that align with the applications you host on DigitalOcean.\n\nThe following resource types can be associated with a project:\n\n* App Platform Apps\n* Database Clusters\n* Domains\n* Droplets\n* Floating IPs\n* Kubernetes Clusters\n* Load Balancers\n* Spaces Buckets\n* Volumes\n\n**Note:** A provider managed project cannot be set as a default project.\n\n## Example Usage\n\nThe following example demonstrates the creation of an empty project:\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst playground = new digitalocean.Project(\"playground\", {\n description: \"A project to represent development resources.\",\n environment: \"Development\",\n purpose: \"Web Application\",\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nplayground = digitalocean.Project(\"playground\",\n description=\"A project to represent development resources.\",\n environment=\"Development\",\n purpose=\"Web Application\")\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var playground = new DigitalOcean.Project(\"playground\", new()\n {\n Description = \"A project to represent development resources.\",\n Environment = \"Development\",\n Purpose = \"Web Application\",\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := digitalocean.NewProject(ctx, \"playground\", \u0026digitalocean.ProjectArgs{\n\t\t\tDescription: pulumi.String(\"A project to represent development resources.\"),\n\t\t\tEnvironment: pulumi.String(\"Development\"),\n\t\t\tPurpose: pulumi.String(\"Web Application\"),\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.digitalocean.Project;\nimport com.pulumi.digitalocean.ProjectArgs;\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 playground = new Project(\"playground\", ProjectArgs.builder() \n .description(\"A project to represent development resources.\")\n .environment(\"Development\")\n .purpose(\"Web Application\")\n .build());\n\n }\n}\n```\n```yaml\nresources:\n playground:\n type: digitalocean:Project\n properties:\n description: A project to represent development resources.\n environment: Development\n purpose: Web Application\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\nThe following example demonstrates the creation of a project with a Droplet resource:\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst foobar = new digitalocean.Droplet(\"foobar\", {\n size: digitalocean.DropletSlug.DropletS1VCPU1GB,\n image: \"ubuntu-22-04-x64\",\n region: digitalocean.Region.NYC3,\n});\nconst playground = new digitalocean.Project(\"playground\", {\n description: \"A project to represent development resources.\",\n purpose: \"Web Application\",\n environment: \"Development\",\n resources: [foobar.dropletUrn],\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nfoobar = digitalocean.Droplet(\"foobar\",\n size=digitalocean.DropletSlug.DROPLET_S1_VCPU1_GB,\n image=\"ubuntu-22-04-x64\",\n region=digitalocean.Region.NYC3)\nplayground = digitalocean.Project(\"playground\",\n description=\"A project to represent development resources.\",\n purpose=\"Web Application\",\n environment=\"Development\",\n resources=[foobar.droplet_urn])\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var foobar = new DigitalOcean.Droplet(\"foobar\", new()\n {\n Size = DigitalOcean.DropletSlug.DropletS1VCPU1GB,\n Image = \"ubuntu-22-04-x64\",\n Region = DigitalOcean.Region.NYC3,\n });\n\n var playground = new DigitalOcean.Project(\"playground\", new()\n {\n Description = \"A project to represent development resources.\",\n Purpose = \"Web Application\",\n Environment = \"Development\",\n Resources = new[]\n {\n foobar.DropletUrn,\n },\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tfoobar, err := digitalocean.NewDroplet(ctx, \"foobar\", \u0026digitalocean.DropletArgs{\n\t\t\tSize: pulumi.String(digitalocean.DropletSlugDropletS1VCPU1GB),\n\t\t\tImage: pulumi.String(\"ubuntu-22-04-x64\"),\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC3),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = digitalocean.NewProject(ctx, \"playground\", \u0026digitalocean.ProjectArgs{\n\t\t\tDescription: pulumi.String(\"A project to represent development resources.\"),\n\t\t\tPurpose: pulumi.String(\"Web Application\"),\n\t\t\tEnvironment: pulumi.String(\"Development\"),\n\t\t\tResources: pulumi.StringArray{\n\t\t\t\tfoobar.DropletUrn,\n\t\t\t},\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.digitalocean.Droplet;\nimport com.pulumi.digitalocean.DropletArgs;\nimport com.pulumi.digitalocean.Project;\nimport com.pulumi.digitalocean.ProjectArgs;\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 foobar = new Droplet(\"foobar\", DropletArgs.builder() \n .size(\"s-1vcpu-1gb\")\n .image(\"ubuntu-22-04-x64\")\n .region(\"nyc3\")\n .build());\n\n var playground = new Project(\"playground\", ProjectArgs.builder() \n .description(\"A project to represent development resources.\")\n .purpose(\"Web Application\")\n .environment(\"Development\")\n .resources(foobar.dropletUrn())\n .build());\n\n }\n}\n```\n```yaml\nresources:\n foobar:\n type: digitalocean:Droplet\n properties:\n size: s-1vcpu-1gb\n image: ubuntu-22-04-x64\n region: nyc3\n playground:\n type: digitalocean:Project\n properties:\n description: A project to represent development resources.\n purpose: Web Application\n environment: Development\n resources:\n - ${foobar.dropletUrn}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n## Import\n\nProjects can be imported using the `id` returned from DigitalOcean, e.g.\n\n```sh\n$ pulumi import digitalocean:index/project:Project myproject 245bcfd0-7f31-4ce6-a2bc-475a116cca97\n```\n\n", + "description": "Provides a DigitalOcean Project resource.\n\nProjects allow you to organize your resources into groups that fit the way you work.\nYou can group resources (like Droplets, Spaces, Load Balancers, domains, and Floating IPs)\nin ways that align with the applications you host on DigitalOcean.\n\nThe following resource types can be associated with a project:\n\n* App Platform Apps\n* Database Clusters\n* Domains\n* Droplets\n* Floating IPs\n* Kubernetes Clusters\n* Load Balancers\n* Spaces Buckets\n* Volumes\n\n**Note:** A provider managed project cannot be set as a default project.\n\n## Example Usage\n\nThe following example demonstrates the creation of an empty project:\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst playground = new digitalocean.Project(\"playground\", {\n name: \"playground\",\n description: \"A project to represent development resources.\",\n purpose: \"Web Application\",\n environment: \"Development\",\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nplayground = digitalocean.Project(\"playground\",\n name=\"playground\",\n description=\"A project to represent development resources.\",\n purpose=\"Web Application\",\n environment=\"Development\")\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var playground = new DigitalOcean.Project(\"playground\", new()\n {\n Name = \"playground\",\n Description = \"A project to represent development resources.\",\n Purpose = \"Web Application\",\n Environment = \"Development\",\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := digitalocean.NewProject(ctx, \"playground\", \u0026digitalocean.ProjectArgs{\n\t\t\tName: pulumi.String(\"playground\"),\n\t\t\tDescription: pulumi.String(\"A project to represent development resources.\"),\n\t\t\tPurpose: pulumi.String(\"Web Application\"),\n\t\t\tEnvironment: pulumi.String(\"Development\"),\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.digitalocean.Project;\nimport com.pulumi.digitalocean.ProjectArgs;\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 playground = new Project(\"playground\", ProjectArgs.builder() \n .name(\"playground\")\n .description(\"A project to represent development resources.\")\n .purpose(\"Web Application\")\n .environment(\"Development\")\n .build());\n\n }\n}\n```\n```yaml\nresources:\n playground:\n type: digitalocean:Project\n properties:\n name: playground\n description: A project to represent development resources.\n purpose: Web Application\n environment: Development\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\nThe following example demonstrates the creation of a project with a Droplet resource:\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst foobar = new digitalocean.Droplet(\"foobar\", {\n name: \"example\",\n size: digitalocean.DropletSlug.DropletS1VCPU1GB,\n image: \"ubuntu-22-04-x64\",\n region: digitalocean.Region.NYC3,\n});\nconst playground = new digitalocean.Project(\"playground\", {\n name: \"playground\",\n description: \"A project to represent development resources.\",\n purpose: \"Web Application\",\n environment: \"Development\",\n resources: [foobar.dropletUrn],\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nfoobar = digitalocean.Droplet(\"foobar\",\n name=\"example\",\n size=digitalocean.DropletSlug.DROPLET_S1_VCPU1_GB,\n image=\"ubuntu-22-04-x64\",\n region=digitalocean.Region.NYC3)\nplayground = digitalocean.Project(\"playground\",\n name=\"playground\",\n description=\"A project to represent development resources.\",\n purpose=\"Web Application\",\n environment=\"Development\",\n resources=[foobar.droplet_urn])\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var foobar = new DigitalOcean.Droplet(\"foobar\", new()\n {\n Name = \"example\",\n Size = DigitalOcean.DropletSlug.DropletS1VCPU1GB,\n Image = \"ubuntu-22-04-x64\",\n Region = DigitalOcean.Region.NYC3,\n });\n\n var playground = new DigitalOcean.Project(\"playground\", new()\n {\n Name = \"playground\",\n Description = \"A project to represent development resources.\",\n Purpose = \"Web Application\",\n Environment = \"Development\",\n Resources = new[]\n {\n foobar.DropletUrn,\n },\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tfoobar, err := digitalocean.NewDroplet(ctx, \"foobar\", \u0026digitalocean.DropletArgs{\n\t\t\tName: pulumi.String(\"example\"),\n\t\t\tSize: pulumi.String(digitalocean.DropletSlugDropletS1VCPU1GB),\n\t\t\tImage: pulumi.String(\"ubuntu-22-04-x64\"),\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC3),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = digitalocean.NewProject(ctx, \"playground\", \u0026digitalocean.ProjectArgs{\n\t\t\tName: pulumi.String(\"playground\"),\n\t\t\tDescription: pulumi.String(\"A project to represent development resources.\"),\n\t\t\tPurpose: pulumi.String(\"Web Application\"),\n\t\t\tEnvironment: pulumi.String(\"Development\"),\n\t\t\tResources: pulumi.StringArray{\n\t\t\t\tfoobar.DropletUrn,\n\t\t\t},\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.digitalocean.Droplet;\nimport com.pulumi.digitalocean.DropletArgs;\nimport com.pulumi.digitalocean.Project;\nimport com.pulumi.digitalocean.ProjectArgs;\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 foobar = new Droplet(\"foobar\", DropletArgs.builder() \n .name(\"example\")\n .size(\"s-1vcpu-1gb\")\n .image(\"ubuntu-22-04-x64\")\n .region(\"nyc3\")\n .build());\n\n var playground = new Project(\"playground\", ProjectArgs.builder() \n .name(\"playground\")\n .description(\"A project to represent development resources.\")\n .purpose(\"Web Application\")\n .environment(\"Development\")\n .resources(foobar.dropletUrn())\n .build());\n\n }\n}\n```\n```yaml\nresources:\n foobar:\n type: digitalocean:Droplet\n properties:\n name: example\n size: s-1vcpu-1gb\n image: ubuntu-22-04-x64\n region: nyc3\n playground:\n type: digitalocean:Project\n properties:\n name: playground\n description: A project to represent development resources.\n purpose: Web Application\n environment: Development\n resources:\n - ${foobar.dropletUrn}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n## Import\n\nProjects can be imported using the `id` returned from DigitalOcean, e.g.\n\n```sh\n$ pulumi import digitalocean:index/project:Project myproject 245bcfd0-7f31-4ce6-a2bc-475a116cca97\n```\n\n", "properties": { "createdAt": { "type": "string", @@ -12962,7 +12962,7 @@ } }, "digitalocean:index/projectResources:ProjectResources": { - "description": "Assign resources to a DigitalOcean Project. This is useful if you need to assign resources\nmanaged via this provider to a DigitalOcean Project managed outside of the provider.\n\nThe following resource types can be associated with a project:\n\n* App Platform Apps\n* Database Clusters\n* Domains\n* Droplets\n* Floating IPs\n* Kubernetes Clusters\n* Load Balancers\n* Spaces Buckets\n* Volumes\n\n## Example Usage\n\nThe following example assigns a droplet to a Project managed outside of the provider:\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst playground = digitalocean.getProject({\n name: \"playground\",\n});\nconst foobar = new digitalocean.Droplet(\"foobar\", {\n size: digitalocean.DropletSlug.DropletS1VCPU1GB,\n image: \"ubuntu-22-04-x64\",\n region: digitalocean.Region.NYC3,\n});\nconst barfoo = new digitalocean.ProjectResources(\"barfoo\", {\n project: playground.then(playground =\u003e playground.id),\n resources: [foobar.dropletUrn],\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nplayground = digitalocean.get_project(name=\"playground\")\nfoobar = digitalocean.Droplet(\"foobar\",\n size=digitalocean.DropletSlug.DROPLET_S1_VCPU1_GB,\n image=\"ubuntu-22-04-x64\",\n region=digitalocean.Region.NYC3)\nbarfoo = digitalocean.ProjectResources(\"barfoo\",\n project=playground.id,\n resources=[foobar.droplet_urn])\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var playground = DigitalOcean.GetProject.Invoke(new()\n {\n Name = \"playground\",\n });\n\n var foobar = new DigitalOcean.Droplet(\"foobar\", new()\n {\n Size = DigitalOcean.DropletSlug.DropletS1VCPU1GB,\n Image = \"ubuntu-22-04-x64\",\n Region = DigitalOcean.Region.NYC3,\n });\n\n var barfoo = new DigitalOcean.ProjectResources(\"barfoo\", new()\n {\n Project = playground.Apply(getProjectResult =\u003e getProjectResult.Id),\n Resources = new[]\n {\n foobar.DropletUrn,\n },\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tplayground, err := digitalocean.LookupProject(ctx, \u0026digitalocean.LookupProjectArgs{\n\t\t\tName: pulumi.StringRef(\"playground\"),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tfoobar, err := digitalocean.NewDroplet(ctx, \"foobar\", \u0026digitalocean.DropletArgs{\n\t\t\tSize: pulumi.String(digitalocean.DropletSlugDropletS1VCPU1GB),\n\t\t\tImage: pulumi.String(\"ubuntu-22-04-x64\"),\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC3),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = digitalocean.NewProjectResources(ctx, \"barfoo\", \u0026digitalocean.ProjectResourcesArgs{\n\t\t\tProject: pulumi.String(playground.Id),\n\t\t\tResources: pulumi.StringArray{\n\t\t\t\tfoobar.DropletUrn,\n\t\t\t},\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.digitalocean.DigitaloceanFunctions;\nimport com.pulumi.digitalocean.inputs.GetProjectArgs;\nimport com.pulumi.digitalocean.Droplet;\nimport com.pulumi.digitalocean.DropletArgs;\nimport com.pulumi.digitalocean.ProjectResources;\nimport com.pulumi.digitalocean.ProjectResourcesArgs;\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 final var playground = DigitaloceanFunctions.getProject(GetProjectArgs.builder()\n .name(\"playground\")\n .build());\n\n var foobar = new Droplet(\"foobar\", DropletArgs.builder() \n .size(\"s-1vcpu-1gb\")\n .image(\"ubuntu-22-04-x64\")\n .region(\"nyc3\")\n .build());\n\n var barfoo = new ProjectResources(\"barfoo\", ProjectResourcesArgs.builder() \n .project(playground.applyValue(getProjectResult -\u003e getProjectResult.id()))\n .resources(foobar.dropletUrn())\n .build());\n\n }\n}\n```\n```yaml\nresources:\n foobar:\n type: digitalocean:Droplet\n properties:\n size: s-1vcpu-1gb\n image: ubuntu-22-04-x64\n region: nyc3\n barfoo:\n type: digitalocean:ProjectResources\n properties:\n project: ${playground.id}\n resources:\n - ${foobar.dropletUrn}\nvariables:\n playground:\n fn::invoke:\n Function: digitalocean:getProject\n Arguments:\n name: playground\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n## Import\n\nImporting this resource is not supported.\n\n", + "description": "Assign resources to a DigitalOcean Project. This is useful if you need to assign resources\nmanaged via this provider to a DigitalOcean Project managed outside of the provider.\n\nThe following resource types can be associated with a project:\n\n* App Platform Apps\n* Database Clusters\n* Domains\n* Droplets\n* Floating IPs\n* Kubernetes Clusters\n* Load Balancers\n* Spaces Buckets\n* Volumes\n\n## Example Usage\n\nThe following example assigns a droplet to a Project managed outside of the provider:\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst playground = digitalocean.getProject({\n name: \"playground\",\n});\nconst foobar = new digitalocean.Droplet(\"foobar\", {\n name: \"example\",\n size: digitalocean.DropletSlug.DropletS1VCPU1GB,\n image: \"ubuntu-22-04-x64\",\n region: digitalocean.Region.NYC3,\n});\nconst barfoo = new digitalocean.ProjectResources(\"barfoo\", {\n project: playground.then(playground =\u003e playground.id),\n resources: [foobar.dropletUrn],\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nplayground = digitalocean.get_project(name=\"playground\")\nfoobar = digitalocean.Droplet(\"foobar\",\n name=\"example\",\n size=digitalocean.DropletSlug.DROPLET_S1_VCPU1_GB,\n image=\"ubuntu-22-04-x64\",\n region=digitalocean.Region.NYC3)\nbarfoo = digitalocean.ProjectResources(\"barfoo\",\n project=playground.id,\n resources=[foobar.droplet_urn])\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var playground = DigitalOcean.GetProject.Invoke(new()\n {\n Name = \"playground\",\n });\n\n var foobar = new DigitalOcean.Droplet(\"foobar\", new()\n {\n Name = \"example\",\n Size = DigitalOcean.DropletSlug.DropletS1VCPU1GB,\n Image = \"ubuntu-22-04-x64\",\n Region = DigitalOcean.Region.NYC3,\n });\n\n var barfoo = new DigitalOcean.ProjectResources(\"barfoo\", new()\n {\n Project = playground.Apply(getProjectResult =\u003e getProjectResult.Id),\n Resources = new[]\n {\n foobar.DropletUrn,\n },\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tplayground, err := digitalocean.LookupProject(ctx, \u0026digitalocean.LookupProjectArgs{\n\t\t\tName: pulumi.StringRef(\"playground\"),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tfoobar, err := digitalocean.NewDroplet(ctx, \"foobar\", \u0026digitalocean.DropletArgs{\n\t\t\tName: pulumi.String(\"example\"),\n\t\t\tSize: pulumi.String(digitalocean.DropletSlugDropletS1VCPU1GB),\n\t\t\tImage: pulumi.String(\"ubuntu-22-04-x64\"),\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC3),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = digitalocean.NewProjectResources(ctx, \"barfoo\", \u0026digitalocean.ProjectResourcesArgs{\n\t\t\tProject: pulumi.String(playground.Id),\n\t\t\tResources: pulumi.StringArray{\n\t\t\t\tfoobar.DropletUrn,\n\t\t\t},\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.digitalocean.DigitaloceanFunctions;\nimport com.pulumi.digitalocean.inputs.GetProjectArgs;\nimport com.pulumi.digitalocean.Droplet;\nimport com.pulumi.digitalocean.DropletArgs;\nimport com.pulumi.digitalocean.ProjectResources;\nimport com.pulumi.digitalocean.ProjectResourcesArgs;\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 final var playground = DigitaloceanFunctions.getProject(GetProjectArgs.builder()\n .name(\"playground\")\n .build());\n\n var foobar = new Droplet(\"foobar\", DropletArgs.builder() \n .name(\"example\")\n .size(\"s-1vcpu-1gb\")\n .image(\"ubuntu-22-04-x64\")\n .region(\"nyc3\")\n .build());\n\n var barfoo = new ProjectResources(\"barfoo\", ProjectResourcesArgs.builder() \n .project(playground.applyValue(getProjectResult -\u003e getProjectResult.id()))\n .resources(foobar.dropletUrn())\n .build());\n\n }\n}\n```\n```yaml\nresources:\n foobar:\n type: digitalocean:Droplet\n properties:\n name: example\n size: s-1vcpu-1gb\n image: ubuntu-22-04-x64\n region: nyc3\n barfoo:\n type: digitalocean:ProjectResources\n properties:\n project: ${playground.id}\n resources:\n - ${foobar.dropletUrn}\nvariables:\n playground:\n fn::invoke:\n Function: digitalocean:getProject\n Arguments:\n name: playground\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n## Import\n\nImporting this resource is not supported.\n\n", "properties": { "project": { "type": "string", @@ -13018,7 +13018,7 @@ } }, "digitalocean:index/reservedIp:ReservedIp": { - "description": "Provides a DigitalOcean reserved IP to represent a publicly-accessible static IP addresses that can be mapped to one of your Droplets.\n\n\u003e **NOTE:** Reserved IPs can be assigned to a Droplet either directly on the `digitalocean.ReservedIp` resource by setting a `droplet_id` or using the `digitalocean.ReservedIpAssignment` resource, but the two cannot be used together.\n\n## Example Usage\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst exampleDroplet = new digitalocean.Droplet(\"exampleDroplet\", {\n size: digitalocean.DropletSlug.DropletS1VCPU1GB,\n image: \"ubuntu-22-04-x64\",\n region: digitalocean.Region.NYC3,\n ipv6: true,\n privateNetworking: true,\n});\nconst exampleReservedIp = new digitalocean.ReservedIp(\"exampleReservedIp\", {\n dropletId: exampleDroplet.id,\n region: exampleDroplet.region,\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nexample_droplet = digitalocean.Droplet(\"exampleDroplet\",\n size=digitalocean.DropletSlug.DROPLET_S1_VCPU1_GB,\n image=\"ubuntu-22-04-x64\",\n region=digitalocean.Region.NYC3,\n ipv6=True,\n private_networking=True)\nexample_reserved_ip = digitalocean.ReservedIp(\"exampleReservedIp\",\n droplet_id=example_droplet.id,\n region=example_droplet.region)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var exampleDroplet = new DigitalOcean.Droplet(\"exampleDroplet\", new()\n {\n Size = DigitalOcean.DropletSlug.DropletS1VCPU1GB,\n Image = \"ubuntu-22-04-x64\",\n Region = DigitalOcean.Region.NYC3,\n Ipv6 = true,\n PrivateNetworking = true,\n });\n\n var exampleReservedIp = new DigitalOcean.ReservedIp(\"exampleReservedIp\", new()\n {\n DropletId = exampleDroplet.Id,\n Region = exampleDroplet.Region,\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\texampleDroplet, err := digitalocean.NewDroplet(ctx, \"exampleDroplet\", \u0026digitalocean.DropletArgs{\n\t\t\tSize: pulumi.String(digitalocean.DropletSlugDropletS1VCPU1GB),\n\t\t\tImage: pulumi.String(\"ubuntu-22-04-x64\"),\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC3),\n\t\t\tIpv6: pulumi.Bool(true),\n\t\t\tPrivateNetworking: pulumi.Bool(true),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = digitalocean.NewReservedIp(ctx, \"exampleReservedIp\", \u0026digitalocean.ReservedIpArgs{\n\t\t\tDropletId: exampleDroplet.ID(),\n\t\t\tRegion: exampleDroplet.Region,\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.digitalocean.Droplet;\nimport com.pulumi.digitalocean.DropletArgs;\nimport com.pulumi.digitalocean.ReservedIp;\nimport com.pulumi.digitalocean.ReservedIpArgs;\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 exampleDroplet = new Droplet(\"exampleDroplet\", DropletArgs.builder() \n .size(\"s-1vcpu-1gb\")\n .image(\"ubuntu-22-04-x64\")\n .region(\"nyc3\")\n .ipv6(true)\n .privateNetworking(true)\n .build());\n\n var exampleReservedIp = new ReservedIp(\"exampleReservedIp\", ReservedIpArgs.builder() \n .dropletId(exampleDroplet.id())\n .region(exampleDroplet.region())\n .build());\n\n }\n}\n```\n```yaml\nresources:\n exampleDroplet:\n type: digitalocean:Droplet\n properties:\n size: s-1vcpu-1gb\n image: ubuntu-22-04-x64\n region: nyc3\n ipv6: true\n privateNetworking: true\n exampleReservedIp:\n type: digitalocean:ReservedIp\n properties:\n dropletId: ${exampleDroplet.id}\n region: ${exampleDroplet.region}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n## Import\n\nReserved IPs can be imported using the `ip`, e.g.\n\n```sh\n$ pulumi import digitalocean:index/reservedIp:ReservedIp myip 192.168.0.1\n```\n\n", + "description": "Provides a DigitalOcean reserved IP to represent a publicly-accessible static IP addresses that can be mapped to one of your Droplets.\n\n\u003e **NOTE:** Reserved IPs can be assigned to a Droplet either directly on the `digitalocean.ReservedIp` resource by setting a `droplet_id` or using the `digitalocean.ReservedIpAssignment` resource, but the two cannot be used together.\n\n## Example Usage\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst example = new digitalocean.Droplet(\"example\", {\n name: \"example\",\n size: digitalocean.DropletSlug.DropletS1VCPU1GB,\n image: \"ubuntu-22-04-x64\",\n region: digitalocean.Region.NYC3,\n ipv6: true,\n privateNetworking: true,\n});\nconst exampleReservedIp = new digitalocean.ReservedIp(\"example\", {\n dropletId: example.id,\n region: example.region,\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nexample = digitalocean.Droplet(\"example\",\n name=\"example\",\n size=digitalocean.DropletSlug.DROPLET_S1_VCPU1_GB,\n image=\"ubuntu-22-04-x64\",\n region=digitalocean.Region.NYC3,\n ipv6=True,\n private_networking=True)\nexample_reserved_ip = digitalocean.ReservedIp(\"example\",\n droplet_id=example.id,\n region=example.region)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var example = new DigitalOcean.Droplet(\"example\", new()\n {\n Name = \"example\",\n Size = DigitalOcean.DropletSlug.DropletS1VCPU1GB,\n Image = \"ubuntu-22-04-x64\",\n Region = DigitalOcean.Region.NYC3,\n Ipv6 = true,\n PrivateNetworking = true,\n });\n\n var exampleReservedIp = new DigitalOcean.ReservedIp(\"example\", new()\n {\n DropletId = example.Id,\n Region = example.Region,\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\texample, err := digitalocean.NewDroplet(ctx, \"example\", \u0026digitalocean.DropletArgs{\n\t\t\tName: pulumi.String(\"example\"),\n\t\t\tSize: pulumi.String(digitalocean.DropletSlugDropletS1VCPU1GB),\n\t\t\tImage: pulumi.String(\"ubuntu-22-04-x64\"),\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC3),\n\t\t\tIpv6: pulumi.Bool(true),\n\t\t\tPrivateNetworking: pulumi.Bool(true),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = digitalocean.NewReservedIp(ctx, \"example\", \u0026digitalocean.ReservedIpArgs{\n\t\t\tDropletId: example.ID(),\n\t\t\tRegion: example.Region,\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.digitalocean.Droplet;\nimport com.pulumi.digitalocean.DropletArgs;\nimport com.pulumi.digitalocean.ReservedIp;\nimport com.pulumi.digitalocean.ReservedIpArgs;\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 example = new Droplet(\"example\", DropletArgs.builder() \n .name(\"example\")\n .size(\"s-1vcpu-1gb\")\n .image(\"ubuntu-22-04-x64\")\n .region(\"nyc3\")\n .ipv6(true)\n .privateNetworking(true)\n .build());\n\n var exampleReservedIp = new ReservedIp(\"exampleReservedIp\", ReservedIpArgs.builder() \n .dropletId(example.id())\n .region(example.region())\n .build());\n\n }\n}\n```\n```yaml\nresources:\n example:\n type: digitalocean:Droplet\n properties:\n name: example\n size: s-1vcpu-1gb\n image: ubuntu-22-04-x64\n region: nyc3\n ipv6: true\n privateNetworking: true\n exampleReservedIp:\n type: digitalocean:ReservedIp\n name: example\n properties:\n dropletId: ${example.id}\n region: ${example.region}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n## Import\n\nReserved IPs can be imported using the `ip`, e.g.\n\n```sh\n$ pulumi import digitalocean:index/reservedIp:ReservedIp myip 192.168.0.1\n```\n\n", "properties": { "dropletId": { "type": "integer", @@ -13085,7 +13085,7 @@ } }, "digitalocean:index/reservedIpAssignment:ReservedIpAssignment": { - "description": "Provides a resource for assigning an existing DigitalOcean reserved IP to a Droplet. This\nmakes it easy to provision reserved IP addresses that are not tied to the lifecycle of your\nDroplet.\n\n## Example Usage\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst exampleReservedIp = new digitalocean.ReservedIp(\"exampleReservedIp\", {region: \"nyc3\"});\nconst exampleDroplet = new digitalocean.Droplet(\"exampleDroplet\", {\n size: digitalocean.DropletSlug.DropletS1VCPU1GB,\n image: \"ubuntu-22-04-x64\",\n region: digitalocean.Region.NYC3,\n ipv6: true,\n privateNetworking: true,\n});\nconst exampleReservedIpAssignment = new digitalocean.ReservedIpAssignment(\"exampleReservedIpAssignment\", {\n ipAddress: exampleReservedIp.ipAddress,\n dropletId: exampleDroplet.id,\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nexample_reserved_ip = digitalocean.ReservedIp(\"exampleReservedIp\", region=\"nyc3\")\nexample_droplet = digitalocean.Droplet(\"exampleDroplet\",\n size=digitalocean.DropletSlug.DROPLET_S1_VCPU1_GB,\n image=\"ubuntu-22-04-x64\",\n region=digitalocean.Region.NYC3,\n ipv6=True,\n private_networking=True)\nexample_reserved_ip_assignment = digitalocean.ReservedIpAssignment(\"exampleReservedIpAssignment\",\n ip_address=example_reserved_ip.ip_address,\n droplet_id=example_droplet.id)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var exampleReservedIp = new DigitalOcean.ReservedIp(\"exampleReservedIp\", new()\n {\n Region = \"nyc3\",\n });\n\n var exampleDroplet = new DigitalOcean.Droplet(\"exampleDroplet\", new()\n {\n Size = DigitalOcean.DropletSlug.DropletS1VCPU1GB,\n Image = \"ubuntu-22-04-x64\",\n Region = DigitalOcean.Region.NYC3,\n Ipv6 = true,\n PrivateNetworking = true,\n });\n\n var exampleReservedIpAssignment = new DigitalOcean.ReservedIpAssignment(\"exampleReservedIpAssignment\", new()\n {\n IpAddress = exampleReservedIp.IpAddress,\n DropletId = exampleDroplet.Id,\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\texampleReservedIp, err := digitalocean.NewReservedIp(ctx, \"exampleReservedIp\", \u0026digitalocean.ReservedIpArgs{\n\t\t\tRegion: pulumi.String(\"nyc3\"),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\texampleDroplet, err := digitalocean.NewDroplet(ctx, \"exampleDroplet\", \u0026digitalocean.DropletArgs{\n\t\t\tSize: pulumi.String(digitalocean.DropletSlugDropletS1VCPU1GB),\n\t\t\tImage: pulumi.String(\"ubuntu-22-04-x64\"),\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC3),\n\t\t\tIpv6: pulumi.Bool(true),\n\t\t\tPrivateNetworking: pulumi.Bool(true),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = digitalocean.NewReservedIpAssignment(ctx, \"exampleReservedIpAssignment\", \u0026digitalocean.ReservedIpAssignmentArgs{\n\t\t\tIpAddress: exampleReservedIp.IpAddress,\n\t\t\tDropletId: exampleDroplet.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.digitalocean.ReservedIp;\nimport com.pulumi.digitalocean.ReservedIpArgs;\nimport com.pulumi.digitalocean.Droplet;\nimport com.pulumi.digitalocean.DropletArgs;\nimport com.pulumi.digitalocean.ReservedIpAssignment;\nimport com.pulumi.digitalocean.ReservedIpAssignmentArgs;\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 exampleReservedIp = new ReservedIp(\"exampleReservedIp\", ReservedIpArgs.builder() \n .region(\"nyc3\")\n .build());\n\n var exampleDroplet = new Droplet(\"exampleDroplet\", DropletArgs.builder() \n .size(\"s-1vcpu-1gb\")\n .image(\"ubuntu-22-04-x64\")\n .region(\"nyc3\")\n .ipv6(true)\n .privateNetworking(true)\n .build());\n\n var exampleReservedIpAssignment = new ReservedIpAssignment(\"exampleReservedIpAssignment\", ReservedIpAssignmentArgs.builder() \n .ipAddress(exampleReservedIp.ipAddress())\n .dropletId(exampleDroplet.id())\n .build());\n\n }\n}\n```\n```yaml\nresources:\n exampleReservedIp:\n type: digitalocean:ReservedIp\n properties:\n region: nyc3\n exampleDroplet:\n type: digitalocean:Droplet\n properties:\n size: s-1vcpu-1gb\n image: ubuntu-22-04-x64\n region: nyc3\n ipv6: true\n privateNetworking: true\n exampleReservedIpAssignment:\n type: digitalocean:ReservedIpAssignment\n properties:\n ipAddress: ${exampleReservedIp.ipAddress}\n dropletId: ${exampleDroplet.id}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n## Import\n\nReserved IP assignments can be imported using the reserved IP itself and the `id` of\n\nthe Droplet joined with a comma. For example:\n\n```sh\n$ pulumi import digitalocean:index/reservedIpAssignment:ReservedIpAssignment foobar 192.0.2.1,123456\n```\n\n", + "description": "Provides a resource for assigning an existing DigitalOcean reserved IP to a Droplet. This\nmakes it easy to provision reserved IP addresses that are not tied to the lifecycle of your\nDroplet.\n\n## Example Usage\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst example = new digitalocean.ReservedIp(\"example\", {region: \"nyc3\"});\nconst exampleDroplet = new digitalocean.Droplet(\"example\", {\n name: \"baz\",\n size: digitalocean.DropletSlug.DropletS1VCPU1GB,\n image: \"ubuntu-22-04-x64\",\n region: digitalocean.Region.NYC3,\n ipv6: true,\n privateNetworking: true,\n});\nconst exampleReservedIpAssignment = new digitalocean.ReservedIpAssignment(\"example\", {\n ipAddress: example.ipAddress,\n dropletId: exampleDroplet.id,\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nexample = digitalocean.ReservedIp(\"example\", region=\"nyc3\")\nexample_droplet = digitalocean.Droplet(\"example\",\n name=\"baz\",\n size=digitalocean.DropletSlug.DROPLET_S1_VCPU1_GB,\n image=\"ubuntu-22-04-x64\",\n region=digitalocean.Region.NYC3,\n ipv6=True,\n private_networking=True)\nexample_reserved_ip_assignment = digitalocean.ReservedIpAssignment(\"example\",\n ip_address=example.ip_address,\n droplet_id=example_droplet.id)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var example = new DigitalOcean.ReservedIp(\"example\", new()\n {\n Region = \"nyc3\",\n });\n\n var exampleDroplet = new DigitalOcean.Droplet(\"example\", new()\n {\n Name = \"baz\",\n Size = DigitalOcean.DropletSlug.DropletS1VCPU1GB,\n Image = \"ubuntu-22-04-x64\",\n Region = DigitalOcean.Region.NYC3,\n Ipv6 = true,\n PrivateNetworking = true,\n });\n\n var exampleReservedIpAssignment = new DigitalOcean.ReservedIpAssignment(\"example\", new()\n {\n IpAddress = example.IpAddress,\n DropletId = exampleDroplet.Id,\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\texample, err := digitalocean.NewReservedIp(ctx, \"example\", \u0026digitalocean.ReservedIpArgs{\n\t\t\tRegion: pulumi.String(\"nyc3\"),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\texampleDroplet, err := digitalocean.NewDroplet(ctx, \"example\", \u0026digitalocean.DropletArgs{\n\t\t\tName: pulumi.String(\"baz\"),\n\t\t\tSize: pulumi.String(digitalocean.DropletSlugDropletS1VCPU1GB),\n\t\t\tImage: pulumi.String(\"ubuntu-22-04-x64\"),\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC3),\n\t\t\tIpv6: pulumi.Bool(true),\n\t\t\tPrivateNetworking: pulumi.Bool(true),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = digitalocean.NewReservedIpAssignment(ctx, \"example\", \u0026digitalocean.ReservedIpAssignmentArgs{\n\t\t\tIpAddress: example.IpAddress,\n\t\t\tDropletId: exampleDroplet.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.digitalocean.ReservedIp;\nimport com.pulumi.digitalocean.ReservedIpArgs;\nimport com.pulumi.digitalocean.Droplet;\nimport com.pulumi.digitalocean.DropletArgs;\nimport com.pulumi.digitalocean.ReservedIpAssignment;\nimport com.pulumi.digitalocean.ReservedIpAssignmentArgs;\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 example = new ReservedIp(\"example\", ReservedIpArgs.builder() \n .region(\"nyc3\")\n .build());\n\n var exampleDroplet = new Droplet(\"exampleDroplet\", DropletArgs.builder() \n .name(\"baz\")\n .size(\"s-1vcpu-1gb\")\n .image(\"ubuntu-22-04-x64\")\n .region(\"nyc3\")\n .ipv6(true)\n .privateNetworking(true)\n .build());\n\n var exampleReservedIpAssignment = new ReservedIpAssignment(\"exampleReservedIpAssignment\", ReservedIpAssignmentArgs.builder() \n .ipAddress(example.ipAddress())\n .dropletId(exampleDroplet.id())\n .build());\n\n }\n}\n```\n```yaml\nresources:\n example:\n type: digitalocean:ReservedIp\n properties:\n region: nyc3\n exampleDroplet:\n type: digitalocean:Droplet\n name: example\n properties:\n name: baz\n size: s-1vcpu-1gb\n image: ubuntu-22-04-x64\n region: nyc3\n ipv6: true\n privateNetworking: true\n exampleReservedIpAssignment:\n type: digitalocean:ReservedIpAssignment\n name: example\n properties:\n ipAddress: ${example.ipAddress}\n dropletId: ${exampleDroplet.id}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n## Import\n\nReserved IP assignments can be imported using the reserved IP itself and the `id` of\n\nthe Droplet joined with a comma. For example:\n\n```sh\n$ pulumi import digitalocean:index/reservedIpAssignment:ReservedIpAssignment foobar 192.0.2.1,123456\n```\n\n", "properties": { "dropletId": { "type": "integer", @@ -13134,7 +13134,7 @@ } }, "digitalocean:index/spacesBucket:SpacesBucket": { - "description": "Provides a bucket resource for Spaces, DigitalOcean's object storage product.\n\nThe [Spaces API](https://docs.digitalocean.com/reference/api/spaces-api/) was\ndesigned to be interoperable with Amazon's AWS S3 API. This allows users to\ninteract with the service while using the tools they already know. Spaces\nmirrors S3's authentication framework and requests to Spaces require a key pair\nsimilar to Amazon's Access ID and Secret Key.\n\nThe authentication requirement can be met by either setting the\n`SPACES_ACCESS_KEY_ID` and `SPACES_SECRET_ACCESS_KEY` environment variables or\nthe provider's `spaces_access_id` and `spaces_secret_key` arguments to the\naccess ID and secret you generate via the DigitalOcean control panel. For\nexample:\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst static_assets = new digitalocean.SpacesBucket(\"static-assets\", {});\n// ...\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nstatic_assets = digitalocean.SpacesBucket(\"static-assets\")\n# ...\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var static_assets = new DigitalOcean.SpacesBucket(\"static-assets\");\n\n // ...\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := digitalocean.NewSpacesBucket(ctx, \"static-assets\", nil)\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.digitalocean.SpacesBucket;\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 static_assets = new SpacesBucket(\"static-assets\");\n\n // ...\n }\n}\n```\n```yaml\nresources:\n static-assets:\n type: digitalocean:SpacesBucket\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\nFor more information, See [An Introduction to DigitalOcean Spaces](https://www.digitalocean.com/community/tutorials/an-introduction-to-digitalocean-spaces)\n\n## Example Usage\n\n### Create a New Bucket\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst foobar = new digitalocean.SpacesBucket(\"foobar\", {region: digitalocean.Region.NYC3});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nfoobar = digitalocean.SpacesBucket(\"foobar\", region=digitalocean.Region.NYC3)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var foobar = new DigitalOcean.SpacesBucket(\"foobar\", new()\n {\n Region = DigitalOcean.Region.NYC3,\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := digitalocean.NewSpacesBucket(ctx, \"foobar\", \u0026digitalocean.SpacesBucketArgs{\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC3),\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.digitalocean.SpacesBucket;\nimport com.pulumi.digitalocean.SpacesBucketArgs;\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 foobar = new SpacesBucket(\"foobar\", SpacesBucketArgs.builder() \n .region(\"nyc3\")\n .build());\n\n }\n}\n```\n```yaml\nresources:\n foobar:\n type: digitalocean:SpacesBucket\n properties:\n region: nyc3\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n### Create a New Bucket With CORS Rules\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst foobar = new digitalocean.SpacesBucket(\"foobar\", {\n corsRules: [\n {\n allowedHeaders: [\"*\"],\n allowedMethods: [\"GET\"],\n allowedOrigins: [\"*\"],\n maxAgeSeconds: 3000,\n },\n {\n allowedHeaders: [\"*\"],\n allowedMethods: [\n \"PUT\",\n \"POST\",\n \"DELETE\",\n ],\n allowedOrigins: [\"https://www.example.com\"],\n maxAgeSeconds: 3000,\n },\n ],\n region: digitalocean.Region.NYC3,\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nfoobar = digitalocean.SpacesBucket(\"foobar\",\n cors_rules=[\n digitalocean.SpacesBucketCorsRuleArgs(\n allowed_headers=[\"*\"],\n allowed_methods=[\"GET\"],\n allowed_origins=[\"*\"],\n max_age_seconds=3000,\n ),\n digitalocean.SpacesBucketCorsRuleArgs(\n allowed_headers=[\"*\"],\n allowed_methods=[\n \"PUT\",\n \"POST\",\n \"DELETE\",\n ],\n allowed_origins=[\"https://www.example.com\"],\n max_age_seconds=3000,\n ),\n ],\n region=digitalocean.Region.NYC3)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var foobar = new DigitalOcean.SpacesBucket(\"foobar\", new()\n {\n CorsRules = new[]\n {\n new DigitalOcean.Inputs.SpacesBucketCorsRuleArgs\n {\n AllowedHeaders = new[]\n {\n \"*\",\n },\n AllowedMethods = new[]\n {\n \"GET\",\n },\n AllowedOrigins = new[]\n {\n \"*\",\n },\n MaxAgeSeconds = 3000,\n },\n new DigitalOcean.Inputs.SpacesBucketCorsRuleArgs\n {\n AllowedHeaders = new[]\n {\n \"*\",\n },\n AllowedMethods = new[]\n {\n \"PUT\",\n \"POST\",\n \"DELETE\",\n },\n AllowedOrigins = new[]\n {\n \"https://www.example.com\",\n },\n MaxAgeSeconds = 3000,\n },\n },\n Region = DigitalOcean.Region.NYC3,\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := digitalocean.NewSpacesBucket(ctx, \"foobar\", \u0026digitalocean.SpacesBucketArgs{\n\t\t\tCorsRules: digitalocean.SpacesBucketCorsRuleArray{\n\t\t\t\t\u0026digitalocean.SpacesBucketCorsRuleArgs{\n\t\t\t\t\tAllowedHeaders: pulumi.StringArray{\n\t\t\t\t\t\tpulumi.String(\"*\"),\n\t\t\t\t\t},\n\t\t\t\t\tAllowedMethods: pulumi.StringArray{\n\t\t\t\t\t\tpulumi.String(\"GET\"),\n\t\t\t\t\t},\n\t\t\t\t\tAllowedOrigins: pulumi.StringArray{\n\t\t\t\t\t\tpulumi.String(\"*\"),\n\t\t\t\t\t},\n\t\t\t\t\tMaxAgeSeconds: pulumi.Int(3000),\n\t\t\t\t},\n\t\t\t\t\u0026digitalocean.SpacesBucketCorsRuleArgs{\n\t\t\t\t\tAllowedHeaders: pulumi.StringArray{\n\t\t\t\t\t\tpulumi.String(\"*\"),\n\t\t\t\t\t},\n\t\t\t\t\tAllowedMethods: pulumi.StringArray{\n\t\t\t\t\t\tpulumi.String(\"PUT\"),\n\t\t\t\t\t\tpulumi.String(\"POST\"),\n\t\t\t\t\t\tpulumi.String(\"DELETE\"),\n\t\t\t\t\t},\n\t\t\t\t\tAllowedOrigins: pulumi.StringArray{\n\t\t\t\t\t\tpulumi.String(\"https://www.example.com\"),\n\t\t\t\t\t},\n\t\t\t\t\tMaxAgeSeconds: pulumi.Int(3000),\n\t\t\t\t},\n\t\t\t},\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC3),\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.digitalocean.SpacesBucket;\nimport com.pulumi.digitalocean.SpacesBucketArgs;\nimport com.pulumi.digitalocean.inputs.SpacesBucketCorsRuleArgs;\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 foobar = new SpacesBucket(\"foobar\", SpacesBucketArgs.builder() \n .corsRules( \n SpacesBucketCorsRuleArgs.builder()\n .allowedHeaders(\"*\")\n .allowedMethods(\"GET\")\n .allowedOrigins(\"*\")\n .maxAgeSeconds(3000)\n .build(),\n SpacesBucketCorsRuleArgs.builder()\n .allowedHeaders(\"*\")\n .allowedMethods( \n \"PUT\",\n \"POST\",\n \"DELETE\")\n .allowedOrigins(\"https://www.example.com\")\n .maxAgeSeconds(3000)\n .build())\n .region(\"nyc3\")\n .build());\n\n }\n}\n```\n```yaml\nresources:\n foobar:\n type: digitalocean:SpacesBucket\n properties:\n corsRules:\n - allowedHeaders:\n - '*'\n allowedMethods:\n - GET\n allowedOrigins:\n - '*'\n maxAgeSeconds: 3000\n - allowedHeaders:\n - '*'\n allowedMethods:\n - PUT\n - POST\n - DELETE\n allowedOrigins:\n - https://www.example.com\n maxAgeSeconds: 3000\n region: nyc3\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n## Import\n\nBuckets can be imported using the `region` and `name` attributes (delimited by a comma):\n\n```sh\n$ pulumi import digitalocean:index/spacesBucket:SpacesBucket foobar `region`,`name`\n```\n\n", + "description": "Provides a bucket resource for Spaces, DigitalOcean's object storage product.\n\nThe [Spaces API](https://docs.digitalocean.com/reference/api/spaces-api/) was\ndesigned to be interoperable with Amazon's AWS S3 API. This allows users to\ninteract with the service while using the tools they already know. Spaces\nmirrors S3's authentication framework and requests to Spaces require a key pair\nsimilar to Amazon's Access ID and Secret Key.\n\nThe authentication requirement can be met by either setting the\n`SPACES_ACCESS_KEY_ID` and `SPACES_SECRET_ACCESS_KEY` environment variables or\nthe provider's `spaces_access_id` and `spaces_secret_key` arguments to the\naccess ID and secret you generate via the DigitalOcean control panel. For\nexample:\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst static_assets = new digitalocean.SpacesBucket(\"static-assets\", {});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nstatic_assets = digitalocean.SpacesBucket(\"static-assets\")\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var static_assets = new DigitalOcean.SpacesBucket(\"static-assets\");\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := digitalocean.NewSpacesBucket(ctx, \"static-assets\", nil)\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.digitalocean.SpacesBucket;\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 static_assets = new SpacesBucket(\"static-assets\");\n\n }\n}\n```\n```yaml\nresources:\n static-assets:\n type: digitalocean:SpacesBucket\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\nFor more information, See [An Introduction to DigitalOcean Spaces](https://www.digitalocean.com/community/tutorials/an-introduction-to-digitalocean-spaces)\n\n## Example Usage\n\n### Create a New Bucket\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst foobar = new digitalocean.SpacesBucket(\"foobar\", {\n name: \"foobar\",\n region: digitalocean.Region.NYC3,\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nfoobar = digitalocean.SpacesBucket(\"foobar\",\n name=\"foobar\",\n region=digitalocean.Region.NYC3)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var foobar = new DigitalOcean.SpacesBucket(\"foobar\", new()\n {\n Name = \"foobar\",\n Region = DigitalOcean.Region.NYC3,\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := digitalocean.NewSpacesBucket(ctx, \"foobar\", \u0026digitalocean.SpacesBucketArgs{\n\t\t\tName: pulumi.String(\"foobar\"),\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC3),\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.digitalocean.SpacesBucket;\nimport com.pulumi.digitalocean.SpacesBucketArgs;\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 foobar = new SpacesBucket(\"foobar\", SpacesBucketArgs.builder() \n .name(\"foobar\")\n .region(\"nyc3\")\n .build());\n\n }\n}\n```\n```yaml\nresources:\n foobar:\n type: digitalocean:SpacesBucket\n properties:\n name: foobar\n region: nyc3\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n### Create a New Bucket With CORS Rules\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst foobar = new digitalocean.SpacesBucket(\"foobar\", {\n name: \"foobar\",\n region: digitalocean.Region.NYC3,\n corsRules: [\n {\n allowedHeaders: [\"*\"],\n allowedMethods: [\"GET\"],\n allowedOrigins: [\"*\"],\n maxAgeSeconds: 3000,\n },\n {\n allowedHeaders: [\"*\"],\n allowedMethods: [\n \"PUT\",\n \"POST\",\n \"DELETE\",\n ],\n allowedOrigins: [\"https://www.example.com\"],\n maxAgeSeconds: 3000,\n },\n ],\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nfoobar = digitalocean.SpacesBucket(\"foobar\",\n name=\"foobar\",\n region=digitalocean.Region.NYC3,\n cors_rules=[\n digitalocean.SpacesBucketCorsRuleArgs(\n allowed_headers=[\"*\"],\n allowed_methods=[\"GET\"],\n allowed_origins=[\"*\"],\n max_age_seconds=3000,\n ),\n digitalocean.SpacesBucketCorsRuleArgs(\n allowed_headers=[\"*\"],\n allowed_methods=[\n \"PUT\",\n \"POST\",\n \"DELETE\",\n ],\n allowed_origins=[\"https://www.example.com\"],\n max_age_seconds=3000,\n ),\n ])\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var foobar = new DigitalOcean.SpacesBucket(\"foobar\", new()\n {\n Name = \"foobar\",\n Region = DigitalOcean.Region.NYC3,\n CorsRules = new[]\n {\n new DigitalOcean.Inputs.SpacesBucketCorsRuleArgs\n {\n AllowedHeaders = new[]\n {\n \"*\",\n },\n AllowedMethods = new[]\n {\n \"GET\",\n },\n AllowedOrigins = new[]\n {\n \"*\",\n },\n MaxAgeSeconds = 3000,\n },\n new DigitalOcean.Inputs.SpacesBucketCorsRuleArgs\n {\n AllowedHeaders = new[]\n {\n \"*\",\n },\n AllowedMethods = new[]\n {\n \"PUT\",\n \"POST\",\n \"DELETE\",\n },\n AllowedOrigins = new[]\n {\n \"https://www.example.com\",\n },\n MaxAgeSeconds = 3000,\n },\n },\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := digitalocean.NewSpacesBucket(ctx, \"foobar\", \u0026digitalocean.SpacesBucketArgs{\n\t\t\tName: pulumi.String(\"foobar\"),\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC3),\n\t\t\tCorsRules: digitalocean.SpacesBucketCorsRuleArray{\n\t\t\t\t\u0026digitalocean.SpacesBucketCorsRuleArgs{\n\t\t\t\t\tAllowedHeaders: pulumi.StringArray{\n\t\t\t\t\t\tpulumi.String(\"*\"),\n\t\t\t\t\t},\n\t\t\t\t\tAllowedMethods: pulumi.StringArray{\n\t\t\t\t\t\tpulumi.String(\"GET\"),\n\t\t\t\t\t},\n\t\t\t\t\tAllowedOrigins: pulumi.StringArray{\n\t\t\t\t\t\tpulumi.String(\"*\"),\n\t\t\t\t\t},\n\t\t\t\t\tMaxAgeSeconds: pulumi.Int(3000),\n\t\t\t\t},\n\t\t\t\t\u0026digitalocean.SpacesBucketCorsRuleArgs{\n\t\t\t\t\tAllowedHeaders: pulumi.StringArray{\n\t\t\t\t\t\tpulumi.String(\"*\"),\n\t\t\t\t\t},\n\t\t\t\t\tAllowedMethods: pulumi.StringArray{\n\t\t\t\t\t\tpulumi.String(\"PUT\"),\n\t\t\t\t\t\tpulumi.String(\"POST\"),\n\t\t\t\t\t\tpulumi.String(\"DELETE\"),\n\t\t\t\t\t},\n\t\t\t\t\tAllowedOrigins: pulumi.StringArray{\n\t\t\t\t\t\tpulumi.String(\"https://www.example.com\"),\n\t\t\t\t\t},\n\t\t\t\t\tMaxAgeSeconds: pulumi.Int(3000),\n\t\t\t\t},\n\t\t\t},\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.digitalocean.SpacesBucket;\nimport com.pulumi.digitalocean.SpacesBucketArgs;\nimport com.pulumi.digitalocean.inputs.SpacesBucketCorsRuleArgs;\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 foobar = new SpacesBucket(\"foobar\", SpacesBucketArgs.builder() \n .name(\"foobar\")\n .region(\"nyc3\")\n .corsRules( \n SpacesBucketCorsRuleArgs.builder()\n .allowedHeaders(\"*\")\n .allowedMethods(\"GET\")\n .allowedOrigins(\"*\")\n .maxAgeSeconds(3000)\n .build(),\n SpacesBucketCorsRuleArgs.builder()\n .allowedHeaders(\"*\")\n .allowedMethods( \n \"PUT\",\n \"POST\",\n \"DELETE\")\n .allowedOrigins(\"https://www.example.com\")\n .maxAgeSeconds(3000)\n .build())\n .build());\n\n }\n}\n```\n```yaml\nresources:\n foobar:\n type: digitalocean:SpacesBucket\n properties:\n name: foobar\n region: nyc3\n corsRules:\n - allowedHeaders:\n - '*'\n allowedMethods:\n - GET\n allowedOrigins:\n - '*'\n maxAgeSeconds: 3000\n - allowedHeaders:\n - '*'\n allowedMethods:\n - PUT\n - POST\n - DELETE\n allowedOrigins:\n - https://www.example.com\n maxAgeSeconds: 3000\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n## Import\n\nBuckets can be imported using the `region` and `name` attributes (delimited by a comma):\n\n```sh\n$ pulumi import digitalocean:index/spacesBucket:SpacesBucket foobar `region`,`name`\n```\n\n", "properties": { "acl": { "type": "string", @@ -13302,7 +13302,7 @@ } }, "digitalocean:index/spacesBucketCorsConfiguration:SpacesBucketCorsConfiguration": { - "description": "## Example Usage\n\n### Create a Key in a Spaces Bucket\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst foobar = new digitalocean.SpacesBucket(\"foobar\", {region: digitalocean.Region.NYC3});\nconst test = new digitalocean.SpacesBucketCorsConfiguration(\"test\", {\n bucket: foobar.id,\n region: \"nyc3\",\n corsRules: [{\n allowedHeaders: [\"*\"],\n allowedMethods: [\n \"PUT\",\n \"POST\",\n ],\n allowedOrigins: [\"https://s3-website-test.hashicorp.com\"],\n exposeHeaders: [\"ETag\"],\n maxAgeSeconds: 3000,\n }],\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nfoobar = digitalocean.SpacesBucket(\"foobar\", region=digitalocean.Region.NYC3)\ntest = digitalocean.SpacesBucketCorsConfiguration(\"test\",\n bucket=foobar.id,\n region=\"nyc3\",\n cors_rules=[digitalocean.SpacesBucketCorsConfigurationCorsRuleArgs(\n allowed_headers=[\"*\"],\n allowed_methods=[\n \"PUT\",\n \"POST\",\n ],\n allowed_origins=[\"https://s3-website-test.hashicorp.com\"],\n expose_headers=[\"ETag\"],\n max_age_seconds=3000,\n )])\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var foobar = new DigitalOcean.SpacesBucket(\"foobar\", new()\n {\n Region = DigitalOcean.Region.NYC3,\n });\n\n var test = new DigitalOcean.SpacesBucketCorsConfiguration(\"test\", new()\n {\n Bucket = foobar.Id,\n Region = \"nyc3\",\n CorsRules = new[]\n {\n new DigitalOcean.Inputs.SpacesBucketCorsConfigurationCorsRuleArgs\n {\n AllowedHeaders = new[]\n {\n \"*\",\n },\n AllowedMethods = new[]\n {\n \"PUT\",\n \"POST\",\n },\n AllowedOrigins = new[]\n {\n \"https://s3-website-test.hashicorp.com\",\n },\n ExposeHeaders = new[]\n {\n \"ETag\",\n },\n MaxAgeSeconds = 3000,\n },\n },\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tfoobar, err := digitalocean.NewSpacesBucket(ctx, \"foobar\", \u0026digitalocean.SpacesBucketArgs{\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC3),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = digitalocean.NewSpacesBucketCorsConfiguration(ctx, \"test\", \u0026digitalocean.SpacesBucketCorsConfigurationArgs{\n\t\t\tBucket: foobar.ID(),\n\t\t\tRegion: pulumi.String(\"nyc3\"),\n\t\t\tCorsRules: digitalocean.SpacesBucketCorsConfigurationCorsRuleArray{\n\t\t\t\t\u0026digitalocean.SpacesBucketCorsConfigurationCorsRuleArgs{\n\t\t\t\t\tAllowedHeaders: pulumi.StringArray{\n\t\t\t\t\t\tpulumi.String(\"*\"),\n\t\t\t\t\t},\n\t\t\t\t\tAllowedMethods: pulumi.StringArray{\n\t\t\t\t\t\tpulumi.String(\"PUT\"),\n\t\t\t\t\t\tpulumi.String(\"POST\"),\n\t\t\t\t\t},\n\t\t\t\t\tAllowedOrigins: pulumi.StringArray{\n\t\t\t\t\t\tpulumi.String(\"https://s3-website-test.hashicorp.com\"),\n\t\t\t\t\t},\n\t\t\t\t\tExposeHeaders: pulumi.StringArray{\n\t\t\t\t\t\tpulumi.String(\"ETag\"),\n\t\t\t\t\t},\n\t\t\t\t\tMaxAgeSeconds: pulumi.Int(3000),\n\t\t\t\t},\n\t\t\t},\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.digitalocean.SpacesBucket;\nimport com.pulumi.digitalocean.SpacesBucketArgs;\nimport com.pulumi.digitalocean.SpacesBucketCorsConfiguration;\nimport com.pulumi.digitalocean.SpacesBucketCorsConfigurationArgs;\nimport com.pulumi.digitalocean.inputs.SpacesBucketCorsConfigurationCorsRuleArgs;\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 foobar = new SpacesBucket(\"foobar\", SpacesBucketArgs.builder() \n .region(\"nyc3\")\n .build());\n\n var test = new SpacesBucketCorsConfiguration(\"test\", SpacesBucketCorsConfigurationArgs.builder() \n .bucket(foobar.id())\n .region(\"nyc3\")\n .corsRules(SpacesBucketCorsConfigurationCorsRuleArgs.builder()\n .allowedHeaders(\"*\")\n .allowedMethods( \n \"PUT\",\n \"POST\")\n .allowedOrigins(\"https://s3-website-test.hashicorp.com\")\n .exposeHeaders(\"ETag\")\n .maxAgeSeconds(3000)\n .build())\n .build());\n\n }\n}\n```\n```yaml\nresources:\n foobar:\n type: digitalocean:SpacesBucket\n properties:\n region: nyc3\n test:\n type: digitalocean:SpacesBucketCorsConfiguration\n properties:\n bucket: ${foobar.id}\n region: nyc3\n corsRules:\n - allowedHeaders:\n - '*'\n allowedMethods:\n - PUT\n - POST\n allowedOrigins:\n - https://s3-website-test.hashicorp.com\n exposeHeaders:\n - ETag\n maxAgeSeconds: 3000\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n## Import\n\nBucket policies can be imported using the `region` and `bucket` attributes (delimited by a comma):\n\n```sh\n$ pulumi import digitalocean:index/spacesBucketCorsConfiguration:SpacesBucketCorsConfiguration foobar `region`,`bucket`\n```\n\n", + "description": "## Example Usage\n\n### Create a Key in a Spaces Bucket\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst foobar = new digitalocean.SpacesBucket(\"foobar\", {\n name: \"foobar\",\n region: digitalocean.Region.NYC3,\n});\nconst test = new digitalocean.SpacesBucketCorsConfiguration(\"test\", {\n bucket: foobar.id,\n region: \"nyc3\",\n corsRules: [{\n allowedHeaders: [\"*\"],\n allowedMethods: [\n \"PUT\",\n \"POST\",\n ],\n allowedOrigins: [\"https://s3-website-test.hashicorp.com\"],\n exposeHeaders: [\"ETag\"],\n maxAgeSeconds: 3000,\n }],\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nfoobar = digitalocean.SpacesBucket(\"foobar\",\n name=\"foobar\",\n region=digitalocean.Region.NYC3)\ntest = digitalocean.SpacesBucketCorsConfiguration(\"test\",\n bucket=foobar.id,\n region=\"nyc3\",\n cors_rules=[digitalocean.SpacesBucketCorsConfigurationCorsRuleArgs(\n allowed_headers=[\"*\"],\n allowed_methods=[\n \"PUT\",\n \"POST\",\n ],\n allowed_origins=[\"https://s3-website-test.hashicorp.com\"],\n expose_headers=[\"ETag\"],\n max_age_seconds=3000,\n )])\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var foobar = new DigitalOcean.SpacesBucket(\"foobar\", new()\n {\n Name = \"foobar\",\n Region = DigitalOcean.Region.NYC3,\n });\n\n var test = new DigitalOcean.SpacesBucketCorsConfiguration(\"test\", new()\n {\n Bucket = foobar.Id,\n Region = \"nyc3\",\n CorsRules = new[]\n {\n new DigitalOcean.Inputs.SpacesBucketCorsConfigurationCorsRuleArgs\n {\n AllowedHeaders = new[]\n {\n \"*\",\n },\n AllowedMethods = new[]\n {\n \"PUT\",\n \"POST\",\n },\n AllowedOrigins = new[]\n {\n \"https://s3-website-test.hashicorp.com\",\n },\n ExposeHeaders = new[]\n {\n \"ETag\",\n },\n MaxAgeSeconds = 3000,\n },\n },\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tfoobar, err := digitalocean.NewSpacesBucket(ctx, \"foobar\", \u0026digitalocean.SpacesBucketArgs{\n\t\t\tName: pulumi.String(\"foobar\"),\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC3),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = digitalocean.NewSpacesBucketCorsConfiguration(ctx, \"test\", \u0026digitalocean.SpacesBucketCorsConfigurationArgs{\n\t\t\tBucket: foobar.ID(),\n\t\t\tRegion: pulumi.String(\"nyc3\"),\n\t\t\tCorsRules: digitalocean.SpacesBucketCorsConfigurationCorsRuleArray{\n\t\t\t\t\u0026digitalocean.SpacesBucketCorsConfigurationCorsRuleArgs{\n\t\t\t\t\tAllowedHeaders: pulumi.StringArray{\n\t\t\t\t\t\tpulumi.String(\"*\"),\n\t\t\t\t\t},\n\t\t\t\t\tAllowedMethods: pulumi.StringArray{\n\t\t\t\t\t\tpulumi.String(\"PUT\"),\n\t\t\t\t\t\tpulumi.String(\"POST\"),\n\t\t\t\t\t},\n\t\t\t\t\tAllowedOrigins: pulumi.StringArray{\n\t\t\t\t\t\tpulumi.String(\"https://s3-website-test.hashicorp.com\"),\n\t\t\t\t\t},\n\t\t\t\t\tExposeHeaders: pulumi.StringArray{\n\t\t\t\t\t\tpulumi.String(\"ETag\"),\n\t\t\t\t\t},\n\t\t\t\t\tMaxAgeSeconds: pulumi.Int(3000),\n\t\t\t\t},\n\t\t\t},\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.digitalocean.SpacesBucket;\nimport com.pulumi.digitalocean.SpacesBucketArgs;\nimport com.pulumi.digitalocean.SpacesBucketCorsConfiguration;\nimport com.pulumi.digitalocean.SpacesBucketCorsConfigurationArgs;\nimport com.pulumi.digitalocean.inputs.SpacesBucketCorsConfigurationCorsRuleArgs;\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 foobar = new SpacesBucket(\"foobar\", SpacesBucketArgs.builder() \n .name(\"foobar\")\n .region(\"nyc3\")\n .build());\n\n var test = new SpacesBucketCorsConfiguration(\"test\", SpacesBucketCorsConfigurationArgs.builder() \n .bucket(foobar.id())\n .region(\"nyc3\")\n .corsRules(SpacesBucketCorsConfigurationCorsRuleArgs.builder()\n .allowedHeaders(\"*\")\n .allowedMethods( \n \"PUT\",\n \"POST\")\n .allowedOrigins(\"https://s3-website-test.hashicorp.com\")\n .exposeHeaders(\"ETag\")\n .maxAgeSeconds(3000)\n .build())\n .build());\n\n }\n}\n```\n```yaml\nresources:\n foobar:\n type: digitalocean:SpacesBucket\n properties:\n name: foobar\n region: nyc3\n test:\n type: digitalocean:SpacesBucketCorsConfiguration\n properties:\n bucket: ${foobar.id}\n region: nyc3\n corsRules:\n - allowedHeaders:\n - '*'\n allowedMethods:\n - PUT\n - POST\n allowedOrigins:\n - https://s3-website-test.hashicorp.com\n exposeHeaders:\n - ETag\n maxAgeSeconds: 3000\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n## Import\n\nBucket policies can be imported using the `region` and `bucket` attributes (delimited by a comma):\n\n```sh\n$ pulumi import digitalocean:index/spacesBucketCorsConfiguration:SpacesBucketCorsConfiguration foobar `region`,`bucket`\n```\n\n", "properties": { "bucket": { "type": "string", @@ -13372,7 +13372,7 @@ } }, "digitalocean:index/spacesBucketObject:SpacesBucketObject": { - "description": "Provides a bucket object resource for Spaces, DigitalOcean's object storage product.\nThe `digitalocean.SpacesBucketObject` resource allows the provider to upload content\nto Spaces.\n\nThe [Spaces API](https://docs.digitalocean.com/reference/api/spaces-api/) was\ndesigned to be interoperable with Amazon's AWS S3 API. This allows users to\ninteract with the service while using the tools they already know. Spaces\nmirrors S3's authentication framework and requests to Spaces require a key pair\nsimilar to Amazon's Access ID and Secret Key.\n\nThe authentication requirement can be met by either setting the\n`SPACES_ACCESS_KEY_ID` and `SPACES_SECRET_ACCESS_KEY` environment variables or\nthe provider's `spaces_access_id` and `spaces_secret_key` arguments to the\naccess ID and secret you generate via the DigitalOcean control panel. For\nexample:\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst static_assets = new digitalocean.SpacesBucket(\"static-assets\", {});\n// ...\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nstatic_assets = digitalocean.SpacesBucket(\"static-assets\")\n# ...\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var static_assets = new DigitalOcean.SpacesBucket(\"static-assets\");\n\n // ...\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := digitalocean.NewSpacesBucket(ctx, \"static-assets\", nil)\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.digitalocean.SpacesBucket;\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 static_assets = new SpacesBucket(\"static-assets\");\n\n // ...\n }\n}\n```\n```yaml\nresources:\n static-assets:\n type: digitalocean:SpacesBucket\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\nFor more information, See [An Introduction to DigitalOcean Spaces](https://www.digitalocean.com/community/tutorials/an-introduction-to-digitalocean-spaces)\n\n## Example Usage\n\n### Create a Key in a Spaces Bucket\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst foobar = new digitalocean.SpacesBucket(\"foobar\", {region: digitalocean.Region.NYC3});\nconst index = new digitalocean.SpacesBucketObject(\"index\", {\n region: foobar.region,\n bucket: foobar.name,\n key: \"index.html\",\n content: \"\u003chtml\u003e\u003cbody\u003e\u003cp\u003eThis page is empty.\u003c/p\u003e\u003c/body\u003e\u003c/html\u003e\",\n contentType: \"text/html\",\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nfoobar = digitalocean.SpacesBucket(\"foobar\", region=digitalocean.Region.NYC3)\nindex = digitalocean.SpacesBucketObject(\"index\",\n region=foobar.region,\n bucket=foobar.name,\n key=\"index.html\",\n content=\"\u003chtml\u003e\u003cbody\u003e\u003cp\u003eThis page is empty.\u003c/p\u003e\u003c/body\u003e\u003c/html\u003e\",\n content_type=\"text/html\")\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var foobar = new DigitalOcean.SpacesBucket(\"foobar\", new()\n {\n Region = DigitalOcean.Region.NYC3,\n });\n\n var index = new DigitalOcean.SpacesBucketObject(\"index\", new()\n {\n Region = foobar.Region,\n Bucket = foobar.Name,\n Key = \"index.html\",\n Content = \"\u003chtml\u003e\u003cbody\u003e\u003cp\u003eThis page is empty.\u003c/p\u003e\u003c/body\u003e\u003c/html\u003e\",\n ContentType = \"text/html\",\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tfoobar, err := digitalocean.NewSpacesBucket(ctx, \"foobar\", \u0026digitalocean.SpacesBucketArgs{\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC3),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = digitalocean.NewSpacesBucketObject(ctx, \"index\", \u0026digitalocean.SpacesBucketObjectArgs{\n\t\t\tRegion: foobar.Region,\n\t\t\tBucket: foobar.Name,\n\t\t\tKey: pulumi.String(\"index.html\"),\n\t\t\tContent: pulumi.String(\"\u003chtml\u003e\u003cbody\u003e\u003cp\u003eThis page is empty.\u003c/p\u003e\u003c/body\u003e\u003c/html\u003e\"),\n\t\t\tContentType: pulumi.String(\"text/html\"),\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.digitalocean.SpacesBucket;\nimport com.pulumi.digitalocean.SpacesBucketArgs;\nimport com.pulumi.digitalocean.SpacesBucketObject;\nimport com.pulumi.digitalocean.SpacesBucketObjectArgs;\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 foobar = new SpacesBucket(\"foobar\", SpacesBucketArgs.builder() \n .region(\"nyc3\")\n .build());\n\n var index = new SpacesBucketObject(\"index\", SpacesBucketObjectArgs.builder() \n .region(foobar.region())\n .bucket(foobar.name())\n .key(\"index.html\")\n .content(\"\u003chtml\u003e\u003cbody\u003e\u003cp\u003eThis page is empty.\u003c/p\u003e\u003c/body\u003e\u003c/html\u003e\")\n .contentType(\"text/html\")\n .build());\n\n }\n}\n```\n```yaml\nresources:\n foobar:\n type: digitalocean:SpacesBucket\n properties:\n region: nyc3\n index:\n type: digitalocean:SpacesBucketObject\n properties:\n region: ${foobar.region}\n bucket: ${foobar.name}\n key: index.html\n content: \u003chtml\u003e\u003cbody\u003e\u003cp\u003eThis page is empty.\u003c/p\u003e\u003c/body\u003e\u003c/html\u003e\n contentType: text/html\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n## Import\n\nImporting this resource is not supported.\n\n", + "description": "Provides a bucket object resource for Spaces, DigitalOcean's object storage product.\nThe `digitalocean.SpacesBucketObject` resource allows the provider to upload content\nto Spaces.\n\nThe [Spaces API](https://docs.digitalocean.com/reference/api/spaces-api/) was\ndesigned to be interoperable with Amazon's AWS S3 API. This allows users to\ninteract with the service while using the tools they already know. Spaces\nmirrors S3's authentication framework and requests to Spaces require a key pair\nsimilar to Amazon's Access ID and Secret Key.\n\nThe authentication requirement can be met by either setting the\n`SPACES_ACCESS_KEY_ID` and `SPACES_SECRET_ACCESS_KEY` environment variables or\nthe provider's `spaces_access_id` and `spaces_secret_key` arguments to the\naccess ID and secret you generate via the DigitalOcean control panel. For\nexample:\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst static_assets = new digitalocean.SpacesBucket(\"static-assets\", {});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nstatic_assets = digitalocean.SpacesBucket(\"static-assets\")\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var static_assets = new DigitalOcean.SpacesBucket(\"static-assets\");\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := digitalocean.NewSpacesBucket(ctx, \"static-assets\", nil)\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.digitalocean.SpacesBucket;\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 static_assets = new SpacesBucket(\"static-assets\");\n\n }\n}\n```\n```yaml\nresources:\n static-assets:\n type: digitalocean:SpacesBucket\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\nFor more information, See [An Introduction to DigitalOcean Spaces](https://www.digitalocean.com/community/tutorials/an-introduction-to-digitalocean-spaces)\n\n## Example Usage\n\n### Create a Key in a Spaces Bucket\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst foobar = new digitalocean.SpacesBucket(\"foobar\", {\n name: \"foobar\",\n region: digitalocean.Region.NYC3,\n});\nconst index = new digitalocean.SpacesBucketObject(\"index\", {\n region: foobar.region,\n bucket: foobar.name,\n key: \"index.html\",\n content: \"\u003chtml\u003e\u003cbody\u003e\u003cp\u003eThis page is empty.\u003c/p\u003e\u003c/body\u003e\u003c/html\u003e\",\n contentType: \"text/html\",\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nfoobar = digitalocean.SpacesBucket(\"foobar\",\n name=\"foobar\",\n region=digitalocean.Region.NYC3)\nindex = digitalocean.SpacesBucketObject(\"index\",\n region=foobar.region,\n bucket=foobar.name,\n key=\"index.html\",\n content=\"\u003chtml\u003e\u003cbody\u003e\u003cp\u003eThis page is empty.\u003c/p\u003e\u003c/body\u003e\u003c/html\u003e\",\n content_type=\"text/html\")\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var foobar = new DigitalOcean.SpacesBucket(\"foobar\", new()\n {\n Name = \"foobar\",\n Region = DigitalOcean.Region.NYC3,\n });\n\n var index = new DigitalOcean.SpacesBucketObject(\"index\", new()\n {\n Region = foobar.Region,\n Bucket = foobar.Name,\n Key = \"index.html\",\n Content = \"\u003chtml\u003e\u003cbody\u003e\u003cp\u003eThis page is empty.\u003c/p\u003e\u003c/body\u003e\u003c/html\u003e\",\n ContentType = \"text/html\",\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tfoobar, err := digitalocean.NewSpacesBucket(ctx, \"foobar\", \u0026digitalocean.SpacesBucketArgs{\n\t\t\tName: pulumi.String(\"foobar\"),\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC3),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = digitalocean.NewSpacesBucketObject(ctx, \"index\", \u0026digitalocean.SpacesBucketObjectArgs{\n\t\t\tRegion: foobar.Region,\n\t\t\tBucket: foobar.Name,\n\t\t\tKey: pulumi.String(\"index.html\"),\n\t\t\tContent: pulumi.String(\"\u003chtml\u003e\u003cbody\u003e\u003cp\u003eThis page is empty.\u003c/p\u003e\u003c/body\u003e\u003c/html\u003e\"),\n\t\t\tContentType: pulumi.String(\"text/html\"),\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.digitalocean.SpacesBucket;\nimport com.pulumi.digitalocean.SpacesBucketArgs;\nimport com.pulumi.digitalocean.SpacesBucketObject;\nimport com.pulumi.digitalocean.SpacesBucketObjectArgs;\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 foobar = new SpacesBucket(\"foobar\", SpacesBucketArgs.builder() \n .name(\"foobar\")\n .region(\"nyc3\")\n .build());\n\n var index = new SpacesBucketObject(\"index\", SpacesBucketObjectArgs.builder() \n .region(foobar.region())\n .bucket(foobar.name())\n .key(\"index.html\")\n .content(\"\u003chtml\u003e\u003cbody\u003e\u003cp\u003eThis page is empty.\u003c/p\u003e\u003c/body\u003e\u003c/html\u003e\")\n .contentType(\"text/html\")\n .build());\n\n }\n}\n```\n```yaml\nresources:\n foobar:\n type: digitalocean:SpacesBucket\n properties:\n name: foobar\n region: nyc3\n index:\n type: digitalocean:SpacesBucketObject\n properties:\n region: ${foobar.region}\n bucket: ${foobar.name}\n key: index.html\n content: \u003chtml\u003e\u003cbody\u003e\u003cp\u003eThis page is empty.\u003c/p\u003e\u003c/body\u003e\u003c/html\u003e\n contentType: text/html\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n## Import\n\nImporting this resource is not supported.\n\n", "properties": { "acl": { "type": "string", @@ -13613,7 +13613,7 @@ } }, "digitalocean:index/spacesBucketPolicy:SpacesBucketPolicy": { - "description": "## Example Usage\n\n### Limiting access to specific IP addresses\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst foobarSpacesBucket = new digitalocean.SpacesBucket(\"foobarSpacesBucket\", {region: digitalocean.Region.NYC3});\nconst foobarSpacesBucketPolicy = new digitalocean.SpacesBucketPolicy(\"foobarSpacesBucketPolicy\", {\n region: foobarSpacesBucket.region,\n bucket: foobarSpacesBucket.name,\n policy: pulumi.jsonStringify({\n Version: \"2012-10-17\",\n Statement: [{\n Sid: \"IPAllow\",\n Effect: \"Deny\",\n Principal: \"*\",\n Action: \"s3:*\",\n Resource: [\n pulumi.interpolate`arn:aws:s3:::${foobarSpacesBucket.name}`,\n pulumi.interpolate`arn:aws:s3:::${foobarSpacesBucket.name}/*`,\n ],\n Condition: {\n NotIpAddress: {\n \"aws:SourceIp\": \"54.240.143.0/24\",\n },\n },\n }],\n }),\n});\n```\n```python\nimport pulumi\nimport json\nimport pulumi_digitalocean as digitalocean\n\nfoobar_spaces_bucket = digitalocean.SpacesBucket(\"foobarSpacesBucket\", region=digitalocean.Region.NYC3)\nfoobar_spaces_bucket_policy = digitalocean.SpacesBucketPolicy(\"foobarSpacesBucketPolicy\",\n region=foobar_spaces_bucket.region,\n bucket=foobar_spaces_bucket.name,\n policy=pulumi.Output.json_dumps({\n \"Version\": \"2012-10-17\",\n \"Statement\": [{\n \"Sid\": \"IPAllow\",\n \"Effect\": \"Deny\",\n \"Principal\": \"*\",\n \"Action\": \"s3:*\",\n \"Resource\": [\n foobar_spaces_bucket.name.apply(lambda name: f\"arn:aws:s3:::{name}\"),\n foobar_spaces_bucket.name.apply(lambda name: f\"arn:aws:s3:::{name}/*\"),\n ],\n \"Condition\": {\n \"NotIpAddress\": {\n \"aws:SourceIp\": \"54.240.143.0/24\",\n },\n },\n }],\n }))\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing System.Text.Json;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var foobarSpacesBucket = new DigitalOcean.SpacesBucket(\"foobarSpacesBucket\", new()\n {\n Region = DigitalOcean.Region.NYC3,\n });\n\n var foobarSpacesBucketPolicy = new DigitalOcean.SpacesBucketPolicy(\"foobarSpacesBucketPolicy\", new()\n {\n Region = foobarSpacesBucket.Region,\n Bucket = foobarSpacesBucket.Name,\n Policy = Output.JsonSerialize(Output.Create(new Dictionary\u003cstring, object?\u003e\n {\n [\"Version\"] = \"2012-10-17\",\n [\"Statement\"] = new[]\n {\n new Dictionary\u003cstring, object?\u003e\n {\n [\"Sid\"] = \"IPAllow\",\n [\"Effect\"] = \"Deny\",\n [\"Principal\"] = \"*\",\n [\"Action\"] = \"s3:*\",\n [\"Resource\"] = new[]\n {\n foobarSpacesBucket.Name.Apply(name =\u003e $\"arn:aws:s3:::{name}\"),\n foobarSpacesBucket.Name.Apply(name =\u003e $\"arn:aws:s3:::{name}/*\"),\n },\n [\"Condition\"] = new Dictionary\u003cstring, object?\u003e\n {\n [\"NotIpAddress\"] = new Dictionary\u003cstring, object?\u003e\n {\n [\"aws:SourceIp\"] = \"54.240.143.0/24\",\n },\n },\n },\n },\n })),\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"encoding/json\"\n\t\"fmt\"\n\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tfoobarSpacesBucket, err := digitalocean.NewSpacesBucket(ctx, \"foobarSpacesBucket\", \u0026digitalocean.SpacesBucketArgs{\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC3),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = digitalocean.NewSpacesBucketPolicy(ctx, \"foobarSpacesBucketPolicy\", \u0026digitalocean.SpacesBucketPolicyArgs{\n\t\t\tRegion: foobarSpacesBucket.Region,\n\t\t\tBucket: foobarSpacesBucket.Name,\n\t\t\tPolicy: pulumi.All(foobarSpacesBucket.Name, foobarSpacesBucket.Name).ApplyT(func(_args []interface{}) (string, error) {\n\t\t\t\tfoobarSpacesBucketName := _args[0].(string)\n\t\t\t\tfoobarSpacesBucketName1 := _args[1].(string)\n\t\t\t\tvar _zero string\n\t\t\t\ttmpJSON0, err := json.Marshal(map[string]interface{}{\n\t\t\t\t\t\"Version\": \"2012-10-17\",\n\t\t\t\t\t\"Statement\": []map[string]interface{}{\n\t\t\t\t\t\tmap[string]interface{}{\n\t\t\t\t\t\t\t\"Sid\": \"IPAllow\",\n\t\t\t\t\t\t\t\"Effect\": \"Deny\",\n\t\t\t\t\t\t\t\"Principal\": \"*\",\n\t\t\t\t\t\t\t\"Action\": \"s3:*\",\n\t\t\t\t\t\t\t\"Resource\": []string{\n\t\t\t\t\t\t\t\tfmt.Sprintf(\"arn:aws:s3:::%v\", foobarSpacesBucketName),\n\t\t\t\t\t\t\t\tfmt.Sprintf(\"arn:aws:s3:::%v/*\", foobarSpacesBucketName1),\n\t\t\t\t\t\t\t},\n\t\t\t\t\t\t\t\"Condition\": map[string]interface{}{\n\t\t\t\t\t\t\t\t\"NotIpAddress\": map[string]interface{}{\n\t\t\t\t\t\t\t\t\t\"aws:SourceIp\": \"54.240.143.0/24\",\n\t\t\t\t\t\t\t\t},\n\t\t\t\t\t\t\t},\n\t\t\t\t\t\t},\n\t\t\t\t\t},\n\t\t\t\t})\n\t\t\t\tif err != nil {\n\t\t\t\t\treturn _zero, err\n\t\t\t\t}\n\t\t\t\tjson0 := string(tmpJSON0)\n\t\t\t\treturn json0, nil\n\t\t\t}).(pulumi.StringOutput),\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.digitalocean.SpacesBucket;\nimport com.pulumi.digitalocean.SpacesBucketArgs;\nimport com.pulumi.digitalocean.SpacesBucketPolicy;\nimport com.pulumi.digitalocean.SpacesBucketPolicyArgs;\nimport static com.pulumi.codegen.internal.Serialization.*;\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 foobarSpacesBucket = new SpacesBucket(\"foobarSpacesBucket\", SpacesBucketArgs.builder() \n .region(\"nyc3\")\n .build());\n\n var foobarSpacesBucketPolicy = new SpacesBucketPolicy(\"foobarSpacesBucketPolicy\", SpacesBucketPolicyArgs.builder() \n .region(foobarSpacesBucket.region())\n .bucket(foobarSpacesBucket.name())\n .policy(Output.tuple(foobarSpacesBucket.name(), foobarSpacesBucket.name()).applyValue(values -\u003e {\n var foobarSpacesBucketName = values.t1;\n var foobarSpacesBucketName1 = values.t2;\n return serializeJson(\n jsonObject(\n jsonProperty(\"Version\", \"2012-10-17\"),\n jsonProperty(\"Statement\", jsonArray(jsonObject(\n jsonProperty(\"Sid\", \"IPAllow\"),\n jsonProperty(\"Effect\", \"Deny\"),\n jsonProperty(\"Principal\", \"*\"),\n jsonProperty(\"Action\", \"s3:*\"),\n jsonProperty(\"Resource\", jsonArray(\n String.format(\"arn:aws:s3:::%s\", foobarSpacesBucketName), \n String.format(\"arn:aws:s3:::%s/*\", foobarSpacesBucketName1)\n )),\n jsonProperty(\"Condition\", jsonObject(\n jsonProperty(\"NotIpAddress\", jsonObject(\n jsonProperty(\"aws:SourceIp\", \"54.240.143.0/24\")\n ))\n ))\n )))\n ));\n }))\n .build());\n\n }\n}\n```\n```yaml\nresources:\n foobarSpacesBucket:\n type: digitalocean:SpacesBucket\n properties:\n region: nyc3\n foobarSpacesBucketPolicy:\n type: digitalocean:SpacesBucketPolicy\n properties:\n region: ${foobarSpacesBucket.region}\n bucket: ${foobarSpacesBucket.name}\n policy:\n fn::toJSON:\n Version: 2012-10-17\n Statement:\n - Sid: IPAllow\n Effect: Deny\n Principal: '*'\n Action: s3:*\n Resource:\n - arn:aws:s3:::${foobarSpacesBucket.name}\n - arn:aws:s3:::${foobarSpacesBucket.name}/*\n Condition:\n NotIpAddress:\n aws:SourceIp: 54.240.143.0/24\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n!\u003e **Warning:** Before using this policy, replace the 54.240.143.0/24 IP address range in this example with an appropriate value for your use case. Otherwise, you will lose the ability to access your bucket.\n\n## Import\n\nBucket policies can be imported using the `region` and `bucket` attributes (delimited by a comma):\n\n```sh\n$ pulumi import digitalocean:index/spacesBucketPolicy:SpacesBucketPolicy foobar `region`,`bucket`\n```\n\n", + "description": "## Example Usage\n\n### Limiting access to specific IP addresses\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst foobar = new digitalocean.SpacesBucket(\"foobar\", {\n name: \"foobar\",\n region: digitalocean.Region.NYC3,\n});\nconst foobarSpacesBucketPolicy = new digitalocean.SpacesBucketPolicy(\"foobar\", {\n region: foobar.region,\n bucket: foobar.name,\n policy: pulumi.jsonStringify({\n Version: \"2012-10-17\",\n Statement: [{\n Sid: \"IPAllow\",\n Effect: \"Deny\",\n Principal: \"*\",\n Action: \"s3:*\",\n Resource: [\n pulumi.interpolate`arn:aws:s3:::${foobar.name}`,\n pulumi.interpolate`arn:aws:s3:::${foobar.name}/*`,\n ],\n Condition: {\n NotIpAddress: {\n \"aws:SourceIp\": \"54.240.143.0/24\",\n },\n },\n }],\n }),\n});\n```\n```python\nimport pulumi\nimport json\nimport pulumi_digitalocean as digitalocean\n\nfoobar = digitalocean.SpacesBucket(\"foobar\",\n name=\"foobar\",\n region=digitalocean.Region.NYC3)\nfoobar_spaces_bucket_policy = digitalocean.SpacesBucketPolicy(\"foobar\",\n region=foobar.region,\n bucket=foobar.name,\n policy=pulumi.Output.json_dumps({\n \"Version\": \"2012-10-17\",\n \"Statement\": [{\n \"Sid\": \"IPAllow\",\n \"Effect\": \"Deny\",\n \"Principal\": \"*\",\n \"Action\": \"s3:*\",\n \"Resource\": [\n foobar.name.apply(lambda name: f\"arn:aws:s3:::{name}\"),\n foobar.name.apply(lambda name: f\"arn:aws:s3:::{name}/*\"),\n ],\n \"Condition\": {\n \"NotIpAddress\": {\n \"aws:SourceIp\": \"54.240.143.0/24\",\n },\n },\n }],\n }))\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing System.Text.Json;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var foobar = new DigitalOcean.SpacesBucket(\"foobar\", new()\n {\n Name = \"foobar\",\n Region = DigitalOcean.Region.NYC3,\n });\n\n var foobarSpacesBucketPolicy = new DigitalOcean.SpacesBucketPolicy(\"foobar\", new()\n {\n Region = foobar.Region,\n Bucket = foobar.Name,\n Policy = Output.JsonSerialize(Output.Create(new Dictionary\u003cstring, object?\u003e\n {\n [\"Version\"] = \"2012-10-17\",\n [\"Statement\"] = new[]\n {\n new Dictionary\u003cstring, object?\u003e\n {\n [\"Sid\"] = \"IPAllow\",\n [\"Effect\"] = \"Deny\",\n [\"Principal\"] = \"*\",\n [\"Action\"] = \"s3:*\",\n [\"Resource\"] = new[]\n {\n foobar.Name.Apply(name =\u003e $\"arn:aws:s3:::{name}\"),\n foobar.Name.Apply(name =\u003e $\"arn:aws:s3:::{name}/*\"),\n },\n [\"Condition\"] = new Dictionary\u003cstring, object?\u003e\n {\n [\"NotIpAddress\"] = new Dictionary\u003cstring, object?\u003e\n {\n [\"aws:SourceIp\"] = \"54.240.143.0/24\",\n },\n },\n },\n },\n })),\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"encoding/json\"\n\t\"fmt\"\n\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tfoobar, err := digitalocean.NewSpacesBucket(ctx, \"foobar\", \u0026digitalocean.SpacesBucketArgs{\n\t\t\tName: pulumi.String(\"foobar\"),\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC3),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = digitalocean.NewSpacesBucketPolicy(ctx, \"foobar\", \u0026digitalocean.SpacesBucketPolicyArgs{\n\t\t\tRegion: foobar.Region,\n\t\t\tBucket: foobar.Name,\n\t\t\tPolicy: pulumi.All(foobar.Name, foobar.Name).ApplyT(func(_args []interface{}) (string, error) {\n\t\t\t\tfoobarName := _args[0].(string)\n\t\t\t\tfoobarName1 := _args[1].(string)\n\t\t\t\tvar _zero string\n\t\t\t\ttmpJSON0, err := json.Marshal(map[string]interface{}{\n\t\t\t\t\t\"Version\": \"2012-10-17\",\n\t\t\t\t\t\"Statement\": []map[string]interface{}{\n\t\t\t\t\t\tmap[string]interface{}{\n\t\t\t\t\t\t\t\"Sid\": \"IPAllow\",\n\t\t\t\t\t\t\t\"Effect\": \"Deny\",\n\t\t\t\t\t\t\t\"Principal\": \"*\",\n\t\t\t\t\t\t\t\"Action\": \"s3:*\",\n\t\t\t\t\t\t\t\"Resource\": []string{\n\t\t\t\t\t\t\t\tfmt.Sprintf(\"arn:aws:s3:::%v\", foobarName),\n\t\t\t\t\t\t\t\tfmt.Sprintf(\"arn:aws:s3:::%v/*\", foobarName1),\n\t\t\t\t\t\t\t},\n\t\t\t\t\t\t\t\"Condition\": map[string]interface{}{\n\t\t\t\t\t\t\t\t\"NotIpAddress\": map[string]interface{}{\n\t\t\t\t\t\t\t\t\t\"aws:SourceIp\": \"54.240.143.0/24\",\n\t\t\t\t\t\t\t\t},\n\t\t\t\t\t\t\t},\n\t\t\t\t\t\t},\n\t\t\t\t\t},\n\t\t\t\t})\n\t\t\t\tif err != nil {\n\t\t\t\t\treturn _zero, err\n\t\t\t\t}\n\t\t\t\tjson0 := string(tmpJSON0)\n\t\t\t\treturn json0, nil\n\t\t\t}).(pulumi.StringOutput),\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.digitalocean.SpacesBucket;\nimport com.pulumi.digitalocean.SpacesBucketArgs;\nimport com.pulumi.digitalocean.SpacesBucketPolicy;\nimport com.pulumi.digitalocean.SpacesBucketPolicyArgs;\nimport static com.pulumi.codegen.internal.Serialization.*;\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 foobar = new SpacesBucket(\"foobar\", SpacesBucketArgs.builder() \n .name(\"foobar\")\n .region(\"nyc3\")\n .build());\n\n var foobarSpacesBucketPolicy = new SpacesBucketPolicy(\"foobarSpacesBucketPolicy\", SpacesBucketPolicyArgs.builder() \n .region(foobar.region())\n .bucket(foobar.name())\n .policy(Output.tuple(foobar.name(), foobar.name()).applyValue(values -\u003e {\n var foobarName = values.t1;\n var foobarName1 = values.t2;\n return serializeJson(\n jsonObject(\n jsonProperty(\"Version\", \"2012-10-17\"),\n jsonProperty(\"Statement\", jsonArray(jsonObject(\n jsonProperty(\"Sid\", \"IPAllow\"),\n jsonProperty(\"Effect\", \"Deny\"),\n jsonProperty(\"Principal\", \"*\"),\n jsonProperty(\"Action\", \"s3:*\"),\n jsonProperty(\"Resource\", jsonArray(\n String.format(\"arn:aws:s3:::%s\", foobarName), \n String.format(\"arn:aws:s3:::%s/*\", foobarName1)\n )),\n jsonProperty(\"Condition\", jsonObject(\n jsonProperty(\"NotIpAddress\", jsonObject(\n jsonProperty(\"aws:SourceIp\", \"54.240.143.0/24\")\n ))\n ))\n )))\n ));\n }))\n .build());\n\n }\n}\n```\n```yaml\nresources:\n foobar:\n type: digitalocean:SpacesBucket\n properties:\n name: foobar\n region: nyc3\n foobarSpacesBucketPolicy:\n type: digitalocean:SpacesBucketPolicy\n name: foobar\n properties:\n region: ${foobar.region}\n bucket: ${foobar.name}\n policy:\n fn::toJSON:\n Version: 2012-10-17\n Statement:\n - Sid: IPAllow\n Effect: Deny\n Principal: '*'\n Action: s3:*\n Resource:\n - arn:aws:s3:::${foobar.name}\n - arn:aws:s3:::${foobar.name}/*\n Condition:\n NotIpAddress:\n aws:SourceIp: 54.240.143.0/24\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n!\u003e **Warning:** Before using this policy, replace the 54.240.143.0/24 IP address range in this example with an appropriate value for your use case. Otherwise, you will lose the ability to access your bucket.\n\n## Import\n\nBucket policies can be imported using the `region` and `bucket` attributes (delimited by a comma):\n\n```sh\n$ pulumi import digitalocean:index/spacesBucketPolicy:SpacesBucketPolicy foobar `region`,`bucket`\n```\n\n", "properties": { "bucket": { "type": "string", @@ -13676,7 +13676,7 @@ } }, "digitalocean:index/sshKey:SshKey": { - "description": "Provides a DigitalOcean SSH key resource to allow you to manage SSH\nkeys for Droplet access. Keys created with this resource\ncan be referenced in your Droplet configuration via their ID or\nfingerprint.\n\n## Example Usage\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\nimport * as fs from \"fs\";\n\n// Create a new SSH key\nconst _default = new digitalocean.SshKey(\"default\", {publicKey: fs.readFileSync(\"/Users/myuser/.ssh/id_rsa.pub\", \"utf8\")});\n// Create a new Droplet using the SSH key\nconst web = new digitalocean.Droplet(\"web\", {\n image: \"ubuntu-18-04-x64\",\n region: digitalocean.Region.NYC3,\n size: digitalocean.DropletSlug.DropletS1VCPU1GB,\n sshKeys: [_default.fingerprint],\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\n# Create a new SSH key\ndefault = digitalocean.SshKey(\"default\", public_key=(lambda path: open(path).read())(\"/Users/myuser/.ssh/id_rsa.pub\"))\n# Create a new Droplet using the SSH key\nweb = digitalocean.Droplet(\"web\",\n image=\"ubuntu-18-04-x64\",\n region=digitalocean.Region.NYC3,\n size=digitalocean.DropletSlug.DROPLET_S1_VCPU1_GB,\n ssh_keys=[default.fingerprint])\n```\n```csharp\nusing System.Collections.Generic;\nusing System.IO;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n // Create a new SSH key\n var @default = new DigitalOcean.SshKey(\"default\", new()\n {\n PublicKey = File.ReadAllText(\"/Users/myuser/.ssh/id_rsa.pub\"),\n });\n\n // Create a new Droplet using the SSH key\n var web = new DigitalOcean.Droplet(\"web\", new()\n {\n Image = \"ubuntu-18-04-x64\",\n Region = DigitalOcean.Region.NYC3,\n Size = DigitalOcean.DropletSlug.DropletS1VCPU1GB,\n SshKeys = new[]\n {\n @default.Fingerprint,\n },\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"os\"\n\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc readFileOrPanic(path string) pulumi.StringPtrInput {\n\tdata, err := os.ReadFile(path)\n\tif err != nil {\n\t\tpanic(err.Error())\n\t}\n\treturn pulumi.String(string(data))\n}\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t// Create a new SSH key\n\t\t_, err := digitalocean.NewSshKey(ctx, \"default\", \u0026digitalocean.SshKeyArgs{\n\t\t\tPublicKey: readFileOrPanic(\"/Users/myuser/.ssh/id_rsa.pub\"),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t// Create a new Droplet using the SSH key\n\t\t_, err = digitalocean.NewDroplet(ctx, \"web\", \u0026digitalocean.DropletArgs{\n\t\t\tImage: pulumi.String(\"ubuntu-18-04-x64\"),\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC3),\n\t\t\tSize: pulumi.String(digitalocean.DropletSlugDropletS1VCPU1GB),\n\t\t\tSshKeys: pulumi.StringArray{\n\t\t\t\t_default.Fingerprint,\n\t\t\t},\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.digitalocean.SshKey;\nimport com.pulumi.digitalocean.SshKeyArgs;\nimport com.pulumi.digitalocean.Droplet;\nimport com.pulumi.digitalocean.DropletArgs;\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 // Create a new SSH key\n var default_ = new SshKey(\"default\", SshKeyArgs.builder() \n .publicKey(Files.readString(Paths.get(\"/Users/myuser/.ssh/id_rsa.pub\")))\n .build());\n\n // Create a new Droplet using the SSH key\n var web = new Droplet(\"web\", DropletArgs.builder() \n .image(\"ubuntu-18-04-x64\")\n .region(\"nyc3\")\n .size(\"s-1vcpu-1gb\")\n .sshKeys(default_.fingerprint())\n .build());\n\n }\n}\n```\n```yaml\nresources:\n # Create a new SSH key\n default:\n type: digitalocean:SshKey\n properties:\n publicKey:\n fn::readFile: /Users/myuser/.ssh/id_rsa.pub\n # Create a new Droplet using the SSH key\n web:\n type: digitalocean:Droplet\n properties:\n image: ubuntu-18-04-x64\n region: nyc3\n size: s-1vcpu-1gb\n sshKeys:\n - ${default.fingerprint}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n## Import\n\nSSH Keys can be imported using the `ssh key id`, e.g.\n\n```sh\n$ pulumi import digitalocean:index/sshKey:SshKey mykey 263654\n```\n\n", + "description": "Provides a DigitalOcean SSH key resource to allow you to manage SSH\nkeys for Droplet access. Keys created with this resource\ncan be referenced in your Droplet configuration via their ID or\nfingerprint.\n\n## Example Usage\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\nimport * as std from \"@pulumi/std\";\n\n// Create a new SSH key\nconst _default = new digitalocean.SshKey(\"default\", {\n name: \"Example\",\n publicKey: std.file({\n input: \"/Users/myuser/.ssh/id_rsa.pub\",\n }).then(invoke =\u003e invoke.result),\n});\n// Create a new Droplet using the SSH key\nconst web = new digitalocean.Droplet(\"web\", {\n image: \"ubuntu-18-04-x64\",\n name: \"web-1\",\n region: digitalocean.Region.NYC3,\n size: digitalocean.DropletSlug.DropletS1VCPU1GB,\n sshKeys: [_default.fingerprint],\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\nimport pulumi_std as std\n\n# Create a new SSH key\ndefault = digitalocean.SshKey(\"default\",\n name=\"Example\",\n public_key=std.file(input=\"/Users/myuser/.ssh/id_rsa.pub\").result)\n# Create a new Droplet using the SSH key\nweb = digitalocean.Droplet(\"web\",\n image=\"ubuntu-18-04-x64\",\n name=\"web-1\",\n region=digitalocean.Region.NYC3,\n size=digitalocean.DropletSlug.DROPLET_S1_VCPU1_GB,\n ssh_keys=[default.fingerprint])\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\nusing Std = Pulumi.Std;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n // Create a new SSH key\n var @default = new DigitalOcean.SshKey(\"default\", new()\n {\n Name = \"Example\",\n PublicKey = Std.File.Invoke(new()\n {\n Input = \"/Users/myuser/.ssh/id_rsa.pub\",\n }).Apply(invoke =\u003e invoke.Result),\n });\n\n // Create a new Droplet using the SSH key\n var web = new DigitalOcean.Droplet(\"web\", new()\n {\n Image = \"ubuntu-18-04-x64\",\n Name = \"web-1\",\n Region = DigitalOcean.Region.NYC3,\n Size = DigitalOcean.DropletSlug.DropletS1VCPU1GB,\n SshKeys = new[]\n {\n @default.Fingerprint,\n },\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi-std/sdk/go/std\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tinvokeFile, err := std.File(ctx, \u0026std.FileArgs{\n\t\t\tInput: \"/Users/myuser/.ssh/id_rsa.pub\",\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t// Create a new SSH key\n\t\t_, err = digitalocean.NewSshKey(ctx, \"default\", \u0026digitalocean.SshKeyArgs{\n\t\t\tName: pulumi.String(\"Example\"),\n\t\t\tPublicKey: invokeFile.Result,\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t// Create a new Droplet using the SSH key\n\t\t_, err = digitalocean.NewDroplet(ctx, \"web\", \u0026digitalocean.DropletArgs{\n\t\t\tImage: pulumi.String(\"ubuntu-18-04-x64\"),\n\t\t\tName: pulumi.String(\"web-1\"),\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC3),\n\t\t\tSize: pulumi.String(digitalocean.DropletSlugDropletS1VCPU1GB),\n\t\t\tSshKeys: pulumi.StringArray{\n\t\t\t\t_default.Fingerprint,\n\t\t\t},\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.digitalocean.SshKey;\nimport com.pulumi.digitalocean.SshKeyArgs;\nimport com.pulumi.digitalocean.Droplet;\nimport com.pulumi.digitalocean.DropletArgs;\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 // Create a new SSH key\n var default_ = new SshKey(\"default\", SshKeyArgs.builder() \n .name(\"Example\")\n .publicKey(StdFunctions.file(FileArgs.builder()\n .input(\"/Users/myuser/.ssh/id_rsa.pub\")\n .build()).result())\n .build());\n\n // Create a new Droplet using the SSH key\n var web = new Droplet(\"web\", DropletArgs.builder() \n .image(\"ubuntu-18-04-x64\")\n .name(\"web-1\")\n .region(\"nyc3\")\n .size(\"s-1vcpu-1gb\")\n .sshKeys(default_.fingerprint())\n .build());\n\n }\n}\n```\n```yaml\nresources:\n # Create a new SSH key\n default:\n type: digitalocean:SshKey\n properties:\n name: Example\n publicKey:\n fn::invoke:\n Function: std:file\n Arguments:\n input: /Users/myuser/.ssh/id_rsa.pub\n Return: result\n # Create a new Droplet using the SSH key\n web:\n type: digitalocean:Droplet\n properties:\n image: ubuntu-18-04-x64\n name: web-1\n region: nyc3\n size: s-1vcpu-1gb\n sshKeys:\n - ${default.fingerprint}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n## Import\n\nSSH Keys can be imported using the `ssh key id`, e.g.\n\n```sh\n$ pulumi import digitalocean:index/sshKey:SshKey mykey 263654\n```\n\n", "properties": { "fingerprint": { "type": "string", @@ -13731,7 +13731,7 @@ } }, "digitalocean:index/tag:Tag": { - "description": "Provides a DigitalOcean Tag resource. A Tag is a label that can be applied to a\nDroplet resource in order to better organize or facilitate the lookups and\nactions on it. Tags created with this resource can be referenced in your Droplet\nconfiguration via their ID or name.\n\n## Example Usage\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\n// Create a new tag\nconst foobar = new digitalocean.Tag(\"foobar\", {});\n// Create a new Droplet in nyc3 with the foobar tag\nconst web = new digitalocean.Droplet(\"web\", {\n image: \"ubuntu-18-04-x64\",\n region: digitalocean.Region.NYC3,\n size: digitalocean.DropletSlug.DropletS1VCPU1GB,\n tags: [foobar.id],\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\n# Create a new tag\nfoobar = digitalocean.Tag(\"foobar\")\n# Create a new Droplet in nyc3 with the foobar tag\nweb = digitalocean.Droplet(\"web\",\n image=\"ubuntu-18-04-x64\",\n region=digitalocean.Region.NYC3,\n size=digitalocean.DropletSlug.DROPLET_S1_VCPU1_GB,\n tags=[foobar.id])\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n // Create a new tag\n var foobar = new DigitalOcean.Tag(\"foobar\");\n\n // Create a new Droplet in nyc3 with the foobar tag\n var web = new DigitalOcean.Droplet(\"web\", new()\n {\n Image = \"ubuntu-18-04-x64\",\n Region = DigitalOcean.Region.NYC3,\n Size = DigitalOcean.DropletSlug.DropletS1VCPU1GB,\n Tags = new[]\n {\n foobar.Id,\n },\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t// Create a new tag\n\t\tfoobar, err := digitalocean.NewTag(ctx, \"foobar\", nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t// Create a new Droplet in nyc3 with the foobar tag\n\t\t_, err = digitalocean.NewDroplet(ctx, \"web\", \u0026digitalocean.DropletArgs{\n\t\t\tImage: pulumi.String(\"ubuntu-18-04-x64\"),\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC3),\n\t\t\tSize: pulumi.String(digitalocean.DropletSlugDropletS1VCPU1GB),\n\t\t\tTags: pulumi.StringArray{\n\t\t\t\tfoobar.ID(),\n\t\t\t},\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.digitalocean.Tag;\nimport com.pulumi.digitalocean.Droplet;\nimport com.pulumi.digitalocean.DropletArgs;\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 // Create a new tag\n var foobar = new Tag(\"foobar\");\n\n // Create a new Droplet in nyc3 with the foobar tag\n var web = new Droplet(\"web\", DropletArgs.builder() \n .image(\"ubuntu-18-04-x64\")\n .region(\"nyc3\")\n .size(\"s-1vcpu-1gb\")\n .tags(foobar.id())\n .build());\n\n }\n}\n```\n```yaml\nresources:\n # Create a new tag\n foobar:\n type: digitalocean:Tag\n # Create a new Droplet in nyc3 with the foobar tag\n web:\n type: digitalocean:Droplet\n properties:\n image: ubuntu-18-04-x64\n region: nyc3\n size: s-1vcpu-1gb\n tags:\n - ${foobar.id}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n## Import\n\nTags can be imported using the `name`, e.g.\n\n```sh\n$ pulumi import digitalocean:index/tag:Tag mytag tagname\n```\n\n", + "description": "Provides a DigitalOcean Tag resource. A Tag is a label that can be applied to a\nDroplet resource in order to better organize or facilitate the lookups and\nactions on it. Tags created with this resource can be referenced in your Droplet\nconfiguration via their ID or name.\n\n## Example Usage\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\n// Create a new tag\nconst foobar = new digitalocean.Tag(\"foobar\", {name: \"foobar\"});\n// Create a new Droplet in nyc3 with the foobar tag\nconst web = new digitalocean.Droplet(\"web\", {\n image: \"ubuntu-18-04-x64\",\n name: \"web-1\",\n region: digitalocean.Region.NYC3,\n size: digitalocean.DropletSlug.DropletS1VCPU1GB,\n tags: [foobar.id],\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\n# Create a new tag\nfoobar = digitalocean.Tag(\"foobar\", name=\"foobar\")\n# Create a new Droplet in nyc3 with the foobar tag\nweb = digitalocean.Droplet(\"web\",\n image=\"ubuntu-18-04-x64\",\n name=\"web-1\",\n region=digitalocean.Region.NYC3,\n size=digitalocean.DropletSlug.DROPLET_S1_VCPU1_GB,\n tags=[foobar.id])\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n // Create a new tag\n var foobar = new DigitalOcean.Tag(\"foobar\", new()\n {\n Name = \"foobar\",\n });\n\n // Create a new Droplet in nyc3 with the foobar tag\n var web = new DigitalOcean.Droplet(\"web\", new()\n {\n Image = \"ubuntu-18-04-x64\",\n Name = \"web-1\",\n Region = DigitalOcean.Region.NYC3,\n Size = DigitalOcean.DropletSlug.DropletS1VCPU1GB,\n Tags = new[]\n {\n foobar.Id,\n },\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t// Create a new tag\n\t\tfoobar, err := digitalocean.NewTag(ctx, \"foobar\", \u0026digitalocean.TagArgs{\n\t\t\tName: pulumi.String(\"foobar\"),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t// Create a new Droplet in nyc3 with the foobar tag\n\t\t_, err = digitalocean.NewDroplet(ctx, \"web\", \u0026digitalocean.DropletArgs{\n\t\t\tImage: pulumi.String(\"ubuntu-18-04-x64\"),\n\t\t\tName: pulumi.String(\"web-1\"),\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC3),\n\t\t\tSize: pulumi.String(digitalocean.DropletSlugDropletS1VCPU1GB),\n\t\t\tTags: pulumi.StringArray{\n\t\t\t\tfoobar.ID(),\n\t\t\t},\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.digitalocean.Tag;\nimport com.pulumi.digitalocean.TagArgs;\nimport com.pulumi.digitalocean.Droplet;\nimport com.pulumi.digitalocean.DropletArgs;\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 // Create a new tag\n var foobar = new Tag(\"foobar\", TagArgs.builder() \n .name(\"foobar\")\n .build());\n\n // Create a new Droplet in nyc3 with the foobar tag\n var web = new Droplet(\"web\", DropletArgs.builder() \n .image(\"ubuntu-18-04-x64\")\n .name(\"web-1\")\n .region(\"nyc3\")\n .size(\"s-1vcpu-1gb\")\n .tags(foobar.id())\n .build());\n\n }\n}\n```\n```yaml\nresources:\n # Create a new tag\n foobar:\n type: digitalocean:Tag\n properties:\n name: foobar\n # Create a new Droplet in nyc3 with the foobar tag\n web:\n type: digitalocean:Droplet\n properties:\n image: ubuntu-18-04-x64\n name: web-1\n region: nyc3\n size: s-1vcpu-1gb\n tags:\n - ${foobar.id}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n## Import\n\nTags can be imported using the `name`, e.g.\n\n```sh\n$ pulumi import digitalocean:index/tag:Tag mytag tagname\n```\n\n", "properties": { "databasesCount": { "type": "integer", @@ -14021,7 +14021,7 @@ } }, "digitalocean:index/volume:Volume": { - "description": "Provides a DigitalOcean Block Storage volume which can be attached to a Droplet in order to provide expanded storage.\n\n## Example Usage\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst foobarVolume = new digitalocean.Volume(\"foobarVolume\", {\n region: digitalocean.Region.NYC1,\n size: 100,\n initialFilesystemType: digitalocean.FileSystemType.EXT4,\n description: \"an example volume\",\n});\nconst foobarDroplet = new digitalocean.Droplet(\"foobarDroplet\", {\n size: digitalocean.DropletSlug.DropletS1VCPU1GB,\n image: \"ubuntu-18-04-x64\",\n region: digitalocean.Region.NYC1,\n});\nconst foobarVolumeAttachment = new digitalocean.VolumeAttachment(\"foobarVolumeAttachment\", {\n dropletId: foobarDroplet.id,\n volumeId: foobarVolume.id,\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nfoobar_volume = digitalocean.Volume(\"foobarVolume\",\n region=digitalocean.Region.NYC1,\n size=100,\n initial_filesystem_type=digitalocean.FileSystemType.EXT4,\n description=\"an example volume\")\nfoobar_droplet = digitalocean.Droplet(\"foobarDroplet\",\n size=digitalocean.DropletSlug.DROPLET_S1_VCPU1_GB,\n image=\"ubuntu-18-04-x64\",\n region=digitalocean.Region.NYC1)\nfoobar_volume_attachment = digitalocean.VolumeAttachment(\"foobarVolumeAttachment\",\n droplet_id=foobar_droplet.id,\n volume_id=foobar_volume.id)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var foobarVolume = new DigitalOcean.Volume(\"foobarVolume\", new()\n {\n Region = DigitalOcean.Region.NYC1,\n Size = 100,\n InitialFilesystemType = DigitalOcean.FileSystemType.EXT4,\n Description = \"an example volume\",\n });\n\n var foobarDroplet = new DigitalOcean.Droplet(\"foobarDroplet\", new()\n {\n Size = DigitalOcean.DropletSlug.DropletS1VCPU1GB,\n Image = \"ubuntu-18-04-x64\",\n Region = DigitalOcean.Region.NYC1,\n });\n\n var foobarVolumeAttachment = new DigitalOcean.VolumeAttachment(\"foobarVolumeAttachment\", new()\n {\n DropletId = foobarDroplet.Id,\n VolumeId = foobarVolume.Id,\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tfoobarVolume, err := digitalocean.NewVolume(ctx, \"foobarVolume\", \u0026digitalocean.VolumeArgs{\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC1),\n\t\t\tSize: pulumi.Int(100),\n\t\t\tInitialFilesystemType: pulumi.String(digitalocean.FileSystemTypeEXT4),\n\t\t\tDescription: pulumi.String(\"an example volume\"),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tfoobarDroplet, err := digitalocean.NewDroplet(ctx, \"foobarDroplet\", \u0026digitalocean.DropletArgs{\n\t\t\tSize: pulumi.String(digitalocean.DropletSlugDropletS1VCPU1GB),\n\t\t\tImage: pulumi.String(\"ubuntu-18-04-x64\"),\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC1),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = digitalocean.NewVolumeAttachment(ctx, \"foobarVolumeAttachment\", \u0026digitalocean.VolumeAttachmentArgs{\n\t\t\tDropletId: foobarDroplet.ID(),\n\t\t\tVolumeId: foobarVolume.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.digitalocean.Volume;\nimport com.pulumi.digitalocean.VolumeArgs;\nimport com.pulumi.digitalocean.Droplet;\nimport com.pulumi.digitalocean.DropletArgs;\nimport com.pulumi.digitalocean.VolumeAttachment;\nimport com.pulumi.digitalocean.VolumeAttachmentArgs;\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 foobarVolume = new Volume(\"foobarVolume\", VolumeArgs.builder() \n .region(\"nyc1\")\n .size(100)\n .initialFilesystemType(\"ext4\")\n .description(\"an example volume\")\n .build());\n\n var foobarDroplet = new Droplet(\"foobarDroplet\", DropletArgs.builder() \n .size(\"s-1vcpu-1gb\")\n .image(\"ubuntu-18-04-x64\")\n .region(\"nyc1\")\n .build());\n\n var foobarVolumeAttachment = new VolumeAttachment(\"foobarVolumeAttachment\", VolumeAttachmentArgs.builder() \n .dropletId(foobarDroplet.id())\n .volumeId(foobarVolume.id())\n .build());\n\n }\n}\n```\n```yaml\nresources:\n foobarVolume:\n type: digitalocean:Volume\n properties:\n region: nyc1\n size: 100\n initialFilesystemType: ext4\n description: an example volume\n foobarDroplet:\n type: digitalocean:Droplet\n properties:\n size: s-1vcpu-1gb\n image: ubuntu-18-04-x64\n region: nyc1\n foobarVolumeAttachment:\n type: digitalocean:VolumeAttachment\n properties:\n dropletId: ${foobarDroplet.id}\n volumeId: ${foobarVolume.id}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\nYou can also create a volume from an existing snapshot.\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst foobarVolumeSnapshot = digitalocean.getVolumeSnapshot({\n name: \"baz\",\n});\nconst foobarVolume = new digitalocean.Volume(\"foobarVolume\", {\n region: digitalocean.Region.LON1,\n size: foobarVolumeSnapshot.then(foobarVolumeSnapshot =\u003e foobarVolumeSnapshot.minDiskSize),\n snapshotId: foobarVolumeSnapshot.then(foobarVolumeSnapshot =\u003e foobarVolumeSnapshot.id),\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nfoobar_volume_snapshot = digitalocean.get_volume_snapshot(name=\"baz\")\nfoobar_volume = digitalocean.Volume(\"foobarVolume\",\n region=digitalocean.Region.LON1,\n size=foobar_volume_snapshot.min_disk_size,\n snapshot_id=foobar_volume_snapshot.id)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var foobarVolumeSnapshot = DigitalOcean.GetVolumeSnapshot.Invoke(new()\n {\n Name = \"baz\",\n });\n\n var foobarVolume = new DigitalOcean.Volume(\"foobarVolume\", new()\n {\n Region = DigitalOcean.Region.LON1,\n Size = foobarVolumeSnapshot.Apply(getVolumeSnapshotResult =\u003e getVolumeSnapshotResult.MinDiskSize),\n SnapshotId = foobarVolumeSnapshot.Apply(getVolumeSnapshotResult =\u003e getVolumeSnapshotResult.Id),\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tfoobarVolumeSnapshot, err := digitalocean.LookupVolumeSnapshot(ctx, \u0026digitalocean.LookupVolumeSnapshotArgs{\n\t\t\tName: pulumi.StringRef(\"baz\"),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = digitalocean.NewVolume(ctx, \"foobarVolume\", \u0026digitalocean.VolumeArgs{\n\t\t\tRegion: pulumi.String(digitalocean.RegionLON1),\n\t\t\tSize: pulumi.Int(foobarVolumeSnapshot.MinDiskSize),\n\t\t\tSnapshotId: pulumi.String(foobarVolumeSnapshot.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.digitalocean.DigitaloceanFunctions;\nimport com.pulumi.digitalocean.inputs.GetVolumeSnapshotArgs;\nimport com.pulumi.digitalocean.Volume;\nimport com.pulumi.digitalocean.VolumeArgs;\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 final var foobarVolumeSnapshot = DigitaloceanFunctions.getVolumeSnapshot(GetVolumeSnapshotArgs.builder()\n .name(\"baz\")\n .build());\n\n var foobarVolume = new Volume(\"foobarVolume\", VolumeArgs.builder() \n .region(\"lon1\")\n .size(foobarVolumeSnapshot.applyValue(getVolumeSnapshotResult -\u003e getVolumeSnapshotResult.minDiskSize()))\n .snapshotId(foobarVolumeSnapshot.applyValue(getVolumeSnapshotResult -\u003e getVolumeSnapshotResult.id()))\n .build());\n\n }\n}\n```\n```yaml\nresources:\n foobarVolume:\n type: digitalocean:Volume\n properties:\n region: lon1\n size: ${foobarVolumeSnapshot.minDiskSize}\n snapshotId: ${foobarVolumeSnapshot.id}\nvariables:\n foobarVolumeSnapshot:\n fn::invoke:\n Function: digitalocean:getVolumeSnapshot\n Arguments:\n name: baz\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n## Import\n\nVolumes can be imported using the `volume id`, e.g.\n\n```sh\n$ pulumi import digitalocean:index/volume:Volume volume 506f78a4-e098-11e5-ad9f-000f53306ae1\n```\n\n", + "description": "Provides a DigitalOcean Block Storage volume which can be attached to a Droplet in order to provide expanded storage.\n\n## Example Usage\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst foobar = new digitalocean.Volume(\"foobar\", {\n region: digitalocean.Region.NYC1,\n name: \"baz\",\n size: 100,\n initialFilesystemType: digitalocean.FileSystemType.EXT4,\n description: \"an example volume\",\n});\nconst foobarDroplet = new digitalocean.Droplet(\"foobar\", {\n name: \"baz\",\n size: digitalocean.DropletSlug.DropletS1VCPU1GB,\n image: \"ubuntu-18-04-x64\",\n region: digitalocean.Region.NYC1,\n});\nconst foobarVolumeAttachment = new digitalocean.VolumeAttachment(\"foobar\", {\n dropletId: foobarDroplet.id,\n volumeId: foobar.id,\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nfoobar = digitalocean.Volume(\"foobar\",\n region=digitalocean.Region.NYC1,\n name=\"baz\",\n size=100,\n initial_filesystem_type=digitalocean.FileSystemType.EXT4,\n description=\"an example volume\")\nfoobar_droplet = digitalocean.Droplet(\"foobar\",\n name=\"baz\",\n size=digitalocean.DropletSlug.DROPLET_S1_VCPU1_GB,\n image=\"ubuntu-18-04-x64\",\n region=digitalocean.Region.NYC1)\nfoobar_volume_attachment = digitalocean.VolumeAttachment(\"foobar\",\n droplet_id=foobar_droplet.id,\n volume_id=foobar.id)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var foobar = new DigitalOcean.Volume(\"foobar\", new()\n {\n Region = DigitalOcean.Region.NYC1,\n Name = \"baz\",\n Size = 100,\n InitialFilesystemType = DigitalOcean.FileSystemType.EXT4,\n Description = \"an example volume\",\n });\n\n var foobarDroplet = new DigitalOcean.Droplet(\"foobar\", new()\n {\n Name = \"baz\",\n Size = DigitalOcean.DropletSlug.DropletS1VCPU1GB,\n Image = \"ubuntu-18-04-x64\",\n Region = DigitalOcean.Region.NYC1,\n });\n\n var foobarVolumeAttachment = new DigitalOcean.VolumeAttachment(\"foobar\", new()\n {\n DropletId = foobarDroplet.Id,\n VolumeId = foobar.Id,\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tfoobar, err := digitalocean.NewVolume(ctx, \"foobar\", \u0026digitalocean.VolumeArgs{\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC1),\n\t\t\tName: pulumi.String(\"baz\"),\n\t\t\tSize: pulumi.Int(100),\n\t\t\tInitialFilesystemType: pulumi.String(digitalocean.FileSystemTypeEXT4),\n\t\t\tDescription: pulumi.String(\"an example volume\"),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tfoobarDroplet, err := digitalocean.NewDroplet(ctx, \"foobar\", \u0026digitalocean.DropletArgs{\n\t\t\tName: pulumi.String(\"baz\"),\n\t\t\tSize: pulumi.String(digitalocean.DropletSlugDropletS1VCPU1GB),\n\t\t\tImage: pulumi.String(\"ubuntu-18-04-x64\"),\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC1),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = digitalocean.NewVolumeAttachment(ctx, \"foobar\", \u0026digitalocean.VolumeAttachmentArgs{\n\t\t\tDropletId: foobarDroplet.ID(),\n\t\t\tVolumeId: foobar.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.digitalocean.Volume;\nimport com.pulumi.digitalocean.VolumeArgs;\nimport com.pulumi.digitalocean.Droplet;\nimport com.pulumi.digitalocean.DropletArgs;\nimport com.pulumi.digitalocean.VolumeAttachment;\nimport com.pulumi.digitalocean.VolumeAttachmentArgs;\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 foobar = new Volume(\"foobar\", VolumeArgs.builder() \n .region(\"nyc1\")\n .name(\"baz\")\n .size(100)\n .initialFilesystemType(\"ext4\")\n .description(\"an example volume\")\n .build());\n\n var foobarDroplet = new Droplet(\"foobarDroplet\", DropletArgs.builder() \n .name(\"baz\")\n .size(\"s-1vcpu-1gb\")\n .image(\"ubuntu-18-04-x64\")\n .region(\"nyc1\")\n .build());\n\n var foobarVolumeAttachment = new VolumeAttachment(\"foobarVolumeAttachment\", VolumeAttachmentArgs.builder() \n .dropletId(foobarDroplet.id())\n .volumeId(foobar.id())\n .build());\n\n }\n}\n```\n```yaml\nresources:\n foobar:\n type: digitalocean:Volume\n properties:\n region: nyc1\n name: baz\n size: 100\n initialFilesystemType: ext4\n description: an example volume\n foobarDroplet:\n type: digitalocean:Droplet\n name: foobar\n properties:\n name: baz\n size: s-1vcpu-1gb\n image: ubuntu-18-04-x64\n region: nyc1\n foobarVolumeAttachment:\n type: digitalocean:VolumeAttachment\n name: foobar\n properties:\n dropletId: ${foobarDroplet.id}\n volumeId: ${foobar.id}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\nYou can also create a volume from an existing snapshot.\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst foobar = digitalocean.getVolumeSnapshot({\n name: \"baz\",\n});\nconst foobarVolume = new digitalocean.Volume(\"foobar\", {\n region: digitalocean.Region.LON1,\n name: \"foo\",\n size: foobar.then(foobar =\u003e foobar.minDiskSize),\n snapshotId: foobar.then(foobar =\u003e foobar.id),\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nfoobar = digitalocean.get_volume_snapshot(name=\"baz\")\nfoobar_volume = digitalocean.Volume(\"foobar\",\n region=digitalocean.Region.LON1,\n name=\"foo\",\n size=foobar.min_disk_size,\n snapshot_id=foobar.id)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var foobar = DigitalOcean.GetVolumeSnapshot.Invoke(new()\n {\n Name = \"baz\",\n });\n\n var foobarVolume = new DigitalOcean.Volume(\"foobar\", new()\n {\n Region = DigitalOcean.Region.LON1,\n Name = \"foo\",\n Size = foobar.Apply(getVolumeSnapshotResult =\u003e getVolumeSnapshotResult.MinDiskSize),\n SnapshotId = foobar.Apply(getVolumeSnapshotResult =\u003e getVolumeSnapshotResult.Id),\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tfoobar, err := digitalocean.LookupVolumeSnapshot(ctx, \u0026digitalocean.LookupVolumeSnapshotArgs{\n\t\t\tName: pulumi.StringRef(\"baz\"),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = digitalocean.NewVolume(ctx, \"foobar\", \u0026digitalocean.VolumeArgs{\n\t\t\tRegion: pulumi.String(digitalocean.RegionLON1),\n\t\t\tName: pulumi.String(\"foo\"),\n\t\t\tSize: pulumi.Int(foobar.MinDiskSize),\n\t\t\tSnapshotId: pulumi.String(foobar.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.digitalocean.DigitaloceanFunctions;\nimport com.pulumi.digitalocean.inputs.GetVolumeSnapshotArgs;\nimport com.pulumi.digitalocean.Volume;\nimport com.pulumi.digitalocean.VolumeArgs;\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 final var foobar = DigitaloceanFunctions.getVolumeSnapshot(GetVolumeSnapshotArgs.builder()\n .name(\"baz\")\n .build());\n\n var foobarVolume = new Volume(\"foobarVolume\", VolumeArgs.builder() \n .region(\"lon1\")\n .name(\"foo\")\n .size(foobar.applyValue(getVolumeSnapshotResult -\u003e getVolumeSnapshotResult.minDiskSize()))\n .snapshotId(foobar.applyValue(getVolumeSnapshotResult -\u003e getVolumeSnapshotResult.id()))\n .build());\n\n }\n}\n```\n```yaml\nresources:\n foobarVolume:\n type: digitalocean:Volume\n name: foobar\n properties:\n region: lon1\n name: foo\n size: ${foobar.minDiskSize}\n snapshotId: ${foobar.id}\nvariables:\n foobar:\n fn::invoke:\n Function: digitalocean:getVolumeSnapshot\n Arguments:\n name: baz\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n## Import\n\nVolumes can be imported using the `volume id`, e.g.\n\n```sh\n$ pulumi import digitalocean:index/volume:Volume volume 506f78a4-e098-11e5-ad9f-000f53306ae1\n```\n\n", "properties": { "description": { "type": "string", @@ -14245,7 +14245,7 @@ } }, "digitalocean:index/volumeAttachment:VolumeAttachment": { - "description": "Manages attaching a Volume to a Droplet.\n\n\u003e **NOTE:** Volumes can be attached either directly on the `digitalocean.Droplet` resource, or using the `digitalocean.VolumeAttachment` resource - but the two cannot be used together. If both are used against the same Droplet, the volume attachments will constantly drift.\n\n\n## Example Usage\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst foobarVolume = new digitalocean.Volume(\"foobarVolume\", {\n region: digitalocean.Region.NYC1,\n size: 100,\n initialFilesystemType: digitalocean.FileSystemType.EXT4,\n description: \"an example volume\",\n});\nconst foobarDroplet = new digitalocean.Droplet(\"foobarDroplet\", {\n size: digitalocean.DropletSlug.DropletS1VCPU1GB,\n image: \"ubuntu-18-04-x64\",\n region: digitalocean.Region.NYC1,\n});\nconst foobarVolumeAttachment = new digitalocean.VolumeAttachment(\"foobarVolumeAttachment\", {\n dropletId: foobarDroplet.id,\n volumeId: foobarVolume.id,\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nfoobar_volume = digitalocean.Volume(\"foobarVolume\",\n region=digitalocean.Region.NYC1,\n size=100,\n initial_filesystem_type=digitalocean.FileSystemType.EXT4,\n description=\"an example volume\")\nfoobar_droplet = digitalocean.Droplet(\"foobarDroplet\",\n size=digitalocean.DropletSlug.DROPLET_S1_VCPU1_GB,\n image=\"ubuntu-18-04-x64\",\n region=digitalocean.Region.NYC1)\nfoobar_volume_attachment = digitalocean.VolumeAttachment(\"foobarVolumeAttachment\",\n droplet_id=foobar_droplet.id,\n volume_id=foobar_volume.id)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var foobarVolume = new DigitalOcean.Volume(\"foobarVolume\", new()\n {\n Region = DigitalOcean.Region.NYC1,\n Size = 100,\n InitialFilesystemType = DigitalOcean.FileSystemType.EXT4,\n Description = \"an example volume\",\n });\n\n var foobarDroplet = new DigitalOcean.Droplet(\"foobarDroplet\", new()\n {\n Size = DigitalOcean.DropletSlug.DropletS1VCPU1GB,\n Image = \"ubuntu-18-04-x64\",\n Region = DigitalOcean.Region.NYC1,\n });\n\n var foobarVolumeAttachment = new DigitalOcean.VolumeAttachment(\"foobarVolumeAttachment\", new()\n {\n DropletId = foobarDroplet.Id,\n VolumeId = foobarVolume.Id,\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tfoobarVolume, err := digitalocean.NewVolume(ctx, \"foobarVolume\", \u0026digitalocean.VolumeArgs{\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC1),\n\t\t\tSize: pulumi.Int(100),\n\t\t\tInitialFilesystemType: pulumi.String(digitalocean.FileSystemTypeEXT4),\n\t\t\tDescription: pulumi.String(\"an example volume\"),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tfoobarDroplet, err := digitalocean.NewDroplet(ctx, \"foobarDroplet\", \u0026digitalocean.DropletArgs{\n\t\t\tSize: pulumi.String(digitalocean.DropletSlugDropletS1VCPU1GB),\n\t\t\tImage: pulumi.String(\"ubuntu-18-04-x64\"),\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC1),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = digitalocean.NewVolumeAttachment(ctx, \"foobarVolumeAttachment\", \u0026digitalocean.VolumeAttachmentArgs{\n\t\t\tDropletId: foobarDroplet.ID(),\n\t\t\tVolumeId: foobarVolume.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.digitalocean.Volume;\nimport com.pulumi.digitalocean.VolumeArgs;\nimport com.pulumi.digitalocean.Droplet;\nimport com.pulumi.digitalocean.DropletArgs;\nimport com.pulumi.digitalocean.VolumeAttachment;\nimport com.pulumi.digitalocean.VolumeAttachmentArgs;\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 foobarVolume = new Volume(\"foobarVolume\", VolumeArgs.builder() \n .region(\"nyc1\")\n .size(100)\n .initialFilesystemType(\"ext4\")\n .description(\"an example volume\")\n .build());\n\n var foobarDroplet = new Droplet(\"foobarDroplet\", DropletArgs.builder() \n .size(\"s-1vcpu-1gb\")\n .image(\"ubuntu-18-04-x64\")\n .region(\"nyc1\")\n .build());\n\n var foobarVolumeAttachment = new VolumeAttachment(\"foobarVolumeAttachment\", VolumeAttachmentArgs.builder() \n .dropletId(foobarDroplet.id())\n .volumeId(foobarVolume.id())\n .build());\n\n }\n}\n```\n```yaml\nresources:\n foobarVolume:\n type: digitalocean:Volume\n properties:\n region: nyc1\n size: 100\n initialFilesystemType: ext4\n description: an example volume\n foobarDroplet:\n type: digitalocean:Droplet\n properties:\n size: s-1vcpu-1gb\n image: ubuntu-18-04-x64\n region: nyc1\n foobarVolumeAttachment:\n type: digitalocean:VolumeAttachment\n properties:\n dropletId: ${foobarDroplet.id}\n volumeId: ${foobarVolume.id}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n", + "description": "Manages attaching a Volume to a Droplet.\n\n\u003e **NOTE:** Volumes can be attached either directly on the `digitalocean.Droplet` resource, or using the `digitalocean.VolumeAttachment` resource - but the two cannot be used together. If both are used against the same Droplet, the volume attachments will constantly drift.\n\n\n## Example Usage\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst foobar = new digitalocean.Volume(\"foobar\", {\n region: digitalocean.Region.NYC1,\n name: \"baz\",\n size: 100,\n initialFilesystemType: digitalocean.FileSystemType.EXT4,\n description: \"an example volume\",\n});\nconst foobarDroplet = new digitalocean.Droplet(\"foobar\", {\n name: \"baz\",\n size: digitalocean.DropletSlug.DropletS1VCPU1GB,\n image: \"ubuntu-18-04-x64\",\n region: digitalocean.Region.NYC1,\n});\nconst foobarVolumeAttachment = new digitalocean.VolumeAttachment(\"foobar\", {\n dropletId: foobarDroplet.id,\n volumeId: foobar.id,\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nfoobar = digitalocean.Volume(\"foobar\",\n region=digitalocean.Region.NYC1,\n name=\"baz\",\n size=100,\n initial_filesystem_type=digitalocean.FileSystemType.EXT4,\n description=\"an example volume\")\nfoobar_droplet = digitalocean.Droplet(\"foobar\",\n name=\"baz\",\n size=digitalocean.DropletSlug.DROPLET_S1_VCPU1_GB,\n image=\"ubuntu-18-04-x64\",\n region=digitalocean.Region.NYC1)\nfoobar_volume_attachment = digitalocean.VolumeAttachment(\"foobar\",\n droplet_id=foobar_droplet.id,\n volume_id=foobar.id)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var foobar = new DigitalOcean.Volume(\"foobar\", new()\n {\n Region = DigitalOcean.Region.NYC1,\n Name = \"baz\",\n Size = 100,\n InitialFilesystemType = DigitalOcean.FileSystemType.EXT4,\n Description = \"an example volume\",\n });\n\n var foobarDroplet = new DigitalOcean.Droplet(\"foobar\", new()\n {\n Name = \"baz\",\n Size = DigitalOcean.DropletSlug.DropletS1VCPU1GB,\n Image = \"ubuntu-18-04-x64\",\n Region = DigitalOcean.Region.NYC1,\n });\n\n var foobarVolumeAttachment = new DigitalOcean.VolumeAttachment(\"foobar\", new()\n {\n DropletId = foobarDroplet.Id,\n VolumeId = foobar.Id,\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tfoobar, err := digitalocean.NewVolume(ctx, \"foobar\", \u0026digitalocean.VolumeArgs{\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC1),\n\t\t\tName: pulumi.String(\"baz\"),\n\t\t\tSize: pulumi.Int(100),\n\t\t\tInitialFilesystemType: pulumi.String(digitalocean.FileSystemTypeEXT4),\n\t\t\tDescription: pulumi.String(\"an example volume\"),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tfoobarDroplet, err := digitalocean.NewDroplet(ctx, \"foobar\", \u0026digitalocean.DropletArgs{\n\t\t\tName: pulumi.String(\"baz\"),\n\t\t\tSize: pulumi.String(digitalocean.DropletSlugDropletS1VCPU1GB),\n\t\t\tImage: pulumi.String(\"ubuntu-18-04-x64\"),\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC1),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = digitalocean.NewVolumeAttachment(ctx, \"foobar\", \u0026digitalocean.VolumeAttachmentArgs{\n\t\t\tDropletId: foobarDroplet.ID(),\n\t\t\tVolumeId: foobar.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.digitalocean.Volume;\nimport com.pulumi.digitalocean.VolumeArgs;\nimport com.pulumi.digitalocean.Droplet;\nimport com.pulumi.digitalocean.DropletArgs;\nimport com.pulumi.digitalocean.VolumeAttachment;\nimport com.pulumi.digitalocean.VolumeAttachmentArgs;\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 foobar = new Volume(\"foobar\", VolumeArgs.builder() \n .region(\"nyc1\")\n .name(\"baz\")\n .size(100)\n .initialFilesystemType(\"ext4\")\n .description(\"an example volume\")\n .build());\n\n var foobarDroplet = new Droplet(\"foobarDroplet\", DropletArgs.builder() \n .name(\"baz\")\n .size(\"s-1vcpu-1gb\")\n .image(\"ubuntu-18-04-x64\")\n .region(\"nyc1\")\n .build());\n\n var foobarVolumeAttachment = new VolumeAttachment(\"foobarVolumeAttachment\", VolumeAttachmentArgs.builder() \n .dropletId(foobarDroplet.id())\n .volumeId(foobar.id())\n .build());\n\n }\n}\n```\n```yaml\nresources:\n foobar:\n type: digitalocean:Volume\n properties:\n region: nyc1\n name: baz\n size: 100\n initialFilesystemType: ext4\n description: an example volume\n foobarDroplet:\n type: digitalocean:Droplet\n name: foobar\n properties:\n name: baz\n size: s-1vcpu-1gb\n image: ubuntu-18-04-x64\n region: nyc1\n foobarVolumeAttachment:\n type: digitalocean:VolumeAttachment\n name: foobar\n properties:\n dropletId: ${foobarDroplet.id}\n volumeId: ${foobar.id}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n", "properties": { "dropletId": { "type": "integer", @@ -14294,7 +14294,7 @@ } }, "digitalocean:index/volumeSnapshot:VolumeSnapshot": { - "description": "Provides a DigitalOcean Volume Snapshot which can be used to create a snapshot from an existing volume.\n\n## Example Usage\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst foobarVolume = new digitalocean.Volume(\"foobarVolume\", {\n region: digitalocean.Region.NYC1,\n size: 100,\n description: \"an example volume\",\n});\nconst foobarVolumeSnapshot = new digitalocean.VolumeSnapshot(\"foobarVolumeSnapshot\", {volumeId: foobarVolume.id});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nfoobar_volume = digitalocean.Volume(\"foobarVolume\",\n region=digitalocean.Region.NYC1,\n size=100,\n description=\"an example volume\")\nfoobar_volume_snapshot = digitalocean.VolumeSnapshot(\"foobarVolumeSnapshot\", volume_id=foobar_volume.id)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var foobarVolume = new DigitalOcean.Volume(\"foobarVolume\", new()\n {\n Region = DigitalOcean.Region.NYC1,\n Size = 100,\n Description = \"an example volume\",\n });\n\n var foobarVolumeSnapshot = new DigitalOcean.VolumeSnapshot(\"foobarVolumeSnapshot\", new()\n {\n VolumeId = foobarVolume.Id,\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tfoobarVolume, err := digitalocean.NewVolume(ctx, \"foobarVolume\", \u0026digitalocean.VolumeArgs{\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC1),\n\t\t\tSize: pulumi.Int(100),\n\t\t\tDescription: pulumi.String(\"an example volume\"),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = digitalocean.NewVolumeSnapshot(ctx, \"foobarVolumeSnapshot\", \u0026digitalocean.VolumeSnapshotArgs{\n\t\t\tVolumeId: foobarVolume.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.digitalocean.Volume;\nimport com.pulumi.digitalocean.VolumeArgs;\nimport com.pulumi.digitalocean.VolumeSnapshot;\nimport com.pulumi.digitalocean.VolumeSnapshotArgs;\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 foobarVolume = new Volume(\"foobarVolume\", VolumeArgs.builder() \n .region(\"nyc1\")\n .size(100)\n .description(\"an example volume\")\n .build());\n\n var foobarVolumeSnapshot = new VolumeSnapshot(\"foobarVolumeSnapshot\", VolumeSnapshotArgs.builder() \n .volumeId(foobarVolume.id())\n .build());\n\n }\n}\n```\n```yaml\nresources:\n foobarVolume:\n type: digitalocean:Volume\n properties:\n region: nyc1\n size: 100\n description: an example volume\n foobarVolumeSnapshot:\n type: digitalocean:VolumeSnapshot\n properties:\n volumeId: ${foobarVolume.id}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n## Import\n\nVolume Snapshots can be imported using the `snapshot id`, e.g.\n\n```sh\n$ pulumi import digitalocean:index/volumeSnapshot:VolumeSnapshot snapshot 506f78a4-e098-11e5-ad9f-000f53306ae1\n```\n\n", + "description": "Provides a DigitalOcean Volume Snapshot which can be used to create a snapshot from an existing volume.\n\n## Example Usage\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst foobar = new digitalocean.Volume(\"foobar\", {\n region: digitalocean.Region.NYC1,\n name: \"baz\",\n size: 100,\n description: \"an example volume\",\n});\nconst foobarVolumeSnapshot = new digitalocean.VolumeSnapshot(\"foobar\", {\n name: \"foo\",\n volumeId: foobar.id,\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nfoobar = digitalocean.Volume(\"foobar\",\n region=digitalocean.Region.NYC1,\n name=\"baz\",\n size=100,\n description=\"an example volume\")\nfoobar_volume_snapshot = digitalocean.VolumeSnapshot(\"foobar\",\n name=\"foo\",\n volume_id=foobar.id)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var foobar = new DigitalOcean.Volume(\"foobar\", new()\n {\n Region = DigitalOcean.Region.NYC1,\n Name = \"baz\",\n Size = 100,\n Description = \"an example volume\",\n });\n\n var foobarVolumeSnapshot = new DigitalOcean.VolumeSnapshot(\"foobar\", new()\n {\n Name = \"foo\",\n VolumeId = foobar.Id,\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tfoobar, err := digitalocean.NewVolume(ctx, \"foobar\", \u0026digitalocean.VolumeArgs{\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC1),\n\t\t\tName: pulumi.String(\"baz\"),\n\t\t\tSize: pulumi.Int(100),\n\t\t\tDescription: pulumi.String(\"an example volume\"),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = digitalocean.NewVolumeSnapshot(ctx, \"foobar\", \u0026digitalocean.VolumeSnapshotArgs{\n\t\t\tName: pulumi.String(\"foo\"),\n\t\t\tVolumeId: foobar.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.digitalocean.Volume;\nimport com.pulumi.digitalocean.VolumeArgs;\nimport com.pulumi.digitalocean.VolumeSnapshot;\nimport com.pulumi.digitalocean.VolumeSnapshotArgs;\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 foobar = new Volume(\"foobar\", VolumeArgs.builder() \n .region(\"nyc1\")\n .name(\"baz\")\n .size(100)\n .description(\"an example volume\")\n .build());\n\n var foobarVolumeSnapshot = new VolumeSnapshot(\"foobarVolumeSnapshot\", VolumeSnapshotArgs.builder() \n .name(\"foo\")\n .volumeId(foobar.id())\n .build());\n\n }\n}\n```\n```yaml\nresources:\n foobar:\n type: digitalocean:Volume\n properties:\n region: nyc1\n name: baz\n size: 100\n description: an example volume\n foobarVolumeSnapshot:\n type: digitalocean:VolumeSnapshot\n name: foobar\n properties:\n name: foo\n volumeId: ${foobar.id}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n## Import\n\nVolume Snapshots can be imported using the `snapshot id`, e.g.\n\n```sh\n$ pulumi import digitalocean:index/volumeSnapshot:VolumeSnapshot snapshot 506f78a4-e098-11e5-ad9f-000f53306ae1\n```\n\n", "properties": { "createdAt": { "type": "string", @@ -14405,7 +14405,7 @@ } }, "digitalocean:index/vpc:Vpc": { - "description": "Provides a [DigitalOcean VPC](https://docs.digitalocean.com/reference/api/api-reference/#tag/VPCs) resource.\n\nVPCs are virtual networks containing resources that can communicate with each\nother in full isolation, using private IP addresses.\n\n## Example Usage\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst example = new digitalocean.Vpc(\"example\", {\n ipRange: \"10.10.10.0/24\",\n region: \"nyc3\",\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nexample = digitalocean.Vpc(\"example\",\n ip_range=\"10.10.10.0/24\",\n region=\"nyc3\")\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var example = new DigitalOcean.Vpc(\"example\", new()\n {\n IpRange = \"10.10.10.0/24\",\n Region = \"nyc3\",\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := digitalocean.NewVpc(ctx, \"example\", \u0026digitalocean.VpcArgs{\n\t\t\tIpRange: pulumi.String(\"10.10.10.0/24\"),\n\t\t\tRegion: pulumi.String(\"nyc3\"),\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.digitalocean.Vpc;\nimport com.pulumi.digitalocean.VpcArgs;\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 example = new Vpc(\"example\", VpcArgs.builder() \n .ipRange(\"10.10.10.0/24\")\n .region(\"nyc3\")\n .build());\n\n }\n}\n```\n```yaml\nresources:\n example:\n type: digitalocean:Vpc\n properties:\n ipRange: 10.10.10.0/24\n region: nyc3\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n### Resource Assignment\n\n`digitalocean.Droplet`, `digitalocean.KubernetesCluster`,\n`digitalocean_load_balancer`, and `digitalocean.DatabaseCluster` resources\nmay be assigned to a VPC by referencing its `id`. For example:\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst exampleVpc = new digitalocean.Vpc(\"exampleVpc\", {region: \"nyc3\"});\nconst exampleDroplet = new digitalocean.Droplet(\"exampleDroplet\", {\n size: digitalocean.DropletSlug.DropletS1VCPU1GB,\n image: \"ubuntu-18-04-x64\",\n region: digitalocean.Region.NYC3,\n vpcUuid: exampleVpc.id,\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nexample_vpc = digitalocean.Vpc(\"exampleVpc\", region=\"nyc3\")\nexample_droplet = digitalocean.Droplet(\"exampleDroplet\",\n size=digitalocean.DropletSlug.DROPLET_S1_VCPU1_GB,\n image=\"ubuntu-18-04-x64\",\n region=digitalocean.Region.NYC3,\n vpc_uuid=example_vpc.id)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var exampleVpc = new DigitalOcean.Vpc(\"exampleVpc\", new()\n {\n Region = \"nyc3\",\n });\n\n var exampleDroplet = new DigitalOcean.Droplet(\"exampleDroplet\", new()\n {\n Size = DigitalOcean.DropletSlug.DropletS1VCPU1GB,\n Image = \"ubuntu-18-04-x64\",\n Region = DigitalOcean.Region.NYC3,\n VpcUuid = exampleVpc.Id,\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\texampleVpc, err := digitalocean.NewVpc(ctx, \"exampleVpc\", \u0026digitalocean.VpcArgs{\n\t\t\tRegion: pulumi.String(\"nyc3\"),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = digitalocean.NewDroplet(ctx, \"exampleDroplet\", \u0026digitalocean.DropletArgs{\n\t\t\tSize: pulumi.String(digitalocean.DropletSlugDropletS1VCPU1GB),\n\t\t\tImage: pulumi.String(\"ubuntu-18-04-x64\"),\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC3),\n\t\t\tVpcUuid: exampleVpc.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.digitalocean.Vpc;\nimport com.pulumi.digitalocean.VpcArgs;\nimport com.pulumi.digitalocean.Droplet;\nimport com.pulumi.digitalocean.DropletArgs;\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 exampleVpc = new Vpc(\"exampleVpc\", VpcArgs.builder() \n .region(\"nyc3\")\n .build());\n\n var exampleDroplet = new Droplet(\"exampleDroplet\", DropletArgs.builder() \n .size(\"s-1vcpu-1gb\")\n .image(\"ubuntu-18-04-x64\")\n .region(\"nyc3\")\n .vpcUuid(exampleVpc.id())\n .build());\n\n }\n}\n```\n```yaml\nresources:\n exampleVpc:\n type: digitalocean:Vpc\n properties:\n region: nyc3\n exampleDroplet:\n type: digitalocean:Droplet\n properties:\n size: s-1vcpu-1gb\n image: ubuntu-18-04-x64\n region: nyc3\n vpcUuid: ${exampleVpc.id}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n## Import\n\nA VPC can be imported using its `id`, e.g.\n\n```sh\n$ pulumi import digitalocean:index/vpc:Vpc example 506f78a4-e098-11e5-ad9f-000f53306ae1\n```\n\n", + "description": "Provides a [DigitalOcean VPC](https://docs.digitalocean.com/reference/api/api-reference/#tag/VPCs) resource.\n\nVPCs are virtual networks containing resources that can communicate with each\nother in full isolation, using private IP addresses.\n\n## Example Usage\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst example = new digitalocean.Vpc(\"example\", {\n name: \"example-project-network\",\n region: \"nyc3\",\n ipRange: \"10.10.10.0/24\",\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nexample = digitalocean.Vpc(\"example\",\n name=\"example-project-network\",\n region=\"nyc3\",\n ip_range=\"10.10.10.0/24\")\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var example = new DigitalOcean.Vpc(\"example\", new()\n {\n Name = \"example-project-network\",\n Region = \"nyc3\",\n IpRange = \"10.10.10.0/24\",\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := digitalocean.NewVpc(ctx, \"example\", \u0026digitalocean.VpcArgs{\n\t\t\tName: pulumi.String(\"example-project-network\"),\n\t\t\tRegion: pulumi.String(\"nyc3\"),\n\t\t\tIpRange: pulumi.String(\"10.10.10.0/24\"),\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.digitalocean.Vpc;\nimport com.pulumi.digitalocean.VpcArgs;\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 example = new Vpc(\"example\", VpcArgs.builder() \n .name(\"example-project-network\")\n .region(\"nyc3\")\n .ipRange(\"10.10.10.0/24\")\n .build());\n\n }\n}\n```\n```yaml\nresources:\n example:\n type: digitalocean:Vpc\n properties:\n name: example-project-network\n region: nyc3\n ipRange: 10.10.10.0/24\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n### Resource Assignment\n\n`digitalocean.Droplet`, `digitalocean.KubernetesCluster`,\n`digitalocean_load_balancer`, and `digitalocean.DatabaseCluster` resources\nmay be assigned to a VPC by referencing its `id`. For example:\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst example = new digitalocean.Vpc(\"example\", {\n name: \"example-project-network\",\n region: \"nyc3\",\n});\nconst exampleDroplet = new digitalocean.Droplet(\"example\", {\n name: \"example-01\",\n size: digitalocean.DropletSlug.DropletS1VCPU1GB,\n image: \"ubuntu-18-04-x64\",\n region: digitalocean.Region.NYC3,\n vpcUuid: example.id,\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nexample = digitalocean.Vpc(\"example\",\n name=\"example-project-network\",\n region=\"nyc3\")\nexample_droplet = digitalocean.Droplet(\"example\",\n name=\"example-01\",\n size=digitalocean.DropletSlug.DROPLET_S1_VCPU1_GB,\n image=\"ubuntu-18-04-x64\",\n region=digitalocean.Region.NYC3,\n vpc_uuid=example.id)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var example = new DigitalOcean.Vpc(\"example\", new()\n {\n Name = \"example-project-network\",\n Region = \"nyc3\",\n });\n\n var exampleDroplet = new DigitalOcean.Droplet(\"example\", new()\n {\n Name = \"example-01\",\n Size = DigitalOcean.DropletSlug.DropletS1VCPU1GB,\n Image = \"ubuntu-18-04-x64\",\n Region = DigitalOcean.Region.NYC3,\n VpcUuid = example.Id,\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\texample, err := digitalocean.NewVpc(ctx, \"example\", \u0026digitalocean.VpcArgs{\n\t\t\tName: pulumi.String(\"example-project-network\"),\n\t\t\tRegion: pulumi.String(\"nyc3\"),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = digitalocean.NewDroplet(ctx, \"example\", \u0026digitalocean.DropletArgs{\n\t\t\tName: pulumi.String(\"example-01\"),\n\t\t\tSize: pulumi.String(digitalocean.DropletSlugDropletS1VCPU1GB),\n\t\t\tImage: pulumi.String(\"ubuntu-18-04-x64\"),\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC3),\n\t\t\tVpcUuid: example.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.digitalocean.Vpc;\nimport com.pulumi.digitalocean.VpcArgs;\nimport com.pulumi.digitalocean.Droplet;\nimport com.pulumi.digitalocean.DropletArgs;\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 example = new Vpc(\"example\", VpcArgs.builder() \n .name(\"example-project-network\")\n .region(\"nyc3\")\n .build());\n\n var exampleDroplet = new Droplet(\"exampleDroplet\", DropletArgs.builder() \n .name(\"example-01\")\n .size(\"s-1vcpu-1gb\")\n .image(\"ubuntu-18-04-x64\")\n .region(\"nyc3\")\n .vpcUuid(example.id())\n .build());\n\n }\n}\n```\n```yaml\nresources:\n example:\n type: digitalocean:Vpc\n properties:\n name: example-project-network\n region: nyc3\n exampleDroplet:\n type: digitalocean:Droplet\n name: example\n properties:\n name: example-01\n size: s-1vcpu-1gb\n image: ubuntu-18-04-x64\n region: nyc3\n vpcUuid: ${example.id}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n## Import\n\nA VPC can be imported using its `id`, e.g.\n\n```sh\n$ pulumi import digitalocean:index/vpc:Vpc example 506f78a4-e098-11e5-ad9f-000f53306ae1\n```\n\n", "properties": { "createdAt": { "type": "string", @@ -14512,39 +14512,38 @@ "description": "A collection of values returned by getAccount.\n", "properties": { "dropletLimit": { - "type": "integer", - "description": "The total number of droplets current user or team may have active at one time.\n" + "description": "The total number of droplets current user or team may have active at one time.\n", + "type": "integer" }, "email": { - "type": "string", - "description": "The email address used by the current user to register for DigitalOcean.\n" + "description": "The email address used by the current user to register for DigitalOcean.\n", + "type": "string" }, "emailVerified": { - "type": "boolean", - "description": "If true, the user has verified their account via email. False otherwise.\n" + "description": "If true, the user has verified their account via email. False otherwise.\n", + "type": "boolean" }, "floatingIpLimit": { - "type": "integer", - "description": "The total number of floating IPs the current user or team may have.\n" + "description": "The total number of floating IPs the current user or team may have.\n", + "type": "integer" }, "id": { - "type": "string", - "description": "The provider-assigned unique ID for this managed resource.\n" + "description": "The provider-assigned unique ID for this managed resource.\n", + "type": "string" }, "status": { - "type": "string", - "description": "This value is one of \"active\", \"warning\" or \"locked\".\n" + "description": "This value is one of \"active\", \"warning\" or \"locked\".\n", + "type": "string" }, "statusMessage": { - "type": "string", - "description": "A human-readable message giving more details about the status of the account.\n" + "description": "A human-readable message giving more details about the status of the account.\n", + "type": "string" }, "uuid": { - "type": "string", - "description": "The unique universal identifier for the current user.\n" + "description": "The unique universal identifier for the current user.\n", + "type": "string" } }, - "type": "object", "required": [ "dropletLimit", "email", @@ -14554,7 +14553,8 @@ "statusMessage", "uuid", "id" - ] + ], + "type": "object" } }, "digitalocean:index/getApp:getApp": { @@ -14576,49 +14576,48 @@ "description": "A collection of values returned by getApp.\n", "properties": { "activeDeploymentId": { - "type": "string", - "description": "The ID the app's currently active deployment.\n" + "description": "The ID the app's currently active deployment.\n", + "type": "string" }, "appId": { "type": "string" }, "createdAt": { - "type": "string", - "description": "The date and time of when the app was created.\n" + "description": "The date and time of when the app was created.\n", + "type": "string" }, "defaultIngress": { - "type": "string", - "description": "The default URL to access the app.\n" + "description": "The default URL to access the app.\n", + "type": "string" }, "id": { - "type": "string", - "description": "The provider-assigned unique ID for this managed resource.\n" + "description": "The provider-assigned unique ID for this managed resource.\n", + "type": "string" }, "liveUrl": { - "type": "string", - "description": "The live URL of the app.\n" + "description": "The live URL of the app.\n", + "type": "string" }, "projectId": { - "type": "string", - "description": "The ID of the project that the app is assigned to.\n" + "description": "The ID of the project that the app is assigned to.\n", + "type": "string" }, "specs": { - "type": "array", + "description": "A DigitalOcean App spec describing the app.\n", "items": { "$ref": "#/types/digitalocean:index/getAppSpec:getAppSpec" }, - "description": "A DigitalOcean App spec describing the app.\n" + "type": "array" }, "updatedAt": { - "type": "string", - "description": "The date and time of when the app was last updated.\n" + "description": "The date and time of when the app was last updated.\n", + "type": "string" }, "urn": { - "type": "string", - "description": "The uniform resource identifier for the app.\n" + "description": "The uniform resource identifier for the app.\n", + "type": "string" } }, - "type": "object", "required": [ "activeDeploymentId", "appId", @@ -14630,7 +14629,8 @@ "updatedAt", "urn", "id" - ] + ], + "type": "object" } }, "digitalocean:index/getCertificate:getCertificate": { @@ -14652,41 +14652,40 @@ "description": "A collection of values returned by getCertificate.\n", "properties": { "domains": { - "type": "array", + "description": "Domains for which the certificate was issued.\n", "items": { "type": "string" }, - "description": "Domains for which the certificate was issued.\n" + "type": "array" }, "id": { - "type": "string", - "description": "The provider-assigned unique ID for this managed resource.\n" + "description": "The provider-assigned unique ID for this managed resource.\n", + "type": "string" }, "name": { "type": "string" }, "notAfter": { - "type": "string", - "description": "The expiration date and time of the certificate.\n" + "description": "The expiration date and time of the certificate.\n", + "type": "string" }, "sha1Fingerprint": { - "type": "string", - "description": "The SHA1 fingerprint of the certificate.\n" + "description": "The SHA1 fingerprint of the certificate.\n", + "type": "string" }, "state": { - "type": "string", - "description": "the current state of the certificate.\n" + "description": "the current state of the certificate.\n", + "type": "string" }, "type": { - "type": "string", - "description": "The type of the certificate.\n" + "description": "The type of the certificate.\n", + "type": "string" }, "uuid": { - "type": "string", - "description": "The ID of the certificate.\n" + "description": "The ID of the certificate.\n", + "type": "string" } }, - "type": "object", "required": [ "domains", "name", @@ -14696,7 +14695,8 @@ "type", "uuid", "id" - ] + ], + "type": "object" } }, "digitalocean:index/getContainerRegistry:getContainerRegistry": { @@ -14718,39 +14718,38 @@ "description": "A collection of values returned by getContainerRegistry.\n", "properties": { "createdAt": { - "type": "string", - "description": "The date and time when the registry was created\n" + "description": "The date and time when the registry was created\n", + "type": "string" }, "endpoint": { - "type": "string", - "description": "The URL endpoint of the container registry. Ex: `registry.digitalocean.com/my_registry`\n" + "description": "The URL endpoint of the container registry. Ex: `registry.digitalocean.com/my_registry`\n", + "type": "string" }, "id": { - "type": "string", - "description": "The provider-assigned unique ID for this managed resource.\n" + "description": "The provider-assigned unique ID for this managed resource.\n", + "type": "string" }, "name": { - "type": "string", - "description": "The name of the container registry\n" + "description": "The name of the container registry\n", + "type": "string" }, "region": { - "type": "string", - "description": "The slug identifier for the region\n" + "description": "The slug identifier for the region\n", + "type": "string" }, "serverUrl": { - "type": "string", - "description": "The domain of the container registry. Ex: `registry.digitalocean.com`\n" + "description": "The domain of the container registry. Ex: `registry.digitalocean.com`\n", + "type": "string" }, "storageUsageBytes": { - "type": "integer", - "description": "The amount of storage used in the registry in bytes.\n" + "description": "The amount of storage used in the registry in bytes.\n", + "type": "integer" }, "subscriptionTierSlug": { - "type": "string", - "description": "The slug identifier for the subscription tier\n" + "description": "The slug identifier for the subscription tier\n", + "type": "string" } }, - "type": "object", "required": [ "createdAt", "endpoint", @@ -14760,7 +14759,8 @@ "storageUsageBytes", "subscriptionTierSlug", "id" - ] + ], + "type": "object" } }, "digitalocean:index/getDatabaseCa:getDatabaseCa": { @@ -14782,23 +14782,23 @@ "description": "A collection of values returned by getDatabaseCa.\n", "properties": { "certificate": { - "type": "string", - "description": "The CA certificate used to secure database connections decoded to a string.\n" + "description": "The CA certificate used to secure database connections decoded to a string.\n", + "type": "string" }, "clusterId": { "type": "string" }, "id": { - "type": "string", - "description": "The provider-assigned unique ID for this managed resource.\n" + "description": "The provider-assigned unique ID for this managed resource.\n", + "type": "string" } }, - "type": "object", "required": [ "certificate", "clusterId", "id" - ] + ], + "type": "object" } }, "digitalocean:index/getDatabaseCluster:getDatabaseCluster": { @@ -14827,123 +14827,122 @@ "description": "A collection of values returned by getDatabaseCluster.\n", "properties": { "database": { - "type": "string", - "description": "Name of the cluster's default database.\n" + "description": "Name of the cluster's default database.\n", + "type": "string" }, "engine": { - "type": "string", - "description": "Database engine used by the cluster (ex. `pg` for PostreSQL).\n" + "description": "Database engine used by the cluster (ex. `pg` for PostreSQL).\n", + "type": "string" }, "host": { - "type": "string", - "description": "Database cluster's hostname.\n" + "description": "Database cluster's hostname.\n", + "type": "string" }, "id": { - "type": "string", - "description": "The provider-assigned unique ID for this managed resource.\n" + "description": "The provider-assigned unique ID for this managed resource.\n", + "type": "string" }, "maintenanceWindows": { - "type": "array", + "description": "Defines when the automatic maintenance should be performed for the database cluster.\n", "items": { "$ref": "#/types/digitalocean:index/getDatabaseClusterMaintenanceWindow:getDatabaseClusterMaintenanceWindow" }, - "description": "Defines when the automatic maintenance should be performed for the database cluster.\n" + "type": "array" }, "name": { "type": "string" }, "nodeCount": { - "type": "integer", - "description": "Number of nodes that will be included in the cluster.\n" + "description": "Number of nodes that will be included in the cluster.\n", + "type": "integer" }, "password": { - "type": "string", "description": "Password for the cluster's default user.\n", - "secret": true + "secret": true, + "type": "string" }, "port": { - "type": "integer", - "description": "Network port that the database cluster is listening on.\n" + "description": "Network port that the database cluster is listening on.\n", + "type": "integer" }, "privateHost": { - "type": "string", - "description": "Same as `host`, but only accessible from resources within the account and in the same region.\n" + "description": "Same as `host`, but only accessible from resources within the account and in the same region.\n", + "type": "string" }, "privateNetworkUuid": { - "type": "string", - "description": "The ID of the VPC where the database cluster is located.\n" + "description": "The ID of the VPC where the database cluster is located.\n", + "type": "string" }, "privateUri": { - "type": "string", "description": "Same as `uri`, but only accessible from resources within the account and in the same region.\n", - "secret": true + "secret": true, + "type": "string" }, "projectId": { - "type": "string", - "description": "The ID of the project that the database cluster is assigned to.\n" + "description": "The ID of the project that the database cluster is assigned to.\n", + "type": "string" }, "region": { - "type": "string", - "description": "DigitalOcean region where the cluster will reside.\n" + "description": "DigitalOcean region where the cluster will reside.\n", + "type": "string" }, "size": { - "type": "string", - "description": "Database droplet size associated with the cluster (ex. `db-s-1vcpu-1gb`).\n" + "description": "Database droplet size associated with the cluster (ex. `db-s-1vcpu-1gb`).\n", + "type": "string" }, "storageSizeMib": { "type": "string" }, "tags": { - "type": "array", "items": { "type": "string" - } + }, + "type": "array" }, "uiDatabase": { - "type": "string", - "description": "Name of the OpenSearch dashboard db.\n" + "description": "Name of the OpenSearch dashboard db.\n", + "type": "string" }, "uiHost": { - "type": "string", - "description": "Hostname for the OpenSearch dashboard.\n" + "description": "Hostname for the OpenSearch dashboard.\n", + "type": "string" }, "uiPassword": { - "type": "string", "description": "Password for the OpenSearch dashboard's default user.\n", - "secret": true + "secret": true, + "type": "string" }, "uiPort": { - "type": "integer", - "description": "Network port that the OpenSearch dashboard is listening on.\n" + "description": "Network port that the OpenSearch dashboard is listening on.\n", + "type": "integer" }, "uiUri": { - "type": "string", "description": "The full URI for connecting to the OpenSearch dashboard.\n", - "secret": true + "secret": true, + "type": "string" }, "uiUser": { - "type": "string", - "description": "Username for OpenSearch dashboard's default user.\n" + "description": "Username for OpenSearch dashboard's default user.\n", + "type": "string" }, "uri": { - "type": "string", "description": "The full URI for connecting to the database cluster.\n", - "secret": true + "secret": true, + "type": "string" }, "urn": { - "type": "string", - "description": "The uniform resource name of the database cluster.\n" + "description": "The uniform resource name of the database cluster.\n", + "type": "string" }, "user": { - "type": "string", - "description": "Username for the cluster's default user.\n" + "description": "Username for the cluster's default user.\n", + "type": "string" }, "version": { - "type": "string", - "description": "Engine version used by the cluster (ex. `11` for PostgreSQL 11).\n" + "description": "Engine version used by the cluster (ex. `11` for PostgreSQL 11).\n", + "type": "string" } }, - "type": "object", "required": [ "database", "engine", @@ -14971,7 +14970,8 @@ "user", "version", "id" - ] + ], + "type": "object" } }, "digitalocean:index/getDatabaseConnectionPool:getDatabaseConnectionPool": { @@ -15003,57 +15003,56 @@ "type": "string" }, "dbName": { - "type": "string", - "description": "Name of the connection pool's default database.\n" + "description": "Name of the connection pool's default database.\n", + "type": "string" }, "host": { - "type": "string", - "description": "Connection pool hostname.\n" + "description": "Connection pool hostname.\n", + "type": "string" }, "id": { - "type": "string", - "description": "The provider-assigned unique ID for this managed resource.\n" + "description": "The provider-assigned unique ID for this managed resource.\n", + "type": "string" }, "mode": { - "type": "string", - "description": "The transaction mode for the connection pool.\n" + "description": "The transaction mode for the connection pool.\n", + "type": "string" }, "name": { "type": "string" }, "password": { - "type": "string", "description": "Password for the connection pool's default user.\n", - "secret": true + "secret": true, + "type": "string" }, "port": { - "type": "integer", - "description": "Network port that the connection pool is listening on.\n" + "description": "Network port that the connection pool is listening on.\n", + "type": "integer" }, "privateHost": { - "type": "string", - "description": "Same as `host`, but only accessible from resources within the account and in the same region.\n" + "description": "Same as `host`, but only accessible from resources within the account and in the same region.\n", + "type": "string" }, "privateUri": { - "type": "string", "description": "Same as `uri`, but only accessible from resources within the account and in the same region.\n", - "secret": true + "secret": true, + "type": "string" }, "size": { - "type": "integer", - "description": "Size of the connection pool.\n" + "description": "Size of the connection pool.\n", + "type": "integer" }, "uri": { - "type": "string", "description": "The full URI for connecting to the database connection pool.\n", - "secret": true + "secret": true, + "type": "string" }, "user": { - "type": "string", - "description": "Username for the connection pool's default user.\n" + "description": "Username for the connection pool's default user.\n", + "type": "string" } }, - "type": "object", "required": [ "clusterId", "dbName", @@ -15068,7 +15067,8 @@ "uri", "user", "id" - ] + ], + "type": "object" } }, "digitalocean:index/getDatabaseReplica:getDatabaseReplica": { @@ -15105,40 +15105,40 @@ "type": "string" }, "database": { - "type": "string", - "description": "Name of the replica's default database.\n" + "description": "Name of the replica's default database.\n", + "type": "string" }, "host": { - "type": "string", - "description": "Database replica's hostname.\n" + "description": "Database replica's hostname.\n", + "type": "string" }, "id": { - "type": "string", - "description": "The provider-assigned unique ID for this managed resource.\n" + "description": "The provider-assigned unique ID for this managed resource.\n", + "type": "string" }, "name": { "type": "string" }, "password": { - "type": "string", "description": "Password for the replica's default user.\n", - "secret": true + "secret": true, + "type": "string" }, "port": { - "type": "integer", - "description": "Network port that the database replica is listening on.\n" + "description": "Network port that the database replica is listening on.\n", + "type": "integer" }, "privateHost": { - "type": "string", - "description": "Same as `host`, but only accessible from resources within the account and in the same region.\n" + "description": "Same as `host`, but only accessible from resources within the account and in the same region.\n", + "type": "string" }, "privateNetworkUuid": { "type": "string" }, "privateUri": { - "type": "string", "description": "Same as `uri`, but only accessible from resources within the account and in the same region.\n", - "secret": true + "secret": true, + "type": "string" }, "region": { "type": "string" @@ -15147,27 +15147,26 @@ "type": "string" }, "tags": { - "type": "array", + "description": "A list of tag names to be applied to the database replica.\n", "items": { "type": "string" }, - "description": "A list of tag names to be applied to the database replica.\n" + "type": "array" }, "uri": { - "type": "string", "description": "The full URI for connecting to the database replica.\n", - "secret": true + "secret": true, + "type": "string" }, "user": { - "type": "string", - "description": "Username for the replica's default user.\n" + "description": "Username for the replica's default user.\n", + "type": "string" }, "uuid": { - "type": "string", - "description": "The UUID of the database replica.\n" + "description": "The UUID of the database replica.\n", + "type": "string" } }, - "type": "object", "required": [ "clusterId", "database", @@ -15184,7 +15183,8 @@ "user", "uuid", "id" - ] + ], + "type": "object" } }, "digitalocean:index/getDatabaseUser:getDatabaseUser": { @@ -15211,46 +15211,45 @@ "description": "A collection of values returned by getDatabaseUser.\n", "properties": { "accessCert": { - "type": "string", "description": "Access certificate for TLS client authentication. (Kafka only)\n", - "secret": true + "secret": true, + "type": "string" }, "accessKey": { - "type": "string", "description": "Access key for TLS client authentication. (Kafka only)\n", - "secret": true + "secret": true, + "type": "string" }, "clusterId": { "type": "string" }, "id": { - "type": "string", - "description": "The provider-assigned unique ID for this managed resource.\n" + "description": "The provider-assigned unique ID for this managed resource.\n", + "type": "string" }, "mysqlAuthPlugin": { - "type": "string", - "description": "The authentication method of the MySQL user. The value will be `mysql_native_password` or `caching_sha2_password`.\n" + "description": "The authentication method of the MySQL user. The value will be `mysql_native_password` or `caching_sha2_password`.\n", + "type": "string" }, "name": { "type": "string" }, "password": { - "type": "string", "description": "The password of the database user. This will not be set for MongoDB users.\n", - "secret": true + "secret": true, + "type": "string" }, "role": { - "type": "string", - "description": "The role of the database user. The value will be either `primary` or `normal`.\n" + "description": "The role of the database user. The value will be either `primary` or `normal`.\n", + "type": "string" }, "settings": { - "type": "array", "items": { "$ref": "#/types/digitalocean:index/getDatabaseUserSetting:getDatabaseUserSetting" - } + }, + "type": "array" } }, - "type": "object", "required": [ "accessCert", "accessKey", @@ -15261,7 +15260,8 @@ "role", "settings", "id" - ] + ], + "type": "object" } }, "digitalocean:index/getDomain:getDomain": { @@ -15283,37 +15283,37 @@ "description": "A collection of values returned by getDomain.\n", "properties": { "domainUrn": { - "type": "string", - "description": "The uniform resource name of the domain\n" + "description": "The uniform resource name of the domain\n", + "type": "string" }, "id": { - "type": "string", - "description": "The provider-assigned unique ID for this managed resource.\n" + "description": "The provider-assigned unique ID for this managed resource.\n", + "type": "string" }, "name": { "type": "string" }, "ttl": { - "type": "integer", - "description": "The TTL of the domain.\n" + "description": "The TTL of the domain.\n", + "type": "integer" }, "zoneFile": { - "type": "string", - "description": "The zone file of the domain.\n" + "description": "The zone file of the domain.\n", + "type": "string" } }, - "type": "object", "required": [ "name", "ttl", "domainUrn", "zoneFile", "id" - ] + ], + "type": "object" } }, "digitalocean:index/getDomains:getDomains": { - "description": "Get information on domains for use in other resources, with the ability to filter and sort the results.\nIf no filters are specified, all domains will be returned.\n\nThis data source is useful if the domains in question are not managed by this provider or you need to\nutilize any of the domains' data.\n\nNote: You can use the `digitalocean.Domain` data source to obtain metadata\nabout a single domain if you already know the `name`.\n\n## Example Usage\n\nUse the `filter` block with a `key` string and `values` list to filter domains. (This example\nalso uses the regular expression `match_by` mode in order to match domains by suffix.)\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst examples = digitalocean.getDomains({\n filters: [{\n key: \"name\",\n matchBy: \"re\",\n values: [\"example\\\\.com$\"],\n }],\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nexamples = digitalocean.get_domains(filters=[digitalocean.GetDomainsFilterArgs(\n key=\"name\",\n match_by=\"re\",\n values=[\"example\\\\.com$\"],\n)])\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var examples = DigitalOcean.GetDomains.Invoke(new()\n {\n Filters = new[]\n {\n new DigitalOcean.Inputs.GetDomainsFilterInputArgs\n {\n Key = \"name\",\n MatchBy = \"re\",\n Values = new[]\n {\n \"example\\\\.com$\",\n },\n },\n },\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := digitalocean.GetDomains(ctx, \u0026digitalocean.GetDomainsArgs{\n\t\t\tFilters: []digitalocean.GetDomainsFilter{\n\t\t\t\t{\n\t\t\t\t\tKey: \"name\",\n\t\t\t\t\tMatchBy: pulumi.StringRef(\"re\"),\n\t\t\t\t\tValues: []string{\n\t\t\t\t\t\t\"example\\\\.com$\",\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t},\n\t\t}, nil)\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.digitalocean.DigitaloceanFunctions;\nimport com.pulumi.digitalocean.inputs.GetDomainsArgs;\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 final var examples = DigitaloceanFunctions.getDomains(GetDomainsArgs.builder()\n .filters(GetDomainsFilterArgs.builder()\n .key(\"name\")\n .matchBy(\"re\")\n .values(\"example\\\\.com$\")\n .build())\n .build());\n\n }\n}\n```\n```yaml\nvariables:\n examples:\n fn::invoke:\n Function: digitalocean:getDomains\n Arguments:\n filters:\n - key: name\n matchBy: re\n values:\n - example\\.com$\n```\n\u003c!--End PulumiCodeChooser --\u003e\n", + "description": "Get information on domains for use in other resources, with the ability to filter and sort the results.\nIf no filters are specified, all domains will be returned.\n\nThis data source is useful if the domains in question are not managed by this provider or you need to\nutilize any of the domains' data.\n\nNote: You can use the `digitalocean.Domain` data source to obtain metadata\nabout a single domain if you already know the `name`.\n\n## Example Usage\n\nUse the `filter` block with a `key` string and `values` list to filter domains. (This example\nalso uses the regular expression `match_by` mode in order to match domains by suffix.)\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst examples = digitalocean.getDomains({\n filters: [{\n key: \"name\",\n values: [\"example\\\\.com$\"],\n matchBy: \"re\",\n }],\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nexamples = digitalocean.get_domains(filters=[digitalocean.GetDomainsFilterArgs(\n key=\"name\",\n values=[\"example\\\\.com$\"],\n match_by=\"re\",\n)])\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var examples = DigitalOcean.GetDomains.Invoke(new()\n {\n Filters = new[]\n {\n new DigitalOcean.Inputs.GetDomainsFilterInputArgs\n {\n Key = \"name\",\n Values = new[]\n {\n \"example\\\\.com$\",\n },\n MatchBy = \"re\",\n },\n },\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := digitalocean.GetDomains(ctx, \u0026digitalocean.GetDomainsArgs{\n\t\t\tFilters: []digitalocean.GetDomainsFilter{\n\t\t\t\t{\n\t\t\t\t\tKey: \"name\",\n\t\t\t\t\tValues: []string{\n\t\t\t\t\t\t\"example\\\\.com$\",\n\t\t\t\t\t},\n\t\t\t\t\tMatchBy: pulumi.StringRef(\"re\"),\n\t\t\t\t},\n\t\t\t},\n\t\t}, nil)\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.digitalocean.DigitaloceanFunctions;\nimport com.pulumi.digitalocean.inputs.GetDomainsArgs;\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 final var examples = DigitaloceanFunctions.getDomains(GetDomainsArgs.builder()\n .filters(GetDomainsFilterArgs.builder()\n .key(\"name\")\n .values(\"example\\\\.com$\")\n .matchBy(\"re\")\n .build())\n .build());\n\n }\n}\n```\n```yaml\nvariables:\n examples:\n fn::invoke:\n Function: digitalocean:getDomains\n Arguments:\n filters:\n - key: name\n values:\n - example\\.com$\n matchBy: re\n```\n\u003c!--End PulumiCodeChooser --\u003e\n", "inputs": { "description": "A collection of arguments for invoking getDomains.\n", "properties": { @@ -15338,38 +15338,38 @@ "description": "A collection of values returned by getDomains.\n", "properties": { "domains": { - "type": "array", + "description": "A list of domains satisfying any `filter` and `sort` criteria. Each domain has the following attributes:\n", "items": { "$ref": "#/types/digitalocean:index/getDomainsDomain:getDomainsDomain" }, - "description": "A list of domains satisfying any `filter` and `sort` criteria. Each domain has the following attributes:\n" + "type": "array" }, "filters": { - "type": "array", "items": { "$ref": "#/types/digitalocean:index/getDomainsFilter:getDomainsFilter" - } + }, + "type": "array" }, "id": { - "type": "string", - "description": "The provider-assigned unique ID for this managed resource.\n" + "description": "The provider-assigned unique ID for this managed resource.\n", + "type": "string" }, "sorts": { - "type": "array", "items": { "$ref": "#/types/digitalocean:index/getDomainsSort:getDomainsSort" - } + }, + "type": "array" } }, - "type": "object", "required": [ "domains", "id" - ] + ], + "type": "object" } }, "digitalocean:index/getDroplet:getDroplet": { - "description": "Get information on a Droplet for use in other resources. This data source provides\nall of the Droplet's properties as configured on your DigitalOcean account. This\nis useful if the Droplet in question is not managed by this provider or you need to\nutilize any of the Droplet's data.\n\n**Note:** This data source returns a single Droplet. When specifying a `tag`, an\nerror is triggered if more than one Droplet is found.\n\n## Example Usage\n\nGet the Droplet by name:\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst example = digitalocean.getDroplet({\n name: \"web\",\n});\nexport const dropletOutput = example.then(example =\u003e example.ipv4Address);\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nexample = digitalocean.get_droplet(name=\"web\")\npulumi.export(\"dropletOutput\", example.ipv4_address)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var example = DigitalOcean.GetDroplet.Invoke(new()\n {\n Name = \"web\",\n });\n\n return new Dictionary\u003cstring, object?\u003e\n {\n [\"dropletOutput\"] = example.Apply(getDropletResult =\u003e getDropletResult.Ipv4Address),\n };\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\texample, err := digitalocean.LookupDroplet(ctx, \u0026digitalocean.LookupDropletArgs{\n\t\t\tName: pulumi.StringRef(\"web\"),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tctx.Export(\"dropletOutput\", example.Ipv4Address)\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.digitalocean.DigitaloceanFunctions;\nimport com.pulumi.digitalocean.inputs.GetDropletArgs;\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 final var example = DigitaloceanFunctions.getDroplet(GetDropletArgs.builder()\n .name(\"web\")\n .build());\n\n ctx.export(\"dropletOutput\", example.applyValue(getDropletResult -\u003e getDropletResult.ipv4Address()));\n }\n}\n```\n```yaml\nvariables:\n example:\n fn::invoke:\n Function: digitalocean:getDroplet\n Arguments:\n name: web\noutputs:\n dropletOutput: ${example.ipv4Address}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\nGet the Droplet by tag:\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst example = digitalocean.getDroplet({\n tag: \"web\",\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nexample = digitalocean.get_droplet(tag=\"web\")\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var example = DigitalOcean.GetDroplet.Invoke(new()\n {\n Tag = \"web\",\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := digitalocean.LookupDroplet(ctx, \u0026digitalocean.LookupDropletArgs{\n\t\t\tTag: pulumi.StringRef(\"web\"),\n\t\t}, nil)\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.digitalocean.DigitaloceanFunctions;\nimport com.pulumi.digitalocean.inputs.GetDropletArgs;\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 final var example = DigitaloceanFunctions.getDroplet(GetDropletArgs.builder()\n .tag(\"web\")\n .build());\n\n }\n}\n```\n```yaml\nvariables:\n example:\n fn::invoke:\n Function: digitalocean:getDroplet\n Arguments:\n tag: web\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\nGet the Droplet by ID:\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst example = digitalocean.getDroplet({\n id: digitalocean_kubernetes_cluster.example.node_pool[0].nodes[0].droplet_id,\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nexample = digitalocean.get_droplet(id=digitalocean_kubernetes_cluster[\"example\"][\"node_pool\"][0][\"nodes\"][0][\"droplet_id\"])\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var example = DigitalOcean.GetDroplet.Invoke(new()\n {\n Id = digitalocean_kubernetes_cluster.Example.Node_pool[0].Nodes[0].Droplet_id,\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := digitalocean.LookupDroplet(ctx, \u0026digitalocean.LookupDropletArgs{\n\t\t\tId: pulumi.IntRef(digitalocean_kubernetes_cluster.Example.Node_pool[0].Nodes[0].Droplet_id),\n\t\t}, nil)\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.digitalocean.DigitaloceanFunctions;\nimport com.pulumi.digitalocean.inputs.GetDropletArgs;\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 final var example = DigitaloceanFunctions.getDroplet(GetDropletArgs.builder()\n .id(digitalocean_kubernetes_cluster.example().node_pool()[0].nodes()[0].droplet_id())\n .build());\n\n }\n}\n```\n```yaml\nvariables:\n example:\n fn::invoke:\n Function: digitalocean:getDroplet\n Arguments:\n id: ${digitalocean_kubernetes_cluster.example.node_pool[0].nodes[0].droplet_id}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n", + "description": "Get information on a Droplet for use in other resources. This data source provides\nall of the Droplet's properties as configured on your DigitalOcean account. This\nis useful if the Droplet in question is not managed by this provider or you need to\nutilize any of the Droplet's data.\n\n**Note:** This data source returns a single Droplet. When specifying a `tag`, an\nerror is triggered if more than one Droplet is found.\n\n## Example Usage\n\nGet the Droplet by name:\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst example = digitalocean.getDroplet({\n name: \"web\",\n});\nexport const dropletOutput = example.then(example =\u003e example.ipv4Address);\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nexample = digitalocean.get_droplet(name=\"web\")\npulumi.export(\"dropletOutput\", example.ipv4_address)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var example = DigitalOcean.GetDroplet.Invoke(new()\n {\n Name = \"web\",\n });\n\n return new Dictionary\u003cstring, object?\u003e\n {\n [\"dropletOutput\"] = example.Apply(getDropletResult =\u003e getDropletResult.Ipv4Address),\n };\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\texample, err := digitalocean.LookupDroplet(ctx, \u0026digitalocean.LookupDropletArgs{\n\t\t\tName: pulumi.StringRef(\"web\"),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tctx.Export(\"dropletOutput\", example.Ipv4Address)\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.digitalocean.DigitaloceanFunctions;\nimport com.pulumi.digitalocean.inputs.GetDropletArgs;\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 final var example = DigitaloceanFunctions.getDroplet(GetDropletArgs.builder()\n .name(\"web\")\n .build());\n\n ctx.export(\"dropletOutput\", example.applyValue(getDropletResult -\u003e getDropletResult.ipv4Address()));\n }\n}\n```\n```yaml\nvariables:\n example:\n fn::invoke:\n Function: digitalocean:getDroplet\n Arguments:\n name: web\noutputs:\n dropletOutput: ${example.ipv4Address}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\nGet the Droplet by tag:\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst example = digitalocean.getDroplet({\n tag: \"web\",\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nexample = digitalocean.get_droplet(tag=\"web\")\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var example = DigitalOcean.GetDroplet.Invoke(new()\n {\n Tag = \"web\",\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := digitalocean.LookupDroplet(ctx, \u0026digitalocean.LookupDropletArgs{\n\t\t\tTag: pulumi.StringRef(\"web\"),\n\t\t}, nil)\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.digitalocean.DigitaloceanFunctions;\nimport com.pulumi.digitalocean.inputs.GetDropletArgs;\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 final var example = DigitaloceanFunctions.getDroplet(GetDropletArgs.builder()\n .tag(\"web\")\n .build());\n\n }\n}\n```\n```yaml\nvariables:\n example:\n fn::invoke:\n Function: digitalocean:getDroplet\n Arguments:\n tag: web\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\nGet the Droplet by ID:\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst example = digitalocean.getDroplet({\n id: exampleDigitaloceanKubernetesCluster.nodePool[0].nodes[0].dropletId,\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nexample = digitalocean.get_droplet(id=example_digitalocean_kubernetes_cluster[\"nodePool\"][0][\"nodes\"][0][\"dropletId\"])\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var example = DigitalOcean.GetDroplet.Invoke(new()\n {\n Id = exampleDigitaloceanKubernetesCluster.NodePool[0].Nodes[0].DropletId,\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := digitalocean.LookupDroplet(ctx, \u0026digitalocean.LookupDropletArgs{\n\t\t\tId: pulumi.IntRef(exampleDigitaloceanKubernetesCluster.NodePool[0].Nodes[0].DropletId),\n\t\t}, nil)\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.digitalocean.DigitaloceanFunctions;\nimport com.pulumi.digitalocean.inputs.GetDropletArgs;\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 final var example = DigitaloceanFunctions.getDroplet(GetDropletArgs.builder()\n .id(exampleDigitaloceanKubernetesCluster.nodePool()[0].nodes()[0].dropletId())\n .build());\n\n }\n}\n```\n```yaml\nvariables:\n example:\n fn::invoke:\n Function: digitalocean:getDroplet\n Arguments:\n id: ${exampleDigitaloceanKubernetesCluster.nodePool[0].nodes[0].dropletId}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n", "inputs": { "description": "A collection of arguments for invoking getDroplet.\n", "properties": { @@ -15392,114 +15392,113 @@ "description": "A collection of values returned by getDroplet.\n", "properties": { "backups": { - "type": "boolean", - "description": "Whether backups are enabled.\n" + "description": "Whether backups are enabled.\n", + "type": "boolean" }, "createdAt": { "type": "string" }, "disk": { - "type": "integer", - "description": "The size of the Droplets disk in GB.\n" + "description": "The size of the Droplets disk in GB.\n", + "type": "integer" }, "id": { - "type": "integer", - "description": "The ID of the Droplet.\n" + "description": "The ID of the Droplet.\n", + "type": "integer" }, "image": { - "type": "string", - "description": "The Droplet image ID or slug.\n" + "description": "The Droplet image ID or slug.\n", + "type": "string" }, "ipv4Address": { - "type": "string", - "description": "The Droplets public IPv4 address\n" + "description": "The Droplets public IPv4 address\n", + "type": "string" }, "ipv4AddressPrivate": { - "type": "string", - "description": "The Droplets private IPv4 address\n" + "description": "The Droplets private IPv4 address\n", + "type": "string" }, "ipv6": { - "type": "boolean", - "description": "Whether IPv6 is enabled.\n" + "description": "Whether IPv6 is enabled.\n", + "type": "boolean" }, "ipv6Address": { - "type": "string", - "description": "The Droplets public IPv6 address\n" + "description": "The Droplets public IPv6 address\n", + "type": "string" }, "ipv6AddressPrivate": { - "type": "string", - "description": "The Droplets private IPv6 address\n" + "description": "The Droplets private IPv6 address\n", + "type": "string" }, "locked": { - "type": "boolean", - "description": "Whether the Droplet is locked.\n" + "description": "Whether the Droplet is locked.\n", + "type": "boolean" }, "memory": { - "type": "integer", - "description": "The amount of the Droplets memory in MB.\n" + "description": "The amount of the Droplets memory in MB.\n", + "type": "integer" }, "monitoring": { - "type": "boolean", - "description": "Whether monitoring agent is installed.\n" + "description": "Whether monitoring agent is installed.\n", + "type": "boolean" }, "name": { "type": "string" }, "priceHourly": { - "type": "number", - "description": "Droplet hourly price.\n" + "description": "Droplet hourly price.\n", + "type": "number" }, "priceMonthly": { - "type": "number", - "description": "Droplet monthly price.\n" + "description": "Droplet monthly price.\n", + "type": "number" }, "privateNetworking": { - "type": "boolean", - "description": "Whether private networks are enabled.\n" + "description": "Whether private networks are enabled.\n", + "type": "boolean" }, "region": { - "type": "string", - "description": "The region the Droplet is running in.\n" + "description": "The region the Droplet is running in.\n", + "type": "string" }, "size": { - "type": "string", - "description": "The unique slug that indentifies the type of Droplet.\n" + "description": "The unique slug that indentifies the type of Droplet.\n", + "type": "string" }, "status": { - "type": "string", - "description": "The status of the Droplet.\n" + "description": "The status of the Droplet.\n", + "type": "string" }, "tag": { "type": "string" }, "tags": { - "type": "array", + "description": "A list of the tags associated to the Droplet.\n", "items": { "type": "string" }, - "description": "A list of the tags associated to the Droplet.\n" + "type": "array" }, "urn": { - "type": "string", - "description": "The uniform resource name of the Droplet\n" + "description": "The uniform resource name of the Droplet\n", + "type": "string" }, "vcpus": { - "type": "integer", - "description": "The number of the Droplets virtual CPUs.\n" + "description": "The number of the Droplets virtual CPUs.\n", + "type": "integer" }, "volumeIds": { - "type": "array", + "description": "List of the IDs of each volumes attached to the Droplet.\n", "items": { "type": "string" }, - "description": "List of the IDs of each volumes attached to the Droplet.\n" + "type": "array" }, "vpcUuid": { - "type": "string", - "description": "The ID of the VPC where the Droplet is located.\n" + "description": "The ID of the VPC where the Droplet is located.\n", + "type": "string" } }, - "type": "object", "required": [ "backups", "createdAt", @@ -15526,11 +15525,12 @@ "vcpus", "volumeIds", "vpcUuid" - ] + ], + "type": "object" } }, "digitalocean:index/getDropletSnapshot:getDropletSnapshot": { - "description": "Droplet snapshots are saved instances of a Droplet. Use this data\nsource to retrieve the ID of a DigitalOcean Droplet snapshot for use in other\nresources.\n\n## Example Usage\n\nGet the Droplet snapshot:\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst web-snapshot = digitalocean.getDropletSnapshot({\n mostRecent: true,\n nameRegex: \"^web\",\n region: \"nyc3\",\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nweb_snapshot = digitalocean.get_droplet_snapshot(most_recent=True,\n name_regex=\"^web\",\n region=\"nyc3\")\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var web_snapshot = DigitalOcean.GetDropletSnapshot.Invoke(new()\n {\n MostRecent = true,\n NameRegex = \"^web\",\n Region = \"nyc3\",\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := digitalocean.LookupDropletSnapshot(ctx, \u0026digitalocean.LookupDropletSnapshotArgs{\n\t\t\tMostRecent: pulumi.BoolRef(true),\n\t\t\tNameRegex: pulumi.StringRef(\"^web\"),\n\t\t\tRegion: pulumi.StringRef(\"nyc3\"),\n\t\t}, nil)\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.digitalocean.DigitaloceanFunctions;\nimport com.pulumi.digitalocean.inputs.GetDropletSnapshotArgs;\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 final var web-snapshot = DigitaloceanFunctions.getDropletSnapshot(GetDropletSnapshotArgs.builder()\n .mostRecent(true)\n .nameRegex(\"^web\")\n .region(\"nyc3\")\n .build());\n\n }\n}\n```\n```yaml\nvariables:\n web-snapshot:\n fn::invoke:\n Function: digitalocean:getDropletSnapshot\n Arguments:\n mostRecent: true\n nameRegex: ^web\n region: nyc3\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\nCreate image from snapshot:\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst web-snapshot = digitalocean.getDropletSnapshot({\n nameRegex: \"^web\",\n region: \"nyc3\",\n mostRecent: true,\n});\nconst from_snapshot = new digitalocean.Droplet(\"from-snapshot\", {\n image: web_snapshot.then(web_snapshot =\u003e web_snapshot.id),\n region: digitalocean.Region.NYC3,\n size: digitalocean.DropletSlug.DropletS2VCPU4GB,\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nweb_snapshot = digitalocean.get_droplet_snapshot(name_regex=\"^web\",\n region=\"nyc3\",\n most_recent=True)\nfrom_snapshot = digitalocean.Droplet(\"from-snapshot\",\n image=web_snapshot.id,\n region=digitalocean.Region.NYC3,\n size=digitalocean.DropletSlug.DROPLET_S2_VCPU4_GB)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var web_snapshot = DigitalOcean.GetDropletSnapshot.Invoke(new()\n {\n NameRegex = \"^web\",\n Region = \"nyc3\",\n MostRecent = true,\n });\n\n var from_snapshot = new DigitalOcean.Droplet(\"from-snapshot\", new()\n {\n Image = web_snapshot.Apply(web_snapshot =\u003e web_snapshot.Apply(getDropletSnapshotResult =\u003e getDropletSnapshotResult.Id)),\n Region = DigitalOcean.Region.NYC3,\n Size = DigitalOcean.DropletSlug.DropletS2VCPU4GB,\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tweb_snapshot, err := digitalocean.LookupDropletSnapshot(ctx, \u0026digitalocean.LookupDropletSnapshotArgs{\n\t\t\tNameRegex: pulumi.StringRef(\"^web\"),\n\t\t\tRegion: pulumi.StringRef(\"nyc3\"),\n\t\t\tMostRecent: pulumi.BoolRef(true),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = digitalocean.NewDroplet(ctx, \"from-snapshot\", \u0026digitalocean.DropletArgs{\n\t\t\tImage: pulumi.String(web_snapshot.Id),\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC3),\n\t\t\tSize: pulumi.String(digitalocean.DropletSlugDropletS2VCPU4GB),\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.digitalocean.DigitaloceanFunctions;\nimport com.pulumi.digitalocean.inputs.GetDropletSnapshotArgs;\nimport com.pulumi.digitalocean.Droplet;\nimport com.pulumi.digitalocean.DropletArgs;\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 final var web-snapshot = DigitaloceanFunctions.getDropletSnapshot(GetDropletSnapshotArgs.builder()\n .nameRegex(\"^web\")\n .region(\"nyc3\")\n .mostRecent(true)\n .build());\n\n var from_snapshot = new Droplet(\"from-snapshot\", DropletArgs.builder() \n .image(web_snapshot.id())\n .region(\"nyc3\")\n .size(\"s-2vcpu-4gb\")\n .build());\n\n }\n}\n```\n```yaml\nresources:\n from-snapshot:\n type: digitalocean:Droplet\n properties:\n image: ${[\"web-snapshot\"].id}\n region: nyc3\n size: s-2vcpu-4gb\nvariables:\n web-snapshot:\n fn::invoke:\n Function: digitalocean:getDropletSnapshot\n Arguments:\n nameRegex: ^web\n region: nyc3\n mostRecent: true\n```\n\u003c!--End PulumiCodeChooser --\u003e\n", + "description": "Droplet snapshots are saved instances of a Droplet. Use this data\nsource to retrieve the ID of a DigitalOcean Droplet snapshot for use in other\nresources.\n\n## Example Usage\n\nGet the Droplet snapshot:\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst web-snapshot = digitalocean.getDropletSnapshot({\n nameRegex: \"^web\",\n region: \"nyc3\",\n mostRecent: true,\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nweb_snapshot = digitalocean.get_droplet_snapshot(name_regex=\"^web\",\n region=\"nyc3\",\n most_recent=True)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var web_snapshot = DigitalOcean.GetDropletSnapshot.Invoke(new()\n {\n NameRegex = \"^web\",\n Region = \"nyc3\",\n MostRecent = true,\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := digitalocean.LookupDropletSnapshot(ctx, \u0026digitalocean.LookupDropletSnapshotArgs{\n\t\t\tNameRegex: pulumi.StringRef(\"^web\"),\n\t\t\tRegion: pulumi.StringRef(\"nyc3\"),\n\t\t\tMostRecent: pulumi.BoolRef(true),\n\t\t}, nil)\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.digitalocean.DigitaloceanFunctions;\nimport com.pulumi.digitalocean.inputs.GetDropletSnapshotArgs;\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 final var web-snapshot = DigitaloceanFunctions.getDropletSnapshot(GetDropletSnapshotArgs.builder()\n .nameRegex(\"^web\")\n .region(\"nyc3\")\n .mostRecent(true)\n .build());\n\n }\n}\n```\n```yaml\nvariables:\n web-snapshot:\n fn::invoke:\n Function: digitalocean:getDropletSnapshot\n Arguments:\n nameRegex: ^web\n region: nyc3\n mostRecent: true\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\nCreate image from snapshot:\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst web-snapshot = digitalocean.getDropletSnapshot({\n nameRegex: \"^web\",\n region: \"nyc3\",\n mostRecent: true,\n});\nconst from_snapshot = new digitalocean.Droplet(\"from-snapshot\", {\n image: web_snapshot.then(web_snapshot =\u003e web_snapshot.id),\n name: \"web-02\",\n region: digitalocean.Region.NYC3,\n size: digitalocean.DropletSlug.DropletS2VCPU4GB,\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nweb_snapshot = digitalocean.get_droplet_snapshot(name_regex=\"^web\",\n region=\"nyc3\",\n most_recent=True)\nfrom_snapshot = digitalocean.Droplet(\"from-snapshot\",\n image=web_snapshot.id,\n name=\"web-02\",\n region=digitalocean.Region.NYC3,\n size=digitalocean.DropletSlug.DROPLET_S2_VCPU4_GB)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var web_snapshot = DigitalOcean.GetDropletSnapshot.Invoke(new()\n {\n NameRegex = \"^web\",\n Region = \"nyc3\",\n MostRecent = true,\n });\n\n var from_snapshot = new DigitalOcean.Droplet(\"from-snapshot\", new()\n {\n Image = web_snapshot.Apply(web_snapshot =\u003e web_snapshot.Apply(getDropletSnapshotResult =\u003e getDropletSnapshotResult.Id)),\n Name = \"web-02\",\n Region = DigitalOcean.Region.NYC3,\n Size = DigitalOcean.DropletSlug.DropletS2VCPU4GB,\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tweb_snapshot, err := digitalocean.LookupDropletSnapshot(ctx, \u0026digitalocean.LookupDropletSnapshotArgs{\n\t\t\tNameRegex: pulumi.StringRef(\"^web\"),\n\t\t\tRegion: pulumi.StringRef(\"nyc3\"),\n\t\t\tMostRecent: pulumi.BoolRef(true),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = digitalocean.NewDroplet(ctx, \"from-snapshot\", \u0026digitalocean.DropletArgs{\n\t\t\tImage: pulumi.String(web_snapshot.Id),\n\t\t\tName: pulumi.String(\"web-02\"),\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC3),\n\t\t\tSize: pulumi.String(digitalocean.DropletSlugDropletS2VCPU4GB),\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.digitalocean.DigitaloceanFunctions;\nimport com.pulumi.digitalocean.inputs.GetDropletSnapshotArgs;\nimport com.pulumi.digitalocean.Droplet;\nimport com.pulumi.digitalocean.DropletArgs;\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 final var web-snapshot = DigitaloceanFunctions.getDropletSnapshot(GetDropletSnapshotArgs.builder()\n .nameRegex(\"^web\")\n .region(\"nyc3\")\n .mostRecent(true)\n .build());\n\n var from_snapshot = new Droplet(\"from-snapshot\", DropletArgs.builder() \n .image(web_snapshot.id())\n .name(\"web-02\")\n .region(\"nyc3\")\n .size(\"s-2vcpu-4gb\")\n .build());\n\n }\n}\n```\n```yaml\nresources:\n from-snapshot:\n type: digitalocean:Droplet\n properties:\n image: ${[\"web-snapshot\"].id}\n name: web-02\n region: nyc3\n size: s-2vcpu-4gb\nvariables:\n web-snapshot:\n fn::invoke:\n Function: digitalocean:getDropletSnapshot\n Arguments:\n nameRegex: ^web\n region: nyc3\n mostRecent: true\n```\n\u003c!--End PulumiCodeChooser --\u003e\n", "inputs": { "description": "A collection of arguments for invoking getDropletSnapshot.\n", "properties": { @@ -15557,20 +15557,20 @@ "description": "A collection of values returned by getDropletSnapshot.\n", "properties": { "createdAt": { - "type": "string", - "description": "The date and time the Droplet snapshot was created.\n" + "description": "The date and time the Droplet snapshot was created.\n", + "type": "string" }, "dropletId": { - "type": "string", - "description": "The ID of the Droplet from which the Droplet snapshot originated.\n" + "description": "The ID of the Droplet from which the Droplet snapshot originated.\n", + "type": "string" }, "id": { - "type": "string", - "description": "The provider-assigned unique ID for this managed resource.\n" + "description": "The provider-assigned unique ID for this managed resource.\n", + "type": "string" }, "minDiskSize": { - "type": "integer", - "description": "The minimum size in gigabytes required for a Droplet to be created based on this Droplet snapshot.\n" + "description": "The minimum size in gigabytes required for a Droplet to be created based on this Droplet snapshot.\n", + "type": "integer" }, "mostRecent": { "type": "boolean" @@ -15585,18 +15585,17 @@ "type": "string" }, "regions": { - "type": "array", + "description": "A list of DigitalOcean region \"slugs\" indicating where the Droplet snapshot is available.\n", "items": { "type": "string" }, - "description": "A list of DigitalOcean region \"slugs\" indicating where the Droplet snapshot is available.\n" + "type": "array" }, "size": { - "type": "number", - "description": "The billable size of the Droplet snapshot in gigabytes.\n" + "description": "The billable size of the Droplet snapshot in gigabytes.\n", + "type": "number" } }, - "type": "object", "required": [ "createdAt", "dropletId", @@ -15604,11 +15603,12 @@ "regions", "size", "id" - ] + ], + "type": "object" } }, "digitalocean:index/getDroplets:getDroplets": { - "description": "Get information on Droplets for use in other resources, with the ability to filter and sort the results.\nIf no filters are specified, all Droplets will be returned.\n\nThis data source is useful if the Droplets in question are not managed by the provider or you need to\nutilize any of the Droplets' data.\n\nNote: You can use the `digitalocean.Droplet` data source to obtain metadata\nabout a single Droplet if you already know the `id`, unique `name`, or unique `tag` to retrieve.\n\n## Example Usage\n\nUse the `filter` block with a `key` string and `values` list to filter images.\n\nFor example to find all Droplets with size `s-1vcpu-1gb`:\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst small = digitalocean.getDroplets({\n filters: [{\n key: \"size\",\n values: [\"s-1vcpu-1gb\"],\n }],\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nsmall = digitalocean.get_droplets(filters=[digitalocean.GetDropletsFilterArgs(\n key=\"size\",\n values=[\"s-1vcpu-1gb\"],\n)])\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var small = DigitalOcean.GetDroplets.Invoke(new()\n {\n Filters = new[]\n {\n new DigitalOcean.Inputs.GetDropletsFilterInputArgs\n {\n Key = \"size\",\n Values = new[]\n {\n \"s-1vcpu-1gb\",\n },\n },\n },\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := digitalocean.GetDroplets(ctx, \u0026digitalocean.GetDropletsArgs{\n\t\t\tFilters: []digitalocean.GetDropletsFilter{\n\t\t\t\t{\n\t\t\t\t\tKey: \"size\",\n\t\t\t\t\tValues: []string{\n\t\t\t\t\t\t\"s-1vcpu-1gb\",\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t},\n\t\t}, nil)\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.digitalocean.DigitaloceanFunctions;\nimport com.pulumi.digitalocean.inputs.GetDropletsArgs;\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 final var small = DigitaloceanFunctions.getDroplets(GetDropletsArgs.builder()\n .filters(GetDropletsFilterArgs.builder()\n .key(\"size\")\n .values(\"s-1vcpu-1gb\")\n .build())\n .build());\n\n }\n}\n```\n```yaml\nvariables:\n small:\n fn::invoke:\n Function: digitalocean:getDroplets\n Arguments:\n filters:\n - key: size\n values:\n - s-1vcpu-1gb\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\nYou can filter on multiple fields and sort the results as well:\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst small-with-backups = digitalocean.getDroplets({\n filters: [\n {\n key: \"size\",\n values: [\"s-1vcpu-1gb\"],\n },\n {\n key: \"backups\",\n values: [\"true\"],\n },\n ],\n sorts: [{\n direction: \"desc\",\n key: \"created_at\",\n }],\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nsmall_with_backups = digitalocean.get_droplets(filters=[\n digitalocean.GetDropletsFilterArgs(\n key=\"size\",\n values=[\"s-1vcpu-1gb\"],\n ),\n digitalocean.GetDropletsFilterArgs(\n key=\"backups\",\n values=[\"true\"],\n ),\n ],\n sorts=[digitalocean.GetDropletsSortArgs(\n direction=\"desc\",\n key=\"created_at\",\n )])\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var small_with_backups = DigitalOcean.GetDroplets.Invoke(new()\n {\n Filters = new[]\n {\n new DigitalOcean.Inputs.GetDropletsFilterInputArgs\n {\n Key = \"size\",\n Values = new[]\n {\n \"s-1vcpu-1gb\",\n },\n },\n new DigitalOcean.Inputs.GetDropletsFilterInputArgs\n {\n Key = \"backups\",\n Values = new[]\n {\n \"true\",\n },\n },\n },\n Sorts = new[]\n {\n new DigitalOcean.Inputs.GetDropletsSortInputArgs\n {\n Direction = \"desc\",\n Key = \"created_at\",\n },\n },\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := digitalocean.GetDroplets(ctx, \u0026digitalocean.GetDropletsArgs{\n\t\t\tFilters: []digitalocean.GetDropletsFilter{\n\t\t\t\t{\n\t\t\t\t\tKey: \"size\",\n\t\t\t\t\tValues: []string{\n\t\t\t\t\t\t\"s-1vcpu-1gb\",\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t\t{\n\t\t\t\t\tKey: \"backups\",\n\t\t\t\t\tValues: []string{\n\t\t\t\t\t\t\"true\",\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t},\n\t\t\tSorts: []digitalocean.GetDropletsSort{\n\t\t\t\t{\n\t\t\t\t\tDirection: pulumi.StringRef(\"desc\"),\n\t\t\t\t\tKey: \"created_at\",\n\t\t\t\t},\n\t\t\t},\n\t\t}, nil)\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.digitalocean.DigitaloceanFunctions;\nimport com.pulumi.digitalocean.inputs.GetDropletsArgs;\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 final var small-with-backups = DigitaloceanFunctions.getDroplets(GetDropletsArgs.builder()\n .filters( \n GetDropletsFilterArgs.builder()\n .key(\"size\")\n .values(\"s-1vcpu-1gb\")\n .build(),\n GetDropletsFilterArgs.builder()\n .key(\"backups\")\n .values(\"true\")\n .build())\n .sorts(GetDropletsSortArgs.builder()\n .direction(\"desc\")\n .key(\"created_at\")\n .build())\n .build());\n\n }\n}\n```\n```yaml\nvariables:\n small-with-backups:\n fn::invoke:\n Function: digitalocean:getDroplets\n Arguments:\n filters:\n - key: size\n values:\n - s-1vcpu-1gb\n - key: backups\n values:\n - 'true'\n sorts:\n - direction: desc\n key: created_at\n```\n\u003c!--End PulumiCodeChooser --\u003e\n", + "description": "Get information on Droplets for use in other resources, with the ability to filter and sort the results.\nIf no filters are specified, all Droplets will be returned.\n\nThis data source is useful if the Droplets in question are not managed by the provider or you need to\nutilize any of the Droplets' data.\n\nNote: You can use the `digitalocean.Droplet` data source to obtain metadata\nabout a single Droplet if you already know the `id`, unique `name`, or unique `tag` to retrieve.\n\n## Example Usage\n\nUse the `filter` block with a `key` string and `values` list to filter images.\n\nFor example to find all Droplets with size `s-1vcpu-1gb`:\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst small = digitalocean.getDroplets({\n filters: [{\n key: \"size\",\n values: [\"s-1vcpu-1gb\"],\n }],\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nsmall = digitalocean.get_droplets(filters=[digitalocean.GetDropletsFilterArgs(\n key=\"size\",\n values=[\"s-1vcpu-1gb\"],\n)])\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var small = DigitalOcean.GetDroplets.Invoke(new()\n {\n Filters = new[]\n {\n new DigitalOcean.Inputs.GetDropletsFilterInputArgs\n {\n Key = \"size\",\n Values = new[]\n {\n \"s-1vcpu-1gb\",\n },\n },\n },\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := digitalocean.GetDroplets(ctx, \u0026digitalocean.GetDropletsArgs{\n\t\t\tFilters: []digitalocean.GetDropletsFilter{\n\t\t\t\t{\n\t\t\t\t\tKey: \"size\",\n\t\t\t\t\tValues: []string{\n\t\t\t\t\t\t\"s-1vcpu-1gb\",\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t},\n\t\t}, nil)\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.digitalocean.DigitaloceanFunctions;\nimport com.pulumi.digitalocean.inputs.GetDropletsArgs;\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 final var small = DigitaloceanFunctions.getDroplets(GetDropletsArgs.builder()\n .filters(GetDropletsFilterArgs.builder()\n .key(\"size\")\n .values(\"s-1vcpu-1gb\")\n .build())\n .build());\n\n }\n}\n```\n```yaml\nvariables:\n small:\n fn::invoke:\n Function: digitalocean:getDroplets\n Arguments:\n filters:\n - key: size\n values:\n - s-1vcpu-1gb\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\nYou can filter on multiple fields and sort the results as well:\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst small-with-backups = digitalocean.getDroplets({\n filters: [\n {\n key: \"size\",\n values: [\"s-1vcpu-1gb\"],\n },\n {\n key: \"backups\",\n values: [\"true\"],\n },\n ],\n sorts: [{\n key: \"created_at\",\n direction: \"desc\",\n }],\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nsmall_with_backups = digitalocean.get_droplets(filters=[\n digitalocean.GetDropletsFilterArgs(\n key=\"size\",\n values=[\"s-1vcpu-1gb\"],\n ),\n digitalocean.GetDropletsFilterArgs(\n key=\"backups\",\n values=[\"true\"],\n ),\n ],\n sorts=[digitalocean.GetDropletsSortArgs(\n key=\"created_at\",\n direction=\"desc\",\n )])\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var small_with_backups = DigitalOcean.GetDroplets.Invoke(new()\n {\n Filters = new[]\n {\n new DigitalOcean.Inputs.GetDropletsFilterInputArgs\n {\n Key = \"size\",\n Values = new[]\n {\n \"s-1vcpu-1gb\",\n },\n },\n new DigitalOcean.Inputs.GetDropletsFilterInputArgs\n {\n Key = \"backups\",\n Values = new[]\n {\n \"true\",\n },\n },\n },\n Sorts = new[]\n {\n new DigitalOcean.Inputs.GetDropletsSortInputArgs\n {\n Key = \"created_at\",\n Direction = \"desc\",\n },\n },\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := digitalocean.GetDroplets(ctx, \u0026digitalocean.GetDropletsArgs{\n\t\t\tFilters: []digitalocean.GetDropletsFilter{\n\t\t\t\t{\n\t\t\t\t\tKey: \"size\",\n\t\t\t\t\tValues: []string{\n\t\t\t\t\t\t\"s-1vcpu-1gb\",\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t\t{\n\t\t\t\t\tKey: \"backups\",\n\t\t\t\t\tValues: []string{\n\t\t\t\t\t\t\"true\",\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t},\n\t\t\tSorts: []digitalocean.GetDropletsSort{\n\t\t\t\t{\n\t\t\t\t\tKey: \"created_at\",\n\t\t\t\t\tDirection: pulumi.StringRef(\"desc\"),\n\t\t\t\t},\n\t\t\t},\n\t\t}, nil)\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.digitalocean.DigitaloceanFunctions;\nimport com.pulumi.digitalocean.inputs.GetDropletsArgs;\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 final var small-with-backups = DigitaloceanFunctions.getDroplets(GetDropletsArgs.builder()\n .filters( \n GetDropletsFilterArgs.builder()\n .key(\"size\")\n .values(\"s-1vcpu-1gb\")\n .build(),\n GetDropletsFilterArgs.builder()\n .key(\"backups\")\n .values(\"true\")\n .build())\n .sorts(GetDropletsSortArgs.builder()\n .key(\"created_at\")\n .direction(\"desc\")\n .build())\n .build());\n\n }\n}\n```\n```yaml\nvariables:\n small-with-backups:\n fn::invoke:\n Function: digitalocean:getDroplets\n Arguments:\n filters:\n - key: size\n values:\n - s-1vcpu-1gb\n - key: backups\n values:\n - 'true'\n sorts:\n - key: created_at\n direction: desc\n```\n\u003c!--End PulumiCodeChooser --\u003e\n", "inputs": { "description": "A collection of arguments for invoking getDroplets.\n", "properties": { @@ -15633,34 +15633,34 @@ "description": "A collection of values returned by getDroplets.\n", "properties": { "droplets": { - "type": "array", + "description": "A list of Droplets satisfying any `filter` and `sort` criteria. Each Droplet has the following attributes:\n", "items": { "$ref": "#/types/digitalocean:index/getDropletsDroplet:getDropletsDroplet" }, - "description": "A list of Droplets satisfying any `filter` and `sort` criteria. Each Droplet has the following attributes:\n" + "type": "array" }, "filters": { - "type": "array", "items": { "$ref": "#/types/digitalocean:index/getDropletsFilter:getDropletsFilter" - } + }, + "type": "array" }, "id": { - "type": "string", - "description": "The provider-assigned unique ID for this managed resource.\n" + "description": "The provider-assigned unique ID for this managed resource.\n", + "type": "string" }, "sorts": { - "type": "array", "items": { "$ref": "#/types/digitalocean:index/getDropletsSort:getDropletsSort" - } + }, + "type": "array" } }, - "type": "object", "required": [ "droplets", "id" - ] + ], + "type": "object" } }, "digitalocean:index/getFirewall:getFirewall": { @@ -15708,59 +15708,58 @@ "description": "A collection of values returned by getFirewall.\n", "properties": { "createdAt": { - "type": "string", - "description": "A time value given in ISO8601 combined date and time format\nthat represents when the Firewall was created.\n" + "description": "A time value given in ISO8601 combined date and time format\nthat represents when the Firewall was created.\n", + "type": "string" }, "dropletIds": { - "type": "array", + "description": "The list of the IDs of the Droplets assigned to\nthe Firewall.\n", "items": { "type": "integer" }, - "description": "The list of the IDs of the Droplets assigned to\nthe Firewall.\n" + "type": "array" }, "firewallId": { "type": "string" }, "id": { - "type": "string", - "description": "The provider-assigned unique ID for this managed resource.\n" + "description": "The provider-assigned unique ID for this managed resource.\n", + "type": "string" }, "inboundRules": { - "type": "array", "items": { "$ref": "#/types/digitalocean:index/getFirewallInboundRule:getFirewallInboundRule" - } + }, + "type": "array" }, "name": { - "type": "string", - "description": "The name of the Firewall.\n" + "description": "The name of the Firewall.\n", + "type": "string" }, "outboundRules": { - "type": "array", "items": { "$ref": "#/types/digitalocean:index/getFirewallOutboundRule:getFirewallOutboundRule" - } + }, + "type": "array" }, "pendingChanges": { - "type": "array", + "description": "A set of object containing the fields, `droplet_id`,\n`removing`, and `status`. It is provided to detail exactly which Droplets\nare having their security policies updated. When empty, all changes\nhave been successfully applied.\n", "items": { "$ref": "#/types/digitalocean:index/getFirewallPendingChange:getFirewallPendingChange" }, - "description": "A set of object containing the fields, `droplet_id`,\n`removing`, and `status`. It is provided to detail exactly which Droplets\nare having their security policies updated. When empty, all changes\nhave been successfully applied.\n" + "type": "array" }, "status": { - "type": "string", - "description": "A status string indicating the current state of the Firewall.\nThis can be \"waiting\", \"succeeded\", or \"failed\".\n" + "description": "A status string indicating the current state of the Firewall.\nThis can be \"waiting\", \"succeeded\", or \"failed\".\n", + "type": "string" }, "tags": { - "type": "array", + "description": "The names of the Tags assigned to the Firewall.\n", "items": { "type": "string" }, - "description": "The names of the Tags assigned to the Firewall.\n" + "type": "array" } }, - "type": "object", "required": [ "createdAt", "dropletIds", @@ -15772,7 +15771,8 @@ "status", "tags", "id" - ] + ], + "type": "object" } }, "digitalocean:index/getFloatingIp:getFloatingIp": { @@ -15794,37 +15794,37 @@ "description": "A collection of values returned by getFloatingIp.\n", "properties": { "dropletId": { - "type": "integer", - "description": "The Droplet id that the floating IP has been assigned to.\n" + "description": "The Droplet id that the floating IP has been assigned to.\n", + "type": "integer" }, "floatingIpUrn": { - "type": "string", - "description": "The uniform resource name of the floating IP.\n" + "description": "The uniform resource name of the floating IP.\n", + "type": "string" }, "id": { - "type": "string", - "description": "The provider-assigned unique ID for this managed resource.\n" + "description": "The provider-assigned unique ID for this managed resource.\n", + "type": "string" }, "ipAddress": { "type": "string" }, "region": { - "type": "string", - "description": "The region that the floating IP is reserved to.\n" + "description": "The region that the floating IP is reserved to.\n", + "type": "string" } }, - "type": "object", "required": [ "dropletId", "ipAddress", "region", "floatingIpUrn", "id" - ] + ], + "type": "object" } }, "digitalocean:index/getImage:getImage": { - "description": "Get information on an image for use in other resources (e.g. creating a Droplet\nbased on snapshot). This data source provides all of the image properties as\nconfigured on your DigitalOcean account. This is useful if the image in question\nis not managed by the provider or you need to utilize any of the image's data.\n\nAn error is triggered if zero or more than one result is returned by the query.\n\n## Example Usage\n\nGet the data about a snapshot:\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst example1 = digitalocean.getImage({\n name: \"example-1.0.0\",\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nexample1 = digitalocean.get_image(name=\"example-1.0.0\")\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var example1 = DigitalOcean.GetImage.Invoke(new()\n {\n Name = \"example-1.0.0\",\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := digitalocean.GetImage(ctx, \u0026digitalocean.GetImageArgs{\n\t\t\tName: pulumi.StringRef(\"example-1.0.0\"),\n\t\t}, nil)\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.digitalocean.DigitaloceanFunctions;\nimport com.pulumi.digitalocean.inputs.GetImageArgs;\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 final var example1 = DigitaloceanFunctions.getImage(GetImageArgs.builder()\n .name(\"example-1.0.0\")\n .build());\n\n }\n}\n```\n```yaml\nvariables:\n example1:\n fn::invoke:\n Function: digitalocean:getImage\n Arguments:\n name: example-1.0.0\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\nReuse the data about a snapshot to create a Droplet:\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst exampleImage = digitalocean.getImage({\n name: \"example-1.0.0\",\n});\nconst exampleDroplet = new digitalocean.Droplet(\"exampleDroplet\", {\n image: exampleImage.then(exampleImage =\u003e exampleImage.id),\n region: digitalocean.Region.NYC2,\n size: digitalocean.DropletSlug.DropletS1VCPU1GB,\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nexample_image = digitalocean.get_image(name=\"example-1.0.0\")\nexample_droplet = digitalocean.Droplet(\"exampleDroplet\",\n image=example_image.id,\n region=digitalocean.Region.NYC2,\n size=digitalocean.DropletSlug.DROPLET_S1_VCPU1_GB)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var exampleImage = DigitalOcean.GetImage.Invoke(new()\n {\n Name = \"example-1.0.0\",\n });\n\n var exampleDroplet = new DigitalOcean.Droplet(\"exampleDroplet\", new()\n {\n Image = exampleImage.Apply(getImageResult =\u003e getImageResult.Id),\n Region = DigitalOcean.Region.NYC2,\n Size = DigitalOcean.DropletSlug.DropletS1VCPU1GB,\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\texampleImage, err := digitalocean.GetImage(ctx, \u0026digitalocean.GetImageArgs{\n\t\t\tName: pulumi.StringRef(\"example-1.0.0\"),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = digitalocean.NewDroplet(ctx, \"exampleDroplet\", \u0026digitalocean.DropletArgs{\n\t\t\tImage: pulumi.Int(exampleImage.Id),\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC2),\n\t\t\tSize: pulumi.String(digitalocean.DropletSlugDropletS1VCPU1GB),\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.digitalocean.DigitaloceanFunctions;\nimport com.pulumi.digitalocean.inputs.GetImageArgs;\nimport com.pulumi.digitalocean.Droplet;\nimport com.pulumi.digitalocean.DropletArgs;\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 final var exampleImage = DigitaloceanFunctions.getImage(GetImageArgs.builder()\n .name(\"example-1.0.0\")\n .build());\n\n var exampleDroplet = new Droplet(\"exampleDroplet\", DropletArgs.builder() \n .image(exampleImage.applyValue(getImageResult -\u003e getImageResult.id()))\n .region(\"nyc2\")\n .size(\"s-1vcpu-1gb\")\n .build());\n\n }\n}\n```\n```yaml\nresources:\n exampleDroplet:\n type: digitalocean:Droplet\n properties:\n image: ${exampleImage.id}\n region: nyc2\n size: s-1vcpu-1gb\nvariables:\n exampleImage:\n fn::invoke:\n Function: digitalocean:getImage\n Arguments:\n name: example-1.0.0\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\nGet the data about an official image:\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst example2 = digitalocean.getImage({\n slug: \"ubuntu-18-04-x64\",\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nexample2 = digitalocean.get_image(slug=\"ubuntu-18-04-x64\")\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var example2 = DigitalOcean.GetImage.Invoke(new()\n {\n Slug = \"ubuntu-18-04-x64\",\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := digitalocean.GetImage(ctx, \u0026digitalocean.GetImageArgs{\n\t\t\tSlug: pulumi.StringRef(\"ubuntu-18-04-x64\"),\n\t\t}, nil)\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.digitalocean.DigitaloceanFunctions;\nimport com.pulumi.digitalocean.inputs.GetImageArgs;\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 final var example2 = DigitaloceanFunctions.getImage(GetImageArgs.builder()\n .slug(\"ubuntu-18-04-x64\")\n .build());\n\n }\n}\n```\n```yaml\nvariables:\n example2:\n fn::invoke:\n Function: digitalocean:getImage\n Arguments:\n slug: ubuntu-18-04-x64\n```\n\u003c!--End PulumiCodeChooser --\u003e\n", + "description": "Get information on an image for use in other resources (e.g. creating a Droplet\nbased on snapshot). This data source provides all of the image properties as\nconfigured on your DigitalOcean account. This is useful if the image in question\nis not managed by the provider or you need to utilize any of the image's data.\n\nAn error is triggered if zero or more than one result is returned by the query.\n\n## Example Usage\n\nGet the data about a snapshot:\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst example1 = digitalocean.getImage({\n name: \"example-1.0.0\",\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nexample1 = digitalocean.get_image(name=\"example-1.0.0\")\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var example1 = DigitalOcean.GetImage.Invoke(new()\n {\n Name = \"example-1.0.0\",\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := digitalocean.GetImage(ctx, \u0026digitalocean.GetImageArgs{\n\t\t\tName: pulumi.StringRef(\"example-1.0.0\"),\n\t\t}, nil)\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.digitalocean.DigitaloceanFunctions;\nimport com.pulumi.digitalocean.inputs.GetImageArgs;\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 final var example1 = DigitaloceanFunctions.getImage(GetImageArgs.builder()\n .name(\"example-1.0.0\")\n .build());\n\n }\n}\n```\n```yaml\nvariables:\n example1:\n fn::invoke:\n Function: digitalocean:getImage\n Arguments:\n name: example-1.0.0\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\nReuse the data about a snapshot to create a Droplet:\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst example = digitalocean.getImage({\n name: \"example-1.0.0\",\n});\nconst exampleDroplet = new digitalocean.Droplet(\"example\", {\n image: example.then(example =\u003e example.id),\n name: \"example-1\",\n region: digitalocean.Region.NYC2,\n size: digitalocean.DropletSlug.DropletS1VCPU1GB,\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nexample = digitalocean.get_image(name=\"example-1.0.0\")\nexample_droplet = digitalocean.Droplet(\"example\",\n image=example.id,\n name=\"example-1\",\n region=digitalocean.Region.NYC2,\n size=digitalocean.DropletSlug.DROPLET_S1_VCPU1_GB)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var example = DigitalOcean.GetImage.Invoke(new()\n {\n Name = \"example-1.0.0\",\n });\n\n var exampleDroplet = new DigitalOcean.Droplet(\"example\", new()\n {\n Image = example.Apply(getImageResult =\u003e getImageResult.Id),\n Name = \"example-1\",\n Region = DigitalOcean.Region.NYC2,\n Size = DigitalOcean.DropletSlug.DropletS1VCPU1GB,\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\texample, err := digitalocean.GetImage(ctx, \u0026digitalocean.GetImageArgs{\n\t\t\tName: pulumi.StringRef(\"example-1.0.0\"),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = digitalocean.NewDroplet(ctx, \"example\", \u0026digitalocean.DropletArgs{\n\t\t\tImage: pulumi.Int(example.Id),\n\t\t\tName: pulumi.String(\"example-1\"),\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC2),\n\t\t\tSize: pulumi.String(digitalocean.DropletSlugDropletS1VCPU1GB),\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.digitalocean.DigitaloceanFunctions;\nimport com.pulumi.digitalocean.inputs.GetImageArgs;\nimport com.pulumi.digitalocean.Droplet;\nimport com.pulumi.digitalocean.DropletArgs;\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 final var example = DigitaloceanFunctions.getImage(GetImageArgs.builder()\n .name(\"example-1.0.0\")\n .build());\n\n var exampleDroplet = new Droplet(\"exampleDroplet\", DropletArgs.builder() \n .image(example.applyValue(getImageResult -\u003e getImageResult.id()))\n .name(\"example-1\")\n .region(\"nyc2\")\n .size(\"s-1vcpu-1gb\")\n .build());\n\n }\n}\n```\n```yaml\nresources:\n exampleDroplet:\n type: digitalocean:Droplet\n name: example\n properties:\n image: ${example.id}\n name: example-1\n region: nyc2\n size: s-1vcpu-1gb\nvariables:\n example:\n fn::invoke:\n Function: digitalocean:getImage\n Arguments:\n name: example-1.0.0\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\nGet the data about an official image:\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst example2 = digitalocean.getImage({\n slug: \"ubuntu-18-04-x64\",\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nexample2 = digitalocean.get_image(slug=\"ubuntu-18-04-x64\")\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var example2 = DigitalOcean.GetImage.Invoke(new()\n {\n Slug = \"ubuntu-18-04-x64\",\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := digitalocean.GetImage(ctx, \u0026digitalocean.GetImageArgs{\n\t\t\tSlug: pulumi.StringRef(\"ubuntu-18-04-x64\"),\n\t\t}, nil)\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.digitalocean.DigitaloceanFunctions;\nimport com.pulumi.digitalocean.inputs.GetImageArgs;\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 final var example2 = DigitaloceanFunctions.getImage(GetImageArgs.builder()\n .slug(\"ubuntu-18-04-x64\")\n .build());\n\n }\n}\n```\n```yaml\nvariables:\n example2:\n fn::invoke:\n Function: digitalocean:getImage\n Arguments:\n slug: ubuntu-18-04-x64\n```\n\u003c!--End PulumiCodeChooser --\u003e\n", "inputs": { "description": "A collection of arguments for invoking getImage.\n", "properties": { @@ -15851,75 +15851,74 @@ "description": "A collection of values returned by getImage.\n", "properties": { "created": { - "type": "string", - "description": "When the image was created\n" + "description": "When the image was created\n", + "type": "string" }, "description": { "type": "string" }, "distribution": { - "type": "string", - "description": "The name of the distribution of the OS of the image.\n" + "description": "The name of the distribution of the OS of the image.\n", + "type": "string" }, "errorMessage": { - "type": "string", - "description": "Any applicable error message pertaining to the image\n" + "description": "Any applicable error message pertaining to the image\n", + "type": "string" }, "id": { - "type": "integer", - "description": "The ID of the image.\n" + "description": "The ID of the image.\n", + "type": "integer" }, "image": { - "type": "string", - "description": "The id of the image (legacy parameter).\n" + "description": "The id of the image (legacy parameter).\n", + "type": "string" }, "minDiskSize": { - "type": "integer", - "description": "The minimum 'disk' required for the image.\n" + "description": "The minimum 'disk' required for the image.\n", + "type": "integer" }, "name": { - "type": "string", - "description": "The name of the image.\n" + "description": "The name of the image.\n", + "type": "string" }, "private": { - "type": "boolean", - "description": "Is image a public image or not. Public images represent\nLinux distributions or One-Click Applications, while non-public images represent\nsnapshots and backups and are only available within your account.\n" + "description": "Is image a public image or not. Public images represent\nLinux distributions or One-Click Applications, while non-public images represent\nsnapshots and backups and are only available within your account.\n", + "type": "boolean" }, "regions": { - "type": "array", + "description": "A set of the regions that the image is available in.\n", "items": { "type": "string" }, - "description": "A set of the regions that the image is available in.\n" + "type": "array" }, "sizeGigabytes": { - "type": "number", - "description": "The size of the image in GB.\n" + "description": "The size of the image in GB.\n", + "type": "number" }, "slug": { - "type": "string", - "description": "Unique text identifier of the image.\n" + "description": "Unique text identifier of the image.\n", + "type": "string" }, "source": { "type": "string" }, "status": { - "type": "string", - "description": "Current status of the image\n" + "description": "Current status of the image\n", + "type": "string" }, "tags": { - "type": "array", + "description": "A set of tags applied to the image\n", "items": { "type": "string" }, - "description": "A set of tags applied to the image\n" + "type": "array" }, "type": { - "type": "string", - "description": "Type of the image.\n" + "description": "Type of the image.\n", + "type": "string" } }, - "type": "object", "required": [ "created", "description", @@ -15936,11 +15935,12 @@ "status", "tags", "type" - ] + ], + "type": "object" } }, "digitalocean:index/getImages:getImages": { - "description": "Get information on images for use in other resources (e.g. creating a Droplet\nbased on a snapshot), with the ability to filter and sort the results. If no filters are specified,\nall images will be returned.\n\nThis data source is useful if the image in question is not managed by the provider or you need to utilize any\nof the image's data.\n\nNote: You can use the `digitalocean.getImage` data source to obtain metadata\nabout a single image if you already know the `slug`, unique `name`, or `id` to retrieve.\n\n## Example Usage\n\nUse the `filter` block with a `key` string and `values` list to filter images.\n\nFor example to find all Ubuntu images:\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst ubuntu = digitalocean.getImages({\n filters: [{\n key: \"distribution\",\n values: [\"Ubuntu\"],\n }],\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nubuntu = digitalocean.get_images(filters=[digitalocean.GetImagesFilterArgs(\n key=\"distribution\",\n values=[\"Ubuntu\"],\n)])\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var ubuntu = DigitalOcean.GetImages.Invoke(new()\n {\n Filters = new[]\n {\n new DigitalOcean.Inputs.GetImagesFilterInputArgs\n {\n Key = \"distribution\",\n Values = new[]\n {\n \"Ubuntu\",\n },\n },\n },\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := digitalocean.GetImages(ctx, \u0026digitalocean.GetImagesArgs{\n\t\t\tFilters: []digitalocean.GetImagesFilter{\n\t\t\t\t{\n\t\t\t\t\tKey: \"distribution\",\n\t\t\t\t\tValues: []string{\n\t\t\t\t\t\t\"Ubuntu\",\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t},\n\t\t}, nil)\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.digitalocean.DigitaloceanFunctions;\nimport com.pulumi.digitalocean.inputs.GetImagesArgs;\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 final var ubuntu = DigitaloceanFunctions.getImages(GetImagesArgs.builder()\n .filters(GetImagesFilterArgs.builder()\n .key(\"distribution\")\n .values(\"Ubuntu\")\n .build())\n .build());\n\n }\n}\n```\n```yaml\nvariables:\n ubuntu:\n fn::invoke:\n Function: digitalocean:getImages\n Arguments:\n filters:\n - key: distribution\n values:\n - Ubuntu\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\nYou can filter on multiple fields and sort the results as well:\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst available = digitalocean.getImages({\n filters: [\n {\n key: \"distribution\",\n values: [\"Ubuntu\"],\n },\n {\n key: \"regions\",\n values: [\"nyc3\"],\n },\n ],\n sorts: [{\n direction: \"desc\",\n key: \"created\",\n }],\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\navailable = digitalocean.get_images(filters=[\n digitalocean.GetImagesFilterArgs(\n key=\"distribution\",\n values=[\"Ubuntu\"],\n ),\n digitalocean.GetImagesFilterArgs(\n key=\"regions\",\n values=[\"nyc3\"],\n ),\n ],\n sorts=[digitalocean.GetImagesSortArgs(\n direction=\"desc\",\n key=\"created\",\n )])\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var available = DigitalOcean.GetImages.Invoke(new()\n {\n Filters = new[]\n {\n new DigitalOcean.Inputs.GetImagesFilterInputArgs\n {\n Key = \"distribution\",\n Values = new[]\n {\n \"Ubuntu\",\n },\n },\n new DigitalOcean.Inputs.GetImagesFilterInputArgs\n {\n Key = \"regions\",\n Values = new[]\n {\n \"nyc3\",\n },\n },\n },\n Sorts = new[]\n {\n new DigitalOcean.Inputs.GetImagesSortInputArgs\n {\n Direction = \"desc\",\n Key = \"created\",\n },\n },\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := digitalocean.GetImages(ctx, \u0026digitalocean.GetImagesArgs{\n\t\t\tFilters: []digitalocean.GetImagesFilter{\n\t\t\t\t{\n\t\t\t\t\tKey: \"distribution\",\n\t\t\t\t\tValues: []string{\n\t\t\t\t\t\t\"Ubuntu\",\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t\t{\n\t\t\t\t\tKey: \"regions\",\n\t\t\t\t\tValues: []string{\n\t\t\t\t\t\t\"nyc3\",\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t},\n\t\t\tSorts: []digitalocean.GetImagesSort{\n\t\t\t\t{\n\t\t\t\t\tDirection: pulumi.StringRef(\"desc\"),\n\t\t\t\t\tKey: \"created\",\n\t\t\t\t},\n\t\t\t},\n\t\t}, nil)\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.digitalocean.DigitaloceanFunctions;\nimport com.pulumi.digitalocean.inputs.GetImagesArgs;\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 final var available = DigitaloceanFunctions.getImages(GetImagesArgs.builder()\n .filters( \n GetImagesFilterArgs.builder()\n .key(\"distribution\")\n .values(\"Ubuntu\")\n .build(),\n GetImagesFilterArgs.builder()\n .key(\"regions\")\n .values(\"nyc3\")\n .build())\n .sorts(GetImagesSortArgs.builder()\n .direction(\"desc\")\n .key(\"created\")\n .build())\n .build());\n\n }\n}\n```\n```yaml\nvariables:\n available:\n fn::invoke:\n Function: digitalocean:getImages\n Arguments:\n filters:\n - key: distribution\n values:\n - Ubuntu\n - key: regions\n values:\n - nyc3\n sorts:\n - direction: desc\n key: created\n```\n\u003c!--End PulumiCodeChooser --\u003e\n", + "description": "Get information on images for use in other resources (e.g. creating a Droplet\nbased on a snapshot), with the ability to filter and sort the results. If no filters are specified,\nall images will be returned.\n\nThis data source is useful if the image in question is not managed by the provider or you need to utilize any\nof the image's data.\n\nNote: You can use the `digitalocean.getImage` data source to obtain metadata\nabout a single image if you already know the `slug`, unique `name`, or `id` to retrieve.\n\n## Example Usage\n\nUse the `filter` block with a `key` string and `values` list to filter images.\n\nFor example to find all Ubuntu images:\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst ubuntu = digitalocean.getImages({\n filters: [{\n key: \"distribution\",\n values: [\"Ubuntu\"],\n }],\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nubuntu = digitalocean.get_images(filters=[digitalocean.GetImagesFilterArgs(\n key=\"distribution\",\n values=[\"Ubuntu\"],\n)])\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var ubuntu = DigitalOcean.GetImages.Invoke(new()\n {\n Filters = new[]\n {\n new DigitalOcean.Inputs.GetImagesFilterInputArgs\n {\n Key = \"distribution\",\n Values = new[]\n {\n \"Ubuntu\",\n },\n },\n },\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := digitalocean.GetImages(ctx, \u0026digitalocean.GetImagesArgs{\n\t\t\tFilters: []digitalocean.GetImagesFilter{\n\t\t\t\t{\n\t\t\t\t\tKey: \"distribution\",\n\t\t\t\t\tValues: []string{\n\t\t\t\t\t\t\"Ubuntu\",\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t},\n\t\t}, nil)\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.digitalocean.DigitaloceanFunctions;\nimport com.pulumi.digitalocean.inputs.GetImagesArgs;\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 final var ubuntu = DigitaloceanFunctions.getImages(GetImagesArgs.builder()\n .filters(GetImagesFilterArgs.builder()\n .key(\"distribution\")\n .values(\"Ubuntu\")\n .build())\n .build());\n\n }\n}\n```\n```yaml\nvariables:\n ubuntu:\n fn::invoke:\n Function: digitalocean:getImages\n Arguments:\n filters:\n - key: distribution\n values:\n - Ubuntu\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\nYou can filter on multiple fields and sort the results as well:\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst available = digitalocean.getImages({\n filters: [\n {\n key: \"distribution\",\n values: [\"Ubuntu\"],\n },\n {\n key: \"regions\",\n values: [\"nyc3\"],\n },\n ],\n sorts: [{\n key: \"created\",\n direction: \"desc\",\n }],\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\navailable = digitalocean.get_images(filters=[\n digitalocean.GetImagesFilterArgs(\n key=\"distribution\",\n values=[\"Ubuntu\"],\n ),\n digitalocean.GetImagesFilterArgs(\n key=\"regions\",\n values=[\"nyc3\"],\n ),\n ],\n sorts=[digitalocean.GetImagesSortArgs(\n key=\"created\",\n direction=\"desc\",\n )])\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var available = DigitalOcean.GetImages.Invoke(new()\n {\n Filters = new[]\n {\n new DigitalOcean.Inputs.GetImagesFilterInputArgs\n {\n Key = \"distribution\",\n Values = new[]\n {\n \"Ubuntu\",\n },\n },\n new DigitalOcean.Inputs.GetImagesFilterInputArgs\n {\n Key = \"regions\",\n Values = new[]\n {\n \"nyc3\",\n },\n },\n },\n Sorts = new[]\n {\n new DigitalOcean.Inputs.GetImagesSortInputArgs\n {\n Key = \"created\",\n Direction = \"desc\",\n },\n },\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := digitalocean.GetImages(ctx, \u0026digitalocean.GetImagesArgs{\n\t\t\tFilters: []digitalocean.GetImagesFilter{\n\t\t\t\t{\n\t\t\t\t\tKey: \"distribution\",\n\t\t\t\t\tValues: []string{\n\t\t\t\t\t\t\"Ubuntu\",\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t\t{\n\t\t\t\t\tKey: \"regions\",\n\t\t\t\t\tValues: []string{\n\t\t\t\t\t\t\"nyc3\",\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t},\n\t\t\tSorts: []digitalocean.GetImagesSort{\n\t\t\t\t{\n\t\t\t\t\tKey: \"created\",\n\t\t\t\t\tDirection: pulumi.StringRef(\"desc\"),\n\t\t\t\t},\n\t\t\t},\n\t\t}, nil)\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.digitalocean.DigitaloceanFunctions;\nimport com.pulumi.digitalocean.inputs.GetImagesArgs;\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 final var available = DigitaloceanFunctions.getImages(GetImagesArgs.builder()\n .filters( \n GetImagesFilterArgs.builder()\n .key(\"distribution\")\n .values(\"Ubuntu\")\n .build(),\n GetImagesFilterArgs.builder()\n .key(\"regions\")\n .values(\"nyc3\")\n .build())\n .sorts(GetImagesSortArgs.builder()\n .key(\"created\")\n .direction(\"desc\")\n .build())\n .build());\n\n }\n}\n```\n```yaml\nvariables:\n available:\n fn::invoke:\n Function: digitalocean:getImages\n Arguments:\n filters:\n - key: distribution\n values:\n - Ubuntu\n - key: regions\n values:\n - nyc3\n sorts:\n - key: created\n direction: desc\n```\n\u003c!--End PulumiCodeChooser --\u003e\n", "inputs": { "description": "A collection of arguments for invoking getImages.\n", "properties": { @@ -15965,38 +15965,38 @@ "description": "A collection of values returned by getImages.\n", "properties": { "filters": { - "type": "array", "items": { "$ref": "#/types/digitalocean:index/getImagesFilter:getImagesFilter" - } + }, + "type": "array" }, "id": { - "type": "string", - "description": "The provider-assigned unique ID for this managed resource.\n" + "description": "The provider-assigned unique ID for this managed resource.\n", + "type": "string" }, "images": { - "type": "array", + "description": "A set of images satisfying any `filter` and `sort` criteria. Each image has the following attributes:\n", "items": { "$ref": "#/types/digitalocean:index/getImagesImage:getImagesImage" }, - "description": "A set of images satisfying any `filter` and `sort` criteria. Each image has the following attributes:\n" + "type": "array" }, "sorts": { - "type": "array", "items": { "$ref": "#/types/digitalocean:index/getImagesSort:getImagesSort" - } + }, + "type": "array" } }, - "type": "object", "required": [ "images", "id" - ] + ], + "type": "object" } }, "digitalocean:index/getKubernetesCluster:getKubernetesCluster": { - "description": "Retrieves information about a DigitalOcean Kubernetes cluster for use in other resources. This data source provides all of the cluster's properties as configured on your DigitalOcean account. This is useful if the cluster in question is not managed by the provider.\n\n", + "description": "Retrieves information about a DigitalOcean Kubernetes cluster for use in other resources. This data source provides all of the cluster's properties as configured on your DigitalOcean account. This is useful if the cluster in question is not managed by the provider.\n\n## Example Usage\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst example = digitalocean.getKubernetesCluster({\n name: \"prod-cluster-01\",\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nexample = digitalocean.get_kubernetes_cluster(name=\"prod-cluster-01\")\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var example = DigitalOcean.GetKubernetesCluster.Invoke(new()\n {\n Name = \"prod-cluster-01\",\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := digitalocean.LookupKubernetesCluster(ctx, \u0026digitalocean.LookupKubernetesClusterArgs{\n\t\t\tName: \"prod-cluster-01\",\n\t\t}, nil)\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.digitalocean.DigitaloceanFunctions;\nimport com.pulumi.digitalocean.inputs.GetKubernetesClusterArgs;\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 final var example = DigitaloceanFunctions.getKubernetesCluster(GetKubernetesClusterArgs.builder()\n .name(\"prod-cluster-01\")\n .build());\n\n }\n}\n```\n```yaml\nvariables:\n example:\n fn::invoke:\n Function: digitalocean:getKubernetesCluster\n Arguments:\n name: prod-cluster-01\n```\n\u003c!--End PulumiCodeChooser --\u003e\n", "inputs": { "description": "A collection of arguments for invoking getKubernetesCluster.\n", "properties": { @@ -16021,98 +16021,97 @@ "description": "A collection of values returned by getKubernetesCluster.\n", "properties": { "autoUpgrade": { - "type": "boolean", - "description": "A boolean value indicating whether the cluster will be automatically upgraded to new patch releases during its maintenance window.\n" + "description": "A boolean value indicating whether the cluster will be automatically upgraded to new patch releases during its maintenance window.\n", + "type": "boolean" }, "clusterSubnet": { - "type": "string", - "description": "The range of IP addresses in the overlay network of the Kubernetes cluster.\n" + "description": "The range of IP addresses in the overlay network of the Kubernetes cluster.\n", + "type": "string" }, "createdAt": { - "type": "string", - "description": "The date and time when the node was created.\n" + "description": "The date and time when the node was created.\n", + "type": "string" }, "endpoint": { - "type": "string", - "description": "The base URL of the API server on the Kubernetes master node.\n" + "description": "The base URL of the API server on the Kubernetes master node.\n", + "type": "string" }, "ha": { "type": "boolean" }, "id": { - "type": "string", - "description": "The provider-assigned unique ID for this managed resource.\n" + "description": "The provider-assigned unique ID for this managed resource.\n", + "type": "string" }, "ipv4Address": { - "type": "string", - "description": "The public IPv4 address of the Kubernetes master node.\n" + "description": "The public IPv4 address of the Kubernetes master node.\n", + "type": "string" }, "kubeConfigs": { - "type": "array", + "description": "A representation of the Kubernetes cluster's kubeconfig with the following attributes:\n", "items": { "$ref": "#/types/digitalocean:index/getKubernetesClusterKubeConfig:getKubernetesClusterKubeConfig" }, - "description": "A representation of the Kubernetes cluster's kubeconfig with the following attributes:\n", - "secret": true + "secret": true, + "type": "array" }, "maintenancePolicies": { - "type": "array", + "description": "The maintenance policy of the Kubernetes cluster. Digital Ocean has a default maintenancen window.\n", "items": { "$ref": "#/types/digitalocean:index/getKubernetesClusterMaintenancePolicy:getKubernetesClusterMaintenancePolicy" }, - "description": "The maintenance policy of the Kubernetes cluster. Digital Ocean has a default maintenancen window.\n" + "type": "array" }, "name": { - "type": "string", - "description": "The auto-generated name for the node.\n" + "description": "The auto-generated name for the node.\n", + "type": "string" }, "nodePools": { - "type": "array", + "description": "A list of node pools associated with the cluster. Each node pool exports the following attributes:\n", "items": { "$ref": "#/types/digitalocean:index/getKubernetesClusterNodePool:getKubernetesClusterNodePool" }, - "description": "A list of node pools associated with the cluster. Each node pool exports the following attributes:\n" + "type": "array" }, "region": { - "type": "string", - "description": "The slug identifier for the region where the Kubernetes cluster is located.\n" + "description": "The slug identifier for the region where the Kubernetes cluster is located.\n", + "type": "string" }, "serviceSubnet": { - "type": "string", - "description": "The range of assignable IP addresses for services running in the Kubernetes cluster.\n" + "description": "The range of assignable IP addresses for services running in the Kubernetes cluster.\n", + "type": "string" }, "status": { - "type": "string", - "description": "A string indicating the current status of the individual node.\n" + "description": "A string indicating the current status of the individual node.\n", + "type": "string" }, "surgeUpgrade": { "type": "boolean" }, "tags": { - "type": "array", + "description": "A list of tag names applied to the node pool.\n", "items": { "type": "string" }, - "description": "A list of tag names applied to the node pool.\n" + "type": "array" }, "updatedAt": { - "type": "string", - "description": "The date and time when the node was last updated.\n" + "description": "The date and time when the node was last updated.\n", + "type": "string" }, "urn": { - "type": "string", - "description": "The uniform resource name (URN) for the Kubernetes cluster.\n" + "description": "The uniform resource name (URN) for the Kubernetes cluster.\n", + "type": "string" }, "version": { - "type": "string", - "description": "The slug identifier for the version of Kubernetes used for the cluster.\n" + "description": "The slug identifier for the version of Kubernetes used for the cluster.\n", + "type": "string" }, "vpcUuid": { - "type": "string", - "description": "The ID of the VPC where the Kubernetes cluster is located.\n" + "description": "The ID of the VPC where the Kubernetes cluster is located.\n", + "type": "string" } }, - "type": "object", "required": [ "autoUpgrade", "clusterSubnet", @@ -16133,11 +16132,12 @@ "version", "vpcUuid", "id" - ] + ], + "type": "object" } }, "digitalocean:index/getKubernetesVersions:getKubernetesVersions": { - "description": "Provides access to the available DigitalOcean Kubernetes Service versions.\n\n## Example Usage\n\n### Output a list of all available versions\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nexport = async () =\u003e {\n const example = await digitalocean.getKubernetesVersions({});\n return {\n \"k8s-versions\": example.validVersions,\n };\n}\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nexample = digitalocean.get_kubernetes_versions()\npulumi.export(\"k8s-versions\", example.valid_versions)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var example = DigitalOcean.GetKubernetesVersions.Invoke();\n\n return new Dictionary\u003cstring, object?\u003e\n {\n [\"k8s-versions\"] = example.Apply(getKubernetesVersionsResult =\u003e getKubernetesVersionsResult.ValidVersions),\n };\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\texample, err := digitalocean.GetKubernetesVersions(ctx, nil, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tctx.Export(\"k8s-versions\", example.ValidVersions)\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.digitalocean.DigitaloceanFunctions;\nimport com.pulumi.digitalocean.inputs.GetKubernetesVersionsArgs;\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 final var example = DigitaloceanFunctions.getKubernetesVersions();\n\n ctx.export(\"k8s-versions\", example.applyValue(getKubernetesVersionsResult -\u003e getKubernetesVersionsResult.validVersions()));\n }\n}\n```\n```yaml\nvariables:\n example:\n fn::invoke:\n Function: digitalocean:getKubernetesVersions\n Arguments: {}\noutputs:\n k8s-versions: ${example.validVersions}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n### Create a Kubernetes cluster using the most recent version available\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst example = digitalocean.getKubernetesVersions({});\nconst example_cluster = new digitalocean.KubernetesCluster(\"example-cluster\", {\n region: digitalocean.Region.LON1,\n version: example.then(example =\u003e example.latestVersion),\n nodePool: {\n name: \"default\",\n size: \"s-1vcpu-2gb\",\n nodeCount: 3,\n },\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nexample = digitalocean.get_kubernetes_versions()\nexample_cluster = digitalocean.KubernetesCluster(\"example-cluster\",\n region=digitalocean.Region.LON1,\n version=example.latest_version,\n node_pool=digitalocean.KubernetesClusterNodePoolArgs(\n name=\"default\",\n size=\"s-1vcpu-2gb\",\n node_count=3,\n ))\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var example = DigitalOcean.GetKubernetesVersions.Invoke();\n\n var example_cluster = new DigitalOcean.KubernetesCluster(\"example-cluster\", new()\n {\n Region = DigitalOcean.Region.LON1,\n Version = example.Apply(getKubernetesVersionsResult =\u003e getKubernetesVersionsResult.LatestVersion),\n NodePool = new DigitalOcean.Inputs.KubernetesClusterNodePoolArgs\n {\n Name = \"default\",\n Size = \"s-1vcpu-2gb\",\n NodeCount = 3,\n },\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\texample, err := digitalocean.GetKubernetesVersions(ctx, nil, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = digitalocean.NewKubernetesCluster(ctx, \"example-cluster\", \u0026digitalocean.KubernetesClusterArgs{\n\t\t\tRegion: pulumi.String(digitalocean.RegionLON1),\n\t\t\tVersion: pulumi.String(example.LatestVersion),\n\t\t\tNodePool: \u0026digitalocean.KubernetesClusterNodePoolArgs{\n\t\t\t\tName: pulumi.String(\"default\"),\n\t\t\t\tSize: pulumi.String(\"s-1vcpu-2gb\"),\n\t\t\t\tNodeCount: pulumi.Int(3),\n\t\t\t},\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.digitalocean.DigitaloceanFunctions;\nimport com.pulumi.digitalocean.inputs.GetKubernetesVersionsArgs;\nimport com.pulumi.digitalocean.KubernetesCluster;\nimport com.pulumi.digitalocean.KubernetesClusterArgs;\nimport com.pulumi.digitalocean.inputs.KubernetesClusterNodePoolArgs;\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 final var example = DigitaloceanFunctions.getKubernetesVersions();\n\n var example_cluster = new KubernetesCluster(\"example-cluster\", KubernetesClusterArgs.builder() \n .region(\"lon1\")\n .version(example.applyValue(getKubernetesVersionsResult -\u003e getKubernetesVersionsResult.latestVersion()))\n .nodePool(KubernetesClusterNodePoolArgs.builder()\n .name(\"default\")\n .size(\"s-1vcpu-2gb\")\n .nodeCount(3)\n .build())\n .build());\n\n }\n}\n```\n```yaml\nresources:\n example-cluster:\n type: digitalocean:KubernetesCluster\n properties:\n region: lon1\n version: ${example.latestVersion}\n nodePool:\n name: default\n size: s-1vcpu-2gb\n nodeCount: 3\nvariables:\n example:\n fn::invoke:\n Function: digitalocean:getKubernetesVersions\n Arguments: {}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n### Pin a Kubernetes cluster to a specific minor version\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst example = digitalocean.getKubernetesVersions({\n versionPrefix: \"1.22.\",\n});\nconst example_cluster = new digitalocean.KubernetesCluster(\"example-cluster\", {\n region: digitalocean.Region.LON1,\n version: example.then(example =\u003e example.latestVersion),\n nodePool: {\n name: \"default\",\n size: \"s-1vcpu-2gb\",\n nodeCount: 3,\n },\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nexample = digitalocean.get_kubernetes_versions(version_prefix=\"1.22.\")\nexample_cluster = digitalocean.KubernetesCluster(\"example-cluster\",\n region=digitalocean.Region.LON1,\n version=example.latest_version,\n node_pool=digitalocean.KubernetesClusterNodePoolArgs(\n name=\"default\",\n size=\"s-1vcpu-2gb\",\n node_count=3,\n ))\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var example = DigitalOcean.GetKubernetesVersions.Invoke(new()\n {\n VersionPrefix = \"1.22.\",\n });\n\n var example_cluster = new DigitalOcean.KubernetesCluster(\"example-cluster\", new()\n {\n Region = DigitalOcean.Region.LON1,\n Version = example.Apply(getKubernetesVersionsResult =\u003e getKubernetesVersionsResult.LatestVersion),\n NodePool = new DigitalOcean.Inputs.KubernetesClusterNodePoolArgs\n {\n Name = \"default\",\n Size = \"s-1vcpu-2gb\",\n NodeCount = 3,\n },\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\texample, err := digitalocean.GetKubernetesVersions(ctx, \u0026digitalocean.GetKubernetesVersionsArgs{\n\t\t\tVersionPrefix: pulumi.StringRef(\"1.22.\"),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = digitalocean.NewKubernetesCluster(ctx, \"example-cluster\", \u0026digitalocean.KubernetesClusterArgs{\n\t\t\tRegion: pulumi.String(digitalocean.RegionLON1),\n\t\t\tVersion: pulumi.String(example.LatestVersion),\n\t\t\tNodePool: \u0026digitalocean.KubernetesClusterNodePoolArgs{\n\t\t\t\tName: pulumi.String(\"default\"),\n\t\t\t\tSize: pulumi.String(\"s-1vcpu-2gb\"),\n\t\t\t\tNodeCount: pulumi.Int(3),\n\t\t\t},\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.digitalocean.DigitaloceanFunctions;\nimport com.pulumi.digitalocean.inputs.GetKubernetesVersionsArgs;\nimport com.pulumi.digitalocean.KubernetesCluster;\nimport com.pulumi.digitalocean.KubernetesClusterArgs;\nimport com.pulumi.digitalocean.inputs.KubernetesClusterNodePoolArgs;\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 final var example = DigitaloceanFunctions.getKubernetesVersions(GetKubernetesVersionsArgs.builder()\n .versionPrefix(\"1.22.\")\n .build());\n\n var example_cluster = new KubernetesCluster(\"example-cluster\", KubernetesClusterArgs.builder() \n .region(\"lon1\")\n .version(example.applyValue(getKubernetesVersionsResult -\u003e getKubernetesVersionsResult.latestVersion()))\n .nodePool(KubernetesClusterNodePoolArgs.builder()\n .name(\"default\")\n .size(\"s-1vcpu-2gb\")\n .nodeCount(3)\n .build())\n .build());\n\n }\n}\n```\n```yaml\nresources:\n example-cluster:\n type: digitalocean:KubernetesCluster\n properties:\n region: lon1\n version: ${example.latestVersion}\n nodePool:\n name: default\n size: s-1vcpu-2gb\n nodeCount: 3\nvariables:\n example:\n fn::invoke:\n Function: digitalocean:getKubernetesVersions\n Arguments:\n versionPrefix: 1.22.\n```\n\u003c!--End PulumiCodeChooser --\u003e\n", + "description": "Provides access to the available DigitalOcean Kubernetes Service versions.\n\n## Example Usage\n\n### Output a list of all available versions\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nexport = async () =\u003e {\n const example = await digitalocean.getKubernetesVersions({});\n return {\n \"k8s-versions\": example.validVersions,\n };\n}\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nexample = digitalocean.get_kubernetes_versions()\npulumi.export(\"k8s-versions\", example.valid_versions)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var example = DigitalOcean.GetKubernetesVersions.Invoke();\n\n return new Dictionary\u003cstring, object?\u003e\n {\n [\"k8s-versions\"] = example.Apply(getKubernetesVersionsResult =\u003e getKubernetesVersionsResult.ValidVersions),\n };\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\texample, err := digitalocean.GetKubernetesVersions(ctx, nil, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\tctx.Export(\"k8s-versions\", example.ValidVersions)\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.digitalocean.DigitaloceanFunctions;\nimport com.pulumi.digitalocean.inputs.GetKubernetesVersionsArgs;\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 final var example = DigitaloceanFunctions.getKubernetesVersions();\n\n ctx.export(\"k8s-versions\", example.applyValue(getKubernetesVersionsResult -\u003e getKubernetesVersionsResult.validVersions()));\n }\n}\n```\n```yaml\nvariables:\n example:\n fn::invoke:\n Function: digitalocean:getKubernetesVersions\n Arguments: {}\noutputs:\n k8s-versions: ${example.validVersions}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n### Create a Kubernetes cluster using the most recent version available\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst example = digitalocean.getKubernetesVersions({});\nconst example_cluster = new digitalocean.KubernetesCluster(\"example-cluster\", {\n name: \"example-cluster\",\n region: digitalocean.Region.LON1,\n version: example.then(example =\u003e example.latestVersion),\n nodePool: {\n name: \"default\",\n size: \"s-1vcpu-2gb\",\n nodeCount: 3,\n },\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nexample = digitalocean.get_kubernetes_versions()\nexample_cluster = digitalocean.KubernetesCluster(\"example-cluster\",\n name=\"example-cluster\",\n region=digitalocean.Region.LON1,\n version=example.latest_version,\n node_pool=digitalocean.KubernetesClusterNodePoolArgs(\n name=\"default\",\n size=\"s-1vcpu-2gb\",\n node_count=3,\n ))\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var example = DigitalOcean.GetKubernetesVersions.Invoke();\n\n var example_cluster = new DigitalOcean.KubernetesCluster(\"example-cluster\", new()\n {\n Name = \"example-cluster\",\n Region = DigitalOcean.Region.LON1,\n Version = example.Apply(getKubernetesVersionsResult =\u003e getKubernetesVersionsResult.LatestVersion),\n NodePool = new DigitalOcean.Inputs.KubernetesClusterNodePoolArgs\n {\n Name = \"default\",\n Size = \"s-1vcpu-2gb\",\n NodeCount = 3,\n },\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\texample, err := digitalocean.GetKubernetesVersions(ctx, nil, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = digitalocean.NewKubernetesCluster(ctx, \"example-cluster\", \u0026digitalocean.KubernetesClusterArgs{\n\t\t\tName: pulumi.String(\"example-cluster\"),\n\t\t\tRegion: pulumi.String(digitalocean.RegionLON1),\n\t\t\tVersion: pulumi.String(example.LatestVersion),\n\t\t\tNodePool: \u0026digitalocean.KubernetesClusterNodePoolArgs{\n\t\t\t\tName: pulumi.String(\"default\"),\n\t\t\t\tSize: pulumi.String(\"s-1vcpu-2gb\"),\n\t\t\t\tNodeCount: pulumi.Int(3),\n\t\t\t},\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.digitalocean.DigitaloceanFunctions;\nimport com.pulumi.digitalocean.inputs.GetKubernetesVersionsArgs;\nimport com.pulumi.digitalocean.KubernetesCluster;\nimport com.pulumi.digitalocean.KubernetesClusterArgs;\nimport com.pulumi.digitalocean.inputs.KubernetesClusterNodePoolArgs;\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 final var example = DigitaloceanFunctions.getKubernetesVersions();\n\n var example_cluster = new KubernetesCluster(\"example-cluster\", KubernetesClusterArgs.builder() \n .name(\"example-cluster\")\n .region(\"lon1\")\n .version(example.applyValue(getKubernetesVersionsResult -\u003e getKubernetesVersionsResult.latestVersion()))\n .nodePool(KubernetesClusterNodePoolArgs.builder()\n .name(\"default\")\n .size(\"s-1vcpu-2gb\")\n .nodeCount(3)\n .build())\n .build());\n\n }\n}\n```\n```yaml\nresources:\n example-cluster:\n type: digitalocean:KubernetesCluster\n properties:\n name: example-cluster\n region: lon1\n version: ${example.latestVersion}\n nodePool:\n name: default\n size: s-1vcpu-2gb\n nodeCount: 3\nvariables:\n example:\n fn::invoke:\n Function: digitalocean:getKubernetesVersions\n Arguments: {}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\n### Pin a Kubernetes cluster to a specific minor version\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst example = digitalocean.getKubernetesVersions({\n versionPrefix: \"1.22.\",\n});\nconst example_cluster = new digitalocean.KubernetesCluster(\"example-cluster\", {\n name: \"example-cluster\",\n region: digitalocean.Region.LON1,\n version: example.then(example =\u003e example.latestVersion),\n nodePool: {\n name: \"default\",\n size: \"s-1vcpu-2gb\",\n nodeCount: 3,\n },\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nexample = digitalocean.get_kubernetes_versions(version_prefix=\"1.22.\")\nexample_cluster = digitalocean.KubernetesCluster(\"example-cluster\",\n name=\"example-cluster\",\n region=digitalocean.Region.LON1,\n version=example.latest_version,\n node_pool=digitalocean.KubernetesClusterNodePoolArgs(\n name=\"default\",\n size=\"s-1vcpu-2gb\",\n node_count=3,\n ))\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var example = DigitalOcean.GetKubernetesVersions.Invoke(new()\n {\n VersionPrefix = \"1.22.\",\n });\n\n var example_cluster = new DigitalOcean.KubernetesCluster(\"example-cluster\", new()\n {\n Name = \"example-cluster\",\n Region = DigitalOcean.Region.LON1,\n Version = example.Apply(getKubernetesVersionsResult =\u003e getKubernetesVersionsResult.LatestVersion),\n NodePool = new DigitalOcean.Inputs.KubernetesClusterNodePoolArgs\n {\n Name = \"default\",\n Size = \"s-1vcpu-2gb\",\n NodeCount = 3,\n },\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\texample, err := digitalocean.GetKubernetesVersions(ctx, \u0026digitalocean.GetKubernetesVersionsArgs{\n\t\t\tVersionPrefix: pulumi.StringRef(\"1.22.\"),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = digitalocean.NewKubernetesCluster(ctx, \"example-cluster\", \u0026digitalocean.KubernetesClusterArgs{\n\t\t\tName: pulumi.String(\"example-cluster\"),\n\t\t\tRegion: pulumi.String(digitalocean.RegionLON1),\n\t\t\tVersion: pulumi.String(example.LatestVersion),\n\t\t\tNodePool: \u0026digitalocean.KubernetesClusterNodePoolArgs{\n\t\t\t\tName: pulumi.String(\"default\"),\n\t\t\t\tSize: pulumi.String(\"s-1vcpu-2gb\"),\n\t\t\t\tNodeCount: pulumi.Int(3),\n\t\t\t},\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.digitalocean.DigitaloceanFunctions;\nimport com.pulumi.digitalocean.inputs.GetKubernetesVersionsArgs;\nimport com.pulumi.digitalocean.KubernetesCluster;\nimport com.pulumi.digitalocean.KubernetesClusterArgs;\nimport com.pulumi.digitalocean.inputs.KubernetesClusterNodePoolArgs;\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 final var example = DigitaloceanFunctions.getKubernetesVersions(GetKubernetesVersionsArgs.builder()\n .versionPrefix(\"1.22.\")\n .build());\n\n var example_cluster = new KubernetesCluster(\"example-cluster\", KubernetesClusterArgs.builder() \n .name(\"example-cluster\")\n .region(\"lon1\")\n .version(example.applyValue(getKubernetesVersionsResult -\u003e getKubernetesVersionsResult.latestVersion()))\n .nodePool(KubernetesClusterNodePoolArgs.builder()\n .name(\"default\")\n .size(\"s-1vcpu-2gb\")\n .nodeCount(3)\n .build())\n .build());\n\n }\n}\n```\n```yaml\nresources:\n example-cluster:\n type: digitalocean:KubernetesCluster\n properties:\n name: example-cluster\n region: lon1\n version: ${example.latestVersion}\n nodePool:\n name: default\n size: s-1vcpu-2gb\n nodeCount: 3\nvariables:\n example:\n fn::invoke:\n Function: digitalocean:getKubernetesVersions\n Arguments:\n versionPrefix: 1.22.\n```\n\u003c!--End PulumiCodeChooser --\u003e\n", "inputs": { "description": "A collection of arguments for invoking getKubernetesVersions.\n", "properties": { @@ -16152,30 +16152,30 @@ "description": "A collection of values returned by getKubernetesVersions.\n", "properties": { "id": { - "type": "string", - "description": "The provider-assigned unique ID for this managed resource.\n" + "description": "The provider-assigned unique ID for this managed resource.\n", + "type": "string" }, "latestVersion": { - "type": "string", - "description": "The most recent version available.\n" + "description": "The most recent version available.\n", + "type": "string" }, "validVersions": { - "type": "array", + "description": "A list of available versions.\n", "items": { "type": "string" }, - "description": "A list of available versions.\n" + "type": "array" }, "versionPrefix": { "type": "string" } }, - "type": "object", "required": [ "latestVersion", "validVersions", "id" - ] + ], + "type": "object" } }, "digitalocean:index/getLoadBalancer:getLoadBalancer": { @@ -16198,23 +16198,23 @@ "description": "A collection of values returned by getLoadBalancer.\n", "properties": { "algorithm": { - "type": "string", - "deprecationMessage": "This field has been deprecated. You can no longer specify an algorithm for load balancers." + "deprecationMessage": "This field has been deprecated. You can no longer specify an algorithm for load balancers.", + "type": "string" }, "disableLetsEncryptDnsRecords": { "type": "boolean" }, "domains": { - "type": "array", "items": { "$ref": "#/types/digitalocean:index/getLoadBalancerDomain:getLoadBalancerDomain" - } + }, + "type": "array" }, "dropletIds": { - "type": "array", "items": { "type": "integer" - } + }, + "type": "array" }, "dropletTag": { "type": "string" @@ -16226,28 +16226,28 @@ "type": "boolean" }, "firewalls": { - "type": "array", "items": { "$ref": "#/types/digitalocean:index/getLoadBalancerFirewall:getLoadBalancerFirewall" - } + }, + "type": "array" }, "forwardingRules": { - "type": "array", "items": { "$ref": "#/types/digitalocean:index/getLoadBalancerForwardingRule:getLoadBalancerForwardingRule" - } + }, + "type": "array" }, "glbSettings": { - "type": "array", "items": { "$ref": "#/types/digitalocean:index/getLoadBalancerGlbSetting:getLoadBalancerGlbSetting" - } + }, + "type": "array" }, "healthchecks": { - "type": "array", "items": { "$ref": "#/types/digitalocean:index/getLoadBalancerHealthcheck:getLoadBalancerHealthcheck" - } + }, + "type": "array" }, "httpIdleTimeoutSeconds": { "type": "integer" @@ -16283,16 +16283,16 @@ "type": "string" }, "stickySessions": { - "type": "array", "items": { "$ref": "#/types/digitalocean:index/getLoadBalancerStickySession:getLoadBalancerStickySession" - } + }, + "type": "array" }, "targetLoadBalancerIds": { - "type": "array", "items": { "type": "string" - } + }, + "type": "array" }, "type": { "type": "string" @@ -16301,7 +16301,6 @@ "type": "string" } }, - "type": "object", "required": [ "algorithm", "disableLetsEncryptDnsRecords", @@ -16327,7 +16326,8 @@ "type", "loadBalancerUrn", "vpcUuid" - ] + ], + "type": "object" } }, "digitalocean:index/getProject:getProject": { @@ -16350,16 +16350,16 @@ "description": "A collection of values returned by getProject.\n", "properties": { "createdAt": { - "type": "string", - "description": "The date and time when the project was created, (ISO8601)\n" + "description": "The date and time when the project was created, (ISO8601)\n", + "type": "string" }, "description": { - "type": "string", - "description": "The description of the project\n" + "description": "The description of the project\n", + "type": "string" }, "environment": { - "type": "string", - "description": "The environment of the project's resources. The possible values are: `Development`, `Staging`, `Production`.\n" + "description": "The environment of the project's resources. The possible values are: `Development`, `Staging`, `Production`.\n", + "type": "string" }, "id": { "type": "string" @@ -16371,30 +16371,29 @@ "type": "string" }, "ownerId": { - "type": "integer", - "description": "The ID of the project owner.\n" + "description": "The ID of the project owner.\n", + "type": "integer" }, "ownerUuid": { - "type": "string", - "description": "The unique universal identifier of the project owner.\n" + "description": "The unique universal identifier of the project owner.\n", + "type": "string" }, "purpose": { - "type": "string", - "description": "The purpose of the project, (Default: \"Web Application\")\n" + "description": "The purpose of the project, (Default: \"Web Application\")\n", + "type": "string" }, "resources": { - "type": "array", + "description": "A set of uniform resource names (URNs) for the resources associated with the project\n", "items": { "type": "string" }, - "description": "A set of uniform resource names (URNs) for the resources associated with the project\n" + "type": "array" }, "updatedAt": { - "type": "string", - "description": "The date and time when the project was last updated, (ISO8601)\n" + "description": "The date and time when the project was last updated, (ISO8601)\n", + "type": "string" } }, - "type": "object", "required": [ "createdAt", "description", @@ -16407,11 +16406,12 @@ "purpose", "resources", "updatedAt" - ] + ], + "type": "object" } }, "digitalocean:index/getProjects:getProjects": { - "description": "Retrieve information about all DigitalOcean projects associated with an account, with\nthe ability to filter and sort the results. If no filters are specified, all projects\nwill be returned.\n\nNote: You can use the `digitalocean.Project` data source to\nobtain metadata about a single project if you already know the `id` to retrieve or the unique\n`name` of the project.\n\n## Example Usage\n\nUse the `filter` block with a `key` string and `values` list to filter projects.\n\nFor example to find all staging environment projects:\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst staging = digitalocean.getProjects({\n filters: [{\n key: \"environment\",\n values: [\"Staging\"],\n }],\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nstaging = digitalocean.get_projects(filters=[digitalocean.GetProjectsFilterArgs(\n key=\"environment\",\n values=[\"Staging\"],\n)])\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var staging = DigitalOcean.GetProjects.Invoke(new()\n {\n Filters = new[]\n {\n new DigitalOcean.Inputs.GetProjectsFilterInputArgs\n {\n Key = \"environment\",\n Values = new[]\n {\n \"Staging\",\n },\n },\n },\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := digitalocean.GetProjects(ctx, \u0026digitalocean.GetProjectsArgs{\n\t\t\tFilters: []digitalocean.GetProjectsFilter{\n\t\t\t\t{\n\t\t\t\t\tKey: \"environment\",\n\t\t\t\t\tValues: []string{\n\t\t\t\t\t\t\"Staging\",\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t},\n\t\t}, nil)\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.digitalocean.DigitaloceanFunctions;\nimport com.pulumi.digitalocean.inputs.GetProjectsArgs;\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 final var staging = DigitaloceanFunctions.getProjects(GetProjectsArgs.builder()\n .filters(GetProjectsFilterArgs.builder()\n .key(\"environment\")\n .values(\"Staging\")\n .build())\n .build());\n\n }\n}\n```\n```yaml\nvariables:\n staging:\n fn::invoke:\n Function: digitalocean:getProjects\n Arguments:\n filters:\n - key: environment\n values:\n - Staging\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\nYou can filter on multiple fields and sort the results as well:\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst non-default-production = digitalocean.getProjects({\n filters: [\n {\n key: \"environment\",\n values: [\"Production\"],\n },\n {\n key: \"is_default\",\n values: [\"false\"],\n },\n ],\n sorts: [{\n direction: \"asc\",\n key: \"name\",\n }],\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nnon_default_production = digitalocean.get_projects(filters=[\n digitalocean.GetProjectsFilterArgs(\n key=\"environment\",\n values=[\"Production\"],\n ),\n digitalocean.GetProjectsFilterArgs(\n key=\"is_default\",\n values=[\"false\"],\n ),\n ],\n sorts=[digitalocean.GetProjectsSortArgs(\n direction=\"asc\",\n key=\"name\",\n )])\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var non_default_production = DigitalOcean.GetProjects.Invoke(new()\n {\n Filters = new[]\n {\n new DigitalOcean.Inputs.GetProjectsFilterInputArgs\n {\n Key = \"environment\",\n Values = new[]\n {\n \"Production\",\n },\n },\n new DigitalOcean.Inputs.GetProjectsFilterInputArgs\n {\n Key = \"is_default\",\n Values = new[]\n {\n \"false\",\n },\n },\n },\n Sorts = new[]\n {\n new DigitalOcean.Inputs.GetProjectsSortInputArgs\n {\n Direction = \"asc\",\n Key = \"name\",\n },\n },\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := digitalocean.GetProjects(ctx, \u0026digitalocean.GetProjectsArgs{\n\t\t\tFilters: []digitalocean.GetProjectsFilter{\n\t\t\t\t{\n\t\t\t\t\tKey: \"environment\",\n\t\t\t\t\tValues: []string{\n\t\t\t\t\t\t\"Production\",\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t\t{\n\t\t\t\t\tKey: \"is_default\",\n\t\t\t\t\tValues: []string{\n\t\t\t\t\t\t\"false\",\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t},\n\t\t\tSorts: []digitalocean.GetProjectsSort{\n\t\t\t\t{\n\t\t\t\t\tDirection: pulumi.StringRef(\"asc\"),\n\t\t\t\t\tKey: \"name\",\n\t\t\t\t},\n\t\t\t},\n\t\t}, nil)\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.digitalocean.DigitaloceanFunctions;\nimport com.pulumi.digitalocean.inputs.GetProjectsArgs;\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 final var non-default-production = DigitaloceanFunctions.getProjects(GetProjectsArgs.builder()\n .filters( \n GetProjectsFilterArgs.builder()\n .key(\"environment\")\n .values(\"Production\")\n .build(),\n GetProjectsFilterArgs.builder()\n .key(\"is_default\")\n .values(\"false\")\n .build())\n .sorts(GetProjectsSortArgs.builder()\n .direction(\"asc\")\n .key(\"name\")\n .build())\n .build());\n\n }\n}\n```\n```yaml\nvariables:\n non-default-production:\n fn::invoke:\n Function: digitalocean:getProjects\n Arguments:\n filters:\n - key: environment\n values:\n - Production\n - key: is_default\n values:\n - 'false'\n sorts:\n - direction: asc\n key: name\n```\n\u003c!--End PulumiCodeChooser --\u003e\n", + "description": "Retrieve information about all DigitalOcean projects associated with an account, with\nthe ability to filter and sort the results. If no filters are specified, all projects\nwill be returned.\n\nNote: You can use the `digitalocean.Project` data source to\nobtain metadata about a single project if you already know the `id` to retrieve or the unique\n`name` of the project.\n\n## Example Usage\n\nUse the `filter` block with a `key` string and `values` list to filter projects.\n\nFor example to find all staging environment projects:\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst staging = digitalocean.getProjects({\n filters: [{\n key: \"environment\",\n values: [\"Staging\"],\n }],\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nstaging = digitalocean.get_projects(filters=[digitalocean.GetProjectsFilterArgs(\n key=\"environment\",\n values=[\"Staging\"],\n)])\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var staging = DigitalOcean.GetProjects.Invoke(new()\n {\n Filters = new[]\n {\n new DigitalOcean.Inputs.GetProjectsFilterInputArgs\n {\n Key = \"environment\",\n Values = new[]\n {\n \"Staging\",\n },\n },\n },\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := digitalocean.GetProjects(ctx, \u0026digitalocean.GetProjectsArgs{\n\t\t\tFilters: []digitalocean.GetProjectsFilter{\n\t\t\t\t{\n\t\t\t\t\tKey: \"environment\",\n\t\t\t\t\tValues: []string{\n\t\t\t\t\t\t\"Staging\",\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t},\n\t\t}, nil)\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.digitalocean.DigitaloceanFunctions;\nimport com.pulumi.digitalocean.inputs.GetProjectsArgs;\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 final var staging = DigitaloceanFunctions.getProjects(GetProjectsArgs.builder()\n .filters(GetProjectsFilterArgs.builder()\n .key(\"environment\")\n .values(\"Staging\")\n .build())\n .build());\n\n }\n}\n```\n```yaml\nvariables:\n staging:\n fn::invoke:\n Function: digitalocean:getProjects\n Arguments:\n filters:\n - key: environment\n values:\n - Staging\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\nYou can filter on multiple fields and sort the results as well:\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst non-default-production = digitalocean.getProjects({\n filters: [\n {\n key: \"environment\",\n values: [\"Production\"],\n },\n {\n key: \"is_default\",\n values: [\"false\"],\n },\n ],\n sorts: [{\n key: \"name\",\n direction: \"asc\",\n }],\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nnon_default_production = digitalocean.get_projects(filters=[\n digitalocean.GetProjectsFilterArgs(\n key=\"environment\",\n values=[\"Production\"],\n ),\n digitalocean.GetProjectsFilterArgs(\n key=\"is_default\",\n values=[\"false\"],\n ),\n ],\n sorts=[digitalocean.GetProjectsSortArgs(\n key=\"name\",\n direction=\"asc\",\n )])\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var non_default_production = DigitalOcean.GetProjects.Invoke(new()\n {\n Filters = new[]\n {\n new DigitalOcean.Inputs.GetProjectsFilterInputArgs\n {\n Key = \"environment\",\n Values = new[]\n {\n \"Production\",\n },\n },\n new DigitalOcean.Inputs.GetProjectsFilterInputArgs\n {\n Key = \"is_default\",\n Values = new[]\n {\n \"false\",\n },\n },\n },\n Sorts = new[]\n {\n new DigitalOcean.Inputs.GetProjectsSortInputArgs\n {\n Key = \"name\",\n Direction = \"asc\",\n },\n },\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := digitalocean.GetProjects(ctx, \u0026digitalocean.GetProjectsArgs{\n\t\t\tFilters: []digitalocean.GetProjectsFilter{\n\t\t\t\t{\n\t\t\t\t\tKey: \"environment\",\n\t\t\t\t\tValues: []string{\n\t\t\t\t\t\t\"Production\",\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t\t{\n\t\t\t\t\tKey: \"is_default\",\n\t\t\t\t\tValues: []string{\n\t\t\t\t\t\t\"false\",\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t},\n\t\t\tSorts: []digitalocean.GetProjectsSort{\n\t\t\t\t{\n\t\t\t\t\tKey: \"name\",\n\t\t\t\t\tDirection: pulumi.StringRef(\"asc\"),\n\t\t\t\t},\n\t\t\t},\n\t\t}, nil)\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.digitalocean.DigitaloceanFunctions;\nimport com.pulumi.digitalocean.inputs.GetProjectsArgs;\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 final var non-default-production = DigitaloceanFunctions.getProjects(GetProjectsArgs.builder()\n .filters( \n GetProjectsFilterArgs.builder()\n .key(\"environment\")\n .values(\"Production\")\n .build(),\n GetProjectsFilterArgs.builder()\n .key(\"is_default\")\n .values(\"false\")\n .build())\n .sorts(GetProjectsSortArgs.builder()\n .key(\"name\")\n .direction(\"asc\")\n .build())\n .build());\n\n }\n}\n```\n```yaml\nvariables:\n non-default-production:\n fn::invoke:\n Function: digitalocean:getProjects\n Arguments:\n filters:\n - key: environment\n values:\n - Production\n - key: is_default\n values:\n - 'false'\n sorts:\n - key: name\n direction: asc\n```\n\u003c!--End PulumiCodeChooser --\u003e\n", "inputs": { "description": "A collection of arguments for invoking getProjects.\n", "properties": { @@ -16436,34 +16436,34 @@ "description": "A collection of values returned by getProjects.\n", "properties": { "filters": { - "type": "array", "items": { "$ref": "#/types/digitalocean:index/getProjectsFilter:getProjectsFilter" - } + }, + "type": "array" }, "id": { - "type": "string", - "description": "The provider-assigned unique ID for this managed resource.\n" + "description": "The provider-assigned unique ID for this managed resource.\n", + "type": "string" }, "projects": { - "type": "array", + "description": "A set of projects satisfying any `filter` and `sort` criteria. Each project has\nthe following attributes:\n", "items": { "$ref": "#/types/digitalocean:index/getProjectsProject:getProjectsProject" }, - "description": "A set of projects satisfying any `filter` and `sort` criteria. Each project has\nthe following attributes:\n" + "type": "array" }, "sorts": { - "type": "array", "items": { "$ref": "#/types/digitalocean:index/getProjectsSort:getProjectsSort" - } + }, + "type": "array" } }, - "type": "object", "required": [ "projects", "id" - ] + ], + "type": "object" } }, "digitalocean:index/getRecord:getRecord": { @@ -16490,49 +16490,48 @@ "description": "A collection of values returned by getRecord.\n", "properties": { "data": { - "type": "string", - "description": "Variable data depending on record type. For example, the \"data\" value for an A record would be the IPv4 address to which the domain will be mapped. For a CAA record, it would contain the domain name of the CA being granted permission to issue certificates.\n" + "description": "Variable data depending on record type. For example, the \"data\" value for an A record would be the IPv4 address to which the domain will be mapped. For a CAA record, it would contain the domain name of the CA being granted permission to issue certificates.\n", + "type": "string" }, "domain": { "type": "string" }, "flags": { - "type": "integer", - "description": "An unsigned integer between 0-255 used for CAA records.\n" + "description": "An unsigned integer between 0-255 used for CAA records.\n", + "type": "integer" }, "id": { - "type": "string", - "description": "The provider-assigned unique ID for this managed resource.\n" + "description": "The provider-assigned unique ID for this managed resource.\n", + "type": "string" }, "name": { "type": "string" }, "port": { - "type": "integer", - "description": "The port for SRV records.\n" + "description": "The port for SRV records.\n", + "type": "integer" }, "priority": { - "type": "integer", - "description": "The priority for SRV and MX records.\n" + "description": "The priority for SRV and MX records.\n", + "type": "integer" }, "tag": { - "type": "string", - "description": "The parameter tag for CAA records.\n" + "description": "The parameter tag for CAA records.\n", + "type": "string" }, "ttl": { - "type": "integer", - "description": "This value is the time to live for the record, in seconds. This defines the time frame that clients can cache queried information before a refresh should be requested.\n" + "description": "This value is the time to live for the record, in seconds. This defines the time frame that clients can cache queried information before a refresh should be requested.\n", + "type": "integer" }, "type": { - "type": "string", - "description": "The type of the DNS record.\n" + "description": "The type of the DNS record.\n", + "type": "string" }, "weight": { - "type": "integer", - "description": "The weight for SRV records.\n" + "description": "The weight for SRV records.\n", + "type": "integer" } }, - "type": "object", "required": [ "data", "domain", @@ -16545,11 +16544,12 @@ "type", "weight", "id" - ] + ], + "type": "object" } }, "digitalocean:index/getRecords:getRecords": { - "description": "Retrieve information about all DNS records within a domain, with the ability to filter and sort the results.\nIf no filters are specified, all records will be returned.\n\n", + "description": "Retrieve information about all DNS records within a domain, with the ability to filter and sort the results.\nIf no filters are specified, all records will be returned.\n\n## Example Usage\n\nGet data for all MX records in a domain:\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\nimport * as std from \"@pulumi/std\";\n\nconst example = digitalocean.getRecords({\n domain: \"example.com\",\n filters: [{\n key: \"type\",\n values: [\"MX\"],\n }],\n});\nexport const mailServers = example.then(example =\u003e std.join({\n separator: \",\",\n input: example.records.map(__item =\u003e __item.value),\n})).then(invoke =\u003e invoke.result);\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\nimport pulumi_std as std\n\nexample = digitalocean.get_records(domain=\"example.com\",\n filters=[digitalocean.GetRecordsFilterArgs(\n key=\"type\",\n values=[\"MX\"],\n )])\npulumi.export(\"mailServers\", std.join(separator=\",\",\n input=[__item.value for __item in example.records]).result)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\nusing Std = Pulumi.Std;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var example = DigitalOcean.GetRecords.Invoke(new()\n {\n Domain = \"example.com\",\n Filters = new[]\n {\n new DigitalOcean.Inputs.GetRecordsFilterInputArgs\n {\n Key = \"type\",\n Values = new[]\n {\n \"MX\",\n },\n },\n },\n });\n\n return new Dictionary\u003cstring, object?\u003e\n {\n [\"mailServers\"] = Std.Join.Invoke(new()\n {\n Separator = \",\",\n Input = example.Apply(getRecordsResult =\u003e getRecordsResult.Records).Select(__item =\u003e __item.Value).ToList(),\n }).Apply(invoke =\u003e invoke.Result),\n };\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi-std/sdk/go/std\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\nfunc main() {\npulumi.Run(func(ctx *pulumi.Context) error {\nexample, err := digitalocean.GetRecords(ctx, \u0026digitalocean.GetRecordsArgs{\nDomain: \"example.com\",\nFilters: []digitalocean.GetRecordsFilter{\n{\nKey: \"type\",\nValues: []string{\n\"MX\",\n},\n},\n},\n}, nil);\nif err != nil {\nreturn err\n}\nctx.Export(\"mailServers\", std.Join(ctx, var splat0 []*string\nfor _, val0 := range example.Records {\nsplat0 = append(splat0, val0.Value)\n}\n\u0026std.JoinArgs{\nSeparator: \",\",\nInput: splat0,\n}, nil).Result)\nreturn nil\n})\n}\n```\n```java\npackage generated_program;\n\nimport com.pulumi.Context;\nimport com.pulumi.Pulumi;\nimport com.pulumi.core.Output;\nimport com.pulumi.digitalocean.DigitaloceanFunctions;\nimport com.pulumi.digitalocean.inputs.GetRecordsArgs;\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 final var example = DigitaloceanFunctions.getRecords(GetRecordsArgs.builder()\n .domain(\"example.com\")\n .filters(GetRecordsFilterArgs.builder()\n .key(\"type\")\n .values(\"MX\")\n .build())\n .build());\n\n ctx.export(\"mailServers\", StdFunctions.join(JoinArgs.builder()\n .separator(\",\")\n .input(example.applyValue(getRecordsResult -\u003e getRecordsResult.records()).stream().map(element -\u003e element.value()).collect(toList()))\n .build()).result());\n }\n}\n```\n\u003c!--End PulumiCodeChooser --\u003e\n", "inputs": { "description": "A collection of arguments for invoking getRecords.\n", "properties": { @@ -16581,38 +16581,38 @@ "description": "A collection of values returned by getRecords.\n", "properties": { "domain": { - "type": "string", - "description": "Domain of the DNS record.\n" + "description": "Domain of the DNS record.\n", + "type": "string" }, "filters": { - "type": "array", "items": { "$ref": "#/types/digitalocean:index/getRecordsFilter:getRecordsFilter" - } + }, + "type": "array" }, "id": { - "type": "string", - "description": "The provider-assigned unique ID for this managed resource.\n" + "description": "The provider-assigned unique ID for this managed resource.\n", + "type": "string" }, "records": { - "type": "array", "items": { "$ref": "#/types/digitalocean:index/getRecordsRecord:getRecordsRecord" - } + }, + "type": "array" }, "sorts": { - "type": "array", "items": { "$ref": "#/types/digitalocean:index/getRecordsSort:getRecordsSort" - } + }, + "type": "array" } }, - "type": "object", "required": [ "domain", "records", "id" - ] + ], + "type": "object" } }, "digitalocean:index/getRegion:getRegion": { @@ -16634,37 +16634,36 @@ "description": "A collection of values returned by getRegion.\n", "properties": { "available": { - "type": "boolean", - "description": "A boolean value that represents whether new Droplets can be created in this region.\n" + "description": "A boolean value that represents whether new Droplets can be created in this region.\n", + "type": "boolean" }, "features": { - "type": "array", + "description": "A set of features available in this region.\n", "items": { "type": "string" }, - "description": "A set of features available in this region.\n" + "type": "array" }, "id": { - "type": "string", - "description": "The provider-assigned unique ID for this managed resource.\n" + "description": "The provider-assigned unique ID for this managed resource.\n", + "type": "string" }, "name": { - "type": "string", - "description": "The display name of the region.\n" + "description": "The display name of the region.\n", + "type": "string" }, "sizes": { - "type": "array", + "description": "A set of identifying slugs for the Droplet sizes available in this region.\n", "items": { "type": "string" }, - "description": "A set of identifying slugs for the Droplet sizes available in this region.\n" + "type": "array" }, "slug": { - "type": "string", - "description": "A human-readable string that is used as a unique identifier for each region.\n" + "description": "A human-readable string that is used as a unique identifier for each region.\n", + "type": "string" } }, - "type": "object", "required": [ "available", "features", @@ -16672,11 +16671,12 @@ "sizes", "slug", "id" - ] + ], + "type": "object" } }, "digitalocean:index/getRegions:getRegions": { - "description": "Retrieve information about all supported DigitalOcean regions, with the ability to\nfilter and sort the results. If no filters are specified, all regions will be returned.\n\nNote: You can use the `digitalocean.getRegion` data source\nto obtain metadata about a single region if you already know the `slug` to retrieve.\n\n## Example Usage\n\nUse the `filter` block with a `key` string and `values` list to filter regions.\n\nFor example to find all available regions:\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst available = digitalocean.getRegions({\n filters: [{\n key: \"available\",\n values: [\"true\"],\n }],\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\navailable = digitalocean.get_regions(filters=[digitalocean.GetRegionsFilterArgs(\n key=\"available\",\n values=[\"true\"],\n)])\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var available = DigitalOcean.GetRegions.Invoke(new()\n {\n Filters = new[]\n {\n new DigitalOcean.Inputs.GetRegionsFilterInputArgs\n {\n Key = \"available\",\n Values = new[]\n {\n \"true\",\n },\n },\n },\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := digitalocean.GetRegions(ctx, \u0026digitalocean.GetRegionsArgs{\n\t\t\tFilters: []digitalocean.GetRegionsFilter{\n\t\t\t\t{\n\t\t\t\t\tKey: \"available\",\n\t\t\t\t\tValues: []string{\n\t\t\t\t\t\t\"true\",\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t},\n\t\t}, nil)\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.digitalocean.DigitaloceanFunctions;\nimport com.pulumi.digitalocean.inputs.GetRegionsArgs;\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 final var available = DigitaloceanFunctions.getRegions(GetRegionsArgs.builder()\n .filters(GetRegionsFilterArgs.builder()\n .key(\"available\")\n .values(\"true\")\n .build())\n .build());\n\n }\n}\n```\n```yaml\nvariables:\n available:\n fn::invoke:\n Function: digitalocean:getRegions\n Arguments:\n filters:\n - key: available\n values:\n - 'true'\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\nYou can filter on multiple fields and sort the results as well:\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst available = digitalocean.getRegions({\n filters: [\n {\n key: \"available\",\n values: [\"true\"],\n },\n {\n key: \"features\",\n values: [\"private_networking\"],\n },\n ],\n sorts: [{\n direction: \"desc\",\n key: \"name\",\n }],\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\navailable = digitalocean.get_regions(filters=[\n digitalocean.GetRegionsFilterArgs(\n key=\"available\",\n values=[\"true\"],\n ),\n digitalocean.GetRegionsFilterArgs(\n key=\"features\",\n values=[\"private_networking\"],\n ),\n ],\n sorts=[digitalocean.GetRegionsSortArgs(\n direction=\"desc\",\n key=\"name\",\n )])\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var available = DigitalOcean.GetRegions.Invoke(new()\n {\n Filters = new[]\n {\n new DigitalOcean.Inputs.GetRegionsFilterInputArgs\n {\n Key = \"available\",\n Values = new[]\n {\n \"true\",\n },\n },\n new DigitalOcean.Inputs.GetRegionsFilterInputArgs\n {\n Key = \"features\",\n Values = new[]\n {\n \"private_networking\",\n },\n },\n },\n Sorts = new[]\n {\n new DigitalOcean.Inputs.GetRegionsSortInputArgs\n {\n Direction = \"desc\",\n Key = \"name\",\n },\n },\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := digitalocean.GetRegions(ctx, \u0026digitalocean.GetRegionsArgs{\n\t\t\tFilters: []digitalocean.GetRegionsFilter{\n\t\t\t\t{\n\t\t\t\t\tKey: \"available\",\n\t\t\t\t\tValues: []string{\n\t\t\t\t\t\t\"true\",\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t\t{\n\t\t\t\t\tKey: \"features\",\n\t\t\t\t\tValues: []string{\n\t\t\t\t\t\t\"private_networking\",\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t},\n\t\t\tSorts: []digitalocean.GetRegionsSort{\n\t\t\t\t{\n\t\t\t\t\tDirection: pulumi.StringRef(\"desc\"),\n\t\t\t\t\tKey: \"name\",\n\t\t\t\t},\n\t\t\t},\n\t\t}, nil)\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.digitalocean.DigitaloceanFunctions;\nimport com.pulumi.digitalocean.inputs.GetRegionsArgs;\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 final var available = DigitaloceanFunctions.getRegions(GetRegionsArgs.builder()\n .filters( \n GetRegionsFilterArgs.builder()\n .key(\"available\")\n .values(\"true\")\n .build(),\n GetRegionsFilterArgs.builder()\n .key(\"features\")\n .values(\"private_networking\")\n .build())\n .sorts(GetRegionsSortArgs.builder()\n .direction(\"desc\")\n .key(\"name\")\n .build())\n .build());\n\n }\n}\n```\n```yaml\nvariables:\n available:\n fn::invoke:\n Function: digitalocean:getRegions\n Arguments:\n filters:\n - key: available\n values:\n - 'true'\n - key: features\n values:\n - private_networking\n sorts:\n - direction: desc\n key: name\n```\n\u003c!--End PulumiCodeChooser --\u003e\n", + "description": "Retrieve information about all supported DigitalOcean regions, with the ability to\nfilter and sort the results. If no filters are specified, all regions will be returned.\n\nNote: You can use the `digitalocean.getRegion` data source\nto obtain metadata about a single region if you already know the `slug` to retrieve.\n\n## Example Usage\n\nUse the `filter` block with a `key` string and `values` list to filter regions.\n\nFor example to find all available regions:\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst available = digitalocean.getRegions({\n filters: [{\n key: \"available\",\n values: [\"true\"],\n }],\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\navailable = digitalocean.get_regions(filters=[digitalocean.GetRegionsFilterArgs(\n key=\"available\",\n values=[\"true\"],\n)])\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var available = DigitalOcean.GetRegions.Invoke(new()\n {\n Filters = new[]\n {\n new DigitalOcean.Inputs.GetRegionsFilterInputArgs\n {\n Key = \"available\",\n Values = new[]\n {\n \"true\",\n },\n },\n },\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := digitalocean.GetRegions(ctx, \u0026digitalocean.GetRegionsArgs{\n\t\t\tFilters: []digitalocean.GetRegionsFilter{\n\t\t\t\t{\n\t\t\t\t\tKey: \"available\",\n\t\t\t\t\tValues: []string{\n\t\t\t\t\t\t\"true\",\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t},\n\t\t}, nil)\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.digitalocean.DigitaloceanFunctions;\nimport com.pulumi.digitalocean.inputs.GetRegionsArgs;\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 final var available = DigitaloceanFunctions.getRegions(GetRegionsArgs.builder()\n .filters(GetRegionsFilterArgs.builder()\n .key(\"available\")\n .values(\"true\")\n .build())\n .build());\n\n }\n}\n```\n```yaml\nvariables:\n available:\n fn::invoke:\n Function: digitalocean:getRegions\n Arguments:\n filters:\n - key: available\n values:\n - 'true'\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\nYou can filter on multiple fields and sort the results as well:\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst available = digitalocean.getRegions({\n filters: [\n {\n key: \"available\",\n values: [\"true\"],\n },\n {\n key: \"features\",\n values: [\"private_networking\"],\n },\n ],\n sorts: [{\n key: \"name\",\n direction: \"desc\",\n }],\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\navailable = digitalocean.get_regions(filters=[\n digitalocean.GetRegionsFilterArgs(\n key=\"available\",\n values=[\"true\"],\n ),\n digitalocean.GetRegionsFilterArgs(\n key=\"features\",\n values=[\"private_networking\"],\n ),\n ],\n sorts=[digitalocean.GetRegionsSortArgs(\n key=\"name\",\n direction=\"desc\",\n )])\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var available = DigitalOcean.GetRegions.Invoke(new()\n {\n Filters = new[]\n {\n new DigitalOcean.Inputs.GetRegionsFilterInputArgs\n {\n Key = \"available\",\n Values = new[]\n {\n \"true\",\n },\n },\n new DigitalOcean.Inputs.GetRegionsFilterInputArgs\n {\n Key = \"features\",\n Values = new[]\n {\n \"private_networking\",\n },\n },\n },\n Sorts = new[]\n {\n new DigitalOcean.Inputs.GetRegionsSortInputArgs\n {\n Key = \"name\",\n Direction = \"desc\",\n },\n },\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := digitalocean.GetRegions(ctx, \u0026digitalocean.GetRegionsArgs{\n\t\t\tFilters: []digitalocean.GetRegionsFilter{\n\t\t\t\t{\n\t\t\t\t\tKey: \"available\",\n\t\t\t\t\tValues: []string{\n\t\t\t\t\t\t\"true\",\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t\t{\n\t\t\t\t\tKey: \"features\",\n\t\t\t\t\tValues: []string{\n\t\t\t\t\t\t\"private_networking\",\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t},\n\t\t\tSorts: []digitalocean.GetRegionsSort{\n\t\t\t\t{\n\t\t\t\t\tKey: \"name\",\n\t\t\t\t\tDirection: pulumi.StringRef(\"desc\"),\n\t\t\t\t},\n\t\t\t},\n\t\t}, nil)\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.digitalocean.DigitaloceanFunctions;\nimport com.pulumi.digitalocean.inputs.GetRegionsArgs;\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 final var available = DigitaloceanFunctions.getRegions(GetRegionsArgs.builder()\n .filters( \n GetRegionsFilterArgs.builder()\n .key(\"available\")\n .values(\"true\")\n .build(),\n GetRegionsFilterArgs.builder()\n .key(\"features\")\n .values(\"private_networking\")\n .build())\n .sorts(GetRegionsSortArgs.builder()\n .key(\"name\")\n .direction(\"desc\")\n .build())\n .build());\n\n }\n}\n```\n```yaml\nvariables:\n available:\n fn::invoke:\n Function: digitalocean:getRegions\n Arguments:\n filters:\n - key: available\n values:\n - 'true'\n - key: features\n values:\n - private_networking\n sorts:\n - key: name\n direction: desc\n```\n\u003c!--End PulumiCodeChooser --\u003e\n", "inputs": { "description": "A collection of arguments for invoking getRegions.\n", "properties": { @@ -16701,34 +16701,34 @@ "description": "A collection of values returned by getRegions.\n", "properties": { "filters": { - "type": "array", "items": { "$ref": "#/types/digitalocean:index/getRegionsFilter:getRegionsFilter" - } + }, + "type": "array" }, "id": { - "type": "string", - "description": "The provider-assigned unique ID for this managed resource.\n" + "description": "The provider-assigned unique ID for this managed resource.\n", + "type": "string" }, "regions": { - "type": "array", + "description": "A set of regions satisfying any `filter` and `sort` criteria. Each region has the following attributes:\n", "items": { "$ref": "#/types/digitalocean:index/getRegionsRegion:getRegionsRegion" }, - "description": "A set of regions satisfying any `filter` and `sort` criteria. Each region has the following attributes:\n" + "type": "array" }, "sorts": { - "type": "array", "items": { "$ref": "#/types/digitalocean:index/getRegionsSort:getRegionsSort" - } + }, + "type": "array" } }, - "type": "object", "required": [ "regions", "id" - ] + ], + "type": "object" } }, "digitalocean:index/getReservedIp:getReservedIp": { @@ -16750,33 +16750,33 @@ "description": "A collection of values returned by getReservedIp.\n", "properties": { "dropletId": { - "type": "integer", - "description": "The Droplet id that the reserved IP has been assigned to.\n" + "description": "The Droplet id that the reserved IP has been assigned to.\n", + "type": "integer" }, "id": { - "type": "string", - "description": "The provider-assigned unique ID for this managed resource.\n" + "description": "The provider-assigned unique ID for this managed resource.\n", + "type": "string" }, "ipAddress": { "type": "string" }, "region": { - "type": "string", - "description": "The region that the reserved IP is reserved to.\n" + "description": "The region that the reserved IP is reserved to.\n", + "type": "string" }, "urn": { - "type": "string", - "description": "The uniform resource name of the reserved IP.\n" + "description": "The uniform resource name of the reserved IP.\n", + "type": "string" } }, - "type": "object", "required": [ "dropletId", "ipAddress", "region", "urn", "id" - ] + ], + "type": "object" } }, "digitalocean:index/getSizes:getSizes": { @@ -16805,33 +16805,33 @@ "description": "A collection of values returned by getSizes.\n", "properties": { "filters": { - "type": "array", "items": { "$ref": "#/types/digitalocean:index/getSizesFilter:getSizesFilter" - } + }, + "type": "array" }, "id": { - "type": "string", - "description": "The provider-assigned unique ID for this managed resource.\n" + "description": "The provider-assigned unique ID for this managed resource.\n", + "type": "string" }, "sizes": { - "type": "array", "items": { "$ref": "#/types/digitalocean:index/getSizesSize:getSizesSize" - } + }, + "type": "array" }, "sorts": { - "type": "array", "items": { "$ref": "#/types/digitalocean:index/getSizesSort:getSizesSort" - } + }, + "type": "array" } }, - "type": "object", "required": [ "sizes", "id" - ] + ], + "type": "object" } }, "digitalocean:index/getSpacesBucket:getSpacesBucket": { @@ -16858,31 +16858,30 @@ "description": "A collection of values returned by getSpacesBucket.\n", "properties": { "bucketDomainName": { - "type": "string", - "description": "The FQDN of the bucket (e.g. bucket-name.nyc3.digitaloceanspaces.com)\n" + "description": "The FQDN of the bucket (e.g. bucket-name.nyc3.digitaloceanspaces.com)\n", + "type": "string" }, "endpoint": { - "type": "string", - "description": "The FQDN of the bucket without the bucket name (e.g. nyc3.digitaloceanspaces.com)\n" + "description": "The FQDN of the bucket without the bucket name (e.g. nyc3.digitaloceanspaces.com)\n", + "type": "string" }, "id": { - "type": "string", - "description": "The provider-assigned unique ID for this managed resource.\n" + "description": "The provider-assigned unique ID for this managed resource.\n", + "type": "string" }, "name": { - "type": "string", - "description": "The name of the Spaces bucket\n" + "description": "The name of the Spaces bucket\n", + "type": "string" }, "region": { - "type": "string", - "description": "The slug of the region where the bucket is stored.\n" + "description": "The slug of the region where the bucket is stored.\n", + "type": "string" }, "urn": { - "type": "string", - "description": "The uniform resource name of the bucket\n" + "description": "The uniform resource name of the bucket\n", + "type": "string" } }, - "type": "object", "required": [ "bucketDomainName", "endpoint", @@ -16890,11 +16889,12 @@ "region", "urn", "id" - ] + ], + "type": "object" } }, "digitalocean:index/getSpacesBucketObject:getSpacesBucketObject": { - "description": "The Spaces object data source allows access to the metadata and\n_optionally_ (see below) content of an object stored inside a Spaces bucket.\n\n\u003e **Note:** The content of an object (`body` field) is available only for objects which have a human-readable\n`Content-Type` (`text/*` and `application/json`). This is to prevent printing unsafe characters and potentially\ndownloading large amount of data which would be thrown away in favor of metadata.\n\n## Example Usage\n\nThe following example retrieves a text object (which must have a `Content-Type`\nvalue starting with `text/`) and uses it as the `user_data` for a Droplet:\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst bootstrapScript = digitalocean.getSpacesBucketObject({\n bucket: \"ourcorp-deploy-config\",\n region: \"nyc3\",\n key: \"droplet-bootstrap-script.sh\",\n});\nconst web = new digitalocean.Droplet(\"web\", {\n image: \"ubuntu-18-04-x64\",\n region: digitalocean.Region.NYC2,\n size: digitalocean.DropletSlug.DropletS1VCPU1GB,\n userData: bootstrapScript.then(bootstrapScript =\u003e bootstrapScript.body),\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nbootstrap_script = digitalocean.get_spaces_bucket_object(bucket=\"ourcorp-deploy-config\",\n region=\"nyc3\",\n key=\"droplet-bootstrap-script.sh\")\nweb = digitalocean.Droplet(\"web\",\n image=\"ubuntu-18-04-x64\",\n region=digitalocean.Region.NYC2,\n size=digitalocean.DropletSlug.DROPLET_S1_VCPU1_GB,\n user_data=bootstrap_script.body)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var bootstrapScript = DigitalOcean.GetSpacesBucketObject.Invoke(new()\n {\n Bucket = \"ourcorp-deploy-config\",\n Region = \"nyc3\",\n Key = \"droplet-bootstrap-script.sh\",\n });\n\n var web = new DigitalOcean.Droplet(\"web\", new()\n {\n Image = \"ubuntu-18-04-x64\",\n Region = DigitalOcean.Region.NYC2,\n Size = DigitalOcean.DropletSlug.DropletS1VCPU1GB,\n UserData = bootstrapScript.Apply(getSpacesBucketObjectResult =\u003e getSpacesBucketObjectResult.Body),\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tbootstrapScript, err := digitalocean.LookupSpacesBucketObject(ctx, \u0026digitalocean.LookupSpacesBucketObjectArgs{\n\t\t\tBucket: \"ourcorp-deploy-config\",\n\t\t\tRegion: \"nyc3\",\n\t\t\tKey: \"droplet-bootstrap-script.sh\",\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = digitalocean.NewDroplet(ctx, \"web\", \u0026digitalocean.DropletArgs{\n\t\t\tImage: pulumi.String(\"ubuntu-18-04-x64\"),\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC2),\n\t\t\tSize: pulumi.String(digitalocean.DropletSlugDropletS1VCPU1GB),\n\t\t\tUserData: pulumi.String(bootstrapScript.Body),\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.digitalocean.DigitaloceanFunctions;\nimport com.pulumi.digitalocean.inputs.GetSpacesBucketObjectArgs;\nimport com.pulumi.digitalocean.Droplet;\nimport com.pulumi.digitalocean.DropletArgs;\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 final var bootstrapScript = DigitaloceanFunctions.getSpacesBucketObject(GetSpacesBucketObjectArgs.builder()\n .bucket(\"ourcorp-deploy-config\")\n .region(\"nyc3\")\n .key(\"droplet-bootstrap-script.sh\")\n .build());\n\n var web = new Droplet(\"web\", DropletArgs.builder() \n .image(\"ubuntu-18-04-x64\")\n .region(\"nyc2\")\n .size(\"s-1vcpu-1gb\")\n .userData(bootstrapScript.applyValue(getSpacesBucketObjectResult -\u003e getSpacesBucketObjectResult.body()))\n .build());\n\n }\n}\n```\n```yaml\nresources:\n web:\n type: digitalocean:Droplet\n properties:\n image: ubuntu-18-04-x64\n region: nyc2\n size: s-1vcpu-1gb\n userData: ${bootstrapScript.body}\nvariables:\n bootstrapScript:\n fn::invoke:\n Function: digitalocean:getSpacesBucketObject\n Arguments:\n bucket: ourcorp-deploy-config\n region: nyc3\n key: droplet-bootstrap-script.sh\n```\n\u003c!--End PulumiCodeChooser --\u003e\n", + "description": "The Spaces object data source allows access to the metadata and\n_optionally_ (see below) content of an object stored inside a Spaces bucket.\n\n\u003e **Note:** The content of an object (`body` field) is available only for objects which have a human-readable\n`Content-Type` (`text/*` and `application/json`). This is to prevent printing unsafe characters and potentially\ndownloading large amount of data which would be thrown away in favor of metadata.\n\n## Example Usage\n\nThe following example retrieves a text object (which must have a `Content-Type`\nvalue starting with `text/`) and uses it as the `user_data` for a Droplet:\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst bootstrapScript = digitalocean.getSpacesBucketObject({\n bucket: \"ourcorp-deploy-config\",\n region: \"nyc3\",\n key: \"droplet-bootstrap-script.sh\",\n});\nconst web = new digitalocean.Droplet(\"web\", {\n image: \"ubuntu-18-04-x64\",\n name: \"web-1\",\n region: digitalocean.Region.NYC2,\n size: digitalocean.DropletSlug.DropletS1VCPU1GB,\n userData: bootstrapScript.then(bootstrapScript =\u003e bootstrapScript.body),\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nbootstrap_script = digitalocean.get_spaces_bucket_object(bucket=\"ourcorp-deploy-config\",\n region=\"nyc3\",\n key=\"droplet-bootstrap-script.sh\")\nweb = digitalocean.Droplet(\"web\",\n image=\"ubuntu-18-04-x64\",\n name=\"web-1\",\n region=digitalocean.Region.NYC2,\n size=digitalocean.DropletSlug.DROPLET_S1_VCPU1_GB,\n user_data=bootstrap_script.body)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var bootstrapScript = DigitalOcean.GetSpacesBucketObject.Invoke(new()\n {\n Bucket = \"ourcorp-deploy-config\",\n Region = \"nyc3\",\n Key = \"droplet-bootstrap-script.sh\",\n });\n\n var web = new DigitalOcean.Droplet(\"web\", new()\n {\n Image = \"ubuntu-18-04-x64\",\n Name = \"web-1\",\n Region = DigitalOcean.Region.NYC2,\n Size = DigitalOcean.DropletSlug.DropletS1VCPU1GB,\n UserData = bootstrapScript.Apply(getSpacesBucketObjectResult =\u003e getSpacesBucketObjectResult.Body),\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tbootstrapScript, err := digitalocean.LookupSpacesBucketObject(ctx, \u0026digitalocean.LookupSpacesBucketObjectArgs{\n\t\t\tBucket: \"ourcorp-deploy-config\",\n\t\t\tRegion: \"nyc3\",\n\t\t\tKey: \"droplet-bootstrap-script.sh\",\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = digitalocean.NewDroplet(ctx, \"web\", \u0026digitalocean.DropletArgs{\n\t\t\tImage: pulumi.String(\"ubuntu-18-04-x64\"),\n\t\t\tName: pulumi.String(\"web-1\"),\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC2),\n\t\t\tSize: pulumi.String(digitalocean.DropletSlugDropletS1VCPU1GB),\n\t\t\tUserData: pulumi.String(bootstrapScript.Body),\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.digitalocean.DigitaloceanFunctions;\nimport com.pulumi.digitalocean.inputs.GetSpacesBucketObjectArgs;\nimport com.pulumi.digitalocean.Droplet;\nimport com.pulumi.digitalocean.DropletArgs;\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 final var bootstrapScript = DigitaloceanFunctions.getSpacesBucketObject(GetSpacesBucketObjectArgs.builder()\n .bucket(\"ourcorp-deploy-config\")\n .region(\"nyc3\")\n .key(\"droplet-bootstrap-script.sh\")\n .build());\n\n var web = new Droplet(\"web\", DropletArgs.builder() \n .image(\"ubuntu-18-04-x64\")\n .name(\"web-1\")\n .region(\"nyc2\")\n .size(\"s-1vcpu-1gb\")\n .userData(bootstrapScript.applyValue(getSpacesBucketObjectResult -\u003e getSpacesBucketObjectResult.body()))\n .build());\n\n }\n}\n```\n```yaml\nresources:\n web:\n type: digitalocean:Droplet\n properties:\n image: ubuntu-18-04-x64\n name: web-1\n region: nyc2\n size: s-1vcpu-1gb\n userData: ${bootstrapScript.body}\nvariables:\n bootstrapScript:\n fn::invoke:\n Function: digitalocean:getSpacesBucketObject\n Arguments:\n bucket: ourcorp-deploy-config\n region: nyc3\n key: droplet-bootstrap-script.sh\n```\n\u003c!--End PulumiCodeChooser --\u003e\n", "inputs": { "description": "A collection of arguments for invoking getSpacesBucketObject.\n", "properties": { @@ -16929,65 +16929,65 @@ "description": "A collection of values returned by getSpacesBucketObject.\n", "properties": { "body": { - "type": "string", - "description": "Object data (see **limitations above** to understand cases in which this field is actually available)\n" + "description": "Object data (see **limitations above** to understand cases in which this field is actually available)\n", + "type": "string" }, "bucket": { "type": "string" }, "cacheControl": { - "type": "string", - "description": "Specifies caching behavior along the request/reply chain.\n" + "description": "Specifies caching behavior along the request/reply chain.\n", + "type": "string" }, "contentDisposition": { - "type": "string", - "description": "Specifies presentational information for the object.\n" + "description": "Specifies presentational information for the object.\n", + "type": "string" }, "contentEncoding": { - "type": "string", - "description": "Specifies what content encodings have been applied to the object and thus what decoding mechanisms must be applied to obtain the media-type referenced by the Content-Type header field.\n" + "description": "Specifies what content encodings have been applied to the object and thus what decoding mechanisms must be applied to obtain the media-type referenced by the Content-Type header field.\n", + "type": "string" }, "contentLanguage": { - "type": "string", - "description": "The language the content is in.\n" + "description": "The language the content is in.\n", + "type": "string" }, "contentLength": { - "type": "integer", - "description": "Size of the body in bytes.\n" + "description": "Size of the body in bytes.\n", + "type": "integer" }, "contentType": { - "type": "string", - "description": "A standard MIME type describing the format of the object data.\n" + "description": "A standard MIME type describing the format of the object data.\n", + "type": "string" }, "etag": { - "type": "string", - "description": "[ETag](https://en.wikipedia.org/wiki/HTTP_ETag) generated for the object (an MD5 sum of the object content in case it's not encrypted)\n" + "description": "[ETag](https://en.wikipedia.org/wiki/HTTP_ETag) generated for the object (an MD5 sum of the object content in case it's not encrypted)\n", + "type": "string" }, "expiration": { - "type": "string", - "description": "If the object expiration is configured (see [object lifecycle management](http://docs.aws.amazon.com/AmazonS3/latest/dev/object-lifecycle-mgmt.html)), the field includes this header. It includes the expiry-date and rule-id key value pairs providing object expiration information. The value of the rule-id is URL encoded.\n" + "description": "If the object expiration is configured (see [object lifecycle management](http://docs.aws.amazon.com/AmazonS3/latest/dev/object-lifecycle-mgmt.html)), the field includes this header. It includes the expiry-date and rule-id key value pairs providing object expiration information. The value of the rule-id is URL encoded.\n", + "type": "string" }, "expires": { - "type": "string", - "description": "The date and time at which the object is no longer cacheable.\n" + "description": "The date and time at which the object is no longer cacheable.\n", + "type": "string" }, "id": { - "type": "string", - "description": "The provider-assigned unique ID for this managed resource.\n" + "description": "The provider-assigned unique ID for this managed resource.\n", + "type": "string" }, "key": { "type": "string" }, "lastModified": { - "type": "string", - "description": "Last modified date of the object in RFC1123 format (e.g. `Mon, 02 Jan 2006 15:04:05 MST`)\n" + "description": "Last modified date of the object in RFC1123 format (e.g. `Mon, 02 Jan 2006 15:04:05 MST`)\n", + "type": "string" }, "metadata": { - "type": "object", "additionalProperties": { "$ref": "pulumi.json#/Any" }, - "description": "A map of metadata stored with the object in Spaces\n" + "description": "A map of metadata stored with the object in Spaces\n", + "type": "object" }, "range": { "type": "string" @@ -16996,15 +16996,14 @@ "type": "string" }, "versionId": { - "type": "string", - "description": "The latest version ID of the object returned.\n" + "description": "The latest version ID of the object returned.\n", + "type": "string" }, "websiteRedirectLocation": { - "type": "string", - "description": "If the bucket is configured as a website, redirects requests for this object to another object in the same bucket or to an external URL. Spaces stores the value of this header in the object metadata.\n" + "description": "If the bucket is configured as a website, redirects requests for this object to another object in the same bucket or to an external URL. Spaces stores the value of this header in the object metadata.\n", + "type": "string" } }, - "type": "object", "required": [ "body", "bucket", @@ -17024,7 +17023,8 @@ "versionId", "websiteRedirectLocation", "id" - ] + ], + "type": "object" } }, "digitalocean:index/getSpacesBucketObjects:getSpacesBucketObjects": { @@ -17070,11 +17070,11 @@ "type": "string" }, "commonPrefixes": { - "type": "array", + "description": "List of any keys between `prefix` and the next occurrence of `delimiter` (i.e., similar to subdirectories of the `prefix` \"directory\"); the list is only returned when you specify `delimiter`\n", "items": { "type": "string" }, - "description": "List of any keys between `prefix` and the next occurrence of `delimiter` (i.e., similar to subdirectories of the `prefix` \"directory\"); the list is only returned when you specify `delimiter`\n" + "type": "array" }, "delimiter": { "type": "string" @@ -17083,25 +17083,25 @@ "type": "string" }, "id": { - "type": "string", - "description": "The provider-assigned unique ID for this managed resource.\n" + "description": "The provider-assigned unique ID for this managed resource.\n", + "type": "string" }, "keys": { - "type": "array", + "description": "List of strings representing object keys\n", "items": { "type": "string" }, - "description": "List of strings representing object keys\n" + "type": "array" }, "maxKeys": { "type": "integer" }, "owners": { - "type": "array", + "description": "List of strings representing object owner IDs\n", "items": { "type": "string" }, - "description": "List of strings representing object owner IDs\n" + "type": "array" }, "prefix": { "type": "string" @@ -17110,7 +17110,6 @@ "type": "string" } }, - "type": "object", "required": [ "bucket", "commonPrefixes", @@ -17118,11 +17117,12 @@ "owners", "region", "id" - ] + ], + "type": "object" } }, "digitalocean:index/getSpacesBuckets:getSpacesBuckets": { - "description": "Get information on Spaces buckets for use in other resources, with the ability to filter and sort the results.\nIf no filters are specified, all Spaces buckets will be returned.\n\nNote: You can use the `digitalocean.SpacesBucket` data source to\nobtain metadata about a single bucket if you already know its `name` and `region`.\n\n## Example Usage\n\nUse the `filter` block with a `key` string and `values` list to filter buckets.\n\nGet all buckets in a region:\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst nyc3 = digitalocean.getSpacesBuckets({\n filters: [{\n key: \"region\",\n values: [\"nyc3\"],\n }],\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nnyc3 = digitalocean.get_spaces_buckets(filters=[digitalocean.GetSpacesBucketsFilterArgs(\n key=\"region\",\n values=[\"nyc3\"],\n)])\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var nyc3 = DigitalOcean.GetSpacesBuckets.Invoke(new()\n {\n Filters = new[]\n {\n new DigitalOcean.Inputs.GetSpacesBucketsFilterInputArgs\n {\n Key = \"region\",\n Values = new[]\n {\n \"nyc3\",\n },\n },\n },\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := digitalocean.GetSpacesBuckets(ctx, \u0026digitalocean.GetSpacesBucketsArgs{\n\t\t\tFilters: []digitalocean.GetSpacesBucketsFilter{\n\t\t\t\t{\n\t\t\t\t\tKey: \"region\",\n\t\t\t\t\tValues: []string{\n\t\t\t\t\t\t\"nyc3\",\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t},\n\t\t}, nil)\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.digitalocean.DigitaloceanFunctions;\nimport com.pulumi.digitalocean.inputs.GetSpacesBucketsArgs;\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 final var nyc3 = DigitaloceanFunctions.getSpacesBuckets(GetSpacesBucketsArgs.builder()\n .filters(GetSpacesBucketsFilterArgs.builder()\n .key(\"region\")\n .values(\"nyc3\")\n .build())\n .build());\n\n }\n}\n```\n```yaml\nvariables:\n nyc3:\n fn::invoke:\n Function: digitalocean:getSpacesBuckets\n Arguments:\n filters:\n - key: region\n values:\n - nyc3\n```\n\u003c!--End PulumiCodeChooser --\u003e\nYou can sort the results as well:\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst nyc3 = digitalocean.getSpacesBuckets({\n filters: [{\n key: \"region\",\n values: [\"nyc3\"],\n }],\n sorts: [{\n direction: \"desc\",\n key: \"name\",\n }],\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nnyc3 = digitalocean.get_spaces_buckets(filters=[digitalocean.GetSpacesBucketsFilterArgs(\n key=\"region\",\n values=[\"nyc3\"],\n )],\n sorts=[digitalocean.GetSpacesBucketsSortArgs(\n direction=\"desc\",\n key=\"name\",\n )])\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var nyc3 = DigitalOcean.GetSpacesBuckets.Invoke(new()\n {\n Filters = new[]\n {\n new DigitalOcean.Inputs.GetSpacesBucketsFilterInputArgs\n {\n Key = \"region\",\n Values = new[]\n {\n \"nyc3\",\n },\n },\n },\n Sorts = new[]\n {\n new DigitalOcean.Inputs.GetSpacesBucketsSortInputArgs\n {\n Direction = \"desc\",\n Key = \"name\",\n },\n },\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := digitalocean.GetSpacesBuckets(ctx, \u0026digitalocean.GetSpacesBucketsArgs{\n\t\t\tFilters: []digitalocean.GetSpacesBucketsFilter{\n\t\t\t\t{\n\t\t\t\t\tKey: \"region\",\n\t\t\t\t\tValues: []string{\n\t\t\t\t\t\t\"nyc3\",\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t},\n\t\t\tSorts: []digitalocean.GetSpacesBucketsSort{\n\t\t\t\t{\n\t\t\t\t\tDirection: pulumi.StringRef(\"desc\"),\n\t\t\t\t\tKey: \"name\",\n\t\t\t\t},\n\t\t\t},\n\t\t}, nil)\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.digitalocean.DigitaloceanFunctions;\nimport com.pulumi.digitalocean.inputs.GetSpacesBucketsArgs;\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 final var nyc3 = DigitaloceanFunctions.getSpacesBuckets(GetSpacesBucketsArgs.builder()\n .filters(GetSpacesBucketsFilterArgs.builder()\n .key(\"region\")\n .values(\"nyc3\")\n .build())\n .sorts(GetSpacesBucketsSortArgs.builder()\n .direction(\"desc\")\n .key(\"name\")\n .build())\n .build());\n\n }\n}\n```\n```yaml\nvariables:\n nyc3:\n fn::invoke:\n Function: digitalocean:getSpacesBuckets\n Arguments:\n filters:\n - key: region\n values:\n - nyc3\n sorts:\n - direction: desc\n key: name\n```\n\u003c!--End PulumiCodeChooser --\u003e\n", + "description": "Get information on Spaces buckets for use in other resources, with the ability to filter and sort the results.\nIf no filters are specified, all Spaces buckets will be returned.\n\nNote: You can use the `digitalocean.SpacesBucket` data source to\nobtain metadata about a single bucket if you already know its `name` and `region`.\n\n## Example Usage\n\nUse the `filter` block with a `key` string and `values` list to filter buckets.\n\nGet all buckets in a region:\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst nyc3 = digitalocean.getSpacesBuckets({\n filters: [{\n key: \"region\",\n values: [\"nyc3\"],\n }],\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nnyc3 = digitalocean.get_spaces_buckets(filters=[digitalocean.GetSpacesBucketsFilterArgs(\n key=\"region\",\n values=[\"nyc3\"],\n)])\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var nyc3 = DigitalOcean.GetSpacesBuckets.Invoke(new()\n {\n Filters = new[]\n {\n new DigitalOcean.Inputs.GetSpacesBucketsFilterInputArgs\n {\n Key = \"region\",\n Values = new[]\n {\n \"nyc3\",\n },\n },\n },\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := digitalocean.GetSpacesBuckets(ctx, \u0026digitalocean.GetSpacesBucketsArgs{\n\t\t\tFilters: []digitalocean.GetSpacesBucketsFilter{\n\t\t\t\t{\n\t\t\t\t\tKey: \"region\",\n\t\t\t\t\tValues: []string{\n\t\t\t\t\t\t\"nyc3\",\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t},\n\t\t}, nil)\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.digitalocean.DigitaloceanFunctions;\nimport com.pulumi.digitalocean.inputs.GetSpacesBucketsArgs;\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 final var nyc3 = DigitaloceanFunctions.getSpacesBuckets(GetSpacesBucketsArgs.builder()\n .filters(GetSpacesBucketsFilterArgs.builder()\n .key(\"region\")\n .values(\"nyc3\")\n .build())\n .build());\n\n }\n}\n```\n```yaml\nvariables:\n nyc3:\n fn::invoke:\n Function: digitalocean:getSpacesBuckets\n Arguments:\n filters:\n - key: region\n values:\n - nyc3\n```\n\u003c!--End PulumiCodeChooser --\u003e\nYou can sort the results as well:\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst nyc3 = digitalocean.getSpacesBuckets({\n filters: [{\n key: \"region\",\n values: [\"nyc3\"],\n }],\n sorts: [{\n key: \"name\",\n direction: \"desc\",\n }],\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nnyc3 = digitalocean.get_spaces_buckets(filters=[digitalocean.GetSpacesBucketsFilterArgs(\n key=\"region\",\n values=[\"nyc3\"],\n )],\n sorts=[digitalocean.GetSpacesBucketsSortArgs(\n key=\"name\",\n direction=\"desc\",\n )])\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var nyc3 = DigitalOcean.GetSpacesBuckets.Invoke(new()\n {\n Filters = new[]\n {\n new DigitalOcean.Inputs.GetSpacesBucketsFilterInputArgs\n {\n Key = \"region\",\n Values = new[]\n {\n \"nyc3\",\n },\n },\n },\n Sorts = new[]\n {\n new DigitalOcean.Inputs.GetSpacesBucketsSortInputArgs\n {\n Key = \"name\",\n Direction = \"desc\",\n },\n },\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := digitalocean.GetSpacesBuckets(ctx, \u0026digitalocean.GetSpacesBucketsArgs{\n\t\t\tFilters: []digitalocean.GetSpacesBucketsFilter{\n\t\t\t\t{\n\t\t\t\t\tKey: \"region\",\n\t\t\t\t\tValues: []string{\n\t\t\t\t\t\t\"nyc3\",\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t},\n\t\t\tSorts: []digitalocean.GetSpacesBucketsSort{\n\t\t\t\t{\n\t\t\t\t\tKey: \"name\",\n\t\t\t\t\tDirection: pulumi.StringRef(\"desc\"),\n\t\t\t\t},\n\t\t\t},\n\t\t}, nil)\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.digitalocean.DigitaloceanFunctions;\nimport com.pulumi.digitalocean.inputs.GetSpacesBucketsArgs;\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 final var nyc3 = DigitaloceanFunctions.getSpacesBuckets(GetSpacesBucketsArgs.builder()\n .filters(GetSpacesBucketsFilterArgs.builder()\n .key(\"region\")\n .values(\"nyc3\")\n .build())\n .sorts(GetSpacesBucketsSortArgs.builder()\n .key(\"name\")\n .direction(\"desc\")\n .build())\n .build());\n\n }\n}\n```\n```yaml\nvariables:\n nyc3:\n fn::invoke:\n Function: digitalocean:getSpacesBuckets\n Arguments:\n filters:\n - key: region\n values:\n - nyc3\n sorts:\n - key: name\n direction: desc\n```\n\u003c!--End PulumiCodeChooser --\u003e\n", "inputs": { "description": "A collection of arguments for invoking getSpacesBuckets.\n", "properties": { @@ -17147,38 +17147,38 @@ "description": "A collection of values returned by getSpacesBuckets.\n", "properties": { "buckets": { - "type": "array", + "description": "A list of Spaces buckets satisfying any `filter` and `sort` criteria. Each bucket has the following attributes:\n", "items": { "$ref": "#/types/digitalocean:index/getSpacesBucketsBucket:getSpacesBucketsBucket" }, - "description": "A list of Spaces buckets satisfying any `filter` and `sort` criteria. Each bucket has the following attributes:\n" + "type": "array" }, "filters": { - "type": "array", "items": { "$ref": "#/types/digitalocean:index/getSpacesBucketsFilter:getSpacesBucketsFilter" - } + }, + "type": "array" }, "id": { - "type": "string", - "description": "The provider-assigned unique ID for this managed resource.\n" + "description": "The provider-assigned unique ID for this managed resource.\n", + "type": "string" }, "sorts": { - "type": "array", "items": { "$ref": "#/types/digitalocean:index/getSpacesBucketsSort:getSpacesBucketsSort" - } + }, + "type": "array" } }, - "type": "object", "required": [ "buckets", "id" - ] + ], + "type": "object" } }, "digitalocean:index/getSshKey:getSshKey": { - "description": "Get information on a ssh key. This data source provides the name, public key,\nand fingerprint as configured on your DigitalOcean account. This is useful if\nthe ssh key in question is not managed by the provider or you need to utilize any\nof the keys data.\n\nAn error is triggered if the provided ssh key name does not exist.\n\n## Example Usage\n\nGet the ssh key:\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst exampleSshKey = digitalocean.getSshKey({\n name: \"example\",\n});\nconst exampleDroplet = new digitalocean.Droplet(\"exampleDroplet\", {\n image: \"ubuntu-18-04-x64\",\n region: digitalocean.Region.NYC2,\n size: digitalocean.DropletSlug.DropletS1VCPU1GB,\n sshKeys: [exampleSshKey.then(exampleSshKey =\u003e exampleSshKey.id)],\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nexample_ssh_key = digitalocean.get_ssh_key(name=\"example\")\nexample_droplet = digitalocean.Droplet(\"exampleDroplet\",\n image=\"ubuntu-18-04-x64\",\n region=digitalocean.Region.NYC2,\n size=digitalocean.DropletSlug.DROPLET_S1_VCPU1_GB,\n ssh_keys=[example_ssh_key.id])\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var exampleSshKey = DigitalOcean.GetSshKey.Invoke(new()\n {\n Name = \"example\",\n });\n\n var exampleDroplet = new DigitalOcean.Droplet(\"exampleDroplet\", new()\n {\n Image = \"ubuntu-18-04-x64\",\n Region = DigitalOcean.Region.NYC2,\n Size = DigitalOcean.DropletSlug.DropletS1VCPU1GB,\n SshKeys = new[]\n {\n exampleSshKey.Apply(getSshKeyResult =\u003e getSshKeyResult.Id),\n },\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\texampleSshKey, err := digitalocean.LookupSshKey(ctx, \u0026digitalocean.LookupSshKeyArgs{\n\t\t\tName: \"example\",\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = digitalocean.NewDroplet(ctx, \"exampleDroplet\", \u0026digitalocean.DropletArgs{\n\t\t\tImage: pulumi.String(\"ubuntu-18-04-x64\"),\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC2),\n\t\t\tSize: pulumi.String(digitalocean.DropletSlugDropletS1VCPU1GB),\n\t\t\tSshKeys: pulumi.StringArray{\n\t\t\t\tpulumi.Int(exampleSshKey.Id),\n\t\t\t},\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.digitalocean.DigitaloceanFunctions;\nimport com.pulumi.digitalocean.inputs.GetSshKeyArgs;\nimport com.pulumi.digitalocean.Droplet;\nimport com.pulumi.digitalocean.DropletArgs;\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 final var exampleSshKey = DigitaloceanFunctions.getSshKey(GetSshKeyArgs.builder()\n .name(\"example\")\n .build());\n\n var exampleDroplet = new Droplet(\"exampleDroplet\", DropletArgs.builder() \n .image(\"ubuntu-18-04-x64\")\n .region(\"nyc2\")\n .size(\"s-1vcpu-1gb\")\n .sshKeys(exampleSshKey.applyValue(getSshKeyResult -\u003e getSshKeyResult.id()))\n .build());\n\n }\n}\n```\n```yaml\nresources:\n exampleDroplet:\n type: digitalocean:Droplet\n properties:\n image: ubuntu-18-04-x64\n region: nyc2\n size: s-1vcpu-1gb\n sshKeys:\n - ${exampleSshKey.id}\nvariables:\n exampleSshKey:\n fn::invoke:\n Function: digitalocean:getSshKey\n Arguments:\n name: example\n```\n\u003c!--End PulumiCodeChooser --\u003e\n", + "description": "Get information on a ssh key. This data source provides the name, public key,\nand fingerprint as configured on your DigitalOcean account. This is useful if\nthe ssh key in question is not managed by the provider or you need to utilize any\nof the keys data.\n\nAn error is triggered if the provided ssh key name does not exist.\n\n## Example Usage\n\nGet the ssh key:\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst example = digitalocean.getSshKey({\n name: \"example\",\n});\nconst exampleDroplet = new digitalocean.Droplet(\"example\", {\n image: \"ubuntu-18-04-x64\",\n name: \"example-1\",\n region: digitalocean.Region.NYC2,\n size: digitalocean.DropletSlug.DropletS1VCPU1GB,\n sshKeys: [example.then(example =\u003e example.id)],\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nexample = digitalocean.get_ssh_key(name=\"example\")\nexample_droplet = digitalocean.Droplet(\"example\",\n image=\"ubuntu-18-04-x64\",\n name=\"example-1\",\n region=digitalocean.Region.NYC2,\n size=digitalocean.DropletSlug.DROPLET_S1_VCPU1_GB,\n ssh_keys=[example.id])\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var example = DigitalOcean.GetSshKey.Invoke(new()\n {\n Name = \"example\",\n });\n\n var exampleDroplet = new DigitalOcean.Droplet(\"example\", new()\n {\n Image = \"ubuntu-18-04-x64\",\n Name = \"example-1\",\n Region = DigitalOcean.Region.NYC2,\n Size = DigitalOcean.DropletSlug.DropletS1VCPU1GB,\n SshKeys = new[]\n {\n example.Apply(getSshKeyResult =\u003e getSshKeyResult.Id),\n },\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\texample, err := digitalocean.LookupSshKey(ctx, \u0026digitalocean.LookupSshKeyArgs{\n\t\t\tName: \"example\",\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = digitalocean.NewDroplet(ctx, \"example\", \u0026digitalocean.DropletArgs{\n\t\t\tImage: pulumi.String(\"ubuntu-18-04-x64\"),\n\t\t\tName: pulumi.String(\"example-1\"),\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC2),\n\t\t\tSize: pulumi.String(digitalocean.DropletSlugDropletS1VCPU1GB),\n\t\t\tSshKeys: pulumi.StringArray{\n\t\t\t\tpulumi.Int(example.Id),\n\t\t\t},\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.digitalocean.DigitaloceanFunctions;\nimport com.pulumi.digitalocean.inputs.GetSshKeyArgs;\nimport com.pulumi.digitalocean.Droplet;\nimport com.pulumi.digitalocean.DropletArgs;\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 final var example = DigitaloceanFunctions.getSshKey(GetSshKeyArgs.builder()\n .name(\"example\")\n .build());\n\n var exampleDroplet = new Droplet(\"exampleDroplet\", DropletArgs.builder() \n .image(\"ubuntu-18-04-x64\")\n .name(\"example-1\")\n .region(\"nyc2\")\n .size(\"s-1vcpu-1gb\")\n .sshKeys(example.applyValue(getSshKeyResult -\u003e getSshKeyResult.id()))\n .build());\n\n }\n}\n```\n```yaml\nresources:\n exampleDroplet:\n type: digitalocean:Droplet\n name: example\n properties:\n image: ubuntu-18-04-x64\n name: example-1\n region: nyc2\n size: s-1vcpu-1gb\n sshKeys:\n - ${example.id}\nvariables:\n example:\n fn::invoke:\n Function: digitalocean:getSshKey\n Arguments:\n name: example\n```\n\u003c!--End PulumiCodeChooser --\u003e\n", "inputs": { "description": "A collection of arguments for invoking getSshKey.\n", "properties": { @@ -17196,32 +17196,32 @@ "description": "A collection of values returned by getSshKey.\n", "properties": { "fingerprint": { - "type": "string", - "description": "The fingerprint of the public key of the ssh key.\n" + "description": "The fingerprint of the public key of the ssh key.\n", + "type": "string" }, "id": { - "type": "integer", - "description": "The ID of the ssh key.\n" + "description": "The ID of the ssh key.\n", + "type": "integer" }, "name": { "type": "string" }, "publicKey": { - "type": "string", - "description": "The public key of the ssh key.\n" + "description": "The public key of the ssh key.\n", + "type": "string" } }, - "type": "object", "required": [ "fingerprint", "id", "name", "publicKey" - ] + ], + "type": "object" } }, "digitalocean:index/getSshKeys:getSshKeys": { - "description": "Get information on SSH Keys for use in other resources.\n\nThis data source is useful if the SSH Keys in question are not managed by the provider or you need to\nutilize any of the SSH Keys' data.\n\nNote: You can use the `digitalocean.SshKey` data source to obtain metadata\nabout a single SSH Key if you already know the unique `name` to retrieve.\n\n## Example Usage\n\nFor example, to find all SSH keys:\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst keys = digitalocean.getSshKeys({\n sorts: [{\n direction: \"asc\",\n key: \"name\",\n }],\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nkeys = digitalocean.get_ssh_keys(sorts=[digitalocean.GetSshKeysSortArgs(\n direction=\"asc\",\n key=\"name\",\n)])\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var keys = DigitalOcean.GetSshKeys.Invoke(new()\n {\n Sorts = new[]\n {\n new DigitalOcean.Inputs.GetSshKeysSortInputArgs\n {\n Direction = \"asc\",\n Key = \"name\",\n },\n },\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := digitalocean.GetSshKeys(ctx, \u0026digitalocean.GetSshKeysArgs{\n\t\t\tSorts: []digitalocean.GetSshKeysSort{\n\t\t\t\t{\n\t\t\t\t\tDirection: pulumi.StringRef(\"asc\"),\n\t\t\t\t\tKey: \"name\",\n\t\t\t\t},\n\t\t\t},\n\t\t}, nil)\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.digitalocean.DigitaloceanFunctions;\nimport com.pulumi.digitalocean.inputs.GetSshKeysArgs;\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 final var keys = DigitaloceanFunctions.getSshKeys(GetSshKeysArgs.builder()\n .sorts(GetSshKeysSortArgs.builder()\n .direction(\"asc\")\n .key(\"name\")\n .build())\n .build());\n\n }\n}\n```\n```yaml\nvariables:\n keys:\n fn::invoke:\n Function: digitalocean:getSshKeys\n Arguments:\n sorts:\n - direction: asc\n key: name\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\nOr to find ones matching specific values:\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst keys = digitalocean.getSshKeys({\n filters: [{\n key: \"name\",\n values: [\n \"laptop\",\n \"desktop\",\n ],\n }],\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nkeys = digitalocean.get_ssh_keys(filters=[digitalocean.GetSshKeysFilterArgs(\n key=\"name\",\n values=[\n \"laptop\",\n \"desktop\",\n ],\n)])\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var keys = DigitalOcean.GetSshKeys.Invoke(new()\n {\n Filters = new[]\n {\n new DigitalOcean.Inputs.GetSshKeysFilterInputArgs\n {\n Key = \"name\",\n Values = new[]\n {\n \"laptop\",\n \"desktop\",\n },\n },\n },\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := digitalocean.GetSshKeys(ctx, \u0026digitalocean.GetSshKeysArgs{\n\t\t\tFilters: []digitalocean.GetSshKeysFilter{\n\t\t\t\t{\n\t\t\t\t\tKey: \"name\",\n\t\t\t\t\tValues: []string{\n\t\t\t\t\t\t\"laptop\",\n\t\t\t\t\t\t\"desktop\",\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t},\n\t\t}, nil)\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.digitalocean.DigitaloceanFunctions;\nimport com.pulumi.digitalocean.inputs.GetSshKeysArgs;\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 final var keys = DigitaloceanFunctions.getSshKeys(GetSshKeysArgs.builder()\n .filters(GetSshKeysFilterArgs.builder()\n .key(\"name\")\n .values( \n \"laptop\",\n \"desktop\")\n .build())\n .build());\n\n }\n}\n```\n```yaml\nvariables:\n keys:\n fn::invoke:\n Function: digitalocean:getSshKeys\n Arguments:\n filters:\n - key: name\n values:\n - laptop\n - desktop\n```\n\u003c!--End PulumiCodeChooser --\u003e\n", + "description": "Get information on SSH Keys for use in other resources.\n\nThis data source is useful if the SSH Keys in question are not managed by the provider or you need to\nutilize any of the SSH Keys' data.\n\nNote: You can use the `digitalocean.SshKey` data source to obtain metadata\nabout a single SSH Key if you already know the unique `name` to retrieve.\n\n## Example Usage\n\nFor example, to find all SSH keys:\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst keys = digitalocean.getSshKeys({\n sorts: [{\n key: \"name\",\n direction: \"asc\",\n }],\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nkeys = digitalocean.get_ssh_keys(sorts=[digitalocean.GetSshKeysSortArgs(\n key=\"name\",\n direction=\"asc\",\n)])\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var keys = DigitalOcean.GetSshKeys.Invoke(new()\n {\n Sorts = new[]\n {\n new DigitalOcean.Inputs.GetSshKeysSortInputArgs\n {\n Key = \"name\",\n Direction = \"asc\",\n },\n },\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := digitalocean.GetSshKeys(ctx, \u0026digitalocean.GetSshKeysArgs{\n\t\t\tSorts: []digitalocean.GetSshKeysSort{\n\t\t\t\t{\n\t\t\t\t\tKey: \"name\",\n\t\t\t\t\tDirection: pulumi.StringRef(\"asc\"),\n\t\t\t\t},\n\t\t\t},\n\t\t}, nil)\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.digitalocean.DigitaloceanFunctions;\nimport com.pulumi.digitalocean.inputs.GetSshKeysArgs;\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 final var keys = DigitaloceanFunctions.getSshKeys(GetSshKeysArgs.builder()\n .sorts(GetSshKeysSortArgs.builder()\n .key(\"name\")\n .direction(\"asc\")\n .build())\n .build());\n\n }\n}\n```\n```yaml\nvariables:\n keys:\n fn::invoke:\n Function: digitalocean:getSshKeys\n Arguments:\n sorts:\n - key: name\n direction: asc\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\nOr to find ones matching specific values:\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst keys = digitalocean.getSshKeys({\n filters: [{\n key: \"name\",\n values: [\n \"laptop\",\n \"desktop\",\n ],\n }],\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nkeys = digitalocean.get_ssh_keys(filters=[digitalocean.GetSshKeysFilterArgs(\n key=\"name\",\n values=[\n \"laptop\",\n \"desktop\",\n ],\n)])\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var keys = DigitalOcean.GetSshKeys.Invoke(new()\n {\n Filters = new[]\n {\n new DigitalOcean.Inputs.GetSshKeysFilterInputArgs\n {\n Key = \"name\",\n Values = new[]\n {\n \"laptop\",\n \"desktop\",\n },\n },\n },\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := digitalocean.GetSshKeys(ctx, \u0026digitalocean.GetSshKeysArgs{\n\t\t\tFilters: []digitalocean.GetSshKeysFilter{\n\t\t\t\t{\n\t\t\t\t\tKey: \"name\",\n\t\t\t\t\tValues: []string{\n\t\t\t\t\t\t\"laptop\",\n\t\t\t\t\t\t\"desktop\",\n\t\t\t\t\t},\n\t\t\t\t},\n\t\t\t},\n\t\t}, nil)\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.digitalocean.DigitaloceanFunctions;\nimport com.pulumi.digitalocean.inputs.GetSshKeysArgs;\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 final var keys = DigitaloceanFunctions.getSshKeys(GetSshKeysArgs.builder()\n .filters(GetSshKeysFilterArgs.builder()\n .key(\"name\")\n .values( \n \"laptop\",\n \"desktop\")\n .build())\n .build());\n\n }\n}\n```\n```yaml\nvariables:\n keys:\n fn::invoke:\n Function: digitalocean:getSshKeys\n Arguments:\n filters:\n - key: name\n values:\n - laptop\n - desktop\n```\n\u003c!--End PulumiCodeChooser --\u003e\n", "inputs": { "description": "A collection of arguments for invoking getSshKeys.\n", "properties": { @@ -17246,38 +17246,38 @@ "description": "A collection of values returned by getSshKeys.\n", "properties": { "filters": { - "type": "array", "items": { "$ref": "#/types/digitalocean:index/getSshKeysFilter:getSshKeysFilter" - } + }, + "type": "array" }, "id": { - "type": "string", - "description": "The provider-assigned unique ID for this managed resource.\n" + "description": "The provider-assigned unique ID for this managed resource.\n", + "type": "string" }, "sorts": { - "type": "array", "items": { "$ref": "#/types/digitalocean:index/getSshKeysSort:getSshKeysSort" - } + }, + "type": "array" }, "sshKeys": { - "type": "array", + "description": "A list of SSH Keys. Each SSH Key has the following attributes:\n", "items": { "$ref": "#/types/digitalocean:index/getSshKeysSshKey:getSshKeysSshKey" }, - "description": "A list of SSH Keys. Each SSH Key has the following attributes:\n" + "type": "array" } }, - "type": "object", "required": [ "sshKeys", "id" - ] + ], + "type": "object" } }, "digitalocean:index/getTag:getTag": { - "description": "Get information on a tag. This data source provides the name as configured on\nyour DigitalOcean account. This is useful if the tag name in question is not\nmanaged by the provider or you need validate if the tag exists in the account.\n\nAn error is triggered if the provided tag name does not exist.\n\n## Example Usage\n\nGet the tag:\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst exampleTag = digitalocean.getTag({\n name: \"example\",\n});\nconst exampleDroplet = new digitalocean.Droplet(\"exampleDroplet\", {\n image: \"ubuntu-18-04-x64\",\n region: digitalocean.Region.NYC2,\n size: digitalocean.DropletSlug.DropletS1VCPU1GB,\n tags: [exampleTag.then(exampleTag =\u003e exampleTag.name)],\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nexample_tag = digitalocean.get_tag(name=\"example\")\nexample_droplet = digitalocean.Droplet(\"exampleDroplet\",\n image=\"ubuntu-18-04-x64\",\n region=digitalocean.Region.NYC2,\n size=digitalocean.DropletSlug.DROPLET_S1_VCPU1_GB,\n tags=[example_tag.name])\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var exampleTag = DigitalOcean.GetTag.Invoke(new()\n {\n Name = \"example\",\n });\n\n var exampleDroplet = new DigitalOcean.Droplet(\"exampleDroplet\", new()\n {\n Image = \"ubuntu-18-04-x64\",\n Region = DigitalOcean.Region.NYC2,\n Size = DigitalOcean.DropletSlug.DropletS1VCPU1GB,\n Tags = new[]\n {\n exampleTag.Apply(getTagResult =\u003e getTagResult.Name),\n },\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\texampleTag, err := digitalocean.LookupTag(ctx, \u0026digitalocean.LookupTagArgs{\n\t\t\tName: \"example\",\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = digitalocean.NewDroplet(ctx, \"exampleDroplet\", \u0026digitalocean.DropletArgs{\n\t\t\tImage: pulumi.String(\"ubuntu-18-04-x64\"),\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC2),\n\t\t\tSize: pulumi.String(digitalocean.DropletSlugDropletS1VCPU1GB),\n\t\t\tTags: pulumi.StringArray{\n\t\t\t\tpulumi.String(exampleTag.Name),\n\t\t\t},\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.digitalocean.DigitaloceanFunctions;\nimport com.pulumi.digitalocean.inputs.GetTagArgs;\nimport com.pulumi.digitalocean.Droplet;\nimport com.pulumi.digitalocean.DropletArgs;\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 final var exampleTag = DigitaloceanFunctions.getTag(GetTagArgs.builder()\n .name(\"example\")\n .build());\n\n var exampleDroplet = new Droplet(\"exampleDroplet\", DropletArgs.builder() \n .image(\"ubuntu-18-04-x64\")\n .region(\"nyc2\")\n .size(\"s-1vcpu-1gb\")\n .tags(exampleTag.applyValue(getTagResult -\u003e getTagResult.name()))\n .build());\n\n }\n}\n```\n```yaml\nresources:\n exampleDroplet:\n type: digitalocean:Droplet\n properties:\n image: ubuntu-18-04-x64\n region: nyc2\n size: s-1vcpu-1gb\n tags:\n - ${exampleTag.name}\nvariables:\n exampleTag:\n fn::invoke:\n Function: digitalocean:getTag\n Arguments:\n name: example\n```\n\u003c!--End PulumiCodeChooser --\u003e\n", + "description": "Get information on a tag. This data source provides the name as configured on\nyour DigitalOcean account. This is useful if the tag name in question is not\nmanaged by the provider or you need validate if the tag exists in the account.\n\nAn error is triggered if the provided tag name does not exist.\n\n## Example Usage\n\nGet the tag:\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst example = digitalocean.getTag({\n name: \"example\",\n});\nconst exampleDroplet = new digitalocean.Droplet(\"example\", {\n image: \"ubuntu-18-04-x64\",\n name: \"example-1\",\n region: digitalocean.Region.NYC2,\n size: digitalocean.DropletSlug.DropletS1VCPU1GB,\n tags: [example.then(example =\u003e example.name)],\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nexample = digitalocean.get_tag(name=\"example\")\nexample_droplet = digitalocean.Droplet(\"example\",\n image=\"ubuntu-18-04-x64\",\n name=\"example-1\",\n region=digitalocean.Region.NYC2,\n size=digitalocean.DropletSlug.DROPLET_S1_VCPU1_GB,\n tags=[example.name])\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var example = DigitalOcean.GetTag.Invoke(new()\n {\n Name = \"example\",\n });\n\n var exampleDroplet = new DigitalOcean.Droplet(\"example\", new()\n {\n Image = \"ubuntu-18-04-x64\",\n Name = \"example-1\",\n Region = DigitalOcean.Region.NYC2,\n Size = DigitalOcean.DropletSlug.DropletS1VCPU1GB,\n Tags = new[]\n {\n example.Apply(getTagResult =\u003e getTagResult.Name),\n },\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\texample, err := digitalocean.LookupTag(ctx, \u0026digitalocean.LookupTagArgs{\n\t\t\tName: \"example\",\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = digitalocean.NewDroplet(ctx, \"example\", \u0026digitalocean.DropletArgs{\n\t\t\tImage: pulumi.String(\"ubuntu-18-04-x64\"),\n\t\t\tName: pulumi.String(\"example-1\"),\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC2),\n\t\t\tSize: pulumi.String(digitalocean.DropletSlugDropletS1VCPU1GB),\n\t\t\tTags: pulumi.StringArray{\n\t\t\t\tpulumi.String(example.Name),\n\t\t\t},\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.digitalocean.DigitaloceanFunctions;\nimport com.pulumi.digitalocean.inputs.GetTagArgs;\nimport com.pulumi.digitalocean.Droplet;\nimport com.pulumi.digitalocean.DropletArgs;\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 final var example = DigitaloceanFunctions.getTag(GetTagArgs.builder()\n .name(\"example\")\n .build());\n\n var exampleDroplet = new Droplet(\"exampleDroplet\", DropletArgs.builder() \n .image(\"ubuntu-18-04-x64\")\n .name(\"example-1\")\n .region(\"nyc2\")\n .size(\"s-1vcpu-1gb\")\n .tags(example.applyValue(getTagResult -\u003e getTagResult.name()))\n .build());\n\n }\n}\n```\n```yaml\nresources:\n exampleDroplet:\n type: digitalocean:Droplet\n name: example\n properties:\n image: ubuntu-18-04-x64\n name: example-1\n region: nyc2\n size: s-1vcpu-1gb\n tags:\n - ${example.name}\nvariables:\n example:\n fn::invoke:\n Function: digitalocean:getTag\n Arguments:\n name: example\n```\n\u003c!--End PulumiCodeChooser --\u003e\n", "inputs": { "description": "A collection of arguments for invoking getTag.\n", "properties": { @@ -17295,38 +17295,37 @@ "description": "A collection of values returned by getTag.\n", "properties": { "databasesCount": { - "type": "integer", - "description": "A count of the database clusters that the tag is applied to.\n" + "description": "A count of the database clusters that the tag is applied to.\n", + "type": "integer" }, "dropletsCount": { - "type": "integer", - "description": "A count of the Droplets the tag is applied to.\n" + "description": "A count of the Droplets the tag is applied to.\n", + "type": "integer" }, "id": { - "type": "string", - "description": "The provider-assigned unique ID for this managed resource.\n" + "description": "The provider-assigned unique ID for this managed resource.\n", + "type": "string" }, "imagesCount": { - "type": "integer", - "description": "A count of the images that the tag is applied to.\n" + "description": "A count of the images that the tag is applied to.\n", + "type": "integer" }, "name": { "type": "string" }, "totalResourceCount": { - "type": "integer", - "description": "A count of the total number of resources that the tag is applied to.\n" + "description": "A count of the total number of resources that the tag is applied to.\n", + "type": "integer" }, "volumeSnapshotsCount": { - "type": "integer", - "description": "A count of the volume snapshots that the tag is applied to.\n" + "description": "A count of the volume snapshots that the tag is applied to.\n", + "type": "integer" }, "volumesCount": { - "type": "integer", - "description": "A count of the volumes that the tag is applied to.\n" + "description": "A count of the volumes that the tag is applied to.\n", + "type": "integer" } }, - "type": "object", "required": [ "databasesCount", "dropletsCount", @@ -17336,7 +17335,8 @@ "volumeSnapshotsCount", "volumesCount", "id" - ] + ], + "type": "object" } }, "digitalocean:index/getTags:getTags": { @@ -17365,37 +17365,37 @@ "description": "A collection of values returned by getTags.\n", "properties": { "filters": { - "type": "array", "items": { "$ref": "#/types/digitalocean:index/getTagsFilter:getTagsFilter" - } + }, + "type": "array" }, "id": { - "type": "string", - "description": "The provider-assigned unique ID for this managed resource.\n" + "description": "The provider-assigned unique ID for this managed resource.\n", + "type": "string" }, "sorts": { - "type": "array", "items": { "$ref": "#/types/digitalocean:index/getTagsSort:getTagsSort" - } + }, + "type": "array" }, "tags": { - "type": "array", "items": { "$ref": "#/types/digitalocean:index/getTagsTag:getTagsTag" - } + }, + "type": "array" } }, - "type": "object", "required": [ "tags", "id" - ] + ], + "type": "object" } }, "digitalocean:index/getVolume:getVolume": { - "description": "Get information on a volume for use in other resources. This data source provides\nall of the volumes properties as configured on your DigitalOcean account. This is\nuseful if the volume in question is not managed by the provider or you need to utilize\nany of the volumes data.\n\nAn error is triggered if the provided volume name does not exist.\n\n## Example Usage\n\nGet the volume:\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst example = digitalocean.getVolume({\n name: \"app-data\",\n region: \"nyc3\",\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nexample = digitalocean.get_volume(name=\"app-data\",\n region=\"nyc3\")\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var example = DigitalOcean.GetVolume.Invoke(new()\n {\n Name = \"app-data\",\n Region = \"nyc3\",\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := digitalocean.LookupVolume(ctx, \u0026digitalocean.LookupVolumeArgs{\n\t\t\tName: \"app-data\",\n\t\t\tRegion: pulumi.StringRef(\"nyc3\"),\n\t\t}, nil)\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.digitalocean.DigitaloceanFunctions;\nimport com.pulumi.digitalocean.inputs.GetVolumeArgs;\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 final var example = DigitaloceanFunctions.getVolume(GetVolumeArgs.builder()\n .name(\"app-data\")\n .region(\"nyc3\")\n .build());\n\n }\n}\n```\n```yaml\nvariables:\n example:\n fn::invoke:\n Function: digitalocean:getVolume\n Arguments:\n name: app-data\n region: nyc3\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\nReuse the data about a volume to attach it to a Droplet:\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst exampleVolume = digitalocean.getVolume({\n name: \"app-data\",\n region: \"nyc3\",\n});\nconst exampleDroplet = new digitalocean.Droplet(\"exampleDroplet\", {\n size: digitalocean.DropletSlug.DropletS1VCPU1GB,\n image: \"ubuntu-18-04-x64\",\n region: digitalocean.Region.NYC3,\n});\nconst foobar = new digitalocean.VolumeAttachment(\"foobar\", {\n dropletId: exampleDroplet.id,\n volumeId: exampleVolume.then(exampleVolume =\u003e exampleVolume.id),\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nexample_volume = digitalocean.get_volume(name=\"app-data\",\n region=\"nyc3\")\nexample_droplet = digitalocean.Droplet(\"exampleDroplet\",\n size=digitalocean.DropletSlug.DROPLET_S1_VCPU1_GB,\n image=\"ubuntu-18-04-x64\",\n region=digitalocean.Region.NYC3)\nfoobar = digitalocean.VolumeAttachment(\"foobar\",\n droplet_id=example_droplet.id,\n volume_id=example_volume.id)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var exampleVolume = DigitalOcean.GetVolume.Invoke(new()\n {\n Name = \"app-data\",\n Region = \"nyc3\",\n });\n\n var exampleDroplet = new DigitalOcean.Droplet(\"exampleDroplet\", new()\n {\n Size = DigitalOcean.DropletSlug.DropletS1VCPU1GB,\n Image = \"ubuntu-18-04-x64\",\n Region = DigitalOcean.Region.NYC3,\n });\n\n var foobar = new DigitalOcean.VolumeAttachment(\"foobar\", new()\n {\n DropletId = exampleDroplet.Id,\n VolumeId = exampleVolume.Apply(getVolumeResult =\u003e getVolumeResult.Id),\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\texampleVolume, err := digitalocean.LookupVolume(ctx, \u0026digitalocean.LookupVolumeArgs{\n\t\t\tName: \"app-data\",\n\t\t\tRegion: pulumi.StringRef(\"nyc3\"),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\texampleDroplet, err := digitalocean.NewDroplet(ctx, \"exampleDroplet\", \u0026digitalocean.DropletArgs{\n\t\t\tSize: pulumi.String(digitalocean.DropletSlugDropletS1VCPU1GB),\n\t\t\tImage: pulumi.String(\"ubuntu-18-04-x64\"),\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC3),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = digitalocean.NewVolumeAttachment(ctx, \"foobar\", \u0026digitalocean.VolumeAttachmentArgs{\n\t\t\tDropletId: exampleDroplet.ID(),\n\t\t\tVolumeId: pulumi.String(exampleVolume.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.digitalocean.DigitaloceanFunctions;\nimport com.pulumi.digitalocean.inputs.GetVolumeArgs;\nimport com.pulumi.digitalocean.Droplet;\nimport com.pulumi.digitalocean.DropletArgs;\nimport com.pulumi.digitalocean.VolumeAttachment;\nimport com.pulumi.digitalocean.VolumeAttachmentArgs;\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 final var exampleVolume = DigitaloceanFunctions.getVolume(GetVolumeArgs.builder()\n .name(\"app-data\")\n .region(\"nyc3\")\n .build());\n\n var exampleDroplet = new Droplet(\"exampleDroplet\", DropletArgs.builder() \n .size(\"s-1vcpu-1gb\")\n .image(\"ubuntu-18-04-x64\")\n .region(\"nyc3\")\n .build());\n\n var foobar = new VolumeAttachment(\"foobar\", VolumeAttachmentArgs.builder() \n .dropletId(exampleDroplet.id())\n .volumeId(exampleVolume.applyValue(getVolumeResult -\u003e getVolumeResult.id()))\n .build());\n\n }\n}\n```\n```yaml\nresources:\n exampleDroplet:\n type: digitalocean:Droplet\n properties:\n size: s-1vcpu-1gb\n image: ubuntu-18-04-x64\n region: nyc3\n foobar:\n type: digitalocean:VolumeAttachment\n properties:\n dropletId: ${exampleDroplet.id}\n volumeId: ${exampleVolume.id}\nvariables:\n exampleVolume:\n fn::invoke:\n Function: digitalocean:getVolume\n Arguments:\n name: app-data\n region: nyc3\n```\n\u003c!--End PulumiCodeChooser --\u003e\n", + "description": "Get information on a volume for use in other resources. This data source provides\nall of the volumes properties as configured on your DigitalOcean account. This is\nuseful if the volume in question is not managed by the provider or you need to utilize\nany of the volumes data.\n\nAn error is triggered if the provided volume name does not exist.\n\n## Example Usage\n\nGet the volume:\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst example = digitalocean.getVolume({\n name: \"app-data\",\n region: \"nyc3\",\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nexample = digitalocean.get_volume(name=\"app-data\",\n region=\"nyc3\")\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var example = DigitalOcean.GetVolume.Invoke(new()\n {\n Name = \"app-data\",\n Region = \"nyc3\",\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := digitalocean.LookupVolume(ctx, \u0026digitalocean.LookupVolumeArgs{\n\t\t\tName: \"app-data\",\n\t\t\tRegion: pulumi.StringRef(\"nyc3\"),\n\t\t}, nil)\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.digitalocean.DigitaloceanFunctions;\nimport com.pulumi.digitalocean.inputs.GetVolumeArgs;\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 final var example = DigitaloceanFunctions.getVolume(GetVolumeArgs.builder()\n .name(\"app-data\")\n .region(\"nyc3\")\n .build());\n\n }\n}\n```\n```yaml\nvariables:\n example:\n fn::invoke:\n Function: digitalocean:getVolume\n Arguments:\n name: app-data\n region: nyc3\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\nReuse the data about a volume to attach it to a Droplet:\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst example = digitalocean.getVolume({\n name: \"app-data\",\n region: \"nyc3\",\n});\nconst exampleDroplet = new digitalocean.Droplet(\"example\", {\n name: \"foo\",\n size: digitalocean.DropletSlug.DropletS1VCPU1GB,\n image: \"ubuntu-18-04-x64\",\n region: digitalocean.Region.NYC3,\n});\nconst foobar = new digitalocean.VolumeAttachment(\"foobar\", {\n dropletId: exampleDroplet.id,\n volumeId: example.then(example =\u003e example.id),\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nexample = digitalocean.get_volume(name=\"app-data\",\n region=\"nyc3\")\nexample_droplet = digitalocean.Droplet(\"example\",\n name=\"foo\",\n size=digitalocean.DropletSlug.DROPLET_S1_VCPU1_GB,\n image=\"ubuntu-18-04-x64\",\n region=digitalocean.Region.NYC3)\nfoobar = digitalocean.VolumeAttachment(\"foobar\",\n droplet_id=example_droplet.id,\n volume_id=example.id)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var example = DigitalOcean.GetVolume.Invoke(new()\n {\n Name = \"app-data\",\n Region = \"nyc3\",\n });\n\n var exampleDroplet = new DigitalOcean.Droplet(\"example\", new()\n {\n Name = \"foo\",\n Size = DigitalOcean.DropletSlug.DropletS1VCPU1GB,\n Image = \"ubuntu-18-04-x64\",\n Region = DigitalOcean.Region.NYC3,\n });\n\n var foobar = new DigitalOcean.VolumeAttachment(\"foobar\", new()\n {\n DropletId = exampleDroplet.Id,\n VolumeId = example.Apply(getVolumeResult =\u003e getVolumeResult.Id),\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\texample, err := digitalocean.LookupVolume(ctx, \u0026digitalocean.LookupVolumeArgs{\n\t\t\tName: \"app-data\",\n\t\t\tRegion: pulumi.StringRef(\"nyc3\"),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\texampleDroplet, err := digitalocean.NewDroplet(ctx, \"example\", \u0026digitalocean.DropletArgs{\n\t\t\tName: pulumi.String(\"foo\"),\n\t\t\tSize: pulumi.String(digitalocean.DropletSlugDropletS1VCPU1GB),\n\t\t\tImage: pulumi.String(\"ubuntu-18-04-x64\"),\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC3),\n\t\t})\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = digitalocean.NewVolumeAttachment(ctx, \"foobar\", \u0026digitalocean.VolumeAttachmentArgs{\n\t\t\tDropletId: exampleDroplet.ID(),\n\t\t\tVolumeId: pulumi.String(example.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.digitalocean.DigitaloceanFunctions;\nimport com.pulumi.digitalocean.inputs.GetVolumeArgs;\nimport com.pulumi.digitalocean.Droplet;\nimport com.pulumi.digitalocean.DropletArgs;\nimport com.pulumi.digitalocean.VolumeAttachment;\nimport com.pulumi.digitalocean.VolumeAttachmentArgs;\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 final var example = DigitaloceanFunctions.getVolume(GetVolumeArgs.builder()\n .name(\"app-data\")\n .region(\"nyc3\")\n .build());\n\n var exampleDroplet = new Droplet(\"exampleDroplet\", DropletArgs.builder() \n .name(\"foo\")\n .size(\"s-1vcpu-1gb\")\n .image(\"ubuntu-18-04-x64\")\n .region(\"nyc3\")\n .build());\n\n var foobar = new VolumeAttachment(\"foobar\", VolumeAttachmentArgs.builder() \n .dropletId(exampleDroplet.id())\n .volumeId(example.applyValue(getVolumeResult -\u003e getVolumeResult.id()))\n .build());\n\n }\n}\n```\n```yaml\nresources:\n exampleDroplet:\n type: digitalocean:Droplet\n name: example\n properties:\n name: foo\n size: s-1vcpu-1gb\n image: ubuntu-18-04-x64\n region: nyc3\n foobar:\n type: digitalocean:VolumeAttachment\n properties:\n dropletId: ${exampleDroplet.id}\n volumeId: ${example.id}\nvariables:\n example:\n fn::invoke:\n Function: digitalocean:getVolume\n Arguments:\n name: app-data\n region: nyc3\n```\n\u003c!--End PulumiCodeChooser --\u003e\n", "inputs": { "description": "A collection of arguments for invoking getVolume.\n", "properties": { @@ -17421,27 +17421,27 @@ "description": "A collection of values returned by getVolume.\n", "properties": { "description": { - "type": "string", - "description": "Text describing a block storage volume.\n" + "description": "Text describing a block storage volume.\n", + "type": "string" }, "dropletIds": { - "type": "array", + "description": "A list of associated Droplet ids.\n", "items": { "type": "integer" }, - "description": "A list of associated Droplet ids.\n" + "type": "array" }, "filesystemLabel": { - "type": "string", - "description": "Filesystem label currently in-use on the block storage volume.\n" + "description": "Filesystem label currently in-use on the block storage volume.\n", + "type": "string" }, "filesystemType": { - "type": "string", - "description": "Filesystem type currently in-use on the block storage volume.\n" + "description": "Filesystem type currently in-use on the block storage volume.\n", + "type": "string" }, "id": { - "type": "string", - "description": "The provider-assigned unique ID for this managed resource.\n" + "description": "The provider-assigned unique ID for this managed resource.\n", + "type": "string" }, "name": { "type": "string" @@ -17450,22 +17450,21 @@ "type": "string" }, "size": { - "type": "integer", - "description": "The size of the block storage volume in GiB.\n" + "description": "The size of the block storage volume in GiB.\n", + "type": "integer" }, "tags": { - "type": "array", + "description": "A list of the tags associated to the Volume.\n", "items": { "type": "string" }, - "description": "A list of the tags associated to the Volume.\n" + "type": "array" }, "urn": { - "type": "string", - "description": "The uniform resource name for the storage volume.\n" + "description": "The uniform resource name for the storage volume.\n", + "type": "string" } }, - "type": "object", "required": [ "dropletIds", "filesystemLabel", @@ -17475,11 +17474,12 @@ "tags", "urn", "id" - ] + ], + "type": "object" } }, "digitalocean:index/getVolumeSnapshot:getVolumeSnapshot": { - "description": "Volume snapshots are saved instances of a block storage volume. Use this data\nsource to retrieve the ID of a DigitalOcean volume snapshot for use in other\nresources.\n\n## Example Usage\n\nGet the volume snapshot:\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst snapshot = digitalocean.getVolumeSnapshot({\n mostRecent: true,\n nameRegex: \"^web\",\n region: \"nyc3\",\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nsnapshot = digitalocean.get_volume_snapshot(most_recent=True,\n name_regex=\"^web\",\n region=\"nyc3\")\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var snapshot = DigitalOcean.GetVolumeSnapshot.Invoke(new()\n {\n MostRecent = true,\n NameRegex = \"^web\",\n Region = \"nyc3\",\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := digitalocean.LookupVolumeSnapshot(ctx, \u0026digitalocean.LookupVolumeSnapshotArgs{\n\t\t\tMostRecent: pulumi.BoolRef(true),\n\t\t\tNameRegex: pulumi.StringRef(\"^web\"),\n\t\t\tRegion: pulumi.StringRef(\"nyc3\"),\n\t\t}, nil)\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.digitalocean.DigitaloceanFunctions;\nimport com.pulumi.digitalocean.inputs.GetVolumeSnapshotArgs;\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 final var snapshot = DigitaloceanFunctions.getVolumeSnapshot(GetVolumeSnapshotArgs.builder()\n .mostRecent(true)\n .nameRegex(\"^web\")\n .region(\"nyc3\")\n .build());\n\n }\n}\n```\n```yaml\nvariables:\n snapshot:\n fn::invoke:\n Function: digitalocean:getVolumeSnapshot\n Arguments:\n mostRecent: true\n nameRegex: ^web\n region: nyc3\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\nReuse the data about a volume snapshot to create a new volume based on it:\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst snapshot = digitalocean.getVolumeSnapshot({\n nameRegex: \"^web\",\n region: \"nyc3\",\n mostRecent: true,\n});\nconst foobar = new digitalocean.Volume(\"foobar\", {\n region: digitalocean.Region.NYC3,\n size: 100,\n snapshotId: snapshot.then(snapshot =\u003e snapshot.id),\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nsnapshot = digitalocean.get_volume_snapshot(name_regex=\"^web\",\n region=\"nyc3\",\n most_recent=True)\nfoobar = digitalocean.Volume(\"foobar\",\n region=digitalocean.Region.NYC3,\n size=100,\n snapshot_id=snapshot.id)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var snapshot = DigitalOcean.GetVolumeSnapshot.Invoke(new()\n {\n NameRegex = \"^web\",\n Region = \"nyc3\",\n MostRecent = true,\n });\n\n var foobar = new DigitalOcean.Volume(\"foobar\", new()\n {\n Region = DigitalOcean.Region.NYC3,\n Size = 100,\n SnapshotId = snapshot.Apply(getVolumeSnapshotResult =\u003e getVolumeSnapshotResult.Id),\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tsnapshot, err := digitalocean.LookupVolumeSnapshot(ctx, \u0026digitalocean.LookupVolumeSnapshotArgs{\n\t\t\tNameRegex: pulumi.StringRef(\"^web\"),\n\t\t\tRegion: pulumi.StringRef(\"nyc3\"),\n\t\t\tMostRecent: pulumi.BoolRef(true),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = digitalocean.NewVolume(ctx, \"foobar\", \u0026digitalocean.VolumeArgs{\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC3),\n\t\t\tSize: pulumi.Int(100),\n\t\t\tSnapshotId: pulumi.String(snapshot.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.digitalocean.DigitaloceanFunctions;\nimport com.pulumi.digitalocean.inputs.GetVolumeSnapshotArgs;\nimport com.pulumi.digitalocean.Volume;\nimport com.pulumi.digitalocean.VolumeArgs;\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 final var snapshot = DigitaloceanFunctions.getVolumeSnapshot(GetVolumeSnapshotArgs.builder()\n .nameRegex(\"^web\")\n .region(\"nyc3\")\n .mostRecent(true)\n .build());\n\n var foobar = new Volume(\"foobar\", VolumeArgs.builder() \n .region(\"nyc3\")\n .size(100)\n .snapshotId(snapshot.applyValue(getVolumeSnapshotResult -\u003e getVolumeSnapshotResult.id()))\n .build());\n\n }\n}\n```\n```yaml\nresources:\n foobar:\n type: digitalocean:Volume\n properties:\n region: nyc3\n size: 100\n snapshotId: ${snapshot.id}\nvariables:\n snapshot:\n fn::invoke:\n Function: digitalocean:getVolumeSnapshot\n Arguments:\n nameRegex: ^web\n region: nyc3\n mostRecent: true\n```\n\u003c!--End PulumiCodeChooser --\u003e\n", + "description": "Volume snapshots are saved instances of a block storage volume. Use this data\nsource to retrieve the ID of a DigitalOcean volume snapshot for use in other\nresources.\n\n## Example Usage\n\nGet the volume snapshot:\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst snapshot = digitalocean.getVolumeSnapshot({\n nameRegex: \"^web\",\n region: \"nyc3\",\n mostRecent: true,\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nsnapshot = digitalocean.get_volume_snapshot(name_regex=\"^web\",\n region=\"nyc3\",\n most_recent=True)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var snapshot = DigitalOcean.GetVolumeSnapshot.Invoke(new()\n {\n NameRegex = \"^web\",\n Region = \"nyc3\",\n MostRecent = true,\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := digitalocean.LookupVolumeSnapshot(ctx, \u0026digitalocean.LookupVolumeSnapshotArgs{\n\t\t\tNameRegex: pulumi.StringRef(\"^web\"),\n\t\t\tRegion: pulumi.StringRef(\"nyc3\"),\n\t\t\tMostRecent: pulumi.BoolRef(true),\n\t\t}, nil)\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.digitalocean.DigitaloceanFunctions;\nimport com.pulumi.digitalocean.inputs.GetVolumeSnapshotArgs;\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 final var snapshot = DigitaloceanFunctions.getVolumeSnapshot(GetVolumeSnapshotArgs.builder()\n .nameRegex(\"^web\")\n .region(\"nyc3\")\n .mostRecent(true)\n .build());\n\n }\n}\n```\n```yaml\nvariables:\n snapshot:\n fn::invoke:\n Function: digitalocean:getVolumeSnapshot\n Arguments:\n nameRegex: ^web\n region: nyc3\n mostRecent: true\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\nReuse the data about a volume snapshot to create a new volume based on it:\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst snapshot = digitalocean.getVolumeSnapshot({\n nameRegex: \"^web\",\n region: \"nyc3\",\n mostRecent: true,\n});\nconst foobar = new digitalocean.Volume(\"foobar\", {\n region: digitalocean.Region.NYC3,\n name: \"baz\",\n size: 100,\n snapshotId: snapshot.then(snapshot =\u003e snapshot.id),\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nsnapshot = digitalocean.get_volume_snapshot(name_regex=\"^web\",\n region=\"nyc3\",\n most_recent=True)\nfoobar = digitalocean.Volume(\"foobar\",\n region=digitalocean.Region.NYC3,\n name=\"baz\",\n size=100,\n snapshot_id=snapshot.id)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var snapshot = DigitalOcean.GetVolumeSnapshot.Invoke(new()\n {\n NameRegex = \"^web\",\n Region = \"nyc3\",\n MostRecent = true,\n });\n\n var foobar = new DigitalOcean.Volume(\"foobar\", new()\n {\n Region = DigitalOcean.Region.NYC3,\n Name = \"baz\",\n Size = 100,\n SnapshotId = snapshot.Apply(getVolumeSnapshotResult =\u003e getVolumeSnapshotResult.Id),\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\tsnapshot, err := digitalocean.LookupVolumeSnapshot(ctx, \u0026digitalocean.LookupVolumeSnapshotArgs{\n\t\t\tNameRegex: pulumi.StringRef(\"^web\"),\n\t\t\tRegion: pulumi.StringRef(\"nyc3\"),\n\t\t\tMostRecent: pulumi.BoolRef(true),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = digitalocean.NewVolume(ctx, \"foobar\", \u0026digitalocean.VolumeArgs{\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC3),\n\t\t\tName: pulumi.String(\"baz\"),\n\t\t\tSize: pulumi.Int(100),\n\t\t\tSnapshotId: pulumi.String(snapshot.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.digitalocean.DigitaloceanFunctions;\nimport com.pulumi.digitalocean.inputs.GetVolumeSnapshotArgs;\nimport com.pulumi.digitalocean.Volume;\nimport com.pulumi.digitalocean.VolumeArgs;\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 final var snapshot = DigitaloceanFunctions.getVolumeSnapshot(GetVolumeSnapshotArgs.builder()\n .nameRegex(\"^web\")\n .region(\"nyc3\")\n .mostRecent(true)\n .build());\n\n var foobar = new Volume(\"foobar\", VolumeArgs.builder() \n .region(\"nyc3\")\n .name(\"baz\")\n .size(100)\n .snapshotId(snapshot.applyValue(getVolumeSnapshotResult -\u003e getVolumeSnapshotResult.id()))\n .build());\n\n }\n}\n```\n```yaml\nresources:\n foobar:\n type: digitalocean:Volume\n properties:\n region: nyc3\n name: baz\n size: 100\n snapshotId: ${snapshot.id}\nvariables:\n snapshot:\n fn::invoke:\n Function: digitalocean:getVolumeSnapshot\n Arguments:\n nameRegex: ^web\n region: nyc3\n mostRecent: true\n```\n\u003c!--End PulumiCodeChooser --\u003e\n", "inputs": { "description": "A collection of arguments for invoking getVolumeSnapshot.\n", "properties": { @@ -17506,16 +17506,16 @@ "description": "A collection of values returned by getVolumeSnapshot.\n", "properties": { "createdAt": { - "type": "string", - "description": "The date and time the volume snapshot was created.\n" + "description": "The date and time the volume snapshot was created.\n", + "type": "string" }, "id": { - "type": "string", - "description": "The provider-assigned unique ID for this managed resource.\n" + "description": "The provider-assigned unique ID for this managed resource.\n", + "type": "string" }, "minDiskSize": { - "type": "integer", - "description": "The minimum size in gigabytes required for a volume to be created based on this volume snapshot.\n" + "description": "The minimum size in gigabytes required for a volume to be created based on this volume snapshot.\n", + "type": "integer" }, "mostRecent": { "type": "boolean" @@ -17530,29 +17530,28 @@ "type": "string" }, "regions": { - "type": "array", + "description": "A list of DigitalOcean region \"slugs\" indicating where the volume snapshot is available.\n", "items": { "type": "string" }, - "description": "A list of DigitalOcean region \"slugs\" indicating where the volume snapshot is available.\n" + "type": "array" }, "size": { - "type": "number", - "description": "The billable size of the volume snapshot in gigabytes.\n" + "description": "The billable size of the volume snapshot in gigabytes.\n", + "type": "number" }, "tags": { - "type": "array", + "description": "A list of the tags associated to the volume snapshot.\n", "items": { "type": "string" }, - "description": "A list of the tags associated to the volume snapshot.\n" + "type": "array" }, "volumeId": { - "type": "string", - "description": "The ID of the volume from which the volume snapshot originated.\n" + "description": "The ID of the volume from which the volume snapshot originated.\n", + "type": "string" } }, - "type": "object", "required": [ "createdAt", "minDiskSize", @@ -17561,11 +17560,12 @@ "tags", "volumeId", "id" - ] + ], + "type": "object" } }, "digitalocean:index/getVpc:getVpc": { - "description": "Retrieve information about a VPC for use in other resources.\n\nThis data source provides all of the VPC's properties as configured on your\nDigitalOcean account. This is useful if the VPC in question is not managed by\nthe provider or you need to utilize any of the VPC's data.\n\nVPCs may be looked up by `id` or `name`. Specifying a `region` will\nreturn that that region's default VPC.\n\n## Example Usage\n\n### VPC By Name\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst example = digitalocean.getVpc({\n name: \"example-network\",\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nexample = digitalocean.get_vpc(name=\"example-network\")\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var example = DigitalOcean.GetVpc.Invoke(new()\n {\n Name = \"example-network\",\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := digitalocean.LookupVpc(ctx, \u0026digitalocean.LookupVpcArgs{\n\t\t\tName: pulumi.StringRef(\"example-network\"),\n\t\t}, nil)\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.digitalocean.DigitaloceanFunctions;\nimport com.pulumi.digitalocean.inputs.GetVpcArgs;\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 final var example = DigitaloceanFunctions.getVpc(GetVpcArgs.builder()\n .name(\"example-network\")\n .build());\n\n }\n}\n```\n```yaml\nvariables:\n example:\n fn::invoke:\n Function: digitalocean:getVpc\n Arguments:\n name: example-network\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\nReuse the data about a VPC to assign a Droplet to it:\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst exampleVpc = digitalocean.getVpc({\n name: \"example-network\",\n});\nconst exampleDroplet = new digitalocean.Droplet(\"exampleDroplet\", {\n size: digitalocean.DropletSlug.DropletS1VCPU1GB,\n image: \"ubuntu-18-04-x64\",\n region: digitalocean.Region.NYC3,\n vpcUuid: exampleVpc.then(exampleVpc =\u003e exampleVpc.id),\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nexample_vpc = digitalocean.get_vpc(name=\"example-network\")\nexample_droplet = digitalocean.Droplet(\"exampleDroplet\",\n size=digitalocean.DropletSlug.DROPLET_S1_VCPU1_GB,\n image=\"ubuntu-18-04-x64\",\n region=digitalocean.Region.NYC3,\n vpc_uuid=example_vpc.id)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var exampleVpc = DigitalOcean.GetVpc.Invoke(new()\n {\n Name = \"example-network\",\n });\n\n var exampleDroplet = new DigitalOcean.Droplet(\"exampleDroplet\", new()\n {\n Size = DigitalOcean.DropletSlug.DropletS1VCPU1GB,\n Image = \"ubuntu-18-04-x64\",\n Region = DigitalOcean.Region.NYC3,\n VpcUuid = exampleVpc.Apply(getVpcResult =\u003e getVpcResult.Id),\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\texampleVpc, err := digitalocean.LookupVpc(ctx, \u0026digitalocean.LookupVpcArgs{\n\t\t\tName: pulumi.StringRef(\"example-network\"),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = digitalocean.NewDroplet(ctx, \"exampleDroplet\", \u0026digitalocean.DropletArgs{\n\t\t\tSize: pulumi.String(digitalocean.DropletSlugDropletS1VCPU1GB),\n\t\t\tImage: pulumi.String(\"ubuntu-18-04-x64\"),\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC3),\n\t\t\tVpcUuid: pulumi.String(exampleVpc.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.digitalocean.DigitaloceanFunctions;\nimport com.pulumi.digitalocean.inputs.GetVpcArgs;\nimport com.pulumi.digitalocean.Droplet;\nimport com.pulumi.digitalocean.DropletArgs;\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 final var exampleVpc = DigitaloceanFunctions.getVpc(GetVpcArgs.builder()\n .name(\"example-network\")\n .build());\n\n var exampleDroplet = new Droplet(\"exampleDroplet\", DropletArgs.builder() \n .size(\"s-1vcpu-1gb\")\n .image(\"ubuntu-18-04-x64\")\n .region(\"nyc3\")\n .vpcUuid(exampleVpc.applyValue(getVpcResult -\u003e getVpcResult.id()))\n .build());\n\n }\n}\n```\n```yaml\nresources:\n exampleDroplet:\n type: digitalocean:Droplet\n properties:\n size: s-1vcpu-1gb\n image: ubuntu-18-04-x64\n region: nyc3\n vpcUuid: ${exampleVpc.id}\nvariables:\n exampleVpc:\n fn::invoke:\n Function: digitalocean:getVpc\n Arguments:\n name: example-network\n```\n\u003c!--End PulumiCodeChooser --\u003e\n", + "description": "Retrieve information about a VPC for use in other resources.\n\nThis data source provides all of the VPC's properties as configured on your\nDigitalOcean account. This is useful if the VPC in question is not managed by\nthe provider or you need to utilize any of the VPC's data.\n\nVPCs may be looked up by `id` or `name`. Specifying a `region` will\nreturn that that region's default VPC.\n\n## Example Usage\n\n### VPC By Name\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst example = digitalocean.getVpc({\n name: \"example-network\",\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nexample = digitalocean.get_vpc(name=\"example-network\")\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var example = DigitalOcean.GetVpc.Invoke(new()\n {\n Name = \"example-network\",\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\t_, err := digitalocean.LookupVpc(ctx, \u0026digitalocean.LookupVpcArgs{\n\t\t\tName: pulumi.StringRef(\"example-network\"),\n\t\t}, nil)\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.digitalocean.DigitaloceanFunctions;\nimport com.pulumi.digitalocean.inputs.GetVpcArgs;\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 final var example = DigitaloceanFunctions.getVpc(GetVpcArgs.builder()\n .name(\"example-network\")\n .build());\n\n }\n}\n```\n```yaml\nvariables:\n example:\n fn::invoke:\n Function: digitalocean:getVpc\n Arguments:\n name: example-network\n```\n\u003c!--End PulumiCodeChooser --\u003e\n\nReuse the data about a VPC to assign a Droplet to it:\n\n\u003c!--Start PulumiCodeChooser --\u003e\n```typescript\nimport * as pulumi from \"@pulumi/pulumi\";\nimport * as digitalocean from \"@pulumi/digitalocean\";\n\nconst example = digitalocean.getVpc({\n name: \"example-network\",\n});\nconst exampleDroplet = new digitalocean.Droplet(\"example\", {\n name: \"example-01\",\n size: digitalocean.DropletSlug.DropletS1VCPU1GB,\n image: \"ubuntu-18-04-x64\",\n region: digitalocean.Region.NYC3,\n vpcUuid: example.then(example =\u003e example.id),\n});\n```\n```python\nimport pulumi\nimport pulumi_digitalocean as digitalocean\n\nexample = digitalocean.get_vpc(name=\"example-network\")\nexample_droplet = digitalocean.Droplet(\"example\",\n name=\"example-01\",\n size=digitalocean.DropletSlug.DROPLET_S1_VCPU1_GB,\n image=\"ubuntu-18-04-x64\",\n region=digitalocean.Region.NYC3,\n vpc_uuid=example.id)\n```\n```csharp\nusing System.Collections.Generic;\nusing System.Linq;\nusing Pulumi;\nusing DigitalOcean = Pulumi.DigitalOcean;\n\nreturn await Deployment.RunAsync(() =\u003e \n{\n var example = DigitalOcean.GetVpc.Invoke(new()\n {\n Name = \"example-network\",\n });\n\n var exampleDroplet = new DigitalOcean.Droplet(\"example\", new()\n {\n Name = \"example-01\",\n Size = DigitalOcean.DropletSlug.DropletS1VCPU1GB,\n Image = \"ubuntu-18-04-x64\",\n Region = DigitalOcean.Region.NYC3,\n VpcUuid = example.Apply(getVpcResult =\u003e getVpcResult.Id),\n });\n\n});\n```\n```go\npackage main\n\nimport (\n\t\"github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean\"\n\t\"github.com/pulumi/pulumi/sdk/v3/go/pulumi\"\n)\n\nfunc main() {\n\tpulumi.Run(func(ctx *pulumi.Context) error {\n\t\texample, err := digitalocean.LookupVpc(ctx, \u0026digitalocean.LookupVpcArgs{\n\t\t\tName: pulumi.StringRef(\"example-network\"),\n\t\t}, nil)\n\t\tif err != nil {\n\t\t\treturn err\n\t\t}\n\t\t_, err = digitalocean.NewDroplet(ctx, \"example\", \u0026digitalocean.DropletArgs{\n\t\t\tName: pulumi.String(\"example-01\"),\n\t\t\tSize: pulumi.String(digitalocean.DropletSlugDropletS1VCPU1GB),\n\t\t\tImage: pulumi.String(\"ubuntu-18-04-x64\"),\n\t\t\tRegion: pulumi.String(digitalocean.RegionNYC3),\n\t\t\tVpcUuid: pulumi.String(example.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.digitalocean.DigitaloceanFunctions;\nimport com.pulumi.digitalocean.inputs.GetVpcArgs;\nimport com.pulumi.digitalocean.Droplet;\nimport com.pulumi.digitalocean.DropletArgs;\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 final var example = DigitaloceanFunctions.getVpc(GetVpcArgs.builder()\n .name(\"example-network\")\n .build());\n\n var exampleDroplet = new Droplet(\"exampleDroplet\", DropletArgs.builder() \n .name(\"example-01\")\n .size(\"s-1vcpu-1gb\")\n .image(\"ubuntu-18-04-x64\")\n .region(\"nyc3\")\n .vpcUuid(example.applyValue(getVpcResult -\u003e getVpcResult.id()))\n .build());\n\n }\n}\n```\n```yaml\nresources:\n exampleDroplet:\n type: digitalocean:Droplet\n name: example\n properties:\n name: example-01\n size: s-1vcpu-1gb\n image: ubuntu-18-04-x64\n region: nyc3\n vpcUuid: ${example.id}\nvariables:\n example:\n fn::invoke:\n Function: digitalocean:getVpc\n Arguments:\n name: example-network\n```\n\u003c!--End PulumiCodeChooser --\u003e\n", "inputs": { "description": "A collection of arguments for invoking getVpc.\n", "properties": { @@ -17588,39 +17588,38 @@ "description": "A collection of values returned by getVpc.\n", "properties": { "createdAt": { - "type": "string", - "description": "The date and time of when the VPC was created.\n" + "description": "The date and time of when the VPC was created.\n", + "type": "string" }, "default": { - "type": "boolean", - "description": "A boolean indicating whether or not the VPC is the default one for the region.\n" + "description": "A boolean indicating whether or not the VPC is the default one for the region.\n", + "type": "boolean" }, "description": { - "type": "string", - "description": "A free-form text field describing the VPC.\n" + "description": "A free-form text field describing the VPC.\n", + "type": "string" }, "id": { - "type": "string", - "description": "The unique identifier for the VPC.\n" + "description": "The unique identifier for the VPC.\n", + "type": "string" }, "ipRange": { - "type": "string", - "description": "The range of IP addresses for the VPC in CIDR notation.\n" + "description": "The range of IP addresses for the VPC in CIDR notation.\n", + "type": "string" }, "name": { - "type": "string", - "description": "The name of the VPC.\n" + "description": "The name of the VPC.\n", + "type": "string" }, "region": { - "type": "string", - "description": "The DigitalOcean region slug for the VPC's location.\n" + "description": "The DigitalOcean region slug for the VPC's location.\n", + "type": "string" }, "urn": { - "type": "string", - "description": "The uniform resource name (URN) for the VPC.\n" + "description": "The uniform resource name (URN) for the VPC.\n", + "type": "string" } }, - "type": "object", "required": [ "createdAt", "default", @@ -17630,7 +17629,8 @@ "name", "region", "urn" - ] + ], + "type": "object" } } } diff --git a/sdk/dotnet/App.cs b/sdk/dotnet/App.cs index 9ce7e6be..e458aca2 100644 --- a/sdk/dotnet/App.cs +++ b/sdk/dotnet/App.cs @@ -36,15 +36,15 @@ namespace Pulumi.DigitalOcean /// { /// new DigitalOcean.Inputs.AppSpecServiceArgs /// { + /// Name = "go-service", /// EnvironmentSlug = "go", + /// InstanceCount = 1, + /// InstanceSizeSlug = "professional-xs", /// Git = new DigitalOcean.Inputs.AppSpecServiceGitArgs /// { - /// Branch = "main", /// RepoCloneUrl = "https://github.com/digitalocean/sample-golang.git", + /// Branch = "main", /// }, - /// InstanceCount = 1, - /// InstanceSizeSlug = "professional-xs", - /// Name = "go-service", /// }, /// }, /// }, @@ -73,14 +73,14 @@ namespace Pulumi.DigitalOcean /// { /// new DigitalOcean.Inputs.AppSpecStaticSiteArgs /// { + /// Name = "sample-jekyll", /// BuildCommand = "bundle exec jekyll build -d ./public", + /// OutputDir = "/public", /// Git = new DigitalOcean.Inputs.AppSpecStaticSiteGitArgs /// { - /// Branch = "main", /// RepoCloneUrl = "https://github.com/digitalocean/sample-jekyll.git", + /// Branch = "main", /// }, - /// Name = "sample-jekyll", - /// OutputDir = "/public", /// }, /// }, /// }, diff --git a/sdk/dotnet/Cdn.cs b/sdk/dotnet/Cdn.cs index 9e74bbfd..77b4c1f5 100644 --- a/sdk/dotnet/Cdn.cs +++ b/sdk/dotnet/Cdn.cs @@ -27,6 +27,7 @@ namespace Pulumi.DigitalOcean /// // Create a new Spaces Bucket /// var mybucket = new DigitalOcean.SpacesBucket("mybucket", new() /// { + /// Name = "example", /// Region = DigitalOcean.Region.SFO2, /// Acl = "public-read", /// }); @@ -57,6 +58,7 @@ namespace Pulumi.DigitalOcean /// // Create a new Spaces Bucket /// var mybucket = new DigitalOcean.SpacesBucket("mybucket", new() /// { + /// Name = "example", /// Region = DigitalOcean.Region.SFO2, /// Acl = "public-read", /// }); @@ -64,6 +66,7 @@ namespace Pulumi.DigitalOcean /// // Create a DigitalOcean managed Let's Encrypt Certificate /// var cert = new DigitalOcean.Certificate("cert", new() /// { + /// Name = "cdn-cert", /// Type = DigitalOcean.CertificateType.LetsEncrypt, /// Domains = new[] /// { diff --git a/sdk/dotnet/Certificate.cs b/sdk/dotnet/Certificate.cs index 20b9e5a4..1359f3dc 100644 --- a/sdk/dotnet/Certificate.cs +++ b/sdk/dotnet/Certificate.cs @@ -23,19 +23,29 @@ namespace Pulumi.DigitalOcean /// /// ```csharp /// using System.Collections.Generic; - /// using System.IO; /// using System.Linq; /// using Pulumi; /// using DigitalOcean = Pulumi.DigitalOcean; + /// using Std = Pulumi.Std; /// /// return await Deployment.RunAsync(() => /// { /// var cert = new DigitalOcean.Certificate("cert", new() /// { + /// Name = "custom-example", /// Type = DigitalOcean.CertificateType.Custom, - /// PrivateKey = File.ReadAllText("/Users/myuser/certs/privkey.pem"), - /// LeafCertificate = File.ReadAllText("/Users/myuser/certs/cert.pem"), - /// CertificateChain = File.ReadAllText("/Users/myuser/certs/fullchain.pem"), + /// PrivateKey = Std.File.Invoke(new() + /// { + /// Input = "/Users/myuser/certs/privkey.pem", + /// }).Apply(invoke => invoke.Result), + /// LeafCertificate = Std.File.Invoke(new() + /// { + /// Input = "/Users/myuser/certs/cert.pem", + /// }).Apply(invoke => invoke.Result), + /// CertificateChain = Std.File.Invoke(new() + /// { + /// Input = "/Users/myuser/certs/fullchain.pem", + /// }).Apply(invoke => invoke.Result), /// }); /// /// }); @@ -53,11 +63,12 @@ namespace Pulumi.DigitalOcean /// { /// var cert = new DigitalOcean.Certificate("cert", new() /// { + /// Name = "le-example", + /// Type = DigitalOcean.CertificateType.LetsEncrypt, /// Domains = new[] /// { /// "example.com", /// }, - /// Type = DigitalOcean.CertificateType.LetsEncrypt, /// }); /// /// }); @@ -78,6 +89,7 @@ namespace Pulumi.DigitalOcean /// { /// var cert = new DigitalOcean.Certificate("cert", new() /// { + /// Name = "le-example", /// Type = DigitalOcean.CertificateType.LetsEncrypt, /// Domains = new[] /// { @@ -88,6 +100,7 @@ namespace Pulumi.DigitalOcean /// // Create a new Load Balancer with TLS termination /// var @public = new DigitalOcean.LoadBalancer("public", new() /// { + /// Name = "secure-loadbalancer-1", /// Region = DigitalOcean.Region.NYC3, /// DropletTag = "backend", /// ForwardingRules = new[] diff --git a/sdk/dotnet/ContainerRegistry.cs b/sdk/dotnet/ContainerRegistry.cs index e4d1726c..2f63462d 100644 --- a/sdk/dotnet/ContainerRegistry.cs +++ b/sdk/dotnet/ContainerRegistry.cs @@ -26,6 +26,7 @@ namespace Pulumi.DigitalOcean /// // Create a new container registry /// var foobar = new DigitalOcean.ContainerRegistry("foobar", new() /// { + /// Name = "foobar", /// SubscriptionTierSlug = "starter", /// }); /// diff --git a/sdk/dotnet/ContainerRegistryDockerCredentials.cs b/sdk/dotnet/ContainerRegistryDockerCredentials.cs index 56748328..9e109edc 100644 --- a/sdk/dotnet/ContainerRegistryDockerCredentials.cs +++ b/sdk/dotnet/ContainerRegistryDockerCredentials.cs @@ -48,18 +48,58 @@ namespace Pulumi.DigitalOcean /// /// return await Deployment.RunAsync(() => /// { - /// var exampleContainerRegistry = DigitalOcean.GetContainerRegistry.Invoke(new() + /// var example = DigitalOcean.GetContainerRegistry.Invoke(new() /// { /// Name = "example", /// }); /// - /// var exampleContainerRegistryDockerCredentials = new DigitalOcean.ContainerRegistryDockerCredentials("exampleContainerRegistryDockerCredentials", new() + /// var exampleContainerRegistryDockerCredentials = new DigitalOcean.ContainerRegistryDockerCredentials("example", new() /// { /// RegistryName = "example", /// }); /// /// }); /// ``` + /// + /// ### Kubernetes Example + /// + /// Combined with the Kubernetes Provider's `kubernetes_secret` resource, you can + /// access the registry from inside your cluster: + /// + /// ```csharp + /// using System.Collections.Generic; + /// using System.Linq; + /// using Pulumi; + /// using DigitalOcean = Pulumi.DigitalOcean; + /// using Kubernetes = Pulumi.Kubernetes; + /// + /// return await Deployment.RunAsync(() => + /// { + /// var exampleContainerRegistryDockerCredentials = new DigitalOcean.ContainerRegistryDockerCredentials("example", new() + /// { + /// RegistryName = "example", + /// }); + /// + /// var example = DigitalOcean.GetKubernetesCluster.Invoke(new() + /// { + /// Name = "prod-cluster-01", + /// }); + /// + /// var exampleSecret = new Kubernetes.Core.V1.Secret("example", new() + /// { + /// Metadata = new Kubernetes.Types.Inputs.Meta.V1.ObjectMetaArgs + /// { + /// Name = "docker-cfg", + /// }, + /// Data = + /// { + /// { ".dockerconfigjson", exampleContainerRegistryDockerCredentials.DockerCredentials }, + /// }, + /// Type = "kubernetes.io/dockerconfigjson", + /// }); + /// + /// }); + /// ``` /// [DigitalOceanResourceType("digitalocean:index/containerRegistryDockerCredentials:ContainerRegistryDockerCredentials")] public partial class ContainerRegistryDockerCredentials : global::Pulumi.CustomResource diff --git a/sdk/dotnet/CustomImage.cs b/sdk/dotnet/CustomImage.cs index 08b855e7..395f8676 100644 --- a/sdk/dotnet/CustomImage.cs +++ b/sdk/dotnet/CustomImage.cs @@ -34,6 +34,7 @@ namespace Pulumi.DigitalOcean /// { /// var flatcar = new DigitalOcean.CustomImage("flatcar", new() /// { + /// Name = "flatcar", /// Url = "https://stable.release.flatcar-linux.net/amd64-usr/2605.7.0/flatcar_production_digitalocean_image.bin.bz2", /// Regions = new[] /// { @@ -44,6 +45,7 @@ namespace Pulumi.DigitalOcean /// var example = new DigitalOcean.Droplet("example", new() /// { /// Image = flatcar.Id, + /// Name = "example-01", /// Region = DigitalOcean.Region.NYC3, /// Size = DigitalOcean.DropletSlug.DropletS1VCPU1GB, /// SshKeys = new[] diff --git a/sdk/dotnet/DatabaseCluster.cs b/sdk/dotnet/DatabaseCluster.cs index 49ffbd51..389bce0e 100644 --- a/sdk/dotnet/DatabaseCluster.cs +++ b/sdk/dotnet/DatabaseCluster.cs @@ -25,11 +25,12 @@ namespace Pulumi.DigitalOcean /// { /// var postgres_example = new DigitalOcean.DatabaseCluster("postgres-example", new() /// { + /// Name = "example-postgres-cluster", /// Engine = "pg", - /// NodeCount = 1, - /// Region = DigitalOcean.Region.NYC1, - /// Size = DigitalOcean.DatabaseSlug.DB_1VPCU1GB, /// Version = "15", + /// Size = DigitalOcean.DatabaseSlug.DB_1VPCU1GB, + /// Region = DigitalOcean.Region.NYC1, + /// NodeCount = 1, /// }); /// /// }); @@ -46,11 +47,12 @@ namespace Pulumi.DigitalOcean /// { /// var mysql_example = new DigitalOcean.DatabaseCluster("mysql-example", new() /// { + /// Name = "example-mysql-cluster", /// Engine = "mysql", - /// NodeCount = 1, - /// Region = DigitalOcean.Region.NYC1, - /// Size = DigitalOcean.DatabaseSlug.DB_1VPCU1GB, /// Version = "8", + /// Size = DigitalOcean.DatabaseSlug.DB_1VPCU1GB, + /// Region = DigitalOcean.Region.NYC1, + /// NodeCount = 1, /// }); /// /// }); @@ -67,11 +69,12 @@ namespace Pulumi.DigitalOcean /// { /// var redis_example = new DigitalOcean.DatabaseCluster("redis-example", new() /// { + /// Name = "example-redis-cluster", /// Engine = "redis", - /// NodeCount = 1, - /// Region = DigitalOcean.Region.NYC1, - /// Size = DigitalOcean.DatabaseSlug.DB_1VPCU1GB, /// Version = "7", + /// Size = DigitalOcean.DatabaseSlug.DB_1VPCU1GB, + /// Region = DigitalOcean.Region.NYC1, + /// NodeCount = 1, /// }); /// /// }); @@ -88,11 +91,12 @@ namespace Pulumi.DigitalOcean /// { /// var kafka_example = new DigitalOcean.DatabaseCluster("kafka-example", new() /// { + /// Name = "example-kafka-cluster", /// Engine = "kafka", - /// NodeCount = 3, - /// Region = DigitalOcean.Region.NYC1, - /// Size = "db-s-2vcpu-2gb", /// Version = "3.5", + /// Size = "db-s-2vcpu-2gb", + /// Region = DigitalOcean.Region.NYC1, + /// NodeCount = 3, /// }); /// /// }); @@ -109,11 +113,12 @@ namespace Pulumi.DigitalOcean /// { /// var mongodb_example = new DigitalOcean.DatabaseCluster("mongodb-example", new() /// { + /// Name = "example-mongo-cluster", /// Engine = "mongodb", - /// NodeCount = 1, - /// Region = DigitalOcean.Region.NYC3, - /// Size = DigitalOcean.DatabaseSlug.DB_1VPCU1GB, /// Version = "6", + /// Size = DigitalOcean.DatabaseSlug.DB_1VPCU1GB, + /// Region = DigitalOcean.Region.NYC3, + /// NodeCount = 1, /// }); /// /// }); @@ -131,6 +136,7 @@ namespace Pulumi.DigitalOcean /// { /// var doby = new DigitalOcean.DatabaseCluster("doby", new() /// { + /// Name = "dobydb", /// Engine = "pg", /// Version = "15", /// Size = DigitalOcean.DatabaseSlug.DB_1VPCU2GB, @@ -142,8 +148,9 @@ namespace Pulumi.DigitalOcean /// }, /// }); /// - /// var dobyBackup = new DigitalOcean.DatabaseCluster("dobyBackup", new() + /// var dobyBackup = new DigitalOcean.DatabaseCluster("doby_backup", new() /// { + /// Name = "dobydupe", /// Engine = "pg", /// Version = "15", /// Size = DigitalOcean.DatabaseSlug.DB_1VPCU2GB, diff --git a/sdk/dotnet/DatabaseConnectionPool.cs b/sdk/dotnet/DatabaseConnectionPool.cs index 379b4225..7e9ef0c8 100644 --- a/sdk/dotnet/DatabaseConnectionPool.cs +++ b/sdk/dotnet/DatabaseConnectionPool.cs @@ -25,6 +25,7 @@ namespace Pulumi.DigitalOcean /// { /// var postgres_example = new DigitalOcean.DatabaseCluster("postgres-example", new() /// { + /// Name = "example-postgres-cluster", /// Engine = "pg", /// Version = "15", /// Size = DigitalOcean.DatabaseSlug.DB_1VPCU1GB, @@ -35,6 +36,7 @@ namespace Pulumi.DigitalOcean /// var pool_01 = new DigitalOcean.DatabaseConnectionPool("pool-01", new() /// { /// ClusterId = postgres_example.Id, + /// Name = "pool-01", /// Mode = "transaction", /// Size = 20, /// DbName = "defaultdb", diff --git a/sdk/dotnet/DatabaseDb.cs b/sdk/dotnet/DatabaseDb.cs index dd3c7cb8..459669b3 100644 --- a/sdk/dotnet/DatabaseDb.cs +++ b/sdk/dotnet/DatabaseDb.cs @@ -25,6 +25,7 @@ namespace Pulumi.DigitalOcean /// { /// var postgres_example = new DigitalOcean.DatabaseCluster("postgres-example", new() /// { + /// Name = "example-postgres-cluster", /// Engine = "pg", /// Version = "15", /// Size = DigitalOcean.DatabaseSlug.DB_1VPCU1GB, @@ -35,6 +36,7 @@ namespace Pulumi.DigitalOcean /// var database_example = new DigitalOcean.DatabaseDb("database-example", new() /// { /// ClusterId = postgres_example.Id, + /// Name = "foobar", /// }); /// /// }); diff --git a/sdk/dotnet/DatabaseFirewall.cs b/sdk/dotnet/DatabaseFirewall.cs index 22462ba4..e225ca88 100644 --- a/sdk/dotnet/DatabaseFirewall.cs +++ b/sdk/dotnet/DatabaseFirewall.cs @@ -28,6 +28,7 @@ namespace Pulumi.DigitalOcean /// { /// var postgres_example = new DigitalOcean.DatabaseCluster("postgres-example", new() /// { + /// Name = "example-postgres-cluster", /// Engine = "pg", /// Version = "15", /// Size = DigitalOcean.DatabaseSlug.DB_1VPCU1GB, @@ -68,6 +69,7 @@ namespace Pulumi.DigitalOcean /// { /// var web = new DigitalOcean.Droplet("web", new() /// { + /// Name = "web-01", /// Size = DigitalOcean.DropletSlug.DropletS1VCPU1GB, /// Image = "ubuntu-22-04-x64", /// Region = DigitalOcean.Region.NYC3, @@ -75,6 +77,7 @@ namespace Pulumi.DigitalOcean /// /// var postgres_example = new DigitalOcean.DatabaseCluster("postgres-example", new() /// { + /// Name = "example-postgres-cluster", /// Engine = "pg", /// Version = "15", /// Size = DigitalOcean.DatabaseSlug.DB_1VPCU1GB, @@ -110,6 +113,7 @@ namespace Pulumi.DigitalOcean /// { /// var postgres_example = new DigitalOcean.DatabaseCluster("postgres-example", new() /// { + /// Name = "example-postgres-cluster", /// Engine = "pg", /// Version = "15", /// Size = DigitalOcean.DatabaseSlug.DB_1VPCU1GB, @@ -120,6 +124,7 @@ namespace Pulumi.DigitalOcean /// var replica_example = new DigitalOcean.DatabaseReplica("replica-example", new() /// { /// ClusterId = postgres_example.Id, + /// Name = "replica-example", /// Size = DigitalOcean.DatabaseSlug.DB_1VPCU1GB, /// Region = DigitalOcean.Region.NYC1, /// }); diff --git a/sdk/dotnet/DatabaseKafkaTopic.cs b/sdk/dotnet/DatabaseKafkaTopic.cs index 1c199d66..b236ef9c 100644 --- a/sdk/dotnet/DatabaseKafkaTopic.cs +++ b/sdk/dotnet/DatabaseKafkaTopic.cs @@ -25,6 +25,7 @@ namespace Pulumi.DigitalOcean /// { /// var kafka_example = new DigitalOcean.DatabaseCluster("kafka-example", new() /// { + /// Name = "example-kafka-cluster", /// Engine = "kafka", /// Version = "3.5", /// Size = "db-s-2vcpu-2gb", @@ -39,6 +40,7 @@ namespace Pulumi.DigitalOcean /// var topic_01 = new DigitalOcean.DatabaseKafkaTopic("topic-01", new() /// { /// ClusterId = kafka_example.Id, + /// Name = "topic-01", /// PartitionCount = 3, /// ReplicationFactor = 2, /// Configs = new[] diff --git a/sdk/dotnet/DatabaseMysqlConfig.cs b/sdk/dotnet/DatabaseMysqlConfig.cs index a8ce3d03..6b766621 100644 --- a/sdk/dotnet/DatabaseMysqlConfig.cs +++ b/sdk/dotnet/DatabaseMysqlConfig.cs @@ -25,8 +25,9 @@ namespace Pulumi.DigitalOcean /// /// return await Deployment.RunAsync(() => /// { - /// var exampleDatabaseCluster = new DigitalOcean.DatabaseCluster("exampleDatabaseCluster", new() + /// var exampleDatabaseCluster = new DigitalOcean.DatabaseCluster("example", new() /// { + /// Name = "example-mysql-cluster", /// Engine = "mysql", /// Version = "8", /// Size = DigitalOcean.DatabaseSlug.DB_1VPCU1GB, @@ -34,7 +35,7 @@ namespace Pulumi.DigitalOcean /// NodeCount = 1, /// }); /// - /// var exampleDatabaseMysqlConfig = new DigitalOcean.DatabaseMysqlConfig("exampleDatabaseMysqlConfig", new() + /// var example = new DigitalOcean.DatabaseMysqlConfig("example", new() /// { /// ClusterId = exampleDatabaseCluster.Id, /// ConnectTimeout = 10, diff --git a/sdk/dotnet/DatabasePostgresqlConfig.cs b/sdk/dotnet/DatabasePostgresqlConfig.cs index c7ba5797..96610d85 100644 --- a/sdk/dotnet/DatabasePostgresqlConfig.cs +++ b/sdk/dotnet/DatabasePostgresqlConfig.cs @@ -25,8 +25,9 @@ namespace Pulumi.DigitalOcean /// /// return await Deployment.RunAsync(() => /// { - /// var exampleDatabaseCluster = new DigitalOcean.DatabaseCluster("exampleDatabaseCluster", new() + /// var exampleDatabaseCluster = new DigitalOcean.DatabaseCluster("example", new() /// { + /// Name = "example-postgresql-cluster", /// Engine = "pg", /// Version = "15", /// Size = DigitalOcean.DatabaseSlug.DB_1VPCU1GB, @@ -34,7 +35,7 @@ namespace Pulumi.DigitalOcean /// NodeCount = 1, /// }); /// - /// var exampleDatabasePostgresqlConfig = new DigitalOcean.DatabasePostgresqlConfig("exampleDatabasePostgresqlConfig", new() + /// var example = new DigitalOcean.DatabasePostgresqlConfig("example", new() /// { /// ClusterId = exampleDatabaseCluster.Id, /// Timezone = "UTC", diff --git a/sdk/dotnet/DatabaseRedisConfig.cs b/sdk/dotnet/DatabaseRedisConfig.cs index 1aa83b6c..ddda0822 100644 --- a/sdk/dotnet/DatabaseRedisConfig.cs +++ b/sdk/dotnet/DatabaseRedisConfig.cs @@ -25,8 +25,9 @@ namespace Pulumi.DigitalOcean /// /// return await Deployment.RunAsync(() => /// { - /// var exampleDatabaseCluster = new DigitalOcean.DatabaseCluster("exampleDatabaseCluster", new() + /// var exampleDatabaseCluster = new DigitalOcean.DatabaseCluster("example", new() /// { + /// Name = "example-redis-cluster", /// Engine = "redis", /// Version = "7", /// Size = DigitalOcean.DatabaseSlug.DB_1VPCU1GB, @@ -34,7 +35,7 @@ namespace Pulumi.DigitalOcean /// NodeCount = 1, /// }); /// - /// var exampleDatabaseRedisConfig = new DigitalOcean.DatabaseRedisConfig("exampleDatabaseRedisConfig", new() + /// var example = new DigitalOcean.DatabaseRedisConfig("example", new() /// { /// ClusterId = exampleDatabaseCluster.Id, /// MaxmemoryPolicy = "allkeys-lru", diff --git a/sdk/dotnet/DatabaseReplica.cs b/sdk/dotnet/DatabaseReplica.cs index 4c57c317..36334ff1 100644 --- a/sdk/dotnet/DatabaseReplica.cs +++ b/sdk/dotnet/DatabaseReplica.cs @@ -25,6 +25,7 @@ namespace Pulumi.DigitalOcean /// { /// var postgres_example = new DigitalOcean.DatabaseCluster("postgres-example", new() /// { + /// Name = "example-postgres-cluster", /// Engine = "pg", /// Version = "15", /// Size = DigitalOcean.DatabaseSlug.DB_1VPCU1GB, @@ -35,6 +36,7 @@ namespace Pulumi.DigitalOcean /// var replica_example = new DigitalOcean.DatabaseReplica("replica-example", new() /// { /// ClusterId = postgres_example.Id, + /// Name = "replica-example", /// Size = DigitalOcean.DatabaseSlug.DB_1VPCU1GB, /// Region = DigitalOcean.Region.NYC1, /// }); @@ -55,7 +57,7 @@ namespace Pulumi.DigitalOcean /// /// return new Dictionary<string, object?> /// { - /// ["uUID"] = replica_example.Uuid, + /// ["UUID"] = replica_example.Uuid, /// }; /// }); /// ``` diff --git a/sdk/dotnet/DatabaseUser.cs b/sdk/dotnet/DatabaseUser.cs index a3f9f17b..74e62a0e 100644 --- a/sdk/dotnet/DatabaseUser.cs +++ b/sdk/dotnet/DatabaseUser.cs @@ -27,6 +27,7 @@ namespace Pulumi.DigitalOcean /// { /// var postgres_example = new DigitalOcean.DatabaseCluster("postgres-example", new() /// { + /// Name = "example-postgres-cluster", /// Engine = "pg", /// Version = "15", /// Size = DigitalOcean.DatabaseSlug.DB_1VPCU1GB, @@ -37,6 +38,7 @@ namespace Pulumi.DigitalOcean /// var user_example = new DigitalOcean.DatabaseUser("user-example", new() /// { /// ClusterId = postgres_example.Id, + /// Name = "foobar", /// }); /// /// }); @@ -53,6 +55,7 @@ namespace Pulumi.DigitalOcean /// { /// var postgres_example = new DigitalOcean.DatabaseCluster("postgres-example", new() /// { + /// Name = "example-postgres-cluster", /// Engine = "pg", /// Version = "15", /// Size = DigitalOcean.DatabaseSlug.DB_1VPCU1GB, @@ -63,6 +66,7 @@ namespace Pulumi.DigitalOcean /// var replica_example = new DigitalOcean.DatabaseReplica("replica-example", new() /// { /// ClusterId = postgres_example.Id, + /// Name = "replica-example", /// Size = DigitalOcean.DatabaseSlug.DB_1VPCU1GB, /// Region = DigitalOcean.Region.NYC1, /// }); @@ -70,6 +74,7 @@ namespace Pulumi.DigitalOcean /// var user_example = new DigitalOcean.DatabaseUser("user-example", new() /// { /// ClusterId = replica_example.Uuid, + /// Name = "foobar", /// }); /// /// }); @@ -86,6 +91,7 @@ namespace Pulumi.DigitalOcean /// { /// var kafka_example = new DigitalOcean.DatabaseCluster("kafka-example", new() /// { + /// Name = "example-kafka-cluster", /// Engine = "kafka", /// Version = "3.5", /// Size = "db-s-2vcpu-2gb", @@ -93,14 +99,16 @@ namespace Pulumi.DigitalOcean /// NodeCount = 3, /// }); /// - /// var foobarTopic = new DigitalOcean.DatabaseKafkaTopic("foobarTopic", new() + /// var foobarTopic = new DigitalOcean.DatabaseKafkaTopic("foobar_topic", new() /// { - /// ClusterId = digitalocean_database_cluster.Foobar.Id, + /// ClusterId = foobar.Id, + /// Name = "topic-1", /// }); /// - /// var foobarUser = new DigitalOcean.DatabaseUser("foobarUser", new() + /// var foobarUser = new DigitalOcean.DatabaseUser("foobar_user", new() /// { - /// ClusterId = digitalocean_database_cluster.Foobar.Id, + /// ClusterId = foobar.Id, + /// Name = "example-user", /// Settings = new[] /// { /// new DigitalOcean.Inputs.DatabaseUserSettingArgs diff --git a/sdk/dotnet/DnsRecord.cs b/sdk/dotnet/DnsRecord.cs index 673e907b..9e1d7314 100644 --- a/sdk/dotnet/DnsRecord.cs +++ b/sdk/dotnet/DnsRecord.cs @@ -32,6 +32,7 @@ namespace Pulumi.DigitalOcean /// { /// Domain = @default.Id, /// Type = DigitalOcean.RecordType.A, + /// Name = "www", /// Value = "192.168.0.11", /// }); /// @@ -40,6 +41,7 @@ namespace Pulumi.DigitalOcean /// { /// Domain = @default.Id, /// Type = DigitalOcean.RecordType.MX, + /// Name = "@", /// Priority = 10, /// Value = "mail.example.com.", /// }); diff --git a/sdk/dotnet/Domain.cs b/sdk/dotnet/Domain.cs index dd4805ca..481bffe2 100644 --- a/sdk/dotnet/Domain.cs +++ b/sdk/dotnet/Domain.cs @@ -26,7 +26,7 @@ namespace Pulumi.DigitalOcean /// var @default = new DigitalOcean.Domain("default", new() /// { /// Name = "example.com", - /// IpAddress = digitalocean_droplet.Foo.Ipv4_address, + /// IpAddress = foo.Ipv4Address, /// }); /// /// }); diff --git a/sdk/dotnet/Droplet.cs b/sdk/dotnet/Droplet.cs index 6c2b531a..5027a059 100644 --- a/sdk/dotnet/Droplet.cs +++ b/sdk/dotnet/Droplet.cs @@ -27,6 +27,7 @@ namespace Pulumi.DigitalOcean /// var web = new DigitalOcean.Droplet("web", new() /// { /// Image = "ubuntu-20-04-x64", + /// Name = "web-1", /// Region = DigitalOcean.Region.NYC2, /// Size = DigitalOcean.DropletSlug.DropletS1VCPU1GB, /// }); diff --git a/sdk/dotnet/DropletSnapshot.cs b/sdk/dotnet/DropletSnapshot.cs index bf1a5bc8..4b66e69d 100644 --- a/sdk/dotnet/DropletSnapshot.cs +++ b/sdk/dotnet/DropletSnapshot.cs @@ -24,6 +24,7 @@ namespace Pulumi.DigitalOcean /// { /// var web = new DigitalOcean.Droplet("web", new() /// { + /// Name = "web-01", /// Size = DigitalOcean.DropletSlug.DropletS1VCPU1GB, /// Image = "ubuntu-22-04-x64", /// Region = DigitalOcean.Region.NYC3, @@ -32,11 +33,13 @@ namespace Pulumi.DigitalOcean /// var web_snapshot = new DigitalOcean.DropletSnapshot("web-snapshot", new() /// { /// DropletId = web.Id, + /// Name = "web-snapshot-01", /// }); /// /// var from_snapshot = new DigitalOcean.Droplet("from-snapshot", new() /// { /// Image = web_snapshot.Id, + /// Name = "web-02", /// Region = DigitalOcean.Region.NYC3, /// Size = DigitalOcean.DropletSlug.DropletS2VCPU4GB, /// }); diff --git a/sdk/dotnet/Firewall.cs b/sdk/dotnet/Firewall.cs index c1b6c5c6..ec0b3293 100644 --- a/sdk/dotnet/Firewall.cs +++ b/sdk/dotnet/Firewall.cs @@ -23,18 +23,20 @@ namespace Pulumi.DigitalOcean /// /// return await Deployment.RunAsync(() => /// { - /// var webDroplet = new DigitalOcean.Droplet("webDroplet", new() + /// var web = new DigitalOcean.Droplet("web", new() /// { + /// Name = "web-1", /// Size = DigitalOcean.DropletSlug.DropletS1VCPU1GB, /// Image = "ubuntu-18-04-x64", /// Region = DigitalOcean.Region.NYC3, /// }); /// - /// var webFirewall = new DigitalOcean.Firewall("webFirewall", new() + /// var webFirewall = new DigitalOcean.Firewall("web", new() /// { + /// Name = "only-22-80-and-443", /// DropletIds = new[] /// { - /// webDroplet.Id, + /// web.Id, /// }, /// InboundRules = new[] /// { diff --git a/sdk/dotnet/FloatingIp.cs b/sdk/dotnet/FloatingIp.cs index 8c1e4277..5faa4e59 100644 --- a/sdk/dotnet/FloatingIp.cs +++ b/sdk/dotnet/FloatingIp.cs @@ -26,8 +26,9 @@ namespace Pulumi.DigitalOcean /// /// return await Deployment.RunAsync(() => /// { - /// var foobarDroplet = new DigitalOcean.Droplet("foobarDroplet", new() + /// var foobar = new DigitalOcean.Droplet("foobar", new() /// { + /// Name = "baz", /// Size = DigitalOcean.DropletSlug.DropletS1VCPU1GB, /// Image = "ubuntu-18-04-x64", /// Region = DigitalOcean.Region.SGP1, @@ -35,10 +36,10 @@ namespace Pulumi.DigitalOcean /// PrivateNetworking = true, /// }); /// - /// var foobarFloatingIp = new DigitalOcean.FloatingIp("foobarFloatingIp", new() + /// var foobarFloatingIp = new DigitalOcean.FloatingIp("foobar", new() /// { - /// DropletId = foobarDroplet.Id, - /// Region = foobarDroplet.Region, + /// DropletId = foobar.Id, + /// Region = foobar.Region, /// }); /// /// }); diff --git a/sdk/dotnet/FloatingIpAssignment.cs b/sdk/dotnet/FloatingIpAssignment.cs index b781123b..71e4d4d6 100644 --- a/sdk/dotnet/FloatingIpAssignment.cs +++ b/sdk/dotnet/FloatingIpAssignment.cs @@ -26,13 +26,14 @@ namespace Pulumi.DigitalOcean /// /// return await Deployment.RunAsync(() => /// { - /// var foobarFloatingIp = new DigitalOcean.FloatingIp("foobarFloatingIp", new() + /// var foobar = new DigitalOcean.FloatingIp("foobar", new() /// { /// Region = "sgp1", /// }); /// - /// var foobarDroplet = new DigitalOcean.Droplet("foobarDroplet", new() + /// var foobarDroplet = new DigitalOcean.Droplet("foobar", new() /// { + /// Name = "baz", /// Size = DigitalOcean.DropletSlug.DropletS1VCPU1GB, /// Image = "ubuntu-18-04-x64", /// Region = DigitalOcean.Region.SGP1, @@ -40,9 +41,9 @@ namespace Pulumi.DigitalOcean /// PrivateNetworking = true, /// }); /// - /// var foobarFloatingIpAssignment = new DigitalOcean.FloatingIpAssignment("foobarFloatingIpAssignment", new() + /// var foobarFloatingIpAssignment = new DigitalOcean.FloatingIpAssignment("foobar", new() /// { - /// IpAddress = foobarFloatingIp.IpAddress, + /// IpAddress = foobar.IpAddress, /// DropletId = foobarDroplet.Id, /// }); /// diff --git a/sdk/dotnet/GetDomains.cs b/sdk/dotnet/GetDomains.cs index 817b11d5..a0d68418 100644 --- a/sdk/dotnet/GetDomains.cs +++ b/sdk/dotnet/GetDomains.cs @@ -41,11 +41,11 @@ public static class GetDomains /// new DigitalOcean.Inputs.GetDomainsFilterInputArgs /// { /// Key = "name", - /// MatchBy = "re", /// Values = new[] /// { /// "example\\.com$", /// }, + /// MatchBy = "re", /// }, /// }, /// }); @@ -86,11 +86,11 @@ public static Task InvokeAsync(GetDomainsArgs? args = null, In /// new DigitalOcean.Inputs.GetDomainsFilterInputArgs /// { /// Key = "name", - /// MatchBy = "re", /// Values = new[] /// { /// "example\\.com$", /// }, + /// MatchBy = "re", /// }, /// }, /// }); diff --git a/sdk/dotnet/GetDroplet.cs b/sdk/dotnet/GetDroplet.cs index 492341ec..0a81a776 100644 --- a/sdk/dotnet/GetDroplet.cs +++ b/sdk/dotnet/GetDroplet.cs @@ -74,7 +74,7 @@ public static class GetDroplet /// { /// var example = DigitalOcean.GetDroplet.Invoke(new() /// { - /// Id = digitalocean_kubernetes_cluster.Example.Node_pool[0].Nodes[0].Droplet_id, + /// Id = exampleDigitaloceanKubernetesCluster.NodePool[0].Nodes[0].DropletId, /// }); /// /// }); @@ -146,7 +146,7 @@ public static Task InvokeAsync(GetDropletArgs? args = null, In /// { /// var example = DigitalOcean.GetDroplet.Invoke(new() /// { - /// Id = digitalocean_kubernetes_cluster.Example.Node_pool[0].Nodes[0].Droplet_id, + /// Id = exampleDigitaloceanKubernetesCluster.NodePool[0].Nodes[0].DropletId, /// }); /// /// }); diff --git a/sdk/dotnet/GetDropletSnapshot.cs b/sdk/dotnet/GetDropletSnapshot.cs index 79efe726..de3a1875 100644 --- a/sdk/dotnet/GetDropletSnapshot.cs +++ b/sdk/dotnet/GetDropletSnapshot.cs @@ -30,9 +30,9 @@ public static class GetDropletSnapshot /// { /// var web_snapshot = DigitalOcean.GetDropletSnapshot.Invoke(new() /// { - /// MostRecent = true, /// NameRegex = "^web", /// Region = "nyc3", + /// MostRecent = true, /// }); /// /// }); @@ -58,6 +58,7 @@ public static class GetDropletSnapshot /// var from_snapshot = new DigitalOcean.Droplet("from-snapshot", new() /// { /// Image = web_snapshot.Apply(web_snapshot => web_snapshot.Apply(getDropletSnapshotResult => getDropletSnapshotResult.Id)), + /// Name = "web-02", /// Region = DigitalOcean.Region.NYC3, /// Size = DigitalOcean.DropletSlug.DropletS2VCPU4GB, /// }); @@ -87,9 +88,9 @@ public static Task InvokeAsync(GetDropletSnapshotArgs? /// { /// var web_snapshot = DigitalOcean.GetDropletSnapshot.Invoke(new() /// { - /// MostRecent = true, /// NameRegex = "^web", /// Region = "nyc3", + /// MostRecent = true, /// }); /// /// }); @@ -115,6 +116,7 @@ public static Task InvokeAsync(GetDropletSnapshotArgs? /// var from_snapshot = new DigitalOcean.Droplet("from-snapshot", new() /// { /// Image = web_snapshot.Apply(web_snapshot => web_snapshot.Apply(getDropletSnapshotResult => getDropletSnapshotResult.Id)), + /// Name = "web-02", /// Region = DigitalOcean.Region.NYC3, /// Size = DigitalOcean.DropletSlug.DropletS2VCPU4GB, /// }); diff --git a/sdk/dotnet/GetDroplets.cs b/sdk/dotnet/GetDroplets.cs index fd15fdcf..3e338adf 100644 --- a/sdk/dotnet/GetDroplets.cs +++ b/sdk/dotnet/GetDroplets.cs @@ -88,8 +88,8 @@ public static class GetDroplets /// { /// new DigitalOcean.Inputs.GetDropletsSortInputArgs /// { - /// Direction = "desc", /// Key = "created_at", + /// Direction = "desc", /// }, /// }, /// }); @@ -177,8 +177,8 @@ public static Task InvokeAsync(GetDropletsArgs? args = null, /// { /// new DigitalOcean.Inputs.GetDropletsSortInputArgs /// { - /// Direction = "desc", /// Key = "created_at", + /// Direction = "desc", /// }, /// }, /// }); diff --git a/sdk/dotnet/GetImage.cs b/sdk/dotnet/GetImage.cs index c258ea88..6d176249 100644 --- a/sdk/dotnet/GetImage.cs +++ b/sdk/dotnet/GetImage.cs @@ -49,14 +49,15 @@ public static class GetImage /// /// return await Deployment.RunAsync(() => /// { - /// var exampleImage = DigitalOcean.GetImage.Invoke(new() + /// var example = DigitalOcean.GetImage.Invoke(new() /// { /// Name = "example-1.0.0", /// }); /// - /// var exampleDroplet = new DigitalOcean.Droplet("exampleDroplet", new() + /// var exampleDroplet = new DigitalOcean.Droplet("example", new() /// { - /// Image = exampleImage.Apply(getImageResult => getImageResult.Id), + /// Image = example.Apply(getImageResult => getImageResult.Id), + /// Name = "example-1", /// Region = DigitalOcean.Region.NYC2, /// Size = DigitalOcean.DropletSlug.DropletS1VCPU1GB, /// }); @@ -123,14 +124,15 @@ public static Task InvokeAsync(GetImageArgs? args = null, Invoke /// /// return await Deployment.RunAsync(() => /// { - /// var exampleImage = DigitalOcean.GetImage.Invoke(new() + /// var example = DigitalOcean.GetImage.Invoke(new() /// { /// Name = "example-1.0.0", /// }); /// - /// var exampleDroplet = new DigitalOcean.Droplet("exampleDroplet", new() + /// var exampleDroplet = new DigitalOcean.Droplet("example", new() /// { - /// Image = exampleImage.Apply(getImageResult => getImageResult.Id), + /// Image = example.Apply(getImageResult => getImageResult.Id), + /// Name = "example-1", /// Region = DigitalOcean.Region.NYC2, /// Size = DigitalOcean.DropletSlug.DropletS1VCPU1GB, /// }); diff --git a/sdk/dotnet/GetImages.cs b/sdk/dotnet/GetImages.cs index f78f0a32..b09b4498 100644 --- a/sdk/dotnet/GetImages.cs +++ b/sdk/dotnet/GetImages.cs @@ -89,8 +89,8 @@ public static class GetImages /// { /// new DigitalOcean.Inputs.GetImagesSortInputArgs /// { - /// Direction = "desc", /// Key = "created", + /// Direction = "desc", /// }, /// }, /// }); @@ -179,8 +179,8 @@ public static Task InvokeAsync(GetImagesArgs? args = null, Invo /// { /// new DigitalOcean.Inputs.GetImagesSortInputArgs /// { - /// Direction = "desc", /// Key = "created", + /// Direction = "desc", /// }, /// }, /// }); diff --git a/sdk/dotnet/GetKubernetesCluster.cs b/sdk/dotnet/GetKubernetesCluster.cs index dd38d8cf..fbc449ca 100644 --- a/sdk/dotnet/GetKubernetesCluster.cs +++ b/sdk/dotnet/GetKubernetesCluster.cs @@ -13,12 +13,48 @@ public static class GetKubernetesCluster { /// /// Retrieves information about a DigitalOcean Kubernetes cluster for use in other resources. This data source provides all of the cluster's properties as configured on your DigitalOcean account. This is useful if the cluster in question is not managed by the provider. + /// + /// ## Example Usage + /// + /// ```csharp + /// using System.Collections.Generic; + /// using System.Linq; + /// using Pulumi; + /// using DigitalOcean = Pulumi.DigitalOcean; + /// + /// return await Deployment.RunAsync(() => + /// { + /// var example = DigitalOcean.GetKubernetesCluster.Invoke(new() + /// { + /// Name = "prod-cluster-01", + /// }); + /// + /// }); + /// ``` /// public static Task InvokeAsync(GetKubernetesClusterArgs args, InvokeOptions? options = null) => global::Pulumi.Deployment.Instance.InvokeAsync("digitalocean:index/getKubernetesCluster:getKubernetesCluster", args ?? new GetKubernetesClusterArgs(), options.WithDefaults()); /// /// Retrieves information about a DigitalOcean Kubernetes cluster for use in other resources. This data source provides all of the cluster's properties as configured on your DigitalOcean account. This is useful if the cluster in question is not managed by the provider. + /// + /// ## Example Usage + /// + /// ```csharp + /// using System.Collections.Generic; + /// using System.Linq; + /// using Pulumi; + /// using DigitalOcean = Pulumi.DigitalOcean; + /// + /// return await Deployment.RunAsync(() => + /// { + /// var example = DigitalOcean.GetKubernetesCluster.Invoke(new() + /// { + /// Name = "prod-cluster-01", + /// }); + /// + /// }); + /// ``` /// public static Output Invoke(GetKubernetesClusterInvokeArgs args, InvokeOptions? options = null) => global::Pulumi.Deployment.Instance.Invoke("digitalocean:index/getKubernetesCluster:getKubernetesCluster", args ?? new GetKubernetesClusterInvokeArgs(), options.WithDefaults()); diff --git a/sdk/dotnet/GetKubernetesVersions.cs b/sdk/dotnet/GetKubernetesVersions.cs index 05fad607..e22a3044 100644 --- a/sdk/dotnet/GetKubernetesVersions.cs +++ b/sdk/dotnet/GetKubernetesVersions.cs @@ -49,6 +49,7 @@ public static class GetKubernetesVersions /// /// var example_cluster = new DigitalOcean.KubernetesCluster("example-cluster", new() /// { + /// Name = "example-cluster", /// Region = DigitalOcean.Region.LON1, /// Version = example.Apply(getKubernetesVersionsResult => getKubernetesVersionsResult.LatestVersion), /// NodePool = new DigitalOcean.Inputs.KubernetesClusterNodePoolArgs @@ -79,6 +80,7 @@ public static class GetKubernetesVersions /// /// var example_cluster = new DigitalOcean.KubernetesCluster("example-cluster", new() /// { + /// Name = "example-cluster", /// Region = DigitalOcean.Region.LON1, /// Version = example.Apply(getKubernetesVersionsResult => getKubernetesVersionsResult.LatestVersion), /// NodePool = new DigitalOcean.Inputs.KubernetesClusterNodePoolArgs @@ -133,6 +135,7 @@ public static Task InvokeAsync(GetKubernetesVersion /// /// var example_cluster = new DigitalOcean.KubernetesCluster("example-cluster", new() /// { + /// Name = "example-cluster", /// Region = DigitalOcean.Region.LON1, /// Version = example.Apply(getKubernetesVersionsResult => getKubernetesVersionsResult.LatestVersion), /// NodePool = new DigitalOcean.Inputs.KubernetesClusterNodePoolArgs @@ -163,6 +166,7 @@ public static Task InvokeAsync(GetKubernetesVersion /// /// var example_cluster = new DigitalOcean.KubernetesCluster("example-cluster", new() /// { + /// Name = "example-cluster", /// Region = DigitalOcean.Region.LON1, /// Version = example.Apply(getKubernetesVersionsResult => getKubernetesVersionsResult.LatestVersion), /// NodePool = new DigitalOcean.Inputs.KubernetesClusterNodePoolArgs diff --git a/sdk/dotnet/GetProjects.cs b/sdk/dotnet/GetProjects.cs index 3b5529bd..1f0fee4a 100644 --- a/sdk/dotnet/GetProjects.cs +++ b/sdk/dotnet/GetProjects.cs @@ -87,8 +87,8 @@ public static class GetProjects /// { /// new DigitalOcean.Inputs.GetProjectsSortInputArgs /// { - /// Direction = "asc", /// Key = "name", + /// Direction = "asc", /// }, /// }, /// }); @@ -175,8 +175,8 @@ public static Task InvokeAsync(GetProjectsArgs? args = null, /// { /// new DigitalOcean.Inputs.GetProjectsSortInputArgs /// { - /// Direction = "asc", /// Key = "name", + /// Direction = "asc", /// }, /// }, /// }); diff --git a/sdk/dotnet/GetRecords.cs b/sdk/dotnet/GetRecords.cs index 46395922..781bdfff 100644 --- a/sdk/dotnet/GetRecords.cs +++ b/sdk/dotnet/GetRecords.cs @@ -14,6 +14,46 @@ public static class GetRecords /// /// Retrieve information about all DNS records within a domain, with the ability to filter and sort the results. /// If no filters are specified, all records will be returned. + /// + /// ## Example Usage + /// + /// Get data for all MX records in a domain: + /// + /// ```csharp + /// using System.Collections.Generic; + /// using System.Linq; + /// using Pulumi; + /// using DigitalOcean = Pulumi.DigitalOcean; + /// using Std = Pulumi.Std; + /// + /// return await Deployment.RunAsync(() => + /// { + /// var example = DigitalOcean.GetRecords.Invoke(new() + /// { + /// Domain = "example.com", + /// Filters = new[] + /// { + /// new DigitalOcean.Inputs.GetRecordsFilterInputArgs + /// { + /// Key = "type", + /// Values = new[] + /// { + /// "MX", + /// }, + /// }, + /// }, + /// }); + /// + /// return new Dictionary<string, object?> + /// { + /// ["mailServers"] = Std.Join.Invoke(new() + /// { + /// Separator = ",", + /// Input = example.Apply(getRecordsResult => getRecordsResult.Records).Select(__item => __item.Value).ToList(), + /// }).Apply(invoke => invoke.Result), + /// }; + /// }); + /// ``` /// public static Task InvokeAsync(GetRecordsArgs args, InvokeOptions? options = null) => global::Pulumi.Deployment.Instance.InvokeAsync("digitalocean:index/getRecords:getRecords", args ?? new GetRecordsArgs(), options.WithDefaults()); @@ -21,6 +61,46 @@ public static Task InvokeAsync(GetRecordsArgs args, InvokeOpti /// /// Retrieve information about all DNS records within a domain, with the ability to filter and sort the results. /// If no filters are specified, all records will be returned. + /// + /// ## Example Usage + /// + /// Get data for all MX records in a domain: + /// + /// ```csharp + /// using System.Collections.Generic; + /// using System.Linq; + /// using Pulumi; + /// using DigitalOcean = Pulumi.DigitalOcean; + /// using Std = Pulumi.Std; + /// + /// return await Deployment.RunAsync(() => + /// { + /// var example = DigitalOcean.GetRecords.Invoke(new() + /// { + /// Domain = "example.com", + /// Filters = new[] + /// { + /// new DigitalOcean.Inputs.GetRecordsFilterInputArgs + /// { + /// Key = "type", + /// Values = new[] + /// { + /// "MX", + /// }, + /// }, + /// }, + /// }); + /// + /// return new Dictionary<string, object?> + /// { + /// ["mailServers"] = Std.Join.Invoke(new() + /// { + /// Separator = ",", + /// Input = example.Apply(getRecordsResult => getRecordsResult.Records).Select(__item => __item.Value).ToList(), + /// }).Apply(invoke => invoke.Result), + /// }; + /// }); + /// ``` /// public static Output Invoke(GetRecordsInvokeArgs args, InvokeOptions? options = null) => global::Pulumi.Deployment.Instance.Invoke("digitalocean:index/getRecords:getRecords", args ?? new GetRecordsInvokeArgs(), options.WithDefaults()); diff --git a/sdk/dotnet/GetRegions.cs b/sdk/dotnet/GetRegions.cs index 42e90292..118f9556 100644 --- a/sdk/dotnet/GetRegions.cs +++ b/sdk/dotnet/GetRegions.cs @@ -85,8 +85,8 @@ public static class GetRegions /// { /// new DigitalOcean.Inputs.GetRegionsSortInputArgs /// { - /// Direction = "desc", /// Key = "name", + /// Direction = "desc", /// }, /// }, /// }); @@ -171,8 +171,8 @@ public static Task InvokeAsync(GetRegionsArgs? args = null, In /// { /// new DigitalOcean.Inputs.GetRegionsSortInputArgs /// { - /// Direction = "desc", /// Key = "name", + /// Direction = "desc", /// }, /// }, /// }); diff --git a/sdk/dotnet/GetSpacesBucketObject.cs b/sdk/dotnet/GetSpacesBucketObject.cs index d4863ee0..f973d675 100644 --- a/sdk/dotnet/GetSpacesBucketObject.cs +++ b/sdk/dotnet/GetSpacesBucketObject.cs @@ -42,6 +42,7 @@ public static class GetSpacesBucketObject /// var web = new DigitalOcean.Droplet("web", new() /// { /// Image = "ubuntu-18-04-x64", + /// Name = "web-1", /// Region = DigitalOcean.Region.NYC2, /// Size = DigitalOcean.DropletSlug.DropletS1VCPU1GB, /// UserData = bootstrapScript.Apply(getSpacesBucketObjectResult => getSpacesBucketObjectResult.Body), @@ -84,6 +85,7 @@ public static Task InvokeAsync(GetSpacesBucketObjec /// var web = new DigitalOcean.Droplet("web", new() /// { /// Image = "ubuntu-18-04-x64", + /// Name = "web-1", /// Region = DigitalOcean.Region.NYC2, /// Size = DigitalOcean.DropletSlug.DropletS1VCPU1GB, /// UserData = bootstrapScript.Apply(getSpacesBucketObjectResult => getSpacesBucketObjectResult.Body), diff --git a/sdk/dotnet/GetSpacesBuckets.cs b/sdk/dotnet/GetSpacesBuckets.cs index 0ce63413..ee7e0091 100644 --- a/sdk/dotnet/GetSpacesBuckets.cs +++ b/sdk/dotnet/GetSpacesBuckets.cs @@ -76,8 +76,8 @@ public static class GetSpacesBuckets /// { /// new DigitalOcean.Inputs.GetSpacesBucketsSortInputArgs /// { - /// Direction = "desc", /// Key = "name", + /// Direction = "desc", /// }, /// }, /// }); @@ -153,8 +153,8 @@ public static Task InvokeAsync(GetSpacesBucketsArgs? arg /// { /// new DigitalOcean.Inputs.GetSpacesBucketsSortInputArgs /// { - /// Direction = "desc", /// Key = "name", + /// Direction = "desc", /// }, /// }, /// }); diff --git a/sdk/dotnet/GetSshKey.cs b/sdk/dotnet/GetSshKey.cs index 70fa2292..2390b13e 100644 --- a/sdk/dotnet/GetSshKey.cs +++ b/sdk/dotnet/GetSshKey.cs @@ -31,19 +31,20 @@ public static class GetSshKey /// /// return await Deployment.RunAsync(() => /// { - /// var exampleSshKey = DigitalOcean.GetSshKey.Invoke(new() + /// var example = DigitalOcean.GetSshKey.Invoke(new() /// { /// Name = "example", /// }); /// - /// var exampleDroplet = new DigitalOcean.Droplet("exampleDroplet", new() + /// var exampleDroplet = new DigitalOcean.Droplet("example", new() /// { /// Image = "ubuntu-18-04-x64", + /// Name = "example-1", /// Region = DigitalOcean.Region.NYC2, /// Size = DigitalOcean.DropletSlug.DropletS1VCPU1GB, /// SshKeys = new[] /// { - /// exampleSshKey.Apply(getSshKeyResult => getSshKeyResult.Id), + /// example.Apply(getSshKeyResult => getSshKeyResult.Id), /// }, /// }); /// @@ -73,19 +74,20 @@ public static Task InvokeAsync(GetSshKeyArgs args, InvokeOption /// /// return await Deployment.RunAsync(() => /// { - /// var exampleSshKey = DigitalOcean.GetSshKey.Invoke(new() + /// var example = DigitalOcean.GetSshKey.Invoke(new() /// { /// Name = "example", /// }); /// - /// var exampleDroplet = new DigitalOcean.Droplet("exampleDroplet", new() + /// var exampleDroplet = new DigitalOcean.Droplet("example", new() /// { /// Image = "ubuntu-18-04-x64", + /// Name = "example-1", /// Region = DigitalOcean.Region.NYC2, /// Size = DigitalOcean.DropletSlug.DropletS1VCPU1GB, /// SshKeys = new[] /// { - /// exampleSshKey.Apply(getSshKeyResult => getSshKeyResult.Id), + /// example.Apply(getSshKeyResult => getSshKeyResult.Id), /// }, /// }); /// diff --git a/sdk/dotnet/GetSshKeys.cs b/sdk/dotnet/GetSshKeys.cs index 4b49fe63..3f5c7ba3 100644 --- a/sdk/dotnet/GetSshKeys.cs +++ b/sdk/dotnet/GetSshKeys.cs @@ -38,8 +38,8 @@ public static class GetSshKeys /// { /// new DigitalOcean.Inputs.GetSshKeysSortInputArgs /// { - /// Direction = "asc", /// Key = "name", + /// Direction = "asc", /// }, /// }, /// }); @@ -106,8 +106,8 @@ public static Task InvokeAsync(GetSshKeysArgs? args = null, In /// { /// new DigitalOcean.Inputs.GetSshKeysSortInputArgs /// { - /// Direction = "asc", /// Key = "name", + /// Direction = "asc", /// }, /// }, /// }); diff --git a/sdk/dotnet/GetTag.cs b/sdk/dotnet/GetTag.cs index 0c062b70..7eda3439 100644 --- a/sdk/dotnet/GetTag.cs +++ b/sdk/dotnet/GetTag.cs @@ -30,19 +30,20 @@ public static class GetTag /// /// return await Deployment.RunAsync(() => /// { - /// var exampleTag = DigitalOcean.GetTag.Invoke(new() + /// var example = DigitalOcean.GetTag.Invoke(new() /// { /// Name = "example", /// }); /// - /// var exampleDroplet = new DigitalOcean.Droplet("exampleDroplet", new() + /// var exampleDroplet = new DigitalOcean.Droplet("example", new() /// { /// Image = "ubuntu-18-04-x64", + /// Name = "example-1", /// Region = DigitalOcean.Region.NYC2, /// Size = DigitalOcean.DropletSlug.DropletS1VCPU1GB, /// Tags = new[] /// { - /// exampleTag.Apply(getTagResult => getTagResult.Name), + /// example.Apply(getTagResult => getTagResult.Name), /// }, /// }); /// @@ -71,19 +72,20 @@ public static Task InvokeAsync(GetTagArgs args, InvokeOptions? opt /// /// return await Deployment.RunAsync(() => /// { - /// var exampleTag = DigitalOcean.GetTag.Invoke(new() + /// var example = DigitalOcean.GetTag.Invoke(new() /// { /// Name = "example", /// }); /// - /// var exampleDroplet = new DigitalOcean.Droplet("exampleDroplet", new() + /// var exampleDroplet = new DigitalOcean.Droplet("example", new() /// { /// Image = "ubuntu-18-04-x64", + /// Name = "example-1", /// Region = DigitalOcean.Region.NYC2, /// Size = DigitalOcean.DropletSlug.DropletS1VCPU1GB, /// Tags = new[] /// { - /// exampleTag.Apply(getTagResult => getTagResult.Name), + /// example.Apply(getTagResult => getTagResult.Name), /// }, /// }); /// diff --git a/sdk/dotnet/GetVolume.cs b/sdk/dotnet/GetVolume.cs index c7df92f8..8f6a7cca 100644 --- a/sdk/dotnet/GetVolume.cs +++ b/sdk/dotnet/GetVolume.cs @@ -50,14 +50,15 @@ public static class GetVolume /// /// return await Deployment.RunAsync(() => /// { - /// var exampleVolume = DigitalOcean.GetVolume.Invoke(new() + /// var example = DigitalOcean.GetVolume.Invoke(new() /// { /// Name = "app-data", /// Region = "nyc3", /// }); /// - /// var exampleDroplet = new DigitalOcean.Droplet("exampleDroplet", new() + /// var exampleDroplet = new DigitalOcean.Droplet("example", new() /// { + /// Name = "foo", /// Size = DigitalOcean.DropletSlug.DropletS1VCPU1GB, /// Image = "ubuntu-18-04-x64", /// Region = DigitalOcean.Region.NYC3, @@ -66,7 +67,7 @@ public static class GetVolume /// var foobar = new DigitalOcean.VolumeAttachment("foobar", new() /// { /// DropletId = exampleDroplet.Id, - /// VolumeId = exampleVolume.Apply(getVolumeResult => getVolumeResult.Id), + /// VolumeId = example.Apply(getVolumeResult => getVolumeResult.Id), /// }); /// /// }); @@ -114,14 +115,15 @@ public static Task InvokeAsync(GetVolumeArgs args, InvokeOption /// /// return await Deployment.RunAsync(() => /// { - /// var exampleVolume = DigitalOcean.GetVolume.Invoke(new() + /// var example = DigitalOcean.GetVolume.Invoke(new() /// { /// Name = "app-data", /// Region = "nyc3", /// }); /// - /// var exampleDroplet = new DigitalOcean.Droplet("exampleDroplet", new() + /// var exampleDroplet = new DigitalOcean.Droplet("example", new() /// { + /// Name = "foo", /// Size = DigitalOcean.DropletSlug.DropletS1VCPU1GB, /// Image = "ubuntu-18-04-x64", /// Region = DigitalOcean.Region.NYC3, @@ -130,7 +132,7 @@ public static Task InvokeAsync(GetVolumeArgs args, InvokeOption /// var foobar = new DigitalOcean.VolumeAttachment("foobar", new() /// { /// DropletId = exampleDroplet.Id, - /// VolumeId = exampleVolume.Apply(getVolumeResult => getVolumeResult.Id), + /// VolumeId = example.Apply(getVolumeResult => getVolumeResult.Id), /// }); /// /// }); diff --git a/sdk/dotnet/GetVolumeSnapshot.cs b/sdk/dotnet/GetVolumeSnapshot.cs index 2c54da46..6bc8e63c 100644 --- a/sdk/dotnet/GetVolumeSnapshot.cs +++ b/sdk/dotnet/GetVolumeSnapshot.cs @@ -30,9 +30,9 @@ public static class GetVolumeSnapshot /// { /// var snapshot = DigitalOcean.GetVolumeSnapshot.Invoke(new() /// { - /// MostRecent = true, /// NameRegex = "^web", /// Region = "nyc3", + /// MostRecent = true, /// }); /// /// }); @@ -58,6 +58,7 @@ public static class GetVolumeSnapshot /// var foobar = new DigitalOcean.Volume("foobar", new() /// { /// Region = DigitalOcean.Region.NYC3, + /// Name = "baz", /// Size = 100, /// SnapshotId = snapshot.Apply(getVolumeSnapshotResult => getVolumeSnapshotResult.Id), /// }); @@ -87,9 +88,9 @@ public static Task InvokeAsync(GetVolumeSnapshotArgs? a /// { /// var snapshot = DigitalOcean.GetVolumeSnapshot.Invoke(new() /// { - /// MostRecent = true, /// NameRegex = "^web", /// Region = "nyc3", + /// MostRecent = true, /// }); /// /// }); @@ -115,6 +116,7 @@ public static Task InvokeAsync(GetVolumeSnapshotArgs? a /// var foobar = new DigitalOcean.Volume("foobar", new() /// { /// Region = DigitalOcean.Region.NYC3, + /// Name = "baz", /// Size = 100, /// SnapshotId = snapshot.Apply(getVolumeSnapshotResult => getVolumeSnapshotResult.Id), /// }); diff --git a/sdk/dotnet/GetVpc.cs b/sdk/dotnet/GetVpc.cs index 3346b48f..52ef9147 100644 --- a/sdk/dotnet/GetVpc.cs +++ b/sdk/dotnet/GetVpc.cs @@ -51,17 +51,18 @@ public static class GetVpc /// /// return await Deployment.RunAsync(() => /// { - /// var exampleVpc = DigitalOcean.GetVpc.Invoke(new() + /// var example = DigitalOcean.GetVpc.Invoke(new() /// { /// Name = "example-network", /// }); /// - /// var exampleDroplet = new DigitalOcean.Droplet("exampleDroplet", new() + /// var exampleDroplet = new DigitalOcean.Droplet("example", new() /// { + /// Name = "example-01", /// Size = DigitalOcean.DropletSlug.DropletS1VCPU1GB, /// Image = "ubuntu-18-04-x64", /// Region = DigitalOcean.Region.NYC3, - /// VpcUuid = exampleVpc.Apply(getVpcResult => getVpcResult.Id), + /// VpcUuid = example.Apply(getVpcResult => getVpcResult.Id), /// }); /// /// }); @@ -110,17 +111,18 @@ public static Task InvokeAsync(GetVpcArgs? args = null, InvokeOpti /// /// return await Deployment.RunAsync(() => /// { - /// var exampleVpc = DigitalOcean.GetVpc.Invoke(new() + /// var example = DigitalOcean.GetVpc.Invoke(new() /// { /// Name = "example-network", /// }); /// - /// var exampleDroplet = new DigitalOcean.Droplet("exampleDroplet", new() + /// var exampleDroplet = new DigitalOcean.Droplet("example", new() /// { + /// Name = "example-01", /// Size = DigitalOcean.DropletSlug.DropletS1VCPU1GB, /// Image = "ubuntu-18-04-x64", /// Region = DigitalOcean.Region.NYC3, - /// VpcUuid = exampleVpc.Apply(getVpcResult => getVpcResult.Id), + /// VpcUuid = example.Apply(getVpcResult => getVpcResult.Id), /// }); /// /// }); diff --git a/sdk/dotnet/KubernetesNodePool.cs b/sdk/dotnet/KubernetesNodePool.cs index 72460a8b..a4eeff0b 100644 --- a/sdk/dotnet/KubernetesNodePool.cs +++ b/sdk/dotnet/KubernetesNodePool.cs @@ -26,6 +26,7 @@ namespace Pulumi.DigitalOcean /// { /// var foo = new DigitalOcean.KubernetesCluster("foo", new() /// { + /// Name = "foo", /// Region = DigitalOcean.Region.NYC1, /// Version = "1.22.8-do.1", /// NodePool = new DigitalOcean.Inputs.KubernetesClusterNodePoolArgs @@ -39,6 +40,7 @@ namespace Pulumi.DigitalOcean /// var bar = new DigitalOcean.KubernetesNodePool("bar", new() /// { /// ClusterId = foo.Id, + /// Name = "backend-pool", /// Size = DigitalOcean.DropletSlug.DropletC2, /// NodeCount = 2, /// Tags = new[] @@ -79,7 +81,8 @@ namespace Pulumi.DigitalOcean /// { /// var autoscale_pool_01 = new DigitalOcean.KubernetesNodePool("autoscale-pool-01", new() /// { - /// ClusterId = digitalocean_kubernetes_cluster.Foo.Id, + /// ClusterId = foo.Id, + /// Name = "autoscale-pool-01", /// Size = DigitalOcean.DropletSlug.DropletS1VCPU2GB, /// AutoScale = true, /// MinNodes = 1, diff --git a/sdk/dotnet/LoadBalancer.cs b/sdk/dotnet/LoadBalancer.cs index a65c9824..b88373c7 100644 --- a/sdk/dotnet/LoadBalancer.cs +++ b/sdk/dotnet/LoadBalancer.cs @@ -25,6 +25,7 @@ namespace Pulumi.DigitalOcean /// { /// var web = new DigitalOcean.Droplet("web", new() /// { + /// Name = "web-1", /// Size = DigitalOcean.DropletSlug.DropletS1VCPU1GB, /// Image = "ubuntu-18-04-x64", /// Region = DigitalOcean.Region.NYC3, @@ -32,6 +33,7 @@ namespace Pulumi.DigitalOcean /// /// var @public = new DigitalOcean.LoadBalancer("public", new() /// { + /// Name = "loadbalancer-1", /// Region = DigitalOcean.Region.NYC3, /// ForwardingRules = new[] /// { @@ -63,55 +65,6 @@ namespace Pulumi.DigitalOcean /// `Delete old certificate`. When doing so, you must also change the name of the certificate, /// as there cannot be multiple certificates with the same name in an account. /// - /// ```csharp - /// using System.Collections.Generic; - /// using System.Linq; - /// using Pulumi; - /// using DigitalOcean = Pulumi.DigitalOcean; - /// - /// return await Deployment.RunAsync(() => - /// { - /// var cert = new DigitalOcean.Certificate("cert", new() - /// { - /// PrivateKey = "file('key.pem')", - /// LeafCertificate = "file('cert.pem')", - /// }); - /// - /// var web = new DigitalOcean.Droplet("web", new() - /// { - /// Size = DigitalOcean.DropletSlug.DropletS1VCPU1GB, - /// Image = "ubuntu-18-04-x64", - /// Region = DigitalOcean.Region.NYC3, - /// }); - /// - /// var @public = new DigitalOcean.LoadBalancer("public", new() - /// { - /// Region = DigitalOcean.Region.NYC3, - /// ForwardingRules = new[] - /// { - /// new DigitalOcean.Inputs.LoadBalancerForwardingRuleArgs - /// { - /// EntryPort = 443, - /// EntryProtocol = "https", - /// TargetPort = 80, - /// TargetProtocol = "http", - /// CertificateName = cert.Name, - /// }, - /// }, - /// Healthcheck = new DigitalOcean.Inputs.LoadBalancerHealthcheckArgs - /// { - /// Port = 22, - /// Protocol = "tcp", - /// }, - /// DropletIds = new[] - /// { - /// web.Id, - /// }, - /// }); - /// - /// }); - /// ``` - /// /// ## Import /// /// Load Balancers can be imported using the `id`, e.g. diff --git a/sdk/dotnet/Project.cs b/sdk/dotnet/Project.cs index bfbce1ad..006db9c4 100644 --- a/sdk/dotnet/Project.cs +++ b/sdk/dotnet/Project.cs @@ -44,9 +44,10 @@ namespace Pulumi.DigitalOcean /// { /// var playground = new DigitalOcean.Project("playground", new() /// { + /// Name = "playground", /// Description = "A project to represent development resources.", - /// Environment = "Development", /// Purpose = "Web Application", + /// Environment = "Development", /// }); /// /// }); @@ -64,6 +65,7 @@ namespace Pulumi.DigitalOcean /// { /// var foobar = new DigitalOcean.Droplet("foobar", new() /// { + /// Name = "example", /// Size = DigitalOcean.DropletSlug.DropletS1VCPU1GB, /// Image = "ubuntu-22-04-x64", /// Region = DigitalOcean.Region.NYC3, @@ -71,6 +73,7 @@ namespace Pulumi.DigitalOcean /// /// var playground = new DigitalOcean.Project("playground", new() /// { + /// Name = "playground", /// Description = "A project to represent development resources.", /// Purpose = "Web Application", /// Environment = "Development", diff --git a/sdk/dotnet/ProjectResources.cs b/sdk/dotnet/ProjectResources.cs index a6846856..e67ad504 100644 --- a/sdk/dotnet/ProjectResources.cs +++ b/sdk/dotnet/ProjectResources.cs @@ -44,6 +44,7 @@ namespace Pulumi.DigitalOcean /// /// var foobar = new DigitalOcean.Droplet("foobar", new() /// { + /// Name = "example", /// Size = DigitalOcean.DropletSlug.DropletS1VCPU1GB, /// Image = "ubuntu-22-04-x64", /// Region = DigitalOcean.Region.NYC3, diff --git a/sdk/dotnet/ReservedIp.cs b/sdk/dotnet/ReservedIp.cs index aefe2e34..759c4333 100644 --- a/sdk/dotnet/ReservedIp.cs +++ b/sdk/dotnet/ReservedIp.cs @@ -24,8 +24,9 @@ namespace Pulumi.DigitalOcean /// /// return await Deployment.RunAsync(() => /// { - /// var exampleDroplet = new DigitalOcean.Droplet("exampleDroplet", new() + /// var example = new DigitalOcean.Droplet("example", new() /// { + /// Name = "example", /// Size = DigitalOcean.DropletSlug.DropletS1VCPU1GB, /// Image = "ubuntu-22-04-x64", /// Region = DigitalOcean.Region.NYC3, @@ -33,10 +34,10 @@ namespace Pulumi.DigitalOcean /// PrivateNetworking = true, /// }); /// - /// var exampleReservedIp = new DigitalOcean.ReservedIp("exampleReservedIp", new() + /// var exampleReservedIp = new DigitalOcean.ReservedIp("example", new() /// { - /// DropletId = exampleDroplet.Id, - /// Region = exampleDroplet.Region, + /// DropletId = example.Id, + /// Region = example.Region, /// }); /// /// }); diff --git a/sdk/dotnet/ReservedIpAssignment.cs b/sdk/dotnet/ReservedIpAssignment.cs index 628ef588..e62392f2 100644 --- a/sdk/dotnet/ReservedIpAssignment.cs +++ b/sdk/dotnet/ReservedIpAssignment.cs @@ -24,13 +24,14 @@ namespace Pulumi.DigitalOcean /// /// return await Deployment.RunAsync(() => /// { - /// var exampleReservedIp = new DigitalOcean.ReservedIp("exampleReservedIp", new() + /// var example = new DigitalOcean.ReservedIp("example", new() /// { /// Region = "nyc3", /// }); /// - /// var exampleDroplet = new DigitalOcean.Droplet("exampleDroplet", new() + /// var exampleDroplet = new DigitalOcean.Droplet("example", new() /// { + /// Name = "baz", /// Size = DigitalOcean.DropletSlug.DropletS1VCPU1GB, /// Image = "ubuntu-22-04-x64", /// Region = DigitalOcean.Region.NYC3, @@ -38,9 +39,9 @@ namespace Pulumi.DigitalOcean /// PrivateNetworking = true, /// }); /// - /// var exampleReservedIpAssignment = new DigitalOcean.ReservedIpAssignment("exampleReservedIpAssignment", new() + /// var exampleReservedIpAssignment = new DigitalOcean.ReservedIpAssignment("example", new() /// { - /// IpAddress = exampleReservedIp.IpAddress, + /// IpAddress = example.IpAddress, /// DropletId = exampleDroplet.Id, /// }); /// diff --git a/sdk/dotnet/SpacesBucket.cs b/sdk/dotnet/SpacesBucket.cs index 9618f8b0..6b36eaa3 100644 --- a/sdk/dotnet/SpacesBucket.cs +++ b/sdk/dotnet/SpacesBucket.cs @@ -34,7 +34,6 @@ namespace Pulumi.DigitalOcean /// { /// var static_assets = new DigitalOcean.SpacesBucket("static-assets"); /// - /// // ... /// }); /// ``` /// @@ -54,6 +53,7 @@ namespace Pulumi.DigitalOcean /// { /// var foobar = new DigitalOcean.SpacesBucket("foobar", new() /// { + /// Name = "foobar", /// Region = DigitalOcean.Region.NYC3, /// }); /// @@ -72,6 +72,8 @@ namespace Pulumi.DigitalOcean /// { /// var foobar = new DigitalOcean.SpacesBucket("foobar", new() /// { + /// Name = "foobar", + /// Region = DigitalOcean.Region.NYC3, /// CorsRules = new[] /// { /// new DigitalOcean.Inputs.SpacesBucketCorsRuleArgs @@ -109,7 +111,6 @@ namespace Pulumi.DigitalOcean /// MaxAgeSeconds = 3000, /// }, /// }, - /// Region = DigitalOcean.Region.NYC3, /// }); /// /// }); diff --git a/sdk/dotnet/SpacesBucketCorsConfiguration.cs b/sdk/dotnet/SpacesBucketCorsConfiguration.cs index 50323aa8..5d82e29f 100644 --- a/sdk/dotnet/SpacesBucketCorsConfiguration.cs +++ b/sdk/dotnet/SpacesBucketCorsConfiguration.cs @@ -24,6 +24,7 @@ namespace Pulumi.DigitalOcean /// { /// var foobar = new DigitalOcean.SpacesBucket("foobar", new() /// { + /// Name = "foobar", /// Region = DigitalOcean.Region.NYC3, /// }); /// diff --git a/sdk/dotnet/SpacesBucketObject.cs b/sdk/dotnet/SpacesBucketObject.cs index 879101f8..bf996d9c 100644 --- a/sdk/dotnet/SpacesBucketObject.cs +++ b/sdk/dotnet/SpacesBucketObject.cs @@ -36,7 +36,6 @@ namespace Pulumi.DigitalOcean /// { /// var static_assets = new DigitalOcean.SpacesBucket("static-assets"); /// - /// // ... /// }); /// ``` /// @@ -56,6 +55,7 @@ namespace Pulumi.DigitalOcean /// { /// var foobar = new DigitalOcean.SpacesBucket("foobar", new() /// { + /// Name = "foobar", /// Region = DigitalOcean.Region.NYC3, /// }); /// diff --git a/sdk/dotnet/SpacesBucketPolicy.cs b/sdk/dotnet/SpacesBucketPolicy.cs index 1d02d2ca..4bbec8e3 100644 --- a/sdk/dotnet/SpacesBucketPolicy.cs +++ b/sdk/dotnet/SpacesBucketPolicy.cs @@ -23,15 +23,16 @@ namespace Pulumi.DigitalOcean /// /// return await Deployment.RunAsync(() => /// { - /// var foobarSpacesBucket = new DigitalOcean.SpacesBucket("foobarSpacesBucket", new() + /// var foobar = new DigitalOcean.SpacesBucket("foobar", new() /// { + /// Name = "foobar", /// Region = DigitalOcean.Region.NYC3, /// }); /// - /// var foobarSpacesBucketPolicy = new DigitalOcean.SpacesBucketPolicy("foobarSpacesBucketPolicy", new() + /// var foobarSpacesBucketPolicy = new DigitalOcean.SpacesBucketPolicy("foobar", new() /// { - /// Region = foobarSpacesBucket.Region, - /// Bucket = foobarSpacesBucket.Name, + /// Region = foobar.Region, + /// Bucket = foobar.Name, /// Policy = Output.JsonSerialize(Output.Create(new Dictionary<string, object?> /// { /// ["Version"] = "2012-10-17", @@ -45,8 +46,8 @@ namespace Pulumi.DigitalOcean /// ["Action"] = "s3:*", /// ["Resource"] = new[] /// { - /// foobarSpacesBucket.Name.Apply(name => $"arn:aws:s3:::{name}"), - /// foobarSpacesBucket.Name.Apply(name => $"arn:aws:s3:::{name}/*"), + /// foobar.Name.Apply(name => $"arn:aws:s3:::{name}"), + /// foobar.Name.Apply(name => $"arn:aws:s3:::{name}/*"), /// }, /// ["Condition"] = new Dictionary<string, object?> /// { diff --git a/sdk/dotnet/SshKey.cs b/sdk/dotnet/SshKey.cs index 2473ddd6..51faf7a7 100644 --- a/sdk/dotnet/SshKey.cs +++ b/sdk/dotnet/SshKey.cs @@ -19,23 +19,28 @@ namespace Pulumi.DigitalOcean /// /// ```csharp /// using System.Collections.Generic; - /// using System.IO; /// using System.Linq; /// using Pulumi; /// using DigitalOcean = Pulumi.DigitalOcean; + /// using Std = Pulumi.Std; /// /// return await Deployment.RunAsync(() => /// { /// // Create a new SSH key /// var @default = new DigitalOcean.SshKey("default", new() /// { - /// PublicKey = File.ReadAllText("/Users/myuser/.ssh/id_rsa.pub"), + /// Name = "Example", + /// PublicKey = Std.File.Invoke(new() + /// { + /// Input = "/Users/myuser/.ssh/id_rsa.pub", + /// }).Apply(invoke => invoke.Result), /// }); /// /// // Create a new Droplet using the SSH key /// var web = new DigitalOcean.Droplet("web", new() /// { /// Image = "ubuntu-18-04-x64", + /// Name = "web-1", /// Region = DigitalOcean.Region.NYC3, /// Size = DigitalOcean.DropletSlug.DropletS1VCPU1GB, /// SshKeys = new[] diff --git a/sdk/dotnet/Tag.cs b/sdk/dotnet/Tag.cs index ba8a74d1..98bb9c8c 100644 --- a/sdk/dotnet/Tag.cs +++ b/sdk/dotnet/Tag.cs @@ -26,12 +26,16 @@ namespace Pulumi.DigitalOcean /// return await Deployment.RunAsync(() => /// { /// // Create a new tag - /// var foobar = new DigitalOcean.Tag("foobar"); + /// var foobar = new DigitalOcean.Tag("foobar", new() + /// { + /// Name = "foobar", + /// }); /// /// // Create a new Droplet in nyc3 with the foobar tag /// var web = new DigitalOcean.Droplet("web", new() /// { /// Image = "ubuntu-18-04-x64", + /// Name = "web-1", /// Region = DigitalOcean.Region.NYC3, /// Size = DigitalOcean.DropletSlug.DropletS1VCPU1GB, /// Tags = new[] diff --git a/sdk/dotnet/Volume.cs b/sdk/dotnet/Volume.cs index 4aced360..a2a40805 100644 --- a/sdk/dotnet/Volume.cs +++ b/sdk/dotnet/Volume.cs @@ -22,25 +22,27 @@ namespace Pulumi.DigitalOcean /// /// return await Deployment.RunAsync(() => /// { - /// var foobarVolume = new DigitalOcean.Volume("foobarVolume", new() + /// var foobar = new DigitalOcean.Volume("foobar", new() /// { /// Region = DigitalOcean.Region.NYC1, + /// Name = "baz", /// Size = 100, /// InitialFilesystemType = DigitalOcean.FileSystemType.EXT4, /// Description = "an example volume", /// }); /// - /// var foobarDroplet = new DigitalOcean.Droplet("foobarDroplet", new() + /// var foobarDroplet = new DigitalOcean.Droplet("foobar", new() /// { + /// Name = "baz", /// Size = DigitalOcean.DropletSlug.DropletS1VCPU1GB, /// Image = "ubuntu-18-04-x64", /// Region = DigitalOcean.Region.NYC1, /// }); /// - /// var foobarVolumeAttachment = new DigitalOcean.VolumeAttachment("foobarVolumeAttachment", new() + /// var foobarVolumeAttachment = new DigitalOcean.VolumeAttachment("foobar", new() /// { /// DropletId = foobarDroplet.Id, - /// VolumeId = foobarVolume.Id, + /// VolumeId = foobar.Id, /// }); /// /// }); @@ -56,16 +58,17 @@ namespace Pulumi.DigitalOcean /// /// return await Deployment.RunAsync(() => /// { - /// var foobarVolumeSnapshot = DigitalOcean.GetVolumeSnapshot.Invoke(new() + /// var foobar = DigitalOcean.GetVolumeSnapshot.Invoke(new() /// { /// Name = "baz", /// }); /// - /// var foobarVolume = new DigitalOcean.Volume("foobarVolume", new() + /// var foobarVolume = new DigitalOcean.Volume("foobar", new() /// { /// Region = DigitalOcean.Region.LON1, - /// Size = foobarVolumeSnapshot.Apply(getVolumeSnapshotResult => getVolumeSnapshotResult.MinDiskSize), - /// SnapshotId = foobarVolumeSnapshot.Apply(getVolumeSnapshotResult => getVolumeSnapshotResult.Id), + /// Name = "foo", + /// Size = foobar.Apply(getVolumeSnapshotResult => getVolumeSnapshotResult.MinDiskSize), + /// SnapshotId = foobar.Apply(getVolumeSnapshotResult => getVolumeSnapshotResult.Id), /// }); /// /// }); diff --git a/sdk/dotnet/VolumeAttachment.cs b/sdk/dotnet/VolumeAttachment.cs index ad34be28..73c01bfc 100644 --- a/sdk/dotnet/VolumeAttachment.cs +++ b/sdk/dotnet/VolumeAttachment.cs @@ -24,25 +24,27 @@ namespace Pulumi.DigitalOcean /// /// return await Deployment.RunAsync(() => /// { - /// var foobarVolume = new DigitalOcean.Volume("foobarVolume", new() + /// var foobar = new DigitalOcean.Volume("foobar", new() /// { /// Region = DigitalOcean.Region.NYC1, + /// Name = "baz", /// Size = 100, /// InitialFilesystemType = DigitalOcean.FileSystemType.EXT4, /// Description = "an example volume", /// }); /// - /// var foobarDroplet = new DigitalOcean.Droplet("foobarDroplet", new() + /// var foobarDroplet = new DigitalOcean.Droplet("foobar", new() /// { + /// Name = "baz", /// Size = DigitalOcean.DropletSlug.DropletS1VCPU1GB, /// Image = "ubuntu-18-04-x64", /// Region = DigitalOcean.Region.NYC1, /// }); /// - /// var foobarVolumeAttachment = new DigitalOcean.VolumeAttachment("foobarVolumeAttachment", new() + /// var foobarVolumeAttachment = new DigitalOcean.VolumeAttachment("foobar", new() /// { /// DropletId = foobarDroplet.Id, - /// VolumeId = foobarVolume.Id, + /// VolumeId = foobar.Id, /// }); /// /// }); diff --git a/sdk/dotnet/VolumeSnapshot.cs b/sdk/dotnet/VolumeSnapshot.cs index 0d03efb9..dde02a5d 100644 --- a/sdk/dotnet/VolumeSnapshot.cs +++ b/sdk/dotnet/VolumeSnapshot.cs @@ -22,16 +22,18 @@ namespace Pulumi.DigitalOcean /// /// return await Deployment.RunAsync(() => /// { - /// var foobarVolume = new DigitalOcean.Volume("foobarVolume", new() + /// var foobar = new DigitalOcean.Volume("foobar", new() /// { /// Region = DigitalOcean.Region.NYC1, + /// Name = "baz", /// Size = 100, /// Description = "an example volume", /// }); /// - /// var foobarVolumeSnapshot = new DigitalOcean.VolumeSnapshot("foobarVolumeSnapshot", new() + /// var foobarVolumeSnapshot = new DigitalOcean.VolumeSnapshot("foobar", new() /// { - /// VolumeId = foobarVolume.Id, + /// Name = "foo", + /// VolumeId = foobar.Id, /// }); /// /// }); diff --git a/sdk/dotnet/Vpc.cs b/sdk/dotnet/Vpc.cs index 949f5b10..673e10e9 100644 --- a/sdk/dotnet/Vpc.cs +++ b/sdk/dotnet/Vpc.cs @@ -27,8 +27,9 @@ namespace Pulumi.DigitalOcean /// { /// var example = new DigitalOcean.Vpc("example", new() /// { - /// IpRange = "10.10.10.0/24", + /// Name = "example-project-network", /// Region = "nyc3", + /// IpRange = "10.10.10.0/24", /// }); /// /// }); @@ -48,17 +49,19 @@ namespace Pulumi.DigitalOcean /// /// return await Deployment.RunAsync(() => /// { - /// var exampleVpc = new DigitalOcean.Vpc("exampleVpc", new() + /// var example = new DigitalOcean.Vpc("example", new() /// { + /// Name = "example-project-network", /// Region = "nyc3", /// }); /// - /// var exampleDroplet = new DigitalOcean.Droplet("exampleDroplet", new() + /// var exampleDroplet = new DigitalOcean.Droplet("example", new() /// { + /// Name = "example-01", /// Size = DigitalOcean.DropletSlug.DropletS1VCPU1GB, /// Image = "ubuntu-18-04-x64", /// Region = DigitalOcean.Region.NYC3, - /// VpcUuid = exampleVpc.Id, + /// VpcUuid = example.Id, /// }); /// /// }); diff --git a/sdk/go/digitalocean/app.go b/sdk/go/digitalocean/app.go index b676e390..dd2a688b 100644 --- a/sdk/go/digitalocean/app.go +++ b/sdk/go/digitalocean/app.go @@ -37,14 +37,14 @@ import ( // Region: pulumi.String("ams"), // Services: digitalocean.AppSpecServiceArray{ // &digitalocean.AppSpecServiceArgs{ -// EnvironmentSlug: pulumi.String("go"), +// Name: pulumi.String("go-service"), +// EnvironmentSlug: pulumi.String("go"), +// InstanceCount: pulumi.Int(1), +// InstanceSizeSlug: pulumi.String("professional-xs"), // Git: &digitalocean.AppSpecServiceGitArgs{ -// Branch: pulumi.String("main"), // RepoCloneUrl: pulumi.String("https://github.com/digitalocean/sample-golang.git"), +// Branch: pulumi.String("main"), // }, -// InstanceCount: pulumi.Int(1), -// InstanceSizeSlug: pulumi.String("professional-xs"), -// Name: pulumi.String("go-service"), // }, // }, // }, @@ -78,13 +78,13 @@ import ( // Region: pulumi.String("ams"), // StaticSites: digitalocean.AppSpecStaticSiteArray{ // &digitalocean.AppSpecStaticSiteArgs{ +// Name: pulumi.String("sample-jekyll"), // BuildCommand: pulumi.String("bundle exec jekyll build -d ./public"), +// OutputDir: pulumi.String("/public"), // Git: &digitalocean.AppSpecStaticSiteGitArgs{ -// Branch: pulumi.String("main"), // RepoCloneUrl: pulumi.String("https://github.com/digitalocean/sample-jekyll.git"), +// Branch: pulumi.String("main"), // }, -// Name: pulumi.String("sample-jekyll"), -// OutputDir: pulumi.String("/public"), // }, // }, // }, diff --git a/sdk/go/digitalocean/cdn.go b/sdk/go/digitalocean/cdn.go index dcb63675..64d1b1b8 100644 --- a/sdk/go/digitalocean/cdn.go +++ b/sdk/go/digitalocean/cdn.go @@ -32,6 +32,7 @@ import ( // pulumi.Run(func(ctx *pulumi.Context) error { // // Create a new Spaces Bucket // mybucket, err := digitalocean.NewSpacesBucket(ctx, "mybucket", &digitalocean.SpacesBucketArgs{ +// Name: pulumi.String("example"), // Region: pulumi.String(digitalocean.RegionSFO2), // Acl: pulumi.String("public-read"), // }) @@ -68,6 +69,7 @@ import ( // pulumi.Run(func(ctx *pulumi.Context) error { // // Create a new Spaces Bucket // mybucket, err := digitalocean.NewSpacesBucket(ctx, "mybucket", &digitalocean.SpacesBucketArgs{ +// Name: pulumi.String("example"), // Region: pulumi.String(digitalocean.RegionSFO2), // Acl: pulumi.String("public-read"), // }) @@ -76,6 +78,7 @@ import ( // } // // Create a DigitalOcean managed Let's Encrypt Certificate // cert, err := digitalocean.NewCertificate(ctx, "cert", &digitalocean.CertificateArgs{ +// Name: pulumi.String("cdn-cert"), // Type: pulumi.String(digitalocean.CertificateTypeLetsEncrypt), // Domains: pulumi.StringArray{ // pulumi.String("static.example.com"), diff --git a/sdk/go/digitalocean/certificate.go b/sdk/go/digitalocean/certificate.go index 66bd06a3..39c6c6f0 100644 --- a/sdk/go/digitalocean/certificate.go +++ b/sdk/go/digitalocean/certificate.go @@ -27,28 +27,38 @@ import ( // // import ( // -// "os" -// // "github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean" +// "github.com/pulumi/pulumi-std/sdk/go/std" // "github.com/pulumi/pulumi/sdk/v3/go/pulumi" // // ) // -// func readFileOrPanic(path string) pulumi.StringPtrInput { -// data, err := os.ReadFile(path) -// if err != nil { -// panic(err.Error()) -// } -// return pulumi.String(string(data)) -// } -// // func main() { // pulumi.Run(func(ctx *pulumi.Context) error { -// _, err := digitalocean.NewCertificate(ctx, "cert", &digitalocean.CertificateArgs{ +// invokeFile, err := std.File(ctx, &std.FileArgs{ +// Input: "/Users/myuser/certs/privkey.pem", +// }, nil) +// if err != nil { +// return err +// } +// invokeFile1, err := std.File(ctx, &std.FileArgs{ +// Input: "/Users/myuser/certs/cert.pem", +// }, nil) +// if err != nil { +// return err +// } +// invokeFile2, err := std.File(ctx, &std.FileArgs{ +// Input: "/Users/myuser/certs/fullchain.pem", +// }, nil) +// if err != nil { +// return err +// } +// _, err = digitalocean.NewCertificate(ctx, "cert", &digitalocean.CertificateArgs{ +// Name: pulumi.String("custom-example"), // Type: pulumi.String(digitalocean.CertificateTypeCustom), -// PrivateKey: readFileOrPanic("/Users/myuser/certs/privkey.pem"), -// LeafCertificate: readFileOrPanic("/Users/myuser/certs/cert.pem"), -// CertificateChain: readFileOrPanic("/Users/myuser/certs/fullchain.pem"), +// PrivateKey: invokeFile.Result, +// LeafCertificate: invokeFile1.Result, +// CertificateChain: invokeFile2.Result, // }) // if err != nil { // return err @@ -74,10 +84,11 @@ import ( // func main() { // pulumi.Run(func(ctx *pulumi.Context) error { // _, err := digitalocean.NewCertificate(ctx, "cert", &digitalocean.CertificateArgs{ +// Name: pulumi.String("le-example"), +// Type: pulumi.String(digitalocean.CertificateTypeLetsEncrypt), // Domains: pulumi.StringArray{ // pulumi.String("example.com"), // }, -// Type: pulumi.String(digitalocean.CertificateTypeLetsEncrypt), // }) // if err != nil { // return err @@ -106,6 +117,7 @@ import ( // func main() { // pulumi.Run(func(ctx *pulumi.Context) error { // cert, err := digitalocean.NewCertificate(ctx, "cert", &digitalocean.CertificateArgs{ +// Name: pulumi.String("le-example"), // Type: pulumi.String(digitalocean.CertificateTypeLetsEncrypt), // Domains: pulumi.StringArray{ // pulumi.String("example.com"), @@ -116,6 +128,7 @@ import ( // } // // Create a new Load Balancer with TLS termination // _, err = digitalocean.NewLoadBalancer(ctx, "public", &digitalocean.LoadBalancerArgs{ +// Name: pulumi.String("secure-loadbalancer-1"), // Region: pulumi.String(digitalocean.RegionNYC3), // DropletTag: pulumi.String("backend"), // ForwardingRules: digitalocean.LoadBalancerForwardingRuleArray{ diff --git a/sdk/go/digitalocean/containerRegistry.go b/sdk/go/digitalocean/containerRegistry.go index 87accf77..f9d5615c 100644 --- a/sdk/go/digitalocean/containerRegistry.go +++ b/sdk/go/digitalocean/containerRegistry.go @@ -31,6 +31,7 @@ import ( // pulumi.Run(func(ctx *pulumi.Context) error { // // Create a new container registry // _, err := digitalocean.NewContainerRegistry(ctx, "foobar", &digitalocean.ContainerRegistryArgs{ +// Name: pulumi.String("foobar"), // SubscriptionTierSlug: pulumi.String("starter"), // }) // if err != nil { diff --git a/sdk/go/digitalocean/containerRegistryDockerCredentials.go b/sdk/go/digitalocean/containerRegistryDockerCredentials.go index 2ade4c22..ae521add 100644 --- a/sdk/go/digitalocean/containerRegistryDockerCredentials.go +++ b/sdk/go/digitalocean/containerRegistryDockerCredentials.go @@ -68,7 +68,7 @@ import ( // if err != nil { // return err // } -// _, err = digitalocean.NewContainerRegistryDockerCredentials(ctx, "exampleContainerRegistryDockerCredentials", &digitalocean.ContainerRegistryDockerCredentialsArgs{ +// _, err = digitalocean.NewContainerRegistryDockerCredentials(ctx, "example", &digitalocean.ContainerRegistryDockerCredentialsArgs{ // RegistryName: pulumi.String("example"), // }) // if err != nil { @@ -79,6 +79,55 @@ import ( // } // // ``` +// +// ### Kubernetes Example +// +// Combined with the Kubernetes Provider's `kubernetesSecret` resource, you can +// access the registry from inside your cluster: +// +// ```go +// package main +// +// import ( +// +// "github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean" +// corev1 "github.com/pulumi/pulumi-kubernetes/sdk/v4/go/kubernetes/core/v1" +// metav1 "github.com/pulumi/pulumi-kubernetes/sdk/v4/go/kubernetes/meta/v1" +// "github.com/pulumi/pulumi/sdk/v3/go/pulumi" +// +// ) +// +// func main() { +// pulumi.Run(func(ctx *pulumi.Context) error { +// exampleContainerRegistryDockerCredentials, err := digitalocean.NewContainerRegistryDockerCredentials(ctx, "example", &digitalocean.ContainerRegistryDockerCredentialsArgs{ +// RegistryName: pulumi.String("example"), +// }) +// if err != nil { +// return err +// } +// _, err = digitalocean.LookupKubernetesCluster(ctx, &digitalocean.LookupKubernetesClusterArgs{ +// Name: "prod-cluster-01", +// }, nil) +// if err != nil { +// return err +// } +// _, err = corev1.NewSecret(ctx, "example", &corev1.SecretArgs{ +// Metadata: &metav1.ObjectMetaArgs{ +// Name: pulumi.String("docker-cfg"), +// }, +// Data: pulumi.StringMap{ +// ".dockerconfigjson": exampleContainerRegistryDockerCredentials.DockerCredentials, +// }, +// Type: pulumi.String("kubernetes.io/dockerconfigjson"), +// }) +// if err != nil { +// return err +// } +// return nil +// }) +// } +// +// ``` type ContainerRegistryDockerCredentials struct { pulumi.CustomResourceState diff --git a/sdk/go/digitalocean/customImage.go b/sdk/go/digitalocean/customImage.go index 6157266b..fb6f7e2f 100644 --- a/sdk/go/digitalocean/customImage.go +++ b/sdk/go/digitalocean/customImage.go @@ -39,7 +39,8 @@ import ( // func main() { // pulumi.Run(func(ctx *pulumi.Context) error { // flatcar, err := digitalocean.NewCustomImage(ctx, "flatcar", &digitalocean.CustomImageArgs{ -// Url: pulumi.String("https://stable.release.flatcar-linux.net/amd64-usr/2605.7.0/flatcar_production_digitalocean_image.bin.bz2"), +// Name: pulumi.String("flatcar"), +// Url: pulumi.String("https://stable.release.flatcar-linux.net/amd64-usr/2605.7.0/flatcar_production_digitalocean_image.bin.bz2"), // Regions: pulumi.StringArray{ // pulumi.String("nyc3"), // }, @@ -49,6 +50,7 @@ import ( // } // _, err = digitalocean.NewDroplet(ctx, "example", &digitalocean.DropletArgs{ // Image: flatcar.ID(), +// Name: pulumi.String("example-01"), // Region: pulumi.String(digitalocean.RegionNYC3), // Size: pulumi.String(digitalocean.DropletSlugDropletS1VCPU1GB), // SshKeys: pulumi.StringArray{ diff --git a/sdk/go/digitalocean/databaseCluster.go b/sdk/go/digitalocean/databaseCluster.go index ab90c6ae..a07da955 100644 --- a/sdk/go/digitalocean/databaseCluster.go +++ b/sdk/go/digitalocean/databaseCluster.go @@ -30,11 +30,12 @@ import ( // func main() { // pulumi.Run(func(ctx *pulumi.Context) error { // _, err := digitalocean.NewDatabaseCluster(ctx, "postgres-example", &digitalocean.DatabaseClusterArgs{ +// Name: pulumi.String("example-postgres-cluster"), // Engine: pulumi.String("pg"), -// NodeCount: pulumi.Int(1), -// Region: pulumi.String(digitalocean.RegionNYC1), -// Size: pulumi.String(digitalocean.DatabaseSlug_DB_1VPCU1GB), // Version: pulumi.String("15"), +// Size: pulumi.String(digitalocean.DatabaseSlug_DB_1VPCU1GB), +// Region: pulumi.String(digitalocean.RegionNYC1), +// NodeCount: pulumi.Int(1), // }) // if err != nil { // return err @@ -59,11 +60,12 @@ import ( // func main() { // pulumi.Run(func(ctx *pulumi.Context) error { // _, err := digitalocean.NewDatabaseCluster(ctx, "mysql-example", &digitalocean.DatabaseClusterArgs{ +// Name: pulumi.String("example-mysql-cluster"), // Engine: pulumi.String("mysql"), -// NodeCount: pulumi.Int(1), -// Region: pulumi.String(digitalocean.RegionNYC1), -// Size: pulumi.String(digitalocean.DatabaseSlug_DB_1VPCU1GB), // Version: pulumi.String("8"), +// Size: pulumi.String(digitalocean.DatabaseSlug_DB_1VPCU1GB), +// Region: pulumi.String(digitalocean.RegionNYC1), +// NodeCount: pulumi.Int(1), // }) // if err != nil { // return err @@ -88,11 +90,12 @@ import ( // func main() { // pulumi.Run(func(ctx *pulumi.Context) error { // _, err := digitalocean.NewDatabaseCluster(ctx, "redis-example", &digitalocean.DatabaseClusterArgs{ +// Name: pulumi.String("example-redis-cluster"), // Engine: pulumi.String("redis"), -// NodeCount: pulumi.Int(1), -// Region: pulumi.String(digitalocean.RegionNYC1), -// Size: pulumi.String(digitalocean.DatabaseSlug_DB_1VPCU1GB), // Version: pulumi.String("7"), +// Size: pulumi.String(digitalocean.DatabaseSlug_DB_1VPCU1GB), +// Region: pulumi.String(digitalocean.RegionNYC1), +// NodeCount: pulumi.Int(1), // }) // if err != nil { // return err @@ -117,11 +120,12 @@ import ( // func main() { // pulumi.Run(func(ctx *pulumi.Context) error { // _, err := digitalocean.NewDatabaseCluster(ctx, "kafka-example", &digitalocean.DatabaseClusterArgs{ +// Name: pulumi.String("example-kafka-cluster"), // Engine: pulumi.String("kafka"), -// NodeCount: pulumi.Int(3), -// Region: pulumi.String(digitalocean.RegionNYC1), -// Size: pulumi.String("db-s-2vcpu-2gb"), // Version: pulumi.String("3.5"), +// Size: pulumi.String("db-s-2vcpu-2gb"), +// Region: pulumi.String(digitalocean.RegionNYC1), +// NodeCount: pulumi.Int(3), // }) // if err != nil { // return err @@ -146,11 +150,12 @@ import ( // func main() { // pulumi.Run(func(ctx *pulumi.Context) error { // _, err := digitalocean.NewDatabaseCluster(ctx, "mongodb-example", &digitalocean.DatabaseClusterArgs{ +// Name: pulumi.String("example-mongo-cluster"), // Engine: pulumi.String("mongodb"), -// NodeCount: pulumi.Int(1), -// Region: pulumi.String(digitalocean.RegionNYC3), -// Size: pulumi.String(digitalocean.DatabaseSlug_DB_1VPCU1GB), // Version: pulumi.String("6"), +// Size: pulumi.String(digitalocean.DatabaseSlug_DB_1VPCU1GB), +// Region: pulumi.String(digitalocean.RegionNYC3), +// NodeCount: pulumi.Int(1), // }) // if err != nil { // return err @@ -176,6 +181,7 @@ import ( // func main() { // pulumi.Run(func(ctx *pulumi.Context) error { // doby, err := digitalocean.NewDatabaseCluster(ctx, "doby", &digitalocean.DatabaseClusterArgs{ +// Name: pulumi.String("dobydb"), // Engine: pulumi.String("pg"), // Version: pulumi.String("15"), // Size: pulumi.String(digitalocean.DatabaseSlug_DB_1VPCU2GB), @@ -188,7 +194,8 @@ import ( // if err != nil { // return err // } -// _, err = digitalocean.NewDatabaseCluster(ctx, "dobyBackup", &digitalocean.DatabaseClusterArgs{ +// _, err = digitalocean.NewDatabaseCluster(ctx, "doby_backup", &digitalocean.DatabaseClusterArgs{ +// Name: pulumi.String("dobydupe"), // Engine: pulumi.String("pg"), // Version: pulumi.String("15"), // Size: pulumi.String(digitalocean.DatabaseSlug_DB_1VPCU2GB), diff --git a/sdk/go/digitalocean/databaseConnectionPool.go b/sdk/go/digitalocean/databaseConnectionPool.go index 5332b734..6c314ff8 100644 --- a/sdk/go/digitalocean/databaseConnectionPool.go +++ b/sdk/go/digitalocean/databaseConnectionPool.go @@ -30,6 +30,7 @@ import ( // func main() { // pulumi.Run(func(ctx *pulumi.Context) error { // _, err := digitalocean.NewDatabaseCluster(ctx, "postgres-example", &digitalocean.DatabaseClusterArgs{ +// Name: pulumi.String("example-postgres-cluster"), // Engine: pulumi.String("pg"), // Version: pulumi.String("15"), // Size: pulumi.String(digitalocean.DatabaseSlug_DB_1VPCU1GB), @@ -41,6 +42,7 @@ import ( // } // _, err = digitalocean.NewDatabaseConnectionPool(ctx, "pool-01", &digitalocean.DatabaseConnectionPoolArgs{ // ClusterId: postgres_example.ID(), +// Name: pulumi.String("pool-01"), // Mode: pulumi.String("transaction"), // Size: pulumi.Int(20), // DbName: pulumi.String("defaultdb"), diff --git a/sdk/go/digitalocean/databaseDb.go b/sdk/go/digitalocean/databaseDb.go index 4c1cb961..76d2c92e 100644 --- a/sdk/go/digitalocean/databaseDb.go +++ b/sdk/go/digitalocean/databaseDb.go @@ -30,6 +30,7 @@ import ( // func main() { // pulumi.Run(func(ctx *pulumi.Context) error { // _, err := digitalocean.NewDatabaseCluster(ctx, "postgres-example", &digitalocean.DatabaseClusterArgs{ +// Name: pulumi.String("example-postgres-cluster"), // Engine: pulumi.String("pg"), // Version: pulumi.String("15"), // Size: pulumi.String(digitalocean.DatabaseSlug_DB_1VPCU1GB), @@ -41,6 +42,7 @@ import ( // } // _, err = digitalocean.NewDatabaseDb(ctx, "database-example", &digitalocean.DatabaseDbArgs{ // ClusterId: postgres_example.ID(), +// Name: pulumi.String("foobar"), // }) // if err != nil { // return err diff --git a/sdk/go/digitalocean/databaseFirewall.go b/sdk/go/digitalocean/databaseFirewall.go index 9dc480cb..d1292f8e 100644 --- a/sdk/go/digitalocean/databaseFirewall.go +++ b/sdk/go/digitalocean/databaseFirewall.go @@ -33,6 +33,7 @@ import ( // func main() { // pulumi.Run(func(ctx *pulumi.Context) error { // _, err := digitalocean.NewDatabaseCluster(ctx, "postgres-example", &digitalocean.DatabaseClusterArgs{ +// Name: pulumi.String("example-postgres-cluster"), // Engine: pulumi.String("pg"), // Version: pulumi.String("15"), // Size: pulumi.String(digitalocean.DatabaseSlug_DB_1VPCU1GB), @@ -79,6 +80,7 @@ import ( // func main() { // pulumi.Run(func(ctx *pulumi.Context) error { // web, err := digitalocean.NewDroplet(ctx, "web", &digitalocean.DropletArgs{ +// Name: pulumi.String("web-01"), // Size: pulumi.String(digitalocean.DropletSlugDropletS1VCPU1GB), // Image: pulumi.String("ubuntu-22-04-x64"), // Region: pulumi.String(digitalocean.RegionNYC3), @@ -87,6 +89,7 @@ import ( // return err // } // _, err = digitalocean.NewDatabaseCluster(ctx, "postgres-example", &digitalocean.DatabaseClusterArgs{ +// Name: pulumi.String("example-postgres-cluster"), // Engine: pulumi.String("pg"), // Version: pulumi.String("15"), // Size: pulumi.String(digitalocean.DatabaseSlug_DB_1VPCU1GB), @@ -129,6 +132,7 @@ import ( // func main() { // pulumi.Run(func(ctx *pulumi.Context) error { // _, err := digitalocean.NewDatabaseCluster(ctx, "postgres-example", &digitalocean.DatabaseClusterArgs{ +// Name: pulumi.String("example-postgres-cluster"), // Engine: pulumi.String("pg"), // Version: pulumi.String("15"), // Size: pulumi.String(digitalocean.DatabaseSlug_DB_1VPCU1GB), @@ -140,6 +144,7 @@ import ( // } // _, err = digitalocean.NewDatabaseReplica(ctx, "replica-example", &digitalocean.DatabaseReplicaArgs{ // ClusterId: postgres_example.ID(), +// Name: pulumi.String("replica-example"), // Size: pulumi.String(digitalocean.DatabaseSlug_DB_1VPCU1GB), // Region: pulumi.String(digitalocean.RegionNYC1), // }) diff --git a/sdk/go/digitalocean/databaseKafkaTopic.go b/sdk/go/digitalocean/databaseKafkaTopic.go index 9d5e2f78..561fb187 100644 --- a/sdk/go/digitalocean/databaseKafkaTopic.go +++ b/sdk/go/digitalocean/databaseKafkaTopic.go @@ -30,6 +30,7 @@ import ( // func main() { // pulumi.Run(func(ctx *pulumi.Context) error { // _, err := digitalocean.NewDatabaseCluster(ctx, "kafka-example", &digitalocean.DatabaseClusterArgs{ +// Name: pulumi.String("example-kafka-cluster"), // Engine: pulumi.String("kafka"), // Version: pulumi.String("3.5"), // Size: pulumi.String("db-s-2vcpu-2gb"), @@ -44,6 +45,7 @@ import ( // } // _, err = digitalocean.NewDatabaseKafkaTopic(ctx, "topic-01", &digitalocean.DatabaseKafkaTopicArgs{ // ClusterId: kafka_example.ID(), +// Name: pulumi.String("topic-01"), // PartitionCount: pulumi.Int(3), // ReplicationFactor: pulumi.Int(2), // Configs: digitalocean.DatabaseKafkaTopicConfigArray{ diff --git a/sdk/go/digitalocean/databaseMysqlConfig.go b/sdk/go/digitalocean/databaseMysqlConfig.go index cdb9f001..4740237a 100644 --- a/sdk/go/digitalocean/databaseMysqlConfig.go +++ b/sdk/go/digitalocean/databaseMysqlConfig.go @@ -31,7 +31,8 @@ import ( // // func main() { // pulumi.Run(func(ctx *pulumi.Context) error { -// exampleDatabaseCluster, err := digitalocean.NewDatabaseCluster(ctx, "exampleDatabaseCluster", &digitalocean.DatabaseClusterArgs{ +// exampleDatabaseCluster, err := digitalocean.NewDatabaseCluster(ctx, "example", &digitalocean.DatabaseClusterArgs{ +// Name: pulumi.String("example-mysql-cluster"), // Engine: pulumi.String("mysql"), // Version: pulumi.String("8"), // Size: pulumi.String(digitalocean.DatabaseSlug_DB_1VPCU1GB), @@ -41,7 +42,7 @@ import ( // if err != nil { // return err // } -// _, err = digitalocean.NewDatabaseMysqlConfig(ctx, "exampleDatabaseMysqlConfig", &digitalocean.DatabaseMysqlConfigArgs{ +// _, err = digitalocean.NewDatabaseMysqlConfig(ctx, "example", &digitalocean.DatabaseMysqlConfigArgs{ // ClusterId: exampleDatabaseCluster.ID(), // ConnectTimeout: pulumi.Int(10), // DefaultTimeZone: pulumi.String("UTC"), diff --git a/sdk/go/digitalocean/databasePostgresqlConfig.go b/sdk/go/digitalocean/databasePostgresqlConfig.go index 78e704d4..93aed307 100644 --- a/sdk/go/digitalocean/databasePostgresqlConfig.go +++ b/sdk/go/digitalocean/databasePostgresqlConfig.go @@ -31,7 +31,8 @@ import ( // // func main() { // pulumi.Run(func(ctx *pulumi.Context) error { -// exampleDatabaseCluster, err := digitalocean.NewDatabaseCluster(ctx, "exampleDatabaseCluster", &digitalocean.DatabaseClusterArgs{ +// exampleDatabaseCluster, err := digitalocean.NewDatabaseCluster(ctx, "example", &digitalocean.DatabaseClusterArgs{ +// Name: pulumi.String("example-postgresql-cluster"), // Engine: pulumi.String("pg"), // Version: pulumi.String("15"), // Size: pulumi.String(digitalocean.DatabaseSlug_DB_1VPCU1GB), @@ -41,7 +42,7 @@ import ( // if err != nil { // return err // } -// _, err = digitalocean.NewDatabasePostgresqlConfig(ctx, "exampleDatabasePostgresqlConfig", &digitalocean.DatabasePostgresqlConfigArgs{ +// _, err = digitalocean.NewDatabasePostgresqlConfig(ctx, "example", &digitalocean.DatabasePostgresqlConfigArgs{ // ClusterId: exampleDatabaseCluster.ID(), // Timezone: pulumi.String("UTC"), // WorkMem: pulumi.Int(16), diff --git a/sdk/go/digitalocean/databaseRedisConfig.go b/sdk/go/digitalocean/databaseRedisConfig.go index 709fb833..6276922d 100644 --- a/sdk/go/digitalocean/databaseRedisConfig.go +++ b/sdk/go/digitalocean/databaseRedisConfig.go @@ -31,7 +31,8 @@ import ( // // func main() { // pulumi.Run(func(ctx *pulumi.Context) error { -// exampleDatabaseCluster, err := digitalocean.NewDatabaseCluster(ctx, "exampleDatabaseCluster", &digitalocean.DatabaseClusterArgs{ +// exampleDatabaseCluster, err := digitalocean.NewDatabaseCluster(ctx, "example", &digitalocean.DatabaseClusterArgs{ +// Name: pulumi.String("example-redis-cluster"), // Engine: pulumi.String("redis"), // Version: pulumi.String("7"), // Size: pulumi.String(digitalocean.DatabaseSlug_DB_1VPCU1GB), @@ -41,7 +42,7 @@ import ( // if err != nil { // return err // } -// _, err = digitalocean.NewDatabaseRedisConfig(ctx, "exampleDatabaseRedisConfig", &digitalocean.DatabaseRedisConfigArgs{ +// _, err = digitalocean.NewDatabaseRedisConfig(ctx, "example", &digitalocean.DatabaseRedisConfigArgs{ // ClusterId: exampleDatabaseCluster.ID(), // MaxmemoryPolicy: pulumi.String("allkeys-lru"), // NotifyKeyspaceEvents: pulumi.String("KEA"), diff --git a/sdk/go/digitalocean/databaseReplica.go b/sdk/go/digitalocean/databaseReplica.go index 7cebc421..7ead0dcc 100644 --- a/sdk/go/digitalocean/databaseReplica.go +++ b/sdk/go/digitalocean/databaseReplica.go @@ -30,6 +30,7 @@ import ( // func main() { // pulumi.Run(func(ctx *pulumi.Context) error { // _, err := digitalocean.NewDatabaseCluster(ctx, "postgres-example", &digitalocean.DatabaseClusterArgs{ +// Name: pulumi.String("example-postgres-cluster"), // Engine: pulumi.String("pg"), // Version: pulumi.String("15"), // Size: pulumi.String(digitalocean.DatabaseSlug_DB_1VPCU1GB), @@ -41,13 +42,14 @@ import ( // } // _, err = digitalocean.NewDatabaseReplica(ctx, "replica-example", &digitalocean.DatabaseReplicaArgs{ // ClusterId: postgres_example.ID(), +// Name: pulumi.String("replica-example"), // Size: pulumi.String(digitalocean.DatabaseSlug_DB_1VPCU1GB), // Region: pulumi.String(digitalocean.RegionNYC1), // }) // if err != nil { // return err // } -// ctx.Export("uUID", replica_example.Uuid) +// ctx.Export("UUID", replica_example.Uuid) // // Create firewall rule for database replica // _, err = digitalocean.NewDatabaseFirewall(ctx, "example-fw", &digitalocean.DatabaseFirewallArgs{ // ClusterId: replica_example.Uuid, diff --git a/sdk/go/digitalocean/databaseUser.go b/sdk/go/digitalocean/databaseUser.go index f7794dbe..67106029 100644 --- a/sdk/go/digitalocean/databaseUser.go +++ b/sdk/go/digitalocean/databaseUser.go @@ -32,6 +32,7 @@ import ( // func main() { // pulumi.Run(func(ctx *pulumi.Context) error { // _, err := digitalocean.NewDatabaseCluster(ctx, "postgres-example", &digitalocean.DatabaseClusterArgs{ +// Name: pulumi.String("example-postgres-cluster"), // Engine: pulumi.String("pg"), // Version: pulumi.String("15"), // Size: pulumi.String(digitalocean.DatabaseSlug_DB_1VPCU1GB), @@ -43,6 +44,7 @@ import ( // } // _, err = digitalocean.NewDatabaseUser(ctx, "user-example", &digitalocean.DatabaseUserArgs{ // ClusterId: postgres_example.ID(), +// Name: pulumi.String("foobar"), // }) // if err != nil { // return err @@ -67,6 +69,7 @@ import ( // func main() { // pulumi.Run(func(ctx *pulumi.Context) error { // _, err := digitalocean.NewDatabaseCluster(ctx, "postgres-example", &digitalocean.DatabaseClusterArgs{ +// Name: pulumi.String("example-postgres-cluster"), // Engine: pulumi.String("pg"), // Version: pulumi.String("15"), // Size: pulumi.String(digitalocean.DatabaseSlug_DB_1VPCU1GB), @@ -78,6 +81,7 @@ import ( // } // _, err = digitalocean.NewDatabaseReplica(ctx, "replica-example", &digitalocean.DatabaseReplicaArgs{ // ClusterId: postgres_example.ID(), +// Name: pulumi.String("replica-example"), // Size: pulumi.String(digitalocean.DatabaseSlug_DB_1VPCU1GB), // Region: pulumi.String(digitalocean.RegionNYC1), // }) @@ -86,6 +90,7 @@ import ( // } // _, err = digitalocean.NewDatabaseUser(ctx, "user-example", &digitalocean.DatabaseUserArgs{ // ClusterId: replica_example.Uuid, +// Name: pulumi.String("foobar"), // }) // if err != nil { // return err @@ -110,6 +115,7 @@ import ( // func main() { // pulumi.Run(func(ctx *pulumi.Context) error { // _, err := digitalocean.NewDatabaseCluster(ctx, "kafka-example", &digitalocean.DatabaseClusterArgs{ +// Name: pulumi.String("example-kafka-cluster"), // Engine: pulumi.String("kafka"), // Version: pulumi.String("3.5"), // Size: pulumi.String("db-s-2vcpu-2gb"), @@ -119,14 +125,16 @@ import ( // if err != nil { // return err // } -// _, err = digitalocean.NewDatabaseKafkaTopic(ctx, "foobarTopic", &digitalocean.DatabaseKafkaTopicArgs{ -// ClusterId: pulumi.Any(digitalocean_database_cluster.Foobar.Id), +// _, err = digitalocean.NewDatabaseKafkaTopic(ctx, "foobar_topic", &digitalocean.DatabaseKafkaTopicArgs{ +// ClusterId: pulumi.Any(foobar.Id), +// Name: pulumi.String("topic-1"), // }) // if err != nil { // return err // } -// _, err = digitalocean.NewDatabaseUser(ctx, "foobarUser", &digitalocean.DatabaseUserArgs{ -// ClusterId: pulumi.Any(digitalocean_database_cluster.Foobar.Id), +// _, err = digitalocean.NewDatabaseUser(ctx, "foobar_user", &digitalocean.DatabaseUserArgs{ +// ClusterId: pulumi.Any(foobar.Id), +// Name: pulumi.String("example-user"), // Settings: digitalocean.DatabaseUserSettingArray{ // &digitalocean.DatabaseUserSettingArgs{ // Acls: digitalocean.DatabaseUserSettingAclArray{ diff --git a/sdk/go/digitalocean/dnsRecord.go b/sdk/go/digitalocean/dnsRecord.go index d9f177d1..1e5cb940 100644 --- a/sdk/go/digitalocean/dnsRecord.go +++ b/sdk/go/digitalocean/dnsRecord.go @@ -38,6 +38,7 @@ import ( // www, err := digitalocean.NewDnsRecord(ctx, "www", &digitalocean.DnsRecordArgs{ // Domain: _default.ID(), // Type: pulumi.String(digitalocean.RecordTypeA), +// Name: pulumi.String("www"), // Value: pulumi.String("192.168.0.11"), // }) // if err != nil { @@ -47,6 +48,7 @@ import ( // mx, err := digitalocean.NewDnsRecord(ctx, "mx", &digitalocean.DnsRecordArgs{ // Domain: _default.ID(), // Type: pulumi.String(digitalocean.RecordTypeMX), +// Name: pulumi.String("@"), // Priority: pulumi.Int(10), // Value: pulumi.String("mail.example.com."), // }) diff --git a/sdk/go/digitalocean/domain.go b/sdk/go/digitalocean/domain.go index 4168616a..1868e4ce 100644 --- a/sdk/go/digitalocean/domain.go +++ b/sdk/go/digitalocean/domain.go @@ -31,7 +31,7 @@ import ( // // Create a new domain // _, err := digitalocean.NewDomain(ctx, "default", &digitalocean.DomainArgs{ // Name: pulumi.String("example.com"), -// IpAddress: pulumi.Any(digitalocean_droplet.Foo.Ipv4_address), +// IpAddress: pulumi.Any(foo.Ipv4Address), // }) // if err != nil { // return err diff --git a/sdk/go/digitalocean/droplet.go b/sdk/go/digitalocean/droplet.go index 411f9da7..7d6961f6 100644 --- a/sdk/go/digitalocean/droplet.go +++ b/sdk/go/digitalocean/droplet.go @@ -32,6 +32,7 @@ import ( // // Create a new Web Droplet in the nyc2 region // _, err := digitalocean.NewDroplet(ctx, "web", &digitalocean.DropletArgs{ // Image: pulumi.String("ubuntu-20-04-x64"), +// Name: pulumi.String("web-1"), // Region: pulumi.String(digitalocean.RegionNYC2), // Size: pulumi.String(digitalocean.DropletSlugDropletS1VCPU1GB), // }) diff --git a/sdk/go/digitalocean/dropletSnapshot.go b/sdk/go/digitalocean/dropletSnapshot.go index 01bcb70f..4a0f8519 100644 --- a/sdk/go/digitalocean/dropletSnapshot.go +++ b/sdk/go/digitalocean/dropletSnapshot.go @@ -29,6 +29,7 @@ import ( // func main() { // pulumi.Run(func(ctx *pulumi.Context) error { // web, err := digitalocean.NewDroplet(ctx, "web", &digitalocean.DropletArgs{ +// Name: pulumi.String("web-01"), // Size: pulumi.String(digitalocean.DropletSlugDropletS1VCPU1GB), // Image: pulumi.String("ubuntu-22-04-x64"), // Region: pulumi.String(digitalocean.RegionNYC3), @@ -38,12 +39,14 @@ import ( // } // _, err = digitalocean.NewDropletSnapshot(ctx, "web-snapshot", &digitalocean.DropletSnapshotArgs{ // DropletId: web.ID(), +// Name: pulumi.String("web-snapshot-01"), // }) // if err != nil { // return err // } // _, err = digitalocean.NewDroplet(ctx, "from-snapshot", &digitalocean.DropletArgs{ // Image: web_snapshot.ID(), +// Name: pulumi.String("web-02"), // Region: pulumi.String(digitalocean.RegionNYC3), // Size: pulumi.String(digitalocean.DropletSlugDropletS2VCPU4GB), // }) diff --git a/sdk/go/digitalocean/firewall.go b/sdk/go/digitalocean/firewall.go index 45bb64bd..dea2374a 100644 --- a/sdk/go/digitalocean/firewall.go +++ b/sdk/go/digitalocean/firewall.go @@ -28,7 +28,8 @@ import ( // // func main() { // pulumi.Run(func(ctx *pulumi.Context) error { -// webDroplet, err := digitalocean.NewDroplet(ctx, "webDroplet", &digitalocean.DropletArgs{ +// web, err := digitalocean.NewDroplet(ctx, "web", &digitalocean.DropletArgs{ +// Name: pulumi.String("web-1"), // Size: pulumi.String(digitalocean.DropletSlugDropletS1VCPU1GB), // Image: pulumi.String("ubuntu-18-04-x64"), // Region: pulumi.String(digitalocean.RegionNYC3), @@ -36,9 +37,10 @@ import ( // if err != nil { // return err // } -// _, err = digitalocean.NewFirewall(ctx, "webFirewall", &digitalocean.FirewallArgs{ +// _, err = digitalocean.NewFirewall(ctx, "web", &digitalocean.FirewallArgs{ +// Name: pulumi.String("only-22-80-and-443"), // DropletIds: pulumi.IntArray{ -// webDroplet.ID(), +// web.ID(), // }, // InboundRules: digitalocean.FirewallInboundRuleArray{ // &digitalocean.FirewallInboundRuleArgs{ diff --git a/sdk/go/digitalocean/floatingIp.go b/sdk/go/digitalocean/floatingIp.go index c44729fc..78740d34 100644 --- a/sdk/go/digitalocean/floatingIp.go +++ b/sdk/go/digitalocean/floatingIp.go @@ -32,7 +32,8 @@ import ( // // func main() { // pulumi.Run(func(ctx *pulumi.Context) error { -// foobarDroplet, err := digitalocean.NewDroplet(ctx, "foobarDroplet", &digitalocean.DropletArgs{ +// foobar, err := digitalocean.NewDroplet(ctx, "foobar", &digitalocean.DropletArgs{ +// Name: pulumi.String("baz"), // Size: pulumi.String(digitalocean.DropletSlugDropletS1VCPU1GB), // Image: pulumi.String("ubuntu-18-04-x64"), // Region: pulumi.String(digitalocean.RegionSGP1), @@ -42,9 +43,9 @@ import ( // if err != nil { // return err // } -// _, err = digitalocean.NewFloatingIp(ctx, "foobarFloatingIp", &digitalocean.FloatingIpArgs{ -// DropletId: foobarDroplet.ID(), -// Region: foobarDroplet.Region, +// _, err = digitalocean.NewFloatingIp(ctx, "foobar", &digitalocean.FloatingIpArgs{ +// DropletId: foobar.ID(), +// Region: foobar.Region, // }) // if err != nil { // return err diff --git a/sdk/go/digitalocean/floatingIpAssignment.go b/sdk/go/digitalocean/floatingIpAssignment.go index 0f386172..a3bfaf8e 100644 --- a/sdk/go/digitalocean/floatingIpAssignment.go +++ b/sdk/go/digitalocean/floatingIpAssignment.go @@ -32,13 +32,14 @@ import ( // // func main() { // pulumi.Run(func(ctx *pulumi.Context) error { -// foobarFloatingIp, err := digitalocean.NewFloatingIp(ctx, "foobarFloatingIp", &digitalocean.FloatingIpArgs{ +// foobar, err := digitalocean.NewFloatingIp(ctx, "foobar", &digitalocean.FloatingIpArgs{ // Region: pulumi.String("sgp1"), // }) // if err != nil { // return err // } -// foobarDroplet, err := digitalocean.NewDroplet(ctx, "foobarDroplet", &digitalocean.DropletArgs{ +// foobarDroplet, err := digitalocean.NewDroplet(ctx, "foobar", &digitalocean.DropletArgs{ +// Name: pulumi.String("baz"), // Size: pulumi.String(digitalocean.DropletSlugDropletS1VCPU1GB), // Image: pulumi.String("ubuntu-18-04-x64"), // Region: pulumi.String(digitalocean.RegionSGP1), @@ -48,8 +49,8 @@ import ( // if err != nil { // return err // } -// _, err = digitalocean.NewFloatingIpAssignment(ctx, "foobarFloatingIpAssignment", &digitalocean.FloatingIpAssignmentArgs{ -// IpAddress: foobarFloatingIp.IpAddress, +// _, err = digitalocean.NewFloatingIpAssignment(ctx, "foobar", &digitalocean.FloatingIpAssignmentArgs{ +// IpAddress: foobar.IpAddress, // DropletId: foobarDroplet.ID(), // }) // if err != nil { diff --git a/sdk/go/digitalocean/getDomains.go b/sdk/go/digitalocean/getDomains.go index 20f90a6c..5546579f 100644 --- a/sdk/go/digitalocean/getDomains.go +++ b/sdk/go/digitalocean/getDomains.go @@ -40,11 +40,11 @@ import ( // _, err := digitalocean.GetDomains(ctx, &digitalocean.GetDomainsArgs{ // Filters: []digitalocean.GetDomainsFilter{ // { -// Key: "name", -// MatchBy: pulumi.StringRef("re"), +// Key: "name", // Values: []string{ // "example\\.com$", // }, +// MatchBy: pulumi.StringRef("re"), // }, // }, // }, nil) diff --git a/sdk/go/digitalocean/getDroplet.go b/sdk/go/digitalocean/getDroplet.go index acff3fcd..8986dc14 100644 --- a/sdk/go/digitalocean/getDroplet.go +++ b/sdk/go/digitalocean/getDroplet.go @@ -89,7 +89,7 @@ import ( // func main() { // pulumi.Run(func(ctx *pulumi.Context) error { // _, err := digitalocean.LookupDroplet(ctx, &digitalocean.LookupDropletArgs{ -// Id: pulumi.IntRef(digitalocean_kubernetes_cluster.Example.Node_pool[0].Nodes[0].Droplet_id), +// Id: pulumi.IntRef(exampleDigitaloceanKubernetesCluster.NodePool[0].Nodes[0].DropletId), // }, nil) // if err != nil { // return err diff --git a/sdk/go/digitalocean/getDropletSnapshot.go b/sdk/go/digitalocean/getDropletSnapshot.go index 49537d02..8efce756 100644 --- a/sdk/go/digitalocean/getDropletSnapshot.go +++ b/sdk/go/digitalocean/getDropletSnapshot.go @@ -32,9 +32,9 @@ import ( // func main() { // pulumi.Run(func(ctx *pulumi.Context) error { // _, err := digitalocean.LookupDropletSnapshot(ctx, &digitalocean.LookupDropletSnapshotArgs{ -// MostRecent: pulumi.BoolRef(true), // NameRegex: pulumi.StringRef("^web"), // Region: pulumi.StringRef("nyc3"), +// MostRecent: pulumi.BoolRef(true), // }, nil) // if err != nil { // return err @@ -69,6 +69,7 @@ import ( // } // _, err = digitalocean.NewDroplet(ctx, "from-snapshot", &digitalocean.DropletArgs{ // Image: pulumi.String(web_snapshot.Id), +// Name: pulumi.String("web-02"), // Region: pulumi.String(digitalocean.RegionNYC3), // Size: pulumi.String(digitalocean.DropletSlugDropletS2VCPU4GB), // }) diff --git a/sdk/go/digitalocean/getDroplets.go b/sdk/go/digitalocean/getDroplets.go index f757f4df..36001b79 100644 --- a/sdk/go/digitalocean/getDroplets.go +++ b/sdk/go/digitalocean/getDroplets.go @@ -88,8 +88,8 @@ import ( // }, // Sorts: []digitalocean.GetDropletsSort{ // { -// Direction: pulumi.StringRef("desc"), // Key: "created_at", +// Direction: pulumi.StringRef("desc"), // }, // }, // }, nil) diff --git a/sdk/go/digitalocean/getImage.go b/sdk/go/digitalocean/getImage.go index bb95f60d..d770a568 100644 --- a/sdk/go/digitalocean/getImage.go +++ b/sdk/go/digitalocean/getImage.go @@ -60,14 +60,15 @@ import ( // // func main() { // pulumi.Run(func(ctx *pulumi.Context) error { -// exampleImage, err := digitalocean.GetImage(ctx, &digitalocean.GetImageArgs{ +// example, err := digitalocean.GetImage(ctx, &digitalocean.GetImageArgs{ // Name: pulumi.StringRef("example-1.0.0"), // }, nil) // if err != nil { // return err // } -// _, err = digitalocean.NewDroplet(ctx, "exampleDroplet", &digitalocean.DropletArgs{ -// Image: pulumi.Int(exampleImage.Id), +// _, err = digitalocean.NewDroplet(ctx, "example", &digitalocean.DropletArgs{ +// Image: pulumi.Int(example.Id), +// Name: pulumi.String("example-1"), // Region: pulumi.String(digitalocean.RegionNYC2), // Size: pulumi.String(digitalocean.DropletSlugDropletS1VCPU1GB), // }) diff --git a/sdk/go/digitalocean/getImages.go b/sdk/go/digitalocean/getImages.go index ac03718b..2296db2e 100644 --- a/sdk/go/digitalocean/getImages.go +++ b/sdk/go/digitalocean/getImages.go @@ -89,8 +89,8 @@ import ( // }, // Sorts: []digitalocean.GetImagesSort{ // { -// Direction: pulumi.StringRef("desc"), // Key: "created", +// Direction: pulumi.StringRef("desc"), // }, // }, // }, nil) diff --git a/sdk/go/digitalocean/getKubernetesCluster.go b/sdk/go/digitalocean/getKubernetesCluster.go index caba1b26..3f8352a1 100644 --- a/sdk/go/digitalocean/getKubernetesCluster.go +++ b/sdk/go/digitalocean/getKubernetesCluster.go @@ -12,6 +12,32 @@ import ( ) // Retrieves information about a DigitalOcean Kubernetes cluster for use in other resources. This data source provides all of the cluster's properties as configured on your DigitalOcean account. This is useful if the cluster in question is not managed by the provider. +// +// ## Example Usage +// +// ```go +// package main +// +// import ( +// +// "github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean" +// "github.com/pulumi/pulumi/sdk/v3/go/pulumi" +// +// ) +// +// func main() { +// pulumi.Run(func(ctx *pulumi.Context) error { +// _, err := digitalocean.LookupKubernetesCluster(ctx, &digitalocean.LookupKubernetesClusterArgs{ +// Name: "prod-cluster-01", +// }, nil) +// if err != nil { +// return err +// } +// return nil +// }) +// } +// +// ``` func LookupKubernetesCluster(ctx *pulumi.Context, args *LookupKubernetesClusterArgs, opts ...pulumi.InvokeOption) (*LookupKubernetesClusterResult, error) { opts = internal.PkgInvokeDefaultOpts(opts) var rv LookupKubernetesClusterResult diff --git a/sdk/go/digitalocean/getKubernetesVersions.go b/sdk/go/digitalocean/getKubernetesVersions.go index dc6155f6..51718d82 100644 --- a/sdk/go/digitalocean/getKubernetesVersions.go +++ b/sdk/go/digitalocean/getKubernetesVersions.go @@ -59,6 +59,7 @@ import ( // return err // } // _, err = digitalocean.NewKubernetesCluster(ctx, "example-cluster", &digitalocean.KubernetesClusterArgs{ +// Name: pulumi.String("example-cluster"), // Region: pulumi.String(digitalocean.RegionLON1), // Version: pulumi.String(example.LatestVersion), // NodePool: &digitalocean.KubernetesClusterNodePoolArgs{ @@ -97,6 +98,7 @@ import ( // return err // } // _, err = digitalocean.NewKubernetesCluster(ctx, "example-cluster", &digitalocean.KubernetesClusterArgs{ +// Name: pulumi.String("example-cluster"), // Region: pulumi.String(digitalocean.RegionLON1), // Version: pulumi.String(example.LatestVersion), // NodePool: &digitalocean.KubernetesClusterNodePoolArgs{ diff --git a/sdk/go/digitalocean/getProjects.go b/sdk/go/digitalocean/getProjects.go index ea1a079c..a2cb5418 100644 --- a/sdk/go/digitalocean/getProjects.go +++ b/sdk/go/digitalocean/getProjects.go @@ -87,8 +87,8 @@ import ( // }, // Sorts: []digitalocean.GetProjectsSort{ // { -// Direction: pulumi.StringRef("asc"), // Key: "name", +// Direction: pulumi.StringRef("asc"), // }, // }, // }, nil) diff --git a/sdk/go/digitalocean/getRecords.go b/sdk/go/digitalocean/getRecords.go index 91f7acab..c8b49512 100644 --- a/sdk/go/digitalocean/getRecords.go +++ b/sdk/go/digitalocean/getRecords.go @@ -13,6 +13,49 @@ import ( // Retrieve information about all DNS records within a domain, with the ability to filter and sort the results. // If no filters are specified, all records will be returned. +// +// ## Example Usage +// +// Get data for all MX records in a domain: +// +// ```go +// package main +// +// import ( +// +// "github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean" +// "github.com/pulumi/pulumi-std/sdk/go/std" +// "github.com/pulumi/pulumi/sdk/v3/go/pulumi" +// +// ) +// func main() { +// pulumi.Run(func(ctx *pulumi.Context) error { +// example, err := digitalocean.GetRecords(ctx, &digitalocean.GetRecordsArgs{ +// Domain: "example.com", +// Filters: []digitalocean.GetRecordsFilter{ +// { +// Key: "type", +// Values: []string{ +// "MX", +// }, +// }, +// }, +// }, nil); +// if err != nil { +// return err +// } +// ctx.Export("mailServers", std.Join(ctx, var splat0 []*string +// for _, val0 := range example.Records { +// splat0 = append(splat0, val0.Value) +// } +// &std.JoinArgs{ +// Separator: ",", +// Input: splat0, +// }, nil).Result) +// return nil +// }) +// } +// ``` func GetRecords(ctx *pulumi.Context, args *GetRecordsArgs, opts ...pulumi.InvokeOption) (*GetRecordsResult, error) { opts = internal.PkgInvokeDefaultOpts(opts) var rv GetRecordsResult diff --git a/sdk/go/digitalocean/getRegions.go b/sdk/go/digitalocean/getRegions.go index c9816df7..fa2d592b 100644 --- a/sdk/go/digitalocean/getRegions.go +++ b/sdk/go/digitalocean/getRegions.go @@ -85,8 +85,8 @@ import ( // }, // Sorts: []digitalocean.GetRegionsSort{ // { -// Direction: pulumi.StringRef("desc"), // Key: "name", +// Direction: pulumi.StringRef("desc"), // }, // }, // }, nil) diff --git a/sdk/go/digitalocean/getSpacesBucketObject.go b/sdk/go/digitalocean/getSpacesBucketObject.go index c0481aaa..d932b36f 100644 --- a/sdk/go/digitalocean/getSpacesBucketObject.go +++ b/sdk/go/digitalocean/getSpacesBucketObject.go @@ -45,6 +45,7 @@ import ( // } // _, err = digitalocean.NewDroplet(ctx, "web", &digitalocean.DropletArgs{ // Image: pulumi.String("ubuntu-18-04-x64"), +// Name: pulumi.String("web-1"), // Region: pulumi.String(digitalocean.RegionNYC2), // Size: pulumi.String(digitalocean.DropletSlugDropletS1VCPU1GB), // UserData: pulumi.String(bootstrapScript.Body), diff --git a/sdk/go/digitalocean/getSpacesBuckets.go b/sdk/go/digitalocean/getSpacesBuckets.go index 1a04722e..b82c467d 100644 --- a/sdk/go/digitalocean/getSpacesBuckets.go +++ b/sdk/go/digitalocean/getSpacesBuckets.go @@ -78,8 +78,8 @@ import ( // }, // Sorts: []digitalocean.GetSpacesBucketsSort{ // { -// Direction: pulumi.StringRef("desc"), // Key: "name", +// Direction: pulumi.StringRef("desc"), // }, // }, // }, nil) diff --git a/sdk/go/digitalocean/getSshKey.go b/sdk/go/digitalocean/getSshKey.go index 022edb36..5b43d0fc 100644 --- a/sdk/go/digitalocean/getSshKey.go +++ b/sdk/go/digitalocean/getSshKey.go @@ -34,18 +34,19 @@ import ( // // func main() { // pulumi.Run(func(ctx *pulumi.Context) error { -// exampleSshKey, err := digitalocean.LookupSshKey(ctx, &digitalocean.LookupSshKeyArgs{ +// example, err := digitalocean.LookupSshKey(ctx, &digitalocean.LookupSshKeyArgs{ // Name: "example", // }, nil) // if err != nil { // return err // } -// _, err = digitalocean.NewDroplet(ctx, "exampleDroplet", &digitalocean.DropletArgs{ +// _, err = digitalocean.NewDroplet(ctx, "example", &digitalocean.DropletArgs{ // Image: pulumi.String("ubuntu-18-04-x64"), +// Name: pulumi.String("example-1"), // Region: pulumi.String(digitalocean.RegionNYC2), // Size: pulumi.String(digitalocean.DropletSlugDropletS1VCPU1GB), // SshKeys: pulumi.StringArray{ -// pulumi.Int(exampleSshKey.Id), +// pulumi.Int(example.Id), // }, // }) // if err != nil { diff --git a/sdk/go/digitalocean/getSshKeys.go b/sdk/go/digitalocean/getSshKeys.go index d82cca79..e8bfddbe 100644 --- a/sdk/go/digitalocean/getSshKeys.go +++ b/sdk/go/digitalocean/getSshKeys.go @@ -38,8 +38,8 @@ import ( // _, err := digitalocean.GetSshKeys(ctx, &digitalocean.GetSshKeysArgs{ // Sorts: []digitalocean.GetSshKeysSort{ // { -// Direction: pulumi.StringRef("asc"), // Key: "name", +// Direction: pulumi.StringRef("asc"), // }, // }, // }, nil) diff --git a/sdk/go/digitalocean/getTag.go b/sdk/go/digitalocean/getTag.go index 263bdec7..eb3eb0de 100644 --- a/sdk/go/digitalocean/getTag.go +++ b/sdk/go/digitalocean/getTag.go @@ -33,18 +33,19 @@ import ( // // func main() { // pulumi.Run(func(ctx *pulumi.Context) error { -// exampleTag, err := digitalocean.LookupTag(ctx, &digitalocean.LookupTagArgs{ +// example, err := digitalocean.LookupTag(ctx, &digitalocean.LookupTagArgs{ // Name: "example", // }, nil) // if err != nil { // return err // } -// _, err = digitalocean.NewDroplet(ctx, "exampleDroplet", &digitalocean.DropletArgs{ +// _, err = digitalocean.NewDroplet(ctx, "example", &digitalocean.DropletArgs{ // Image: pulumi.String("ubuntu-18-04-x64"), +// Name: pulumi.String("example-1"), // Region: pulumi.String(digitalocean.RegionNYC2), // Size: pulumi.String(digitalocean.DropletSlugDropletS1VCPU1GB), // Tags: pulumi.StringArray{ -// pulumi.String(exampleTag.Name), +// pulumi.String(example.Name), // }, // }) // if err != nil { diff --git a/sdk/go/digitalocean/getVolume.go b/sdk/go/digitalocean/getVolume.go index fc467c7d..4c40fc4d 100644 --- a/sdk/go/digitalocean/getVolume.go +++ b/sdk/go/digitalocean/getVolume.go @@ -61,14 +61,15 @@ import ( // // func main() { // pulumi.Run(func(ctx *pulumi.Context) error { -// exampleVolume, err := digitalocean.LookupVolume(ctx, &digitalocean.LookupVolumeArgs{ +// example, err := digitalocean.LookupVolume(ctx, &digitalocean.LookupVolumeArgs{ // Name: "app-data", // Region: pulumi.StringRef("nyc3"), // }, nil) // if err != nil { // return err // } -// exampleDroplet, err := digitalocean.NewDroplet(ctx, "exampleDroplet", &digitalocean.DropletArgs{ +// exampleDroplet, err := digitalocean.NewDroplet(ctx, "example", &digitalocean.DropletArgs{ +// Name: pulumi.String("foo"), // Size: pulumi.String(digitalocean.DropletSlugDropletS1VCPU1GB), // Image: pulumi.String("ubuntu-18-04-x64"), // Region: pulumi.String(digitalocean.RegionNYC3), @@ -78,7 +79,7 @@ import ( // } // _, err = digitalocean.NewVolumeAttachment(ctx, "foobar", &digitalocean.VolumeAttachmentArgs{ // DropletId: exampleDroplet.ID(), -// VolumeId: pulumi.String(exampleVolume.Id), +// VolumeId: pulumi.String(example.Id), // }) // if err != nil { // return err diff --git a/sdk/go/digitalocean/getVolumeSnapshot.go b/sdk/go/digitalocean/getVolumeSnapshot.go index 4ed3dac4..924bc1f7 100644 --- a/sdk/go/digitalocean/getVolumeSnapshot.go +++ b/sdk/go/digitalocean/getVolumeSnapshot.go @@ -32,9 +32,9 @@ import ( // func main() { // pulumi.Run(func(ctx *pulumi.Context) error { // _, err := digitalocean.LookupVolumeSnapshot(ctx, &digitalocean.LookupVolumeSnapshotArgs{ -// MostRecent: pulumi.BoolRef(true), // NameRegex: pulumi.StringRef("^web"), // Region: pulumi.StringRef("nyc3"), +// MostRecent: pulumi.BoolRef(true), // }, nil) // if err != nil { // return err @@ -69,6 +69,7 @@ import ( // } // _, err = digitalocean.NewVolume(ctx, "foobar", &digitalocean.VolumeArgs{ // Region: pulumi.String(digitalocean.RegionNYC3), +// Name: pulumi.String("baz"), // Size: pulumi.Int(100), // SnapshotId: pulumi.String(snapshot.Id), // }) diff --git a/sdk/go/digitalocean/getVpc.go b/sdk/go/digitalocean/getVpc.go index dfa4be86..e2a67ec7 100644 --- a/sdk/go/digitalocean/getVpc.go +++ b/sdk/go/digitalocean/getVpc.go @@ -62,17 +62,18 @@ import ( // // func main() { // pulumi.Run(func(ctx *pulumi.Context) error { -// exampleVpc, err := digitalocean.LookupVpc(ctx, &digitalocean.LookupVpcArgs{ +// example, err := digitalocean.LookupVpc(ctx, &digitalocean.LookupVpcArgs{ // Name: pulumi.StringRef("example-network"), // }, nil) // if err != nil { // return err // } -// _, err = digitalocean.NewDroplet(ctx, "exampleDroplet", &digitalocean.DropletArgs{ +// _, err = digitalocean.NewDroplet(ctx, "example", &digitalocean.DropletArgs{ +// Name: pulumi.String("example-01"), // Size: pulumi.String(digitalocean.DropletSlugDropletS1VCPU1GB), // Image: pulumi.String("ubuntu-18-04-x64"), // Region: pulumi.String(digitalocean.RegionNYC3), -// VpcUuid: pulumi.String(exampleVpc.Id), +// VpcUuid: pulumi.String(example.Id), // }) // if err != nil { // return err diff --git a/sdk/go/digitalocean/kubernetesNodePool.go b/sdk/go/digitalocean/kubernetesNodePool.go index dc6e1041..4e86b35c 100644 --- a/sdk/go/digitalocean/kubernetesNodePool.go +++ b/sdk/go/digitalocean/kubernetesNodePool.go @@ -31,6 +31,7 @@ import ( // func main() { // pulumi.Run(func(ctx *pulumi.Context) error { // foo, err := digitalocean.NewKubernetesCluster(ctx, "foo", &digitalocean.KubernetesClusterArgs{ +// Name: pulumi.String("foo"), // Region: pulumi.String(digitalocean.RegionNYC1), // Version: pulumi.String("1.22.8-do.1"), // NodePool: &digitalocean.KubernetesClusterNodePoolArgs{ @@ -44,6 +45,7 @@ import ( // } // _, err = digitalocean.NewKubernetesNodePool(ctx, "bar", &digitalocean.KubernetesNodePoolArgs{ // ClusterId: foo.ID(), +// Name: pulumi.String("backend-pool"), // Size: pulumi.String(digitalocean.DropletSlugDropletC2), // NodeCount: pulumi.Int(2), // Tags: pulumi.StringArray{ @@ -88,7 +90,8 @@ import ( // func main() { // pulumi.Run(func(ctx *pulumi.Context) error { // _, err := digitalocean.NewKubernetesNodePool(ctx, "autoscale-pool-01", &digitalocean.KubernetesNodePoolArgs{ -// ClusterId: pulumi.Any(digitalocean_kubernetes_cluster.Foo.Id), +// ClusterId: pulumi.Any(foo.Id), +// Name: pulumi.String("autoscale-pool-01"), // Size: pulumi.String(digitalocean.DropletSlugDropletS1VCPU2GB), // AutoScale: pulumi.Bool(true), // MinNodes: pulumi.Int(1), diff --git a/sdk/go/digitalocean/loadBalancer.go b/sdk/go/digitalocean/loadBalancer.go index 91011419..7efabedd 100644 --- a/sdk/go/digitalocean/loadBalancer.go +++ b/sdk/go/digitalocean/loadBalancer.go @@ -29,6 +29,7 @@ import ( // func main() { // pulumi.Run(func(ctx *pulumi.Context) error { // web, err := digitalocean.NewDroplet(ctx, "web", &digitalocean.DropletArgs{ +// Name: pulumi.String("web-1"), // Size: pulumi.String(digitalocean.DropletSlugDropletS1VCPU1GB), // Image: pulumi.String("ubuntu-18-04-x64"), // Region: pulumi.String(digitalocean.RegionNYC3), @@ -37,6 +38,7 @@ import ( // return err // } // _, err = digitalocean.NewLoadBalancer(ctx, "public", &digitalocean.LoadBalancerArgs{ +// Name: pulumi.String("loadbalancer-1"), // Region: pulumi.String(digitalocean.RegionNYC3), // ForwardingRules: digitalocean.LoadBalancerForwardingRuleArray{ // &digitalocean.LoadBalancerForwardingRuleArgs{ @@ -69,61 +71,6 @@ import ( // `Delete old certificate`. When doing so, you must also change the name of the certificate, // as there cannot be multiple certificates with the same name in an account. // -// ```go -// package main -// -// import ( -// -// "github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean" -// "github.com/pulumi/pulumi/sdk/v3/go/pulumi" -// -// ) -// -// func main() { -// pulumi.Run(func(ctx *pulumi.Context) error { -// cert, err := digitalocean.NewCertificate(ctx, "cert", &digitalocean.CertificateArgs{ -// PrivateKey: pulumi.String("file('key.pem')"), -// LeafCertificate: pulumi.String("file('cert.pem')"), -// }) -// if err != nil { -// return err -// } -// web, err := digitalocean.NewDroplet(ctx, "web", &digitalocean.DropletArgs{ -// Size: pulumi.String(digitalocean.DropletSlugDropletS1VCPU1GB), -// Image: pulumi.String("ubuntu-18-04-x64"), -// Region: pulumi.String(digitalocean.RegionNYC3), -// }) -// if err != nil { -// return err -// } -// _, err = digitalocean.NewLoadBalancer(ctx, "public", &digitalocean.LoadBalancerArgs{ -// Region: pulumi.String(digitalocean.RegionNYC3), -// ForwardingRules: digitalocean.LoadBalancerForwardingRuleArray{ -// &digitalocean.LoadBalancerForwardingRuleArgs{ -// EntryPort: pulumi.Int(443), -// EntryProtocol: pulumi.String("https"), -// TargetPort: pulumi.Int(80), -// TargetProtocol: pulumi.String("http"), -// CertificateName: cert.Name, -// }, -// }, -// Healthcheck: &digitalocean.LoadBalancerHealthcheckArgs{ -// Port: pulumi.Int(22), -// Protocol: pulumi.String("tcp"), -// }, -// DropletIds: pulumi.IntArray{ -// web.ID(), -// }, -// }) -// if err != nil { -// return err -// } -// return nil -// }) -// } -// -// ``` -// // ## Import // // Load Balancers can be imported using the `id`, e.g. diff --git a/sdk/go/digitalocean/project.go b/sdk/go/digitalocean/project.go index 889c0d6f..d3045993 100644 --- a/sdk/go/digitalocean/project.go +++ b/sdk/go/digitalocean/project.go @@ -48,9 +48,10 @@ import ( // func main() { // pulumi.Run(func(ctx *pulumi.Context) error { // _, err := digitalocean.NewProject(ctx, "playground", &digitalocean.ProjectArgs{ +// Name: pulumi.String("playground"), // Description: pulumi.String("A project to represent development resources."), -// Environment: pulumi.String("Development"), // Purpose: pulumi.String("Web Application"), +// Environment: pulumi.String("Development"), // }) // if err != nil { // return err @@ -76,6 +77,7 @@ import ( // func main() { // pulumi.Run(func(ctx *pulumi.Context) error { // foobar, err := digitalocean.NewDroplet(ctx, "foobar", &digitalocean.DropletArgs{ +// Name: pulumi.String("example"), // Size: pulumi.String(digitalocean.DropletSlugDropletS1VCPU1GB), // Image: pulumi.String("ubuntu-22-04-x64"), // Region: pulumi.String(digitalocean.RegionNYC3), @@ -84,6 +86,7 @@ import ( // return err // } // _, err = digitalocean.NewProject(ctx, "playground", &digitalocean.ProjectArgs{ +// Name: pulumi.String("playground"), // Description: pulumi.String("A project to represent development resources."), // Purpose: pulumi.String("Web Application"), // Environment: pulumi.String("Development"), diff --git a/sdk/go/digitalocean/projectResources.go b/sdk/go/digitalocean/projectResources.go index a6d5496e..da5f578c 100644 --- a/sdk/go/digitalocean/projectResources.go +++ b/sdk/go/digitalocean/projectResources.go @@ -50,6 +50,7 @@ import ( // return err // } // foobar, err := digitalocean.NewDroplet(ctx, "foobar", &digitalocean.DropletArgs{ +// Name: pulumi.String("example"), // Size: pulumi.String(digitalocean.DropletSlugDropletS1VCPU1GB), // Image: pulumi.String("ubuntu-22-04-x64"), // Region: pulumi.String(digitalocean.RegionNYC3), diff --git a/sdk/go/digitalocean/reservedIp.go b/sdk/go/digitalocean/reservedIp.go index 4d70aa1a..fb3a958e 100644 --- a/sdk/go/digitalocean/reservedIp.go +++ b/sdk/go/digitalocean/reservedIp.go @@ -30,7 +30,8 @@ import ( // // func main() { // pulumi.Run(func(ctx *pulumi.Context) error { -// exampleDroplet, err := digitalocean.NewDroplet(ctx, "exampleDroplet", &digitalocean.DropletArgs{ +// example, err := digitalocean.NewDroplet(ctx, "example", &digitalocean.DropletArgs{ +// Name: pulumi.String("example"), // Size: pulumi.String(digitalocean.DropletSlugDropletS1VCPU1GB), // Image: pulumi.String("ubuntu-22-04-x64"), // Region: pulumi.String(digitalocean.RegionNYC3), @@ -40,9 +41,9 @@ import ( // if err != nil { // return err // } -// _, err = digitalocean.NewReservedIp(ctx, "exampleReservedIp", &digitalocean.ReservedIpArgs{ -// DropletId: exampleDroplet.ID(), -// Region: exampleDroplet.Region, +// _, err = digitalocean.NewReservedIp(ctx, "example", &digitalocean.ReservedIpArgs{ +// DropletId: example.ID(), +// Region: example.Region, // }) // if err != nil { // return err diff --git a/sdk/go/digitalocean/reservedIpAssignment.go b/sdk/go/digitalocean/reservedIpAssignment.go index 2ec931a2..52cedc68 100644 --- a/sdk/go/digitalocean/reservedIpAssignment.go +++ b/sdk/go/digitalocean/reservedIpAssignment.go @@ -30,13 +30,14 @@ import ( // // func main() { // pulumi.Run(func(ctx *pulumi.Context) error { -// exampleReservedIp, err := digitalocean.NewReservedIp(ctx, "exampleReservedIp", &digitalocean.ReservedIpArgs{ +// example, err := digitalocean.NewReservedIp(ctx, "example", &digitalocean.ReservedIpArgs{ // Region: pulumi.String("nyc3"), // }) // if err != nil { // return err // } -// exampleDroplet, err := digitalocean.NewDroplet(ctx, "exampleDroplet", &digitalocean.DropletArgs{ +// exampleDroplet, err := digitalocean.NewDroplet(ctx, "example", &digitalocean.DropletArgs{ +// Name: pulumi.String("baz"), // Size: pulumi.String(digitalocean.DropletSlugDropletS1VCPU1GB), // Image: pulumi.String("ubuntu-22-04-x64"), // Region: pulumi.String(digitalocean.RegionNYC3), @@ -46,8 +47,8 @@ import ( // if err != nil { // return err // } -// _, err = digitalocean.NewReservedIpAssignment(ctx, "exampleReservedIpAssignment", &digitalocean.ReservedIpAssignmentArgs{ -// IpAddress: exampleReservedIp.IpAddress, +// _, err = digitalocean.NewReservedIpAssignment(ctx, "example", &digitalocean.ReservedIpAssignmentArgs{ +// IpAddress: example.IpAddress, // DropletId: exampleDroplet.ID(), // }) // if err != nil { diff --git a/sdk/go/digitalocean/spacesBucket.go b/sdk/go/digitalocean/spacesBucket.go index 516eb3ec..eb8fe594 100644 --- a/sdk/go/digitalocean/spacesBucket.go +++ b/sdk/go/digitalocean/spacesBucket.go @@ -66,6 +66,7 @@ import ( // func main() { // pulumi.Run(func(ctx *pulumi.Context) error { // _, err := digitalocean.NewSpacesBucket(ctx, "foobar", &digitalocean.SpacesBucketArgs{ +// Name: pulumi.String("foobar"), // Region: pulumi.String(digitalocean.RegionNYC3), // }) // if err != nil { @@ -92,6 +93,8 @@ import ( // func main() { // pulumi.Run(func(ctx *pulumi.Context) error { // _, err := digitalocean.NewSpacesBucket(ctx, "foobar", &digitalocean.SpacesBucketArgs{ +// Name: pulumi.String("foobar"), +// Region: pulumi.String(digitalocean.RegionNYC3), // CorsRules: digitalocean.SpacesBucketCorsRuleArray{ // &digitalocean.SpacesBucketCorsRuleArgs{ // AllowedHeaders: pulumi.StringArray{ @@ -120,7 +123,6 @@ import ( // MaxAgeSeconds: pulumi.Int(3000), // }, // }, -// Region: pulumi.String(digitalocean.RegionNYC3), // }) // if err != nil { // return err diff --git a/sdk/go/digitalocean/spacesBucketCorsConfiguration.go b/sdk/go/digitalocean/spacesBucketCorsConfiguration.go index d92fea6b..27cc3ffe 100644 --- a/sdk/go/digitalocean/spacesBucketCorsConfiguration.go +++ b/sdk/go/digitalocean/spacesBucketCorsConfiguration.go @@ -29,6 +29,7 @@ import ( // func main() { // pulumi.Run(func(ctx *pulumi.Context) error { // foobar, err := digitalocean.NewSpacesBucket(ctx, "foobar", &digitalocean.SpacesBucketArgs{ +// Name: pulumi.String("foobar"), // Region: pulumi.String(digitalocean.RegionNYC3), // }) // if err != nil { diff --git a/sdk/go/digitalocean/spacesBucketObject.go b/sdk/go/digitalocean/spacesBucketObject.go index 345c9fb4..667fcd10 100644 --- a/sdk/go/digitalocean/spacesBucketObject.go +++ b/sdk/go/digitalocean/spacesBucketObject.go @@ -69,6 +69,7 @@ import ( // func main() { // pulumi.Run(func(ctx *pulumi.Context) error { // foobar, err := digitalocean.NewSpacesBucket(ctx, "foobar", &digitalocean.SpacesBucketArgs{ +// Name: pulumi.String("foobar"), // Region: pulumi.String(digitalocean.RegionNYC3), // }) // if err != nil { diff --git a/sdk/go/digitalocean/spacesBucketPolicy.go b/sdk/go/digitalocean/spacesBucketPolicy.go index 2c37ae47..c5d1002b 100644 --- a/sdk/go/digitalocean/spacesBucketPolicy.go +++ b/sdk/go/digitalocean/spacesBucketPolicy.go @@ -31,18 +31,19 @@ import ( // // func main() { // pulumi.Run(func(ctx *pulumi.Context) error { -// foobarSpacesBucket, err := digitalocean.NewSpacesBucket(ctx, "foobarSpacesBucket", &digitalocean.SpacesBucketArgs{ +// foobar, err := digitalocean.NewSpacesBucket(ctx, "foobar", &digitalocean.SpacesBucketArgs{ +// Name: pulumi.String("foobar"), // Region: pulumi.String(digitalocean.RegionNYC3), // }) // if err != nil { // return err // } -// _, err = digitalocean.NewSpacesBucketPolicy(ctx, "foobarSpacesBucketPolicy", &digitalocean.SpacesBucketPolicyArgs{ -// Region: foobarSpacesBucket.Region, -// Bucket: foobarSpacesBucket.Name, -// Policy: pulumi.All(foobarSpacesBucket.Name, foobarSpacesBucket.Name).ApplyT(func(_args []interface{}) (string, error) { -// foobarSpacesBucketName := _args[0].(string) -// foobarSpacesBucketName1 := _args[1].(string) +// _, err = digitalocean.NewSpacesBucketPolicy(ctx, "foobar", &digitalocean.SpacesBucketPolicyArgs{ +// Region: foobar.Region, +// Bucket: foobar.Name, +// Policy: pulumi.All(foobar.Name, foobar.Name).ApplyT(func(_args []interface{}) (string, error) { +// foobarName := _args[0].(string) +// foobarName1 := _args[1].(string) // var _zero string // tmpJSON0, err := json.Marshal(map[string]interface{}{ // "Version": "2012-10-17", @@ -53,8 +54,8 @@ import ( // "Principal": "*", // "Action": "s3:*", // "Resource": []string{ -// fmt.Sprintf("arn:aws:s3:::%v", foobarSpacesBucketName), -// fmt.Sprintf("arn:aws:s3:::%v/*", foobarSpacesBucketName1), +// fmt.Sprintf("arn:aws:s3:::%v", foobarName), +// fmt.Sprintf("arn:aws:s3:::%v/*", foobarName1), // }, // "Condition": map[string]interface{}{ // "NotIpAddress": map[string]interface{}{ diff --git a/sdk/go/digitalocean/sshKey.go b/sdk/go/digitalocean/sshKey.go index 5215121a..190c76c1 100644 --- a/sdk/go/digitalocean/sshKey.go +++ b/sdk/go/digitalocean/sshKey.go @@ -24,26 +24,24 @@ import ( // // import ( // -// "os" -// // "github.com/pulumi/pulumi-digitalocean/sdk/v4/go/digitalocean" +// "github.com/pulumi/pulumi-std/sdk/go/std" // "github.com/pulumi/pulumi/sdk/v3/go/pulumi" // // ) // -// func readFileOrPanic(path string) pulumi.StringPtrInput { -// data, err := os.ReadFile(path) -// if err != nil { -// panic(err.Error()) -// } -// return pulumi.String(string(data)) -// } -// // func main() { // pulumi.Run(func(ctx *pulumi.Context) error { +// invokeFile, err := std.File(ctx, &std.FileArgs{ +// Input: "/Users/myuser/.ssh/id_rsa.pub", +// }, nil) +// if err != nil { +// return err +// } // // Create a new SSH key -// _, err := digitalocean.NewSshKey(ctx, "default", &digitalocean.SshKeyArgs{ -// PublicKey: readFileOrPanic("/Users/myuser/.ssh/id_rsa.pub"), +// _, err = digitalocean.NewSshKey(ctx, "default", &digitalocean.SshKeyArgs{ +// Name: pulumi.String("Example"), +// PublicKey: invokeFile.Result, // }) // if err != nil { // return err @@ -51,6 +49,7 @@ import ( // // Create a new Droplet using the SSH key // _, err = digitalocean.NewDroplet(ctx, "web", &digitalocean.DropletArgs{ // Image: pulumi.String("ubuntu-18-04-x64"), +// Name: pulumi.String("web-1"), // Region: pulumi.String(digitalocean.RegionNYC3), // Size: pulumi.String(digitalocean.DropletSlugDropletS1VCPU1GB), // SshKeys: pulumi.StringArray{ diff --git a/sdk/go/digitalocean/tag.go b/sdk/go/digitalocean/tag.go index 37be35e0..6fbbf2b1 100644 --- a/sdk/go/digitalocean/tag.go +++ b/sdk/go/digitalocean/tag.go @@ -31,13 +31,16 @@ import ( // func main() { // pulumi.Run(func(ctx *pulumi.Context) error { // // Create a new tag -// foobar, err := digitalocean.NewTag(ctx, "foobar", nil) +// foobar, err := digitalocean.NewTag(ctx, "foobar", &digitalocean.TagArgs{ +// Name: pulumi.String("foobar"), +// }) // if err != nil { // return err // } // // Create a new Droplet in nyc3 with the foobar tag // _, err = digitalocean.NewDroplet(ctx, "web", &digitalocean.DropletArgs{ // Image: pulumi.String("ubuntu-18-04-x64"), +// Name: pulumi.String("web-1"), // Region: pulumi.String(digitalocean.RegionNYC3), // Size: pulumi.String(digitalocean.DropletSlugDropletS1VCPU1GB), // Tags: pulumi.StringArray{ diff --git a/sdk/go/digitalocean/volume.go b/sdk/go/digitalocean/volume.go index bb5b292e..c7ce2088 100644 --- a/sdk/go/digitalocean/volume.go +++ b/sdk/go/digitalocean/volume.go @@ -28,8 +28,9 @@ import ( // // func main() { // pulumi.Run(func(ctx *pulumi.Context) error { -// foobarVolume, err := digitalocean.NewVolume(ctx, "foobarVolume", &digitalocean.VolumeArgs{ +// foobar, err := digitalocean.NewVolume(ctx, "foobar", &digitalocean.VolumeArgs{ // Region: pulumi.String(digitalocean.RegionNYC1), +// Name: pulumi.String("baz"), // Size: pulumi.Int(100), // InitialFilesystemType: pulumi.String(digitalocean.FileSystemTypeEXT4), // Description: pulumi.String("an example volume"), @@ -37,7 +38,8 @@ import ( // if err != nil { // return err // } -// foobarDroplet, err := digitalocean.NewDroplet(ctx, "foobarDroplet", &digitalocean.DropletArgs{ +// foobarDroplet, err := digitalocean.NewDroplet(ctx, "foobar", &digitalocean.DropletArgs{ +// Name: pulumi.String("baz"), // Size: pulumi.String(digitalocean.DropletSlugDropletS1VCPU1GB), // Image: pulumi.String("ubuntu-18-04-x64"), // Region: pulumi.String(digitalocean.RegionNYC1), @@ -45,9 +47,9 @@ import ( // if err != nil { // return err // } -// _, err = digitalocean.NewVolumeAttachment(ctx, "foobarVolumeAttachment", &digitalocean.VolumeAttachmentArgs{ +// _, err = digitalocean.NewVolumeAttachment(ctx, "foobar", &digitalocean.VolumeAttachmentArgs{ // DropletId: foobarDroplet.ID(), -// VolumeId: foobarVolume.ID(), +// VolumeId: foobar.ID(), // }) // if err != nil { // return err @@ -72,16 +74,17 @@ import ( // // func main() { // pulumi.Run(func(ctx *pulumi.Context) error { -// foobarVolumeSnapshot, err := digitalocean.LookupVolumeSnapshot(ctx, &digitalocean.LookupVolumeSnapshotArgs{ +// foobar, err := digitalocean.LookupVolumeSnapshot(ctx, &digitalocean.LookupVolumeSnapshotArgs{ // Name: pulumi.StringRef("baz"), // }, nil) // if err != nil { // return err // } -// _, err = digitalocean.NewVolume(ctx, "foobarVolume", &digitalocean.VolumeArgs{ +// _, err = digitalocean.NewVolume(ctx, "foobar", &digitalocean.VolumeArgs{ // Region: pulumi.String(digitalocean.RegionLON1), -// Size: pulumi.Int(foobarVolumeSnapshot.MinDiskSize), -// SnapshotId: pulumi.String(foobarVolumeSnapshot.Id), +// Name: pulumi.String("foo"), +// Size: pulumi.Int(foobar.MinDiskSize), +// SnapshotId: pulumi.String(foobar.Id), // }) // if err != nil { // return err diff --git a/sdk/go/digitalocean/volumeAttachment.go b/sdk/go/digitalocean/volumeAttachment.go index 21d6f3b1..d74b069a 100644 --- a/sdk/go/digitalocean/volumeAttachment.go +++ b/sdk/go/digitalocean/volumeAttachment.go @@ -30,8 +30,9 @@ import ( // // func main() { // pulumi.Run(func(ctx *pulumi.Context) error { -// foobarVolume, err := digitalocean.NewVolume(ctx, "foobarVolume", &digitalocean.VolumeArgs{ +// foobar, err := digitalocean.NewVolume(ctx, "foobar", &digitalocean.VolumeArgs{ // Region: pulumi.String(digitalocean.RegionNYC1), +// Name: pulumi.String("baz"), // Size: pulumi.Int(100), // InitialFilesystemType: pulumi.String(digitalocean.FileSystemTypeEXT4), // Description: pulumi.String("an example volume"), @@ -39,7 +40,8 @@ import ( // if err != nil { // return err // } -// foobarDroplet, err := digitalocean.NewDroplet(ctx, "foobarDroplet", &digitalocean.DropletArgs{ +// foobarDroplet, err := digitalocean.NewDroplet(ctx, "foobar", &digitalocean.DropletArgs{ +// Name: pulumi.String("baz"), // Size: pulumi.String(digitalocean.DropletSlugDropletS1VCPU1GB), // Image: pulumi.String("ubuntu-18-04-x64"), // Region: pulumi.String(digitalocean.RegionNYC1), @@ -47,9 +49,9 @@ import ( // if err != nil { // return err // } -// _, err = digitalocean.NewVolumeAttachment(ctx, "foobarVolumeAttachment", &digitalocean.VolumeAttachmentArgs{ +// _, err = digitalocean.NewVolumeAttachment(ctx, "foobar", &digitalocean.VolumeAttachmentArgs{ // DropletId: foobarDroplet.ID(), -// VolumeId: foobarVolume.ID(), +// VolumeId: foobar.ID(), // }) // if err != nil { // return err diff --git a/sdk/go/digitalocean/volumeSnapshot.go b/sdk/go/digitalocean/volumeSnapshot.go index 8ca97c58..f42873e3 100644 --- a/sdk/go/digitalocean/volumeSnapshot.go +++ b/sdk/go/digitalocean/volumeSnapshot.go @@ -28,16 +28,18 @@ import ( // // func main() { // pulumi.Run(func(ctx *pulumi.Context) error { -// foobarVolume, err := digitalocean.NewVolume(ctx, "foobarVolume", &digitalocean.VolumeArgs{ +// foobar, err := digitalocean.NewVolume(ctx, "foobar", &digitalocean.VolumeArgs{ // Region: pulumi.String(digitalocean.RegionNYC1), +// Name: pulumi.String("baz"), // Size: pulumi.Int(100), // Description: pulumi.String("an example volume"), // }) // if err != nil { // return err // } -// _, err = digitalocean.NewVolumeSnapshot(ctx, "foobarVolumeSnapshot", &digitalocean.VolumeSnapshotArgs{ -// VolumeId: foobarVolume.ID(), +// _, err = digitalocean.NewVolumeSnapshot(ctx, "foobar", &digitalocean.VolumeSnapshotArgs{ +// Name: pulumi.String("foo"), +// VolumeId: foobar.ID(), // }) // if err != nil { // return err diff --git a/sdk/go/digitalocean/vpc.go b/sdk/go/digitalocean/vpc.go index fd37b0f2..4f38902d 100644 --- a/sdk/go/digitalocean/vpc.go +++ b/sdk/go/digitalocean/vpc.go @@ -32,8 +32,9 @@ import ( // func main() { // pulumi.Run(func(ctx *pulumi.Context) error { // _, err := digitalocean.NewVpc(ctx, "example", &digitalocean.VpcArgs{ -// IpRange: pulumi.String("10.10.10.0/24"), +// Name: pulumi.String("example-project-network"), // Region: pulumi.String("nyc3"), +// IpRange: pulumi.String("10.10.10.0/24"), // }) // if err != nil { // return err @@ -62,17 +63,19 @@ import ( // // func main() { // pulumi.Run(func(ctx *pulumi.Context) error { -// exampleVpc, err := digitalocean.NewVpc(ctx, "exampleVpc", &digitalocean.VpcArgs{ +// example, err := digitalocean.NewVpc(ctx, "example", &digitalocean.VpcArgs{ +// Name: pulumi.String("example-project-network"), // Region: pulumi.String("nyc3"), // }) // if err != nil { // return err // } -// _, err = digitalocean.NewDroplet(ctx, "exampleDroplet", &digitalocean.DropletArgs{ +// _, err = digitalocean.NewDroplet(ctx, "example", &digitalocean.DropletArgs{ +// Name: pulumi.String("example-01"), // Size: pulumi.String(digitalocean.DropletSlugDropletS1VCPU1GB), // Image: pulumi.String("ubuntu-18-04-x64"), // Region: pulumi.String(digitalocean.RegionNYC3), -// VpcUuid: exampleVpc.ID(), +// VpcUuid: example.ID(), // }) // if err != nil { // return err diff --git a/sdk/java/src/main/java/com/pulumi/digitalocean/App.java b/sdk/java/src/main/java/com/pulumi/digitalocean/App.java index 4cc47d9b..a6a544c4 100644 --- a/sdk/java/src/main/java/com/pulumi/digitalocean/App.java +++ b/sdk/java/src/main/java/com/pulumi/digitalocean/App.java @@ -53,14 +53,14 @@ * .name("golang-sample") * .region("ams") * .services(AppSpecServiceArgs.builder() + * .name("go-service") * .environmentSlug("go") + * .instanceCount(1) + * .instanceSizeSlug("professional-xs") * .git(AppSpecServiceGitArgs.builder() - * .branch("main") * .repoCloneUrl("https://github.com/digitalocean/sample-golang.git") + * .branch("main") * .build()) - * .instanceCount(1) - * .instanceSizeSlug("professional-xs") - * .name("go-service") * .build()) * .build()) * .build()); @@ -102,13 +102,13 @@ * .name("static-site-example") * .region("ams") * .staticSites(AppSpecStaticSiteArgs.builder() + * .name("sample-jekyll") * .buildCommand("bundle exec jekyll build -d ./public") + * .outputDir("/public") * .git(AppSpecStaticSiteGitArgs.builder() - * .branch("main") * .repoCloneUrl("https://github.com/digitalocean/sample-jekyll.git") + * .branch("main") * .build()) - * .name("sample-jekyll") - * .outputDir("/public") * .build()) * .build()) * .build()); @@ -148,46 +148,74 @@ * public static void stack(Context ctx) { * var mono_repo_example = new App("mono-repo-example", AppArgs.builder() * .spec(AppSpecArgs.builder() + * .name("mono-repo-example") + * .region("ams") + * .domains(Map.of("name", "foo.example.com")) * .alerts(AppSpecAlertArgs.builder() * .rule("DEPLOYMENT_FAILED") * .build()) - * .databases(AppSpecDatabaseArgs.builder() - * .engine("PG") - * .name("starter-db") - * .production(false) - * .build()) - * .domains(Map.of("name", "foo.example.com")) - * .ingress(AppSpecIngressArgs.builder() - * .rule( - * %!v(PANIC=Format method: runtime error: invalid memory address or nil pointer dereference), - * %!v(PANIC=Format method: runtime error: invalid memory address or nil pointer dereference)) - * .build()) - * .name("mono-repo-example") - * .region("ams") * .services(AppSpecServiceArgs.builder() - * .alert(%!v(PANIC=Format method: runtime error: invalid memory address or nil pointer dereference)) + * .name("api") * .environmentSlug("go") + * .instanceCount(2) + * .instanceSizeSlug("professional-xs") * .github(AppSpecServiceGithubArgs.builder() * .branch("main") * .deployOnPush(true) * .repo("username/repo") * .build()) + * .sourceDir("api/") * .httpPort(3000) - * .instanceCount(2) - * .instanceSizeSlug("professional-xs") - * .logDestination(%!v(PANIC=Format method: runtime error: invalid memory address or nil pointer dereference)) - * .name("api") + * .alerts(AppSpecServiceAlertArgs.builder() + * .value(75) + * .operator("GREATER_THAN") + * .window("TEN_MINUTES") + * .rule("CPU_UTILIZATION") + * .build()) + * .logDestinations(AppSpecServiceLogDestinationArgs.builder() + * .name("MyLogs") + * .papertrail(AppSpecServiceLogDestinationPapertrailArgs.builder() + * .endpoint("syslog+tls://example.com:12345") + * .build()) + * .build()) * .runCommand("bin/api") - * .sourceDir("api/") * .build()) * .staticSites(AppSpecStaticSiteArgs.builder() + * .name("web") * .buildCommand("npm run build") * .github(AppSpecStaticSiteGithubArgs.builder() * .branch("main") * .deployOnPush(true) * .repo("username/repo") * .build()) - * .name("web") + * .build()) + * .databases(AppSpecDatabaseArgs.builder() + * .name("starter-db") + * .engine("PG") + * .production(false) + * .build()) + * .ingress(AppSpecIngressArgs.builder() + * .rules( + * AppSpecIngressRuleArgs.builder() + * .component(AppSpecIngressRuleComponentArgs.builder() + * .name("api") + * .build()) + * .match(AppSpecIngressRuleMatchArgs.builder() + * .path(AppSpecIngressRuleMatchPathArgs.builder() + * .prefix("/api") + * .build()) + * .build()) + * .build(), + * AppSpecIngressRuleArgs.builder() + * .component(AppSpecIngressRuleComponentArgs.builder() + * .name("web") + * .build()) + * .match(AppSpecIngressRuleMatchArgs.builder() + * .path(AppSpecIngressRuleMatchPathArgs.builder() + * .prefix("/") + * .build()) + * .build()) + * .build()) * .build()) * .build()) * .build()); diff --git a/sdk/java/src/main/java/com/pulumi/digitalocean/Cdn.java b/sdk/java/src/main/java/com/pulumi/digitalocean/Cdn.java index bd2d0d6c..2de99041 100644 --- a/sdk/java/src/main/java/com/pulumi/digitalocean/Cdn.java +++ b/sdk/java/src/main/java/com/pulumi/digitalocean/Cdn.java @@ -49,6 +49,7 @@ * public static void stack(Context ctx) { * // Create a new Spaces Bucket * var mybucket = new SpacesBucket("mybucket", SpacesBucketArgs.builder() + * .name("example") * .region("sfo2") * .acl("public-read") * .build()); @@ -96,12 +97,14 @@ * public static void stack(Context ctx) { * // Create a new Spaces Bucket * var mybucket = new SpacesBucket("mybucket", SpacesBucketArgs.builder() + * .name("example") * .region("sfo2") * .acl("public-read") * .build()); * * // Create a DigitalOcean managed Let's Encrypt Certificate * var cert = new Certificate("cert", CertificateArgs.builder() + * .name("cdn-cert") * .type("lets_encrypt") * .domains("static.example.com") * .build()); diff --git a/sdk/java/src/main/java/com/pulumi/digitalocean/Certificate.java b/sdk/java/src/main/java/com/pulumi/digitalocean/Certificate.java index 45b41cf9..8caa6778 100644 --- a/sdk/java/src/main/java/com/pulumi/digitalocean/Certificate.java +++ b/sdk/java/src/main/java/com/pulumi/digitalocean/Certificate.java @@ -51,10 +51,17 @@ * * public static void stack(Context ctx) { * var cert = new Certificate("cert", CertificateArgs.builder() + * .name("custom-example") * .type("custom") - * .privateKey(Files.readString(Paths.get("/Users/myuser/certs/privkey.pem"))) - * .leafCertificate(Files.readString(Paths.get("/Users/myuser/certs/cert.pem"))) - * .certificateChain(Files.readString(Paths.get("/Users/myuser/certs/fullchain.pem"))) + * .privateKey(StdFunctions.file(FileArgs.builder() + * .input("/Users/myuser/certs/privkey.pem") + * .build()).result()) + * .leafCertificate(StdFunctions.file(FileArgs.builder() + * .input("/Users/myuser/certs/cert.pem") + * .build()).result()) + * .certificateChain(StdFunctions.file(FileArgs.builder() + * .input("/Users/myuser/certs/fullchain.pem") + * .build()).result()) * .build()); * * } @@ -89,8 +96,9 @@ * * public static void stack(Context ctx) { * var cert = new Certificate("cert", CertificateArgs.builder() - * .domains("example.com") + * .name("le-example") * .type("lets_encrypt") + * .domains("example.com") * .build()); * * } @@ -131,12 +139,14 @@ * * public static void stack(Context ctx) { * var cert = new Certificate("cert", CertificateArgs.builder() + * .name("le-example") * .type("lets_encrypt") * .domains("example.com") * .build()); * * // Create a new Load Balancer with TLS termination * var public_ = new LoadBalancer("public", LoadBalancerArgs.builder() + * .name("secure-loadbalancer-1") * .region("nyc3") * .dropletTag("backend") * .forwardingRules(LoadBalancerForwardingRuleArgs.builder() diff --git a/sdk/java/src/main/java/com/pulumi/digitalocean/ContainerRegistry.java b/sdk/java/src/main/java/com/pulumi/digitalocean/ContainerRegistry.java index a7ed8f94..581fb780 100644 --- a/sdk/java/src/main/java/com/pulumi/digitalocean/ContainerRegistry.java +++ b/sdk/java/src/main/java/com/pulumi/digitalocean/ContainerRegistry.java @@ -45,6 +45,7 @@ * public static void stack(Context ctx) { * // Create a new container registry * var foobar = new ContainerRegistry("foobar", ContainerRegistryArgs.builder() + * .name("foobar") * .subscriptionTierSlug("starter") * .build()); * diff --git a/sdk/java/src/main/java/com/pulumi/digitalocean/ContainerRegistryDockerCredentials.java b/sdk/java/src/main/java/com/pulumi/digitalocean/ContainerRegistryDockerCredentials.java index 3fa14081..2e671134 100644 --- a/sdk/java/src/main/java/com/pulumi/digitalocean/ContainerRegistryDockerCredentials.java +++ b/sdk/java/src/main/java/com/pulumi/digitalocean/ContainerRegistryDockerCredentials.java @@ -90,7 +90,7 @@ * } * * public static void stack(Context ctx) { - * final var exampleContainerRegistry = DigitaloceanFunctions.getContainerRegistry(GetContainerRegistryArgs.builder() + * final var example = DigitaloceanFunctions.getContainerRegistry(GetContainerRegistryArgs.builder() * .name("example") * .build()); * @@ -104,6 +104,61 @@ * * <!--End PulumiCodeChooser --> * + * ### Kubernetes Example + * + * Combined with the Kubernetes Provider's `kubernetes_secret` resource, you can + * access the registry from inside your cluster: + * + * <!--Start PulumiCodeChooser --> + *
+ * {@code
+ * package generated_program;
+ * 
+ * import com.pulumi.Context;
+ * import com.pulumi.Pulumi;
+ * import com.pulumi.core.Output;
+ * import com.pulumi.digitalocean.ContainerRegistryDockerCredentials;
+ * import com.pulumi.digitalocean.ContainerRegistryDockerCredentialsArgs;
+ * import com.pulumi.digitalocean.DigitaloceanFunctions;
+ * import com.pulumi.digitalocean.inputs.GetKubernetesClusterArgs;
+ * import com.pulumi.kubernetes.core_v1.Secret;
+ * import com.pulumi.kubernetes.core_v1.SecretArgs;
+ * import com.pulumi.kubernetes.meta_v1.inputs.ObjectMetaArgs;
+ * import java.util.List;
+ * import java.util.ArrayList;
+ * import java.util.Map;
+ * import java.io.File;
+ * import java.nio.file.Files;
+ * import java.nio.file.Paths;
+ * 
+ * public class App {
+ *     public static void main(String[] args) {
+ *         Pulumi.run(App::stack);
+ *     }
+ * 
+ *     public static void stack(Context ctx) {
+ *         var exampleContainerRegistryDockerCredentials = new ContainerRegistryDockerCredentials("exampleContainerRegistryDockerCredentials", ContainerRegistryDockerCredentialsArgs.builder()        
+ *             .registryName("example")
+ *             .build());
+ * 
+ *         final var example = DigitaloceanFunctions.getKubernetesCluster(GetKubernetesClusterArgs.builder()
+ *             .name("prod-cluster-01")
+ *             .build());
+ * 
+ *         var exampleSecret = new Secret("exampleSecret", SecretArgs.builder()        
+ *             .metadata(ObjectMetaArgs.builder()
+ *                 .name("docker-cfg")
+ *                 .build())
+ *             .data(Map.of(".dockerconfigjson", exampleContainerRegistryDockerCredentials.dockerCredentials()))
+ *             .type("kubernetes.io/dockerconfigjson")
+ *             .build());
+ * 
+ *     }
+ * }
+ * }
+ * 
+ * <!--End PulumiCodeChooser --> + * */ @ResourceType(type="digitalocean:index/containerRegistryDockerCredentials:ContainerRegistryDockerCredentials") public class ContainerRegistryDockerCredentials extends com.pulumi.resources.CustomResource { diff --git a/sdk/java/src/main/java/com/pulumi/digitalocean/CustomImage.java b/sdk/java/src/main/java/com/pulumi/digitalocean/CustomImage.java index 664d4f39..bfe4d4e0 100644 --- a/sdk/java/src/main/java/com/pulumi/digitalocean/CustomImage.java +++ b/sdk/java/src/main/java/com/pulumi/digitalocean/CustomImage.java @@ -59,12 +59,14 @@ * * public static void stack(Context ctx) { * var flatcar = new CustomImage("flatcar", CustomImageArgs.builder() + * .name("flatcar") * .url("https://stable.release.flatcar-linux.net/amd64-usr/2605.7.0/flatcar_production_digitalocean_image.bin.bz2") * .regions("nyc3") * .build()); * * var example = new Droplet("example", DropletArgs.builder() * .image(flatcar.id()) + * .name("example-01") * .region("nyc3") * .size("s-1vcpu-1gb") * .sshKeys(12345) diff --git a/sdk/java/src/main/java/com/pulumi/digitalocean/DatabaseCluster.java b/sdk/java/src/main/java/com/pulumi/digitalocean/DatabaseCluster.java index 51813a50..473cdd4c 100644 --- a/sdk/java/src/main/java/com/pulumi/digitalocean/DatabaseCluster.java +++ b/sdk/java/src/main/java/com/pulumi/digitalocean/DatabaseCluster.java @@ -48,11 +48,12 @@ * * public static void stack(Context ctx) { * var postgres_example = new DatabaseCluster("postgres-example", DatabaseClusterArgs.builder() + * .name("example-postgres-cluster") * .engine("pg") - * .nodeCount(1) - * .region("nyc1") - * .size("db-s-1vcpu-1gb") * .version("15") + * .size("db-s-1vcpu-1gb") + * .region("nyc1") + * .nodeCount(1) * .build()); * * } @@ -86,11 +87,12 @@ * * public static void stack(Context ctx) { * var mysql_example = new DatabaseCluster("mysql-example", DatabaseClusterArgs.builder() + * .name("example-mysql-cluster") * .engine("mysql") - * .nodeCount(1) - * .region("nyc1") - * .size("db-s-1vcpu-1gb") * .version("8") + * .size("db-s-1vcpu-1gb") + * .region("nyc1") + * .nodeCount(1) * .build()); * * } @@ -124,11 +126,12 @@ * * public static void stack(Context ctx) { * var redis_example = new DatabaseCluster("redis-example", DatabaseClusterArgs.builder() + * .name("example-redis-cluster") * .engine("redis") - * .nodeCount(1) - * .region("nyc1") - * .size("db-s-1vcpu-1gb") * .version("7") + * .size("db-s-1vcpu-1gb") + * .region("nyc1") + * .nodeCount(1) * .build()); * * } @@ -162,11 +165,12 @@ * * public static void stack(Context ctx) { * var kafka_example = new DatabaseCluster("kafka-example", DatabaseClusterArgs.builder() + * .name("example-kafka-cluster") * .engine("kafka") - * .nodeCount(3) - * .region("nyc1") - * .size("db-s-2vcpu-2gb") * .version("3.5") + * .size("db-s-2vcpu-2gb") + * .region("nyc1") + * .nodeCount(3) * .build()); * * } @@ -200,11 +204,12 @@ * * public static void stack(Context ctx) { * var mongodb_example = new DatabaseCluster("mongodb-example", DatabaseClusterArgs.builder() + * .name("example-mongo-cluster") * .engine("mongodb") - * .nodeCount(1) - * .region("nyc3") - * .size("db-s-1vcpu-1gb") * .version("6") + * .size("db-s-1vcpu-1gb") + * .region("nyc3") + * .nodeCount(1) * .build()); * * } @@ -241,6 +246,7 @@ * * public static void stack(Context ctx) { * var doby = new DatabaseCluster("doby", DatabaseClusterArgs.builder() + * .name("dobydb") * .engine("pg") * .version("15") * .size("db-s-1vcpu-2gb") @@ -250,6 +256,7 @@ * .build()); * * var dobyBackup = new DatabaseCluster("dobyBackup", DatabaseClusterArgs.builder() + * .name("dobydupe") * .engine("pg") * .version("15") * .size("db-s-1vcpu-2gb") diff --git a/sdk/java/src/main/java/com/pulumi/digitalocean/DatabaseConnectionPool.java b/sdk/java/src/main/java/com/pulumi/digitalocean/DatabaseConnectionPool.java index fb4cf622..2a898a0a 100644 --- a/sdk/java/src/main/java/com/pulumi/digitalocean/DatabaseConnectionPool.java +++ b/sdk/java/src/main/java/com/pulumi/digitalocean/DatabaseConnectionPool.java @@ -48,6 +48,7 @@ * * public static void stack(Context ctx) { * var postgres_example = new DatabaseCluster("postgres-example", DatabaseClusterArgs.builder() + * .name("example-postgres-cluster") * .engine("pg") * .version("15") * .size("db-s-1vcpu-1gb") @@ -57,6 +58,7 @@ * * var pool_01 = new DatabaseConnectionPool("pool-01", DatabaseConnectionPoolArgs.builder() * .clusterId(postgres_example.id()) + * .name("pool-01") * .mode("transaction") * .size(20) * .dbName("defaultdb") diff --git a/sdk/java/src/main/java/com/pulumi/digitalocean/DatabaseDb.java b/sdk/java/src/main/java/com/pulumi/digitalocean/DatabaseDb.java index e4b860d2..47ad36be 100644 --- a/sdk/java/src/main/java/com/pulumi/digitalocean/DatabaseDb.java +++ b/sdk/java/src/main/java/com/pulumi/digitalocean/DatabaseDb.java @@ -45,6 +45,7 @@ * * public static void stack(Context ctx) { * var postgres_example = new DatabaseCluster("postgres-example", DatabaseClusterArgs.builder() + * .name("example-postgres-cluster") * .engine("pg") * .version("15") * .size("db-s-1vcpu-1gb") @@ -54,6 +55,7 @@ * * var database_example = new DatabaseDb("database-example", DatabaseDbArgs.builder() * .clusterId(postgres_example.id()) + * .name("foobar") * .build()); * * } diff --git a/sdk/java/src/main/java/com/pulumi/digitalocean/DatabaseFirewall.java b/sdk/java/src/main/java/com/pulumi/digitalocean/DatabaseFirewall.java index 888e2391..c8bfa88d 100644 --- a/sdk/java/src/main/java/com/pulumi/digitalocean/DatabaseFirewall.java +++ b/sdk/java/src/main/java/com/pulumi/digitalocean/DatabaseFirewall.java @@ -51,6 +51,7 @@ * * public static void stack(Context ctx) { * var postgres_example = new DatabaseCluster("postgres-example", DatabaseClusterArgs.builder() + * .name("example-postgres-cluster") * .engine("pg") * .version("15") * .size("db-s-1vcpu-1gb") @@ -108,12 +109,14 @@ * * public static void stack(Context ctx) { * var web = new Droplet("web", DropletArgs.builder() + * .name("web-01") * .size("s-1vcpu-1gb") * .image("ubuntu-22-04-x64") * .region("nyc3") * .build()); * * var postgres_example = new DatabaseCluster("postgres-example", DatabaseClusterArgs.builder() + * .name("example-postgres-cluster") * .engine("pg") * .version("15") * .size("db-s-1vcpu-1gb") @@ -166,6 +169,7 @@ * * public static void stack(Context ctx) { * var postgres_example = new DatabaseCluster("postgres-example", DatabaseClusterArgs.builder() + * .name("example-postgres-cluster") * .engine("pg") * .version("15") * .size("db-s-1vcpu-1gb") @@ -175,6 +179,7 @@ * * var replica_example = new DatabaseReplica("replica-example", DatabaseReplicaArgs.builder() * .clusterId(postgres_example.id()) + * .name("replica-example") * .size("db-s-1vcpu-1gb") * .region("nyc1") * .build()); diff --git a/sdk/java/src/main/java/com/pulumi/digitalocean/DatabaseKafkaTopic.java b/sdk/java/src/main/java/com/pulumi/digitalocean/DatabaseKafkaTopic.java index a2c55612..f9596453 100644 --- a/sdk/java/src/main/java/com/pulumi/digitalocean/DatabaseKafkaTopic.java +++ b/sdk/java/src/main/java/com/pulumi/digitalocean/DatabaseKafkaTopic.java @@ -24,75 +24,6 @@ * * ### Create a new Kafka topic * <!--Start PulumiCodeChooser --> - *
- * {@code
- * package generated_program;
- * 
- * import com.pulumi.Context;
- * import com.pulumi.Pulumi;
- * import com.pulumi.core.Output;
- * import com.pulumi.digitalocean.DatabaseCluster;
- * import com.pulumi.digitalocean.DatabaseClusterArgs;
- * import com.pulumi.digitalocean.DatabaseKafkaTopic;
- * import com.pulumi.digitalocean.DatabaseKafkaTopicArgs;
- * import com.pulumi.digitalocean.inputs.DatabaseKafkaTopicConfigArgs;
- * import java.util.List;
- * import java.util.ArrayList;
- * import java.util.Map;
- * import java.io.File;
- * import java.nio.file.Files;
- * import java.nio.file.Paths;
- * 
- * public class App {
- *     public static void main(String[] args) {
- *         Pulumi.run(App::stack);
- *     }
- * 
- *     public static void stack(Context ctx) {
- *         var kafka_example = new DatabaseCluster("kafka-example", DatabaseClusterArgs.builder()        
- *             .engine("kafka")
- *             .version("3.5")
- *             .size("db-s-2vcpu-2gb")
- *             .region("nyc1")
- *             .nodeCount(3)
- *             .tags("production")
- *             .build());
- * 
- *         var topic_01 = new DatabaseKafkaTopic("topic-01", DatabaseKafkaTopicArgs.builder()        
- *             .clusterId(kafka_example.id())
- *             .partitionCount(3)
- *             .replicationFactor(2)
- *             .configs(DatabaseKafkaTopicConfigArgs.builder()
- *                 .cleanupPolicy("compact")
- *                 .compressionType("uncompressed")
- *                 .deleteRetentionMs(14000)
- *                 .fileDeleteDelayMs(170000)
- *                 .flushMessages(92233)
- *                 .flushMs(92233720368)
- *                 .indexIntervalBytes(40962)
- *                 .maxCompactionLagMs(9223372036854775807)
- *                 .maxMessageBytes(1048588)
- *                 .messageDownConversionEnable(true)
- *                 .messageFormatVersion("3.0-IV1")
- *                 .messageTimestampDifferenceMaxMs(9223372036854775807)
- *                 .messageTimestampType("log_append_time")
- *                 .minCleanableDirtyRatio(0.5)
- *                 .minCompactionLagMs(20000)
- *                 .minInsyncReplicas(2)
- *                 .preallocate(false)
- *                 .retentionBytes("TODO: GenUnaryOpExpression")
- *                 .retentionMs("TODO: GenUnaryOpExpression")
- *                 .segmentBytes(209715200)
- *                 .segmentIndexBytes(10485760)
- *                 .segmentJitterMs(0)
- *                 .segmentMs(604800000)
- *                 .build())
- *             .build());
- * 
- *     }
- * }
- * }
- * 
* <!--End PulumiCodeChooser --> * * ## Import diff --git a/sdk/java/src/main/java/com/pulumi/digitalocean/DatabaseMysqlConfig.java b/sdk/java/src/main/java/com/pulumi/digitalocean/DatabaseMysqlConfig.java index 3b3923ab..6d32a915 100644 --- a/sdk/java/src/main/java/com/pulumi/digitalocean/DatabaseMysqlConfig.java +++ b/sdk/java/src/main/java/com/pulumi/digitalocean/DatabaseMysqlConfig.java @@ -50,6 +50,7 @@ * * public static void stack(Context ctx) { * var exampleDatabaseCluster = new DatabaseCluster("exampleDatabaseCluster", DatabaseClusterArgs.builder() + * .name("example-mysql-cluster") * .engine("mysql") * .version("8") * .size("db-s-1vcpu-1gb") @@ -57,7 +58,7 @@ * .nodeCount(1) * .build()); * - * var exampleDatabaseMysqlConfig = new DatabaseMysqlConfig("exampleDatabaseMysqlConfig", DatabaseMysqlConfigArgs.builder() + * var example = new DatabaseMysqlConfig("example", DatabaseMysqlConfigArgs.builder() * .clusterId(exampleDatabaseCluster.id()) * .connectTimeout(10) * .defaultTimeZone("UTC") diff --git a/sdk/java/src/main/java/com/pulumi/digitalocean/DatabasePostgresqlConfig.java b/sdk/java/src/main/java/com/pulumi/digitalocean/DatabasePostgresqlConfig.java index 4ea6fe51..4312ed23 100644 --- a/sdk/java/src/main/java/com/pulumi/digitalocean/DatabasePostgresqlConfig.java +++ b/sdk/java/src/main/java/com/pulumi/digitalocean/DatabasePostgresqlConfig.java @@ -53,6 +53,7 @@ * * public static void stack(Context ctx) { * var exampleDatabaseCluster = new DatabaseCluster("exampleDatabaseCluster", DatabaseClusterArgs.builder() + * .name("example-postgresql-cluster") * .engine("pg") * .version("15") * .size("db-s-1vcpu-1gb") @@ -60,7 +61,7 @@ * .nodeCount(1) * .build()); * - * var exampleDatabasePostgresqlConfig = new DatabasePostgresqlConfig("exampleDatabasePostgresqlConfig", DatabasePostgresqlConfigArgs.builder() + * var example = new DatabasePostgresqlConfig("example", DatabasePostgresqlConfigArgs.builder() * .clusterId(exampleDatabaseCluster.id()) * .timezone("UTC") * .workMem(16) diff --git a/sdk/java/src/main/java/com/pulumi/digitalocean/DatabaseRedisConfig.java b/sdk/java/src/main/java/com/pulumi/digitalocean/DatabaseRedisConfig.java index d94f4969..aa450f9a 100644 --- a/sdk/java/src/main/java/com/pulumi/digitalocean/DatabaseRedisConfig.java +++ b/sdk/java/src/main/java/com/pulumi/digitalocean/DatabaseRedisConfig.java @@ -49,6 +49,7 @@ * * public static void stack(Context ctx) { * var exampleDatabaseCluster = new DatabaseCluster("exampleDatabaseCluster", DatabaseClusterArgs.builder() + * .name("example-redis-cluster") * .engine("redis") * .version("7") * .size("db-s-1vcpu-1gb") @@ -56,7 +57,7 @@ * .nodeCount(1) * .build()); * - * var exampleDatabaseRedisConfig = new DatabaseRedisConfig("exampleDatabaseRedisConfig", DatabaseRedisConfigArgs.builder() + * var example = new DatabaseRedisConfig("example", DatabaseRedisConfigArgs.builder() * .clusterId(exampleDatabaseCluster.id()) * .maxmemoryPolicy("allkeys-lru") * .notifyKeyspaceEvents("KEA") diff --git a/sdk/java/src/main/java/com/pulumi/digitalocean/DatabaseReplica.java b/sdk/java/src/main/java/com/pulumi/digitalocean/DatabaseReplica.java index dc4bdae1..7f4cf330 100644 --- a/sdk/java/src/main/java/com/pulumi/digitalocean/DatabaseReplica.java +++ b/sdk/java/src/main/java/com/pulumi/digitalocean/DatabaseReplica.java @@ -51,6 +51,7 @@ * * public static void stack(Context ctx) { * var postgres_example = new DatabaseCluster("postgres-example", DatabaseClusterArgs.builder() + * .name("example-postgres-cluster") * .engine("pg") * .version("15") * .size("db-s-1vcpu-1gb") @@ -60,11 +61,12 @@ * * var replica_example = new DatabaseReplica("replica-example", DatabaseReplicaArgs.builder() * .clusterId(postgres_example.id()) + * .name("replica-example") * .size("db-s-1vcpu-1gb") * .region("nyc1") * .build()); * - * ctx.export("uUID", replica_example.uuid()); + * ctx.export("UUID", replica_example.uuid()); * // Create firewall rule for database replica * var example_fw = new DatabaseFirewall("example-fw", DatabaseFirewallArgs.builder() * .clusterId(replica_example.uuid()) diff --git a/sdk/java/src/main/java/com/pulumi/digitalocean/DatabaseUser.java b/sdk/java/src/main/java/com/pulumi/digitalocean/DatabaseUser.java index fb1432e2..af89e63b 100644 --- a/sdk/java/src/main/java/com/pulumi/digitalocean/DatabaseUser.java +++ b/sdk/java/src/main/java/com/pulumi/digitalocean/DatabaseUser.java @@ -50,6 +50,7 @@ * * public static void stack(Context ctx) { * var postgres_example = new DatabaseCluster("postgres-example", DatabaseClusterArgs.builder() + * .name("example-postgres-cluster") * .engine("pg") * .version("15") * .size("db-s-1vcpu-1gb") @@ -59,6 +60,7 @@ * * var user_example = new DatabaseUser("user-example", DatabaseUserArgs.builder() * .clusterId(postgres_example.id()) + * .name("foobar") * .build()); * * } @@ -96,6 +98,7 @@ * * public static void stack(Context ctx) { * var postgres_example = new DatabaseCluster("postgres-example", DatabaseClusterArgs.builder() + * .name("example-postgres-cluster") * .engine("pg") * .version("15") * .size("db-s-1vcpu-1gb") @@ -105,12 +108,14 @@ * * var replica_example = new DatabaseReplica("replica-example", DatabaseReplicaArgs.builder() * .clusterId(postgres_example.id()) + * .name("replica-example") * .size("db-s-1vcpu-1gb") * .region("nyc1") * .build()); * * var user_example = new DatabaseUser("user-example", DatabaseUserArgs.builder() * .clusterId(replica_example.uuid()) + * .name("foobar") * .build()); * * } @@ -149,6 +154,7 @@ * * public static void stack(Context ctx) { * var kafka_example = new DatabaseCluster("kafka-example", DatabaseClusterArgs.builder() + * .name("example-kafka-cluster") * .engine("kafka") * .version("3.5") * .size("db-s-2vcpu-2gb") @@ -157,11 +163,13 @@ * .build()); * * var foobarTopic = new DatabaseKafkaTopic("foobarTopic", DatabaseKafkaTopicArgs.builder() - * .clusterId(digitalocean_database_cluster.foobar().id()) + * .clusterId(foobar.id()) + * .name("topic-1") * .build()); * * var foobarUser = new DatabaseUser("foobarUser", DatabaseUserArgs.builder() - * .clusterId(digitalocean_database_cluster.foobar().id()) + * .clusterId(foobar.id()) + * .name("example-user") * .settings(DatabaseUserSettingArgs.builder() * .acls( * DatabaseUserSettingAclArgs.builder() diff --git a/sdk/java/src/main/java/com/pulumi/digitalocean/DigitaloceanFunctions.java b/sdk/java/src/main/java/com/pulumi/digitalocean/DigitaloceanFunctions.java index f6a38d49..238257e2 100644 --- a/sdk/java/src/main/java/com/pulumi/digitalocean/DigitaloceanFunctions.java +++ b/sdk/java/src/main/java/com/pulumi/digitalocean/DigitaloceanFunctions.java @@ -2133,8 +2133,8 @@ public static CompletableFuture getDomainPlain(GetDomainPlainAr * final var examples = DigitaloceanFunctions.getDomains(GetDomainsArgs.builder() * .filters(GetDomainsFilterArgs.builder() * .key("name") - * .matchBy("re") * .values("example\\.com$") + * .matchBy("re") * .build()) * .build()); * @@ -2189,8 +2189,8 @@ public static Output getDomains() { * final var examples = DigitaloceanFunctions.getDomains(GetDomainsArgs.builder() * .filters(GetDomainsFilterArgs.builder() * .key("name") - * .matchBy("re") * .values("example\\.com$") + * .matchBy("re") * .build()) * .build()); * @@ -2245,8 +2245,8 @@ public static CompletableFuture getDomainsPlain() { * final var examples = DigitaloceanFunctions.getDomains(GetDomainsArgs.builder() * .filters(GetDomainsFilterArgs.builder() * .key("name") - * .matchBy("re") * .values("example\\.com$") + * .matchBy("re") * .build()) * .build()); * @@ -2301,8 +2301,8 @@ public static Output getDomains(GetDomainsArgs args) { * final var examples = DigitaloceanFunctions.getDomains(GetDomainsArgs.builder() * .filters(GetDomainsFilterArgs.builder() * .key("name") - * .matchBy("re") * .values("example\\.com$") + * .matchBy("re") * .build()) * .build()); * @@ -2357,8 +2357,8 @@ public static CompletableFuture getDomainsPlain(GetDomainsPlai * final var examples = DigitaloceanFunctions.getDomains(GetDomainsArgs.builder() * .filters(GetDomainsFilterArgs.builder() * .key("name") - * .matchBy("re") * .values("example\\.com$") + * .matchBy("re") * .build()) * .build()); * @@ -2413,8 +2413,8 @@ public static Output getDomains(GetDomainsArgs args, InvokeOpt * final var examples = DigitaloceanFunctions.getDomains(GetDomainsArgs.builder() * .filters(GetDomainsFilterArgs.builder() * .key("name") - * .matchBy("re") * .values("example\\.com$") + * .matchBy("re") * .build()) * .build()); * @@ -2536,7 +2536,7 @@ public static CompletableFuture getDomainsPlain(GetDomainsPlai * * public static void stack(Context ctx) { * final var example = DigitaloceanFunctions.getDroplet(GetDropletArgs.builder() - * .id(digitalocean_kubernetes_cluster.example().node_pool()[0].nodes()[0].droplet_id()) + * .id(exampleDigitaloceanKubernetesCluster.nodePool()[0].nodes()[0].dropletId()) * .build()); * * } @@ -2657,7 +2657,7 @@ public static Output getDroplet() { * * public static void stack(Context ctx) { * final var example = DigitaloceanFunctions.getDroplet(GetDropletArgs.builder() - * .id(digitalocean_kubernetes_cluster.example().node_pool()[0].nodes()[0].droplet_id()) + * .id(exampleDigitaloceanKubernetesCluster.nodePool()[0].nodes()[0].dropletId()) * .build()); * * } @@ -2778,7 +2778,7 @@ public static CompletableFuture getDropletPlain() { * * public static void stack(Context ctx) { * final var example = DigitaloceanFunctions.getDroplet(GetDropletArgs.builder() - * .id(digitalocean_kubernetes_cluster.example().node_pool()[0].nodes()[0].droplet_id()) + * .id(exampleDigitaloceanKubernetesCluster.nodePool()[0].nodes()[0].dropletId()) * .build()); * * } @@ -2899,7 +2899,7 @@ public static Output getDroplet(GetDropletArgs args) { * * public static void stack(Context ctx) { * final var example = DigitaloceanFunctions.getDroplet(GetDropletArgs.builder() - * .id(digitalocean_kubernetes_cluster.example().node_pool()[0].nodes()[0].droplet_id()) + * .id(exampleDigitaloceanKubernetesCluster.nodePool()[0].nodes()[0].dropletId()) * .build()); * * } @@ -3020,7 +3020,7 @@ public static CompletableFuture getDropletPlain(GetDropletPlai * * public static void stack(Context ctx) { * final var example = DigitaloceanFunctions.getDroplet(GetDropletArgs.builder() - * .id(digitalocean_kubernetes_cluster.example().node_pool()[0].nodes()[0].droplet_id()) + * .id(exampleDigitaloceanKubernetesCluster.nodePool()[0].nodes()[0].dropletId()) * .build()); * * } @@ -3141,7 +3141,7 @@ public static Output getDroplet(GetDropletArgs args, InvokeOpt * * public static void stack(Context ctx) { * final var example = DigitaloceanFunctions.getDroplet(GetDropletArgs.builder() - * .id(digitalocean_kubernetes_cluster.example().node_pool()[0].nodes()[0].droplet_id()) + * .id(exampleDigitaloceanKubernetesCluster.nodePool()[0].nodes()[0].dropletId()) * .build()); * * } @@ -3187,9 +3187,9 @@ public static CompletableFuture getDropletPlain(GetDropletPlai * * public static void stack(Context ctx) { * final var web-snapshot = DigitaloceanFunctions.getDropletSnapshot(GetDropletSnapshotArgs.builder() - * .mostRecent(true) * .nameRegex("^web") * .region("nyc3") + * .mostRecent(true) * .build()); * * } @@ -3233,6 +3233,7 @@ public static CompletableFuture getDropletPlain(GetDropletPlai * * var from_snapshot = new Droplet("from-snapshot", DropletArgs.builder() * .image(web_snapshot.id()) + * .name("web-02") * .region("nyc3") * .size("s-2vcpu-4gb") * .build()); @@ -3280,9 +3281,9 @@ public static Output getDropletSnapshot() { * * public static void stack(Context ctx) { * final var web-snapshot = DigitaloceanFunctions.getDropletSnapshot(GetDropletSnapshotArgs.builder() - * .mostRecent(true) * .nameRegex("^web") * .region("nyc3") + * .mostRecent(true) * .build()); * * } @@ -3326,6 +3327,7 @@ public static Output getDropletSnapshot() { * * var from_snapshot = new Droplet("from-snapshot", DropletArgs.builder() * .image(web_snapshot.id()) + * .name("web-02") * .region("nyc3") * .size("s-2vcpu-4gb") * .build()); @@ -3373,9 +3375,9 @@ public static CompletableFuture getDropletSnapshotPlai * * public static void stack(Context ctx) { * final var web-snapshot = DigitaloceanFunctions.getDropletSnapshot(GetDropletSnapshotArgs.builder() - * .mostRecent(true) * .nameRegex("^web") * .region("nyc3") + * .mostRecent(true) * .build()); * * } @@ -3419,6 +3421,7 @@ public static CompletableFuture getDropletSnapshotPlai * * var from_snapshot = new Droplet("from-snapshot", DropletArgs.builder() * .image(web_snapshot.id()) + * .name("web-02") * .region("nyc3") * .size("s-2vcpu-4gb") * .build()); @@ -3466,9 +3469,9 @@ public static Output getDropletSnapshot(GetDropletSnap * * public static void stack(Context ctx) { * final var web-snapshot = DigitaloceanFunctions.getDropletSnapshot(GetDropletSnapshotArgs.builder() - * .mostRecent(true) * .nameRegex("^web") * .region("nyc3") + * .mostRecent(true) * .build()); * * } @@ -3512,6 +3515,7 @@ public static Output getDropletSnapshot(GetDropletSnap * * var from_snapshot = new Droplet("from-snapshot", DropletArgs.builder() * .image(web_snapshot.id()) + * .name("web-02") * .region("nyc3") * .size("s-2vcpu-4gb") * .build()); @@ -3559,9 +3563,9 @@ public static CompletableFuture getDropletSnapshotPlai * * public static void stack(Context ctx) { * final var web-snapshot = DigitaloceanFunctions.getDropletSnapshot(GetDropletSnapshotArgs.builder() - * .mostRecent(true) * .nameRegex("^web") * .region("nyc3") + * .mostRecent(true) * .build()); * * } @@ -3605,6 +3609,7 @@ public static CompletableFuture getDropletSnapshotPlai * * var from_snapshot = new Droplet("from-snapshot", DropletArgs.builder() * .image(web_snapshot.id()) + * .name("web-02") * .region("nyc3") * .size("s-2vcpu-4gb") * .build()); @@ -3652,9 +3657,9 @@ public static Output getDropletSnapshot(GetDropletSnap * * public static void stack(Context ctx) { * final var web-snapshot = DigitaloceanFunctions.getDropletSnapshot(GetDropletSnapshotArgs.builder() - * .mostRecent(true) * .nameRegex("^web") * .region("nyc3") + * .mostRecent(true) * .build()); * * } @@ -3698,6 +3703,7 @@ public static Output getDropletSnapshot(GetDropletSnap * * var from_snapshot = new Droplet("from-snapshot", DropletArgs.builder() * .image(web_snapshot.id()) + * .name("web-02") * .region("nyc3") * .size("s-2vcpu-4gb") * .build()); @@ -3800,8 +3806,8 @@ public static CompletableFuture getDropletSnapshotPlai * .values("true") * .build()) * .sorts(GetDropletsSortArgs.builder() - * .direction("desc") * .key("created_at") + * .direction("desc") * .build()) * .build()); * @@ -3903,8 +3909,8 @@ public static Output getDroplets() { * .values("true") * .build()) * .sorts(GetDropletsSortArgs.builder() - * .direction("desc") * .key("created_at") + * .direction("desc") * .build()) * .build()); * @@ -4006,8 +4012,8 @@ public static CompletableFuture getDropletsPlain() { * .values("true") * .build()) * .sorts(GetDropletsSortArgs.builder() - * .direction("desc") * .key("created_at") + * .direction("desc") * .build()) * .build()); * @@ -4109,8 +4115,8 @@ public static Output getDroplets(GetDropletsArgs args) { * .values("true") * .build()) * .sorts(GetDropletsSortArgs.builder() - * .direction("desc") * .key("created_at") + * .direction("desc") * .build()) * .build()); * @@ -4212,8 +4218,8 @@ public static CompletableFuture getDropletsPlain(GetDropletsP * .values("true") * .build()) * .sorts(GetDropletsSortArgs.builder() - * .direction("desc") * .key("created_at") + * .direction("desc") * .build()) * .build()); * @@ -4315,8 +4321,8 @@ public static Output getDroplets(GetDropletsArgs args, Invoke * .values("true") * .build()) * .sorts(GetDropletsSortArgs.builder() - * .direction("desc") * .key("created_at") + * .direction("desc") * .build()) * .build()); * @@ -4798,12 +4804,13 @@ public static CompletableFuture getFloatingIpPlain(GetFloat * } * * public static void stack(Context ctx) { - * final var exampleImage = DigitaloceanFunctions.getImage(GetImageArgs.builder() + * final var example = DigitaloceanFunctions.getImage(GetImageArgs.builder() * .name("example-1.0.0") * .build()); * * var exampleDroplet = new Droplet("exampleDroplet", DropletArgs.builder() - * .image(exampleImage.applyValue(getImageResult -> getImageResult.id())) + * .image(example.applyValue(getImageResult -> getImageResult.id())) + * .name("example-1") * .region("nyc2") * .size("s-1vcpu-1gb") * .build()); @@ -4925,12 +4932,13 @@ public static Output getImage() { * } * * public static void stack(Context ctx) { - * final var exampleImage = DigitaloceanFunctions.getImage(GetImageArgs.builder() + * final var example = DigitaloceanFunctions.getImage(GetImageArgs.builder() * .name("example-1.0.0") * .build()); * * var exampleDroplet = new Droplet("exampleDroplet", DropletArgs.builder() - * .image(exampleImage.applyValue(getImageResult -> getImageResult.id())) + * .image(example.applyValue(getImageResult -> getImageResult.id())) + * .name("example-1") * .region("nyc2") * .size("s-1vcpu-1gb") * .build()); @@ -5052,12 +5060,13 @@ public static CompletableFuture getImagePlain() { * } * * public static void stack(Context ctx) { - * final var exampleImage = DigitaloceanFunctions.getImage(GetImageArgs.builder() + * final var example = DigitaloceanFunctions.getImage(GetImageArgs.builder() * .name("example-1.0.0") * .build()); * * var exampleDroplet = new Droplet("exampleDroplet", DropletArgs.builder() - * .image(exampleImage.applyValue(getImageResult -> getImageResult.id())) + * .image(example.applyValue(getImageResult -> getImageResult.id())) + * .name("example-1") * .region("nyc2") * .size("s-1vcpu-1gb") * .build()); @@ -5179,12 +5188,13 @@ public static Output getImage(GetImageArgs args) { * } * * public static void stack(Context ctx) { - * final var exampleImage = DigitaloceanFunctions.getImage(GetImageArgs.builder() + * final var example = DigitaloceanFunctions.getImage(GetImageArgs.builder() * .name("example-1.0.0") * .build()); * * var exampleDroplet = new Droplet("exampleDroplet", DropletArgs.builder() - * .image(exampleImage.applyValue(getImageResult -> getImageResult.id())) + * .image(example.applyValue(getImageResult -> getImageResult.id())) + * .name("example-1") * .region("nyc2") * .size("s-1vcpu-1gb") * .build()); @@ -5306,12 +5316,13 @@ public static CompletableFuture getImagePlain(GetImagePlainArgs * } * * public static void stack(Context ctx) { - * final var exampleImage = DigitaloceanFunctions.getImage(GetImageArgs.builder() + * final var example = DigitaloceanFunctions.getImage(GetImageArgs.builder() * .name("example-1.0.0") * .build()); * * var exampleDroplet = new Droplet("exampleDroplet", DropletArgs.builder() - * .image(exampleImage.applyValue(getImageResult -> getImageResult.id())) + * .image(example.applyValue(getImageResult -> getImageResult.id())) + * .name("example-1") * .region("nyc2") * .size("s-1vcpu-1gb") * .build()); @@ -5433,12 +5444,13 @@ public static Output getImage(GetImageArgs args, InvokeOptions o * } * * public static void stack(Context ctx) { - * final var exampleImage = DigitaloceanFunctions.getImage(GetImageArgs.builder() + * final var example = DigitaloceanFunctions.getImage(GetImageArgs.builder() * .name("example-1.0.0") * .build()); * * var exampleDroplet = new Droplet("exampleDroplet", DropletArgs.builder() - * .image(exampleImage.applyValue(getImageResult -> getImageResult.id())) + * .image(example.applyValue(getImageResult -> getImageResult.id())) + * .name("example-1") * .region("nyc2") * .size("s-1vcpu-1gb") * .build()); @@ -5577,8 +5589,8 @@ public static CompletableFuture getImagePlain(GetImagePlainArgs * .values("nyc3") * .build()) * .sorts(GetImagesSortArgs.builder() - * .direction("desc") * .key("created") + * .direction("desc") * .build()) * .build()); * @@ -5681,8 +5693,8 @@ public static Output getImages() { * .values("nyc3") * .build()) * .sorts(GetImagesSortArgs.builder() - * .direction("desc") * .key("created") + * .direction("desc") * .build()) * .build()); * @@ -5785,8 +5797,8 @@ public static CompletableFuture getImagesPlain() { * .values("nyc3") * .build()) * .sorts(GetImagesSortArgs.builder() - * .direction("desc") * .key("created") + * .direction("desc") * .build()) * .build()); * @@ -5889,8 +5901,8 @@ public static Output getImages(GetImagesArgs args) { * .values("nyc3") * .build()) * .sorts(GetImagesSortArgs.builder() - * .direction("desc") * .key("created") + * .direction("desc") * .build()) * .build()); * @@ -5993,8 +6005,8 @@ public static CompletableFuture getImagesPlain(GetImagesPlainAr * .values("nyc3") * .build()) * .sorts(GetImagesSortArgs.builder() - * .direction("desc") * .key("created") + * .direction("desc") * .build()) * .build()); * @@ -6097,8 +6109,8 @@ public static Output getImages(GetImagesArgs args, InvokeOption * .values("nyc3") * .build()) * .sorts(GetImagesSortArgs.builder() - * .direction("desc") * .key("created") + * .direction("desc") * .build()) * .build()); * @@ -6115,6 +6127,41 @@ public static CompletableFuture getImagesPlain(GetImagesPlainAr /** * Retrieves information about a DigitalOcean Kubernetes cluster for use in other resources. This data source provides all of the cluster's properties as configured on your DigitalOcean account. This is useful if the cluster in question is not managed by the provider. * + * ## Example Usage + * + * <!--Start PulumiCodeChooser --> + *
+     * {@code
+     * package generated_program;
+     * 
+     * import com.pulumi.Context;
+     * import com.pulumi.Pulumi;
+     * import com.pulumi.core.Output;
+     * import com.pulumi.digitalocean.DigitaloceanFunctions;
+     * import com.pulumi.digitalocean.inputs.GetKubernetesClusterArgs;
+     * import java.util.List;
+     * import java.util.ArrayList;
+     * import java.util.Map;
+     * import java.io.File;
+     * import java.nio.file.Files;
+     * import java.nio.file.Paths;
+     * 
+     * public class App {
+     *     public static void main(String[] args) {
+     *         Pulumi.run(App::stack);
+     *     }
+     * 
+     *     public static void stack(Context ctx) {
+     *         final var example = DigitaloceanFunctions.getKubernetesCluster(GetKubernetesClusterArgs.builder()
+     *             .name("prod-cluster-01")
+     *             .build());
+     * 
+     *     }
+     * }
+     * }
+     * 
+ * <!--End PulumiCodeChooser --> + * */ public static Output getKubernetesCluster(GetKubernetesClusterArgs args) { return getKubernetesCluster(args, InvokeOptions.Empty); @@ -6122,6 +6169,41 @@ public static Output getKubernetesCluster(GetKuberne /** * Retrieves information about a DigitalOcean Kubernetes cluster for use in other resources. This data source provides all of the cluster's properties as configured on your DigitalOcean account. This is useful if the cluster in question is not managed by the provider. * + * ## Example Usage + * + * <!--Start PulumiCodeChooser --> + *
+     * {@code
+     * package generated_program;
+     * 
+     * import com.pulumi.Context;
+     * import com.pulumi.Pulumi;
+     * import com.pulumi.core.Output;
+     * import com.pulumi.digitalocean.DigitaloceanFunctions;
+     * import com.pulumi.digitalocean.inputs.GetKubernetesClusterArgs;
+     * import java.util.List;
+     * import java.util.ArrayList;
+     * import java.util.Map;
+     * import java.io.File;
+     * import java.nio.file.Files;
+     * import java.nio.file.Paths;
+     * 
+     * public class App {
+     *     public static void main(String[] args) {
+     *         Pulumi.run(App::stack);
+     *     }
+     * 
+     *     public static void stack(Context ctx) {
+     *         final var example = DigitaloceanFunctions.getKubernetesCluster(GetKubernetesClusterArgs.builder()
+     *             .name("prod-cluster-01")
+     *             .build());
+     * 
+     *     }
+     * }
+     * }
+     * 
+ * <!--End PulumiCodeChooser --> + * */ public static CompletableFuture getKubernetesClusterPlain(GetKubernetesClusterPlainArgs args) { return getKubernetesClusterPlain(args, InvokeOptions.Empty); @@ -6129,6 +6211,41 @@ public static CompletableFuture getKubernetesCluster /** * Retrieves information about a DigitalOcean Kubernetes cluster for use in other resources. This data source provides all of the cluster's properties as configured on your DigitalOcean account. This is useful if the cluster in question is not managed by the provider. * + * ## Example Usage + * + * <!--Start PulumiCodeChooser --> + *
+     * {@code
+     * package generated_program;
+     * 
+     * import com.pulumi.Context;
+     * import com.pulumi.Pulumi;
+     * import com.pulumi.core.Output;
+     * import com.pulumi.digitalocean.DigitaloceanFunctions;
+     * import com.pulumi.digitalocean.inputs.GetKubernetesClusterArgs;
+     * import java.util.List;
+     * import java.util.ArrayList;
+     * import java.util.Map;
+     * import java.io.File;
+     * import java.nio.file.Files;
+     * import java.nio.file.Paths;
+     * 
+     * public class App {
+     *     public static void main(String[] args) {
+     *         Pulumi.run(App::stack);
+     *     }
+     * 
+     *     public static void stack(Context ctx) {
+     *         final var example = DigitaloceanFunctions.getKubernetesCluster(GetKubernetesClusterArgs.builder()
+     *             .name("prod-cluster-01")
+     *             .build());
+     * 
+     *     }
+     * }
+     * }
+     * 
+ * <!--End PulumiCodeChooser --> + * */ public static Output getKubernetesCluster(GetKubernetesClusterArgs args, InvokeOptions options) { return Deployment.getInstance().invoke("digitalocean:index/getKubernetesCluster:getKubernetesCluster", TypeShape.of(GetKubernetesClusterResult.class), args, Utilities.withVersion(options)); @@ -6136,6 +6253,41 @@ public static Output getKubernetesCluster(GetKuberne /** * Retrieves information about a DigitalOcean Kubernetes cluster for use in other resources. This data source provides all of the cluster's properties as configured on your DigitalOcean account. This is useful if the cluster in question is not managed by the provider. * + * ## Example Usage + * + * <!--Start PulumiCodeChooser --> + *
+     * {@code
+     * package generated_program;
+     * 
+     * import com.pulumi.Context;
+     * import com.pulumi.Pulumi;
+     * import com.pulumi.core.Output;
+     * import com.pulumi.digitalocean.DigitaloceanFunctions;
+     * import com.pulumi.digitalocean.inputs.GetKubernetesClusterArgs;
+     * import java.util.List;
+     * import java.util.ArrayList;
+     * import java.util.Map;
+     * import java.io.File;
+     * import java.nio.file.Files;
+     * import java.nio.file.Paths;
+     * 
+     * public class App {
+     *     public static void main(String[] args) {
+     *         Pulumi.run(App::stack);
+     *     }
+     * 
+     *     public static void stack(Context ctx) {
+     *         final var example = DigitaloceanFunctions.getKubernetesCluster(GetKubernetesClusterArgs.builder()
+     *             .name("prod-cluster-01")
+     *             .build());
+     * 
+     *     }
+     * }
+     * }
+     * 
+ * <!--End PulumiCodeChooser --> + * */ public static CompletableFuture getKubernetesClusterPlain(GetKubernetesClusterPlainArgs args, InvokeOptions options) { return Deployment.getInstance().invokeAsync("digitalocean:index/getKubernetesCluster:getKubernetesCluster", TypeShape.of(GetKubernetesClusterResult.class), args, Utilities.withVersion(options)); @@ -6210,6 +6362,7 @@ public static CompletableFuture getKubernetesCluster * final var example = DigitaloceanFunctions.getKubernetesVersions(); * * var example_cluster = new KubernetesCluster("example-cluster", KubernetesClusterArgs.builder() + * .name("example-cluster") * .region("lon1") * .version(example.applyValue(getKubernetesVersionsResult -> getKubernetesVersionsResult.latestVersion())) * .nodePool(KubernetesClusterNodePoolArgs.builder() @@ -6258,6 +6411,7 @@ public static CompletableFuture getKubernetesCluster * .build()); * * var example_cluster = new KubernetesCluster("example-cluster", KubernetesClusterArgs.builder() + * .name("example-cluster") * .region("lon1") * .version(example.applyValue(getKubernetesVersionsResult -> getKubernetesVersionsResult.latestVersion())) * .nodePool(KubernetesClusterNodePoolArgs.builder() @@ -6347,6 +6501,7 @@ public static Output getKubernetesVersions() { * final var example = DigitaloceanFunctions.getKubernetesVersions(); * * var example_cluster = new KubernetesCluster("example-cluster", KubernetesClusterArgs.builder() + * .name("example-cluster") * .region("lon1") * .version(example.applyValue(getKubernetesVersionsResult -> getKubernetesVersionsResult.latestVersion())) * .nodePool(KubernetesClusterNodePoolArgs.builder() @@ -6395,6 +6550,7 @@ public static Output getKubernetesVersions() { * .build()); * * var example_cluster = new KubernetesCluster("example-cluster", KubernetesClusterArgs.builder() + * .name("example-cluster") * .region("lon1") * .version(example.applyValue(getKubernetesVersionsResult -> getKubernetesVersionsResult.latestVersion())) * .nodePool(KubernetesClusterNodePoolArgs.builder() @@ -6484,6 +6640,7 @@ public static CompletableFuture getKubernetesVersio * final var example = DigitaloceanFunctions.getKubernetesVersions(); * * var example_cluster = new KubernetesCluster("example-cluster", KubernetesClusterArgs.builder() + * .name("example-cluster") * .region("lon1") * .version(example.applyValue(getKubernetesVersionsResult -> getKubernetesVersionsResult.latestVersion())) * .nodePool(KubernetesClusterNodePoolArgs.builder() @@ -6532,6 +6689,7 @@ public static CompletableFuture getKubernetesVersio * .build()); * * var example_cluster = new KubernetesCluster("example-cluster", KubernetesClusterArgs.builder() + * .name("example-cluster") * .region("lon1") * .version(example.applyValue(getKubernetesVersionsResult -> getKubernetesVersionsResult.latestVersion())) * .nodePool(KubernetesClusterNodePoolArgs.builder() @@ -6621,6 +6779,7 @@ public static Output getKubernetesVersions(GetKuber * final var example = DigitaloceanFunctions.getKubernetesVersions(); * * var example_cluster = new KubernetesCluster("example-cluster", KubernetesClusterArgs.builder() + * .name("example-cluster") * .region("lon1") * .version(example.applyValue(getKubernetesVersionsResult -> getKubernetesVersionsResult.latestVersion())) * .nodePool(KubernetesClusterNodePoolArgs.builder() @@ -6669,6 +6828,7 @@ public static Output getKubernetesVersions(GetKuber * .build()); * * var example_cluster = new KubernetesCluster("example-cluster", KubernetesClusterArgs.builder() + * .name("example-cluster") * .region("lon1") * .version(example.applyValue(getKubernetesVersionsResult -> getKubernetesVersionsResult.latestVersion())) * .nodePool(KubernetesClusterNodePoolArgs.builder() @@ -6758,6 +6918,7 @@ public static CompletableFuture getKubernetesVersio * final var example = DigitaloceanFunctions.getKubernetesVersions(); * * var example_cluster = new KubernetesCluster("example-cluster", KubernetesClusterArgs.builder() + * .name("example-cluster") * .region("lon1") * .version(example.applyValue(getKubernetesVersionsResult -> getKubernetesVersionsResult.latestVersion())) * .nodePool(KubernetesClusterNodePoolArgs.builder() @@ -6806,6 +6967,7 @@ public static CompletableFuture getKubernetesVersio * .build()); * * var example_cluster = new KubernetesCluster("example-cluster", KubernetesClusterArgs.builder() + * .name("example-cluster") * .region("lon1") * .version(example.applyValue(getKubernetesVersionsResult -> getKubernetesVersionsResult.latestVersion())) * .nodePool(KubernetesClusterNodePoolArgs.builder() @@ -6895,6 +7057,7 @@ public static Output getKubernetesVersions(GetKuber * final var example = DigitaloceanFunctions.getKubernetesVersions(); * * var example_cluster = new KubernetesCluster("example-cluster", KubernetesClusterArgs.builder() + * .name("example-cluster") * .region("lon1") * .version(example.applyValue(getKubernetesVersionsResult -> getKubernetesVersionsResult.latestVersion())) * .nodePool(KubernetesClusterNodePoolArgs.builder() @@ -6943,6 +7106,7 @@ public static Output getKubernetesVersions(GetKuber * .build()); * * var example_cluster = new KubernetesCluster("example-cluster", KubernetesClusterArgs.builder() + * .name("example-cluster") * .region("lon1") * .version(example.applyValue(getKubernetesVersionsResult -> getKubernetesVersionsResult.latestVersion())) * .nodePool(KubernetesClusterNodePoolArgs.builder() @@ -7829,8 +7993,8 @@ public static CompletableFuture getProjectPlain(GetProjectPlai * .values("false") * .build()) * .sorts(GetProjectsSortArgs.builder() - * .direction("asc") * .key("name") + * .direction("asc") * .build()) * .build()); * @@ -7931,8 +8095,8 @@ public static Output getProjects() { * .values("false") * .build()) * .sorts(GetProjectsSortArgs.builder() - * .direction("asc") * .key("name") + * .direction("asc") * .build()) * .build()); * @@ -8033,8 +8197,8 @@ public static CompletableFuture getProjectsPlain() { * .values("false") * .build()) * .sorts(GetProjectsSortArgs.builder() - * .direction("asc") * .key("name") + * .direction("asc") * .build()) * .build()); * @@ -8135,8 +8299,8 @@ public static Output getProjects(GetProjectsArgs args) { * .values("false") * .build()) * .sorts(GetProjectsSortArgs.builder() - * .direction("asc") * .key("name") + * .direction("asc") * .build()) * .build()); * @@ -8237,8 +8401,8 @@ public static CompletableFuture getProjectsPlain(GetProjectsP * .values("false") * .build()) * .sorts(GetProjectsSortArgs.builder() - * .direction("asc") * .key("name") + * .direction("asc") * .build()) * .build()); * @@ -8339,8 +8503,8 @@ public static Output getProjects(GetProjectsArgs args, Invoke * .values("false") * .build()) * .sorts(GetProjectsSortArgs.builder() - * .direction("asc") * .key("name") + * .direction("asc") * .build()) * .build()); * @@ -8566,6 +8730,51 @@ public static CompletableFuture getRecordPlain(GetRecordPlainAr * Retrieve information about all DNS records within a domain, with the ability to filter and sort the results. * If no filters are specified, all records will be returned. * + * ## Example Usage + * + * Get data for all MX records in a domain: + * + * <!--Start PulumiCodeChooser --> + *
+     * {@code
+     * package generated_program;
+     * 
+     * import com.pulumi.Context;
+     * import com.pulumi.Pulumi;
+     * import com.pulumi.core.Output;
+     * import com.pulumi.digitalocean.DigitaloceanFunctions;
+     * import com.pulumi.digitalocean.inputs.GetRecordsArgs;
+     * import java.util.List;
+     * import java.util.ArrayList;
+     * import java.util.Map;
+     * import java.io.File;
+     * import java.nio.file.Files;
+     * import java.nio.file.Paths;
+     * 
+     * public class App {
+     *     public static void main(String[] args) {
+     *         Pulumi.run(App::stack);
+     *     }
+     * 
+     *     public static void stack(Context ctx) {
+     *         final var example = DigitaloceanFunctions.getRecords(GetRecordsArgs.builder()
+     *             .domain("example.com")
+     *             .filters(GetRecordsFilterArgs.builder()
+     *                 .key("type")
+     *                 .values("MX")
+     *                 .build())
+     *             .build());
+     * 
+     *         ctx.export("mailServers", StdFunctions.join(JoinArgs.builder()
+     *             .separator(",")
+     *             .input(example.applyValue(getRecordsResult -> getRecordsResult.records()).stream().map(element -> element.value()).collect(toList()))
+     *             .build()).result());
+     *     }
+     * }
+     * }
+     * 
+ * <!--End PulumiCodeChooser --> + * */ public static Output getRecords(GetRecordsArgs args) { return getRecords(args, InvokeOptions.Empty); @@ -8574,6 +8783,51 @@ public static Output getRecords(GetRecordsArgs args) { * Retrieve information about all DNS records within a domain, with the ability to filter and sort the results. * If no filters are specified, all records will be returned. * + * ## Example Usage + * + * Get data for all MX records in a domain: + * + * <!--Start PulumiCodeChooser --> + *
+     * {@code
+     * package generated_program;
+     * 
+     * import com.pulumi.Context;
+     * import com.pulumi.Pulumi;
+     * import com.pulumi.core.Output;
+     * import com.pulumi.digitalocean.DigitaloceanFunctions;
+     * import com.pulumi.digitalocean.inputs.GetRecordsArgs;
+     * import java.util.List;
+     * import java.util.ArrayList;
+     * import java.util.Map;
+     * import java.io.File;
+     * import java.nio.file.Files;
+     * import java.nio.file.Paths;
+     * 
+     * public class App {
+     *     public static void main(String[] args) {
+     *         Pulumi.run(App::stack);
+     *     }
+     * 
+     *     public static void stack(Context ctx) {
+     *         final var example = DigitaloceanFunctions.getRecords(GetRecordsArgs.builder()
+     *             .domain("example.com")
+     *             .filters(GetRecordsFilterArgs.builder()
+     *                 .key("type")
+     *                 .values("MX")
+     *                 .build())
+     *             .build());
+     * 
+     *         ctx.export("mailServers", StdFunctions.join(JoinArgs.builder()
+     *             .separator(",")
+     *             .input(example.applyValue(getRecordsResult -> getRecordsResult.records()).stream().map(element -> element.value()).collect(toList()))
+     *             .build()).result());
+     *     }
+     * }
+     * }
+     * 
+ * <!--End PulumiCodeChooser --> + * */ public static CompletableFuture getRecordsPlain(GetRecordsPlainArgs args) { return getRecordsPlain(args, InvokeOptions.Empty); @@ -8582,6 +8836,51 @@ public static CompletableFuture getRecordsPlain(GetRecordsPlai * Retrieve information about all DNS records within a domain, with the ability to filter and sort the results. * If no filters are specified, all records will be returned. * + * ## Example Usage + * + * Get data for all MX records in a domain: + * + * <!--Start PulumiCodeChooser --> + *
+     * {@code
+     * package generated_program;
+     * 
+     * import com.pulumi.Context;
+     * import com.pulumi.Pulumi;
+     * import com.pulumi.core.Output;
+     * import com.pulumi.digitalocean.DigitaloceanFunctions;
+     * import com.pulumi.digitalocean.inputs.GetRecordsArgs;
+     * import java.util.List;
+     * import java.util.ArrayList;
+     * import java.util.Map;
+     * import java.io.File;
+     * import java.nio.file.Files;
+     * import java.nio.file.Paths;
+     * 
+     * public class App {
+     *     public static void main(String[] args) {
+     *         Pulumi.run(App::stack);
+     *     }
+     * 
+     *     public static void stack(Context ctx) {
+     *         final var example = DigitaloceanFunctions.getRecords(GetRecordsArgs.builder()
+     *             .domain("example.com")
+     *             .filters(GetRecordsFilterArgs.builder()
+     *                 .key("type")
+     *                 .values("MX")
+     *                 .build())
+     *             .build());
+     * 
+     *         ctx.export("mailServers", StdFunctions.join(JoinArgs.builder()
+     *             .separator(",")
+     *             .input(example.applyValue(getRecordsResult -> getRecordsResult.records()).stream().map(element -> element.value()).collect(toList()))
+     *             .build()).result());
+     *     }
+     * }
+     * }
+     * 
+ * <!--End PulumiCodeChooser --> + * */ public static Output getRecords(GetRecordsArgs args, InvokeOptions options) { return Deployment.getInstance().invoke("digitalocean:index/getRecords:getRecords", TypeShape.of(GetRecordsResult.class), args, Utilities.withVersion(options)); @@ -8590,6 +8889,51 @@ public static Output getRecords(GetRecordsArgs args, InvokeOpt * Retrieve information about all DNS records within a domain, with the ability to filter and sort the results. * If no filters are specified, all records will be returned. * + * ## Example Usage + * + * Get data for all MX records in a domain: + * + * <!--Start PulumiCodeChooser --> + *
+     * {@code
+     * package generated_program;
+     * 
+     * import com.pulumi.Context;
+     * import com.pulumi.Pulumi;
+     * import com.pulumi.core.Output;
+     * import com.pulumi.digitalocean.DigitaloceanFunctions;
+     * import com.pulumi.digitalocean.inputs.GetRecordsArgs;
+     * import java.util.List;
+     * import java.util.ArrayList;
+     * import java.util.Map;
+     * import java.io.File;
+     * import java.nio.file.Files;
+     * import java.nio.file.Paths;
+     * 
+     * public class App {
+     *     public static void main(String[] args) {
+     *         Pulumi.run(App::stack);
+     *     }
+     * 
+     *     public static void stack(Context ctx) {
+     *         final var example = DigitaloceanFunctions.getRecords(GetRecordsArgs.builder()
+     *             .domain("example.com")
+     *             .filters(GetRecordsFilterArgs.builder()
+     *                 .key("type")
+     *                 .values("MX")
+     *                 .build())
+     *             .build());
+     * 
+     *         ctx.export("mailServers", StdFunctions.join(JoinArgs.builder()
+     *             .separator(",")
+     *             .input(example.applyValue(getRecordsResult -> getRecordsResult.records()).stream().map(element -> element.value()).collect(toList()))
+     *             .build()).result());
+     *     }
+     * }
+     * }
+     * 
+ * <!--End PulumiCodeChooser --> + * */ public static CompletableFuture getRecordsPlain(GetRecordsPlainArgs args, InvokeOptions options) { return Deployment.getInstance().invokeAsync("digitalocean:index/getRecords:getRecords", TypeShape.of(GetRecordsResult.class), args, Utilities.withVersion(options)); @@ -8855,8 +9199,8 @@ public static CompletableFuture getRegionPlain(GetRegionPlainAr * .values("private_networking") * .build()) * .sorts(GetRegionsSortArgs.builder() - * .direction("desc") * .key("name") + * .direction("desc") * .build()) * .build()); * @@ -8955,8 +9299,8 @@ public static Output getRegions() { * .values("private_networking") * .build()) * .sorts(GetRegionsSortArgs.builder() - * .direction("desc") * .key("name") + * .direction("desc") * .build()) * .build()); * @@ -9055,8 +9399,8 @@ public static CompletableFuture getRegionsPlain() { * .values("private_networking") * .build()) * .sorts(GetRegionsSortArgs.builder() - * .direction("desc") * .key("name") + * .direction("desc") * .build()) * .build()); * @@ -9155,8 +9499,8 @@ public static Output getRegions(GetRegionsArgs args) { * .values("private_networking") * .build()) * .sorts(GetRegionsSortArgs.builder() - * .direction("desc") * .key("name") + * .direction("desc") * .build()) * .build()); * @@ -9255,8 +9599,8 @@ public static CompletableFuture getRegionsPlain(GetRegionsPlai * .values("private_networking") * .build()) * .sorts(GetRegionsSortArgs.builder() - * .direction("desc") * .key("name") + * .direction("desc") * .build()) * .build()); * @@ -9355,8 +9699,8 @@ public static Output getRegions(GetRegionsArgs args, InvokeOpt * .values("private_networking") * .build()) * .sorts(GetRegionsSortArgs.builder() - * .direction("desc") * .key("name") + * .direction("desc") * .build()) * .build()); * @@ -9838,6 +10182,7 @@ public static CompletableFuture getSpacesBucketPlain(GetS * * var web = new Droplet("web", DropletArgs.builder() * .image("ubuntu-18-04-x64") + * .name("web-1") * .region("nyc2") * .size("s-1vcpu-1gb") * .userData(bootstrapScript.applyValue(getSpacesBucketObjectResult -> getSpacesBucketObjectResult.body())) @@ -9899,6 +10244,7 @@ public static Output getSpacesBucketObject(GetSpace * * var web = new Droplet("web", DropletArgs.builder() * .image("ubuntu-18-04-x64") + * .name("web-1") * .region("nyc2") * .size("s-1vcpu-1gb") * .userData(bootstrapScript.applyValue(getSpacesBucketObjectResult -> getSpacesBucketObjectResult.body())) @@ -9960,6 +10306,7 @@ public static CompletableFuture getSpacesBucketObje * * var web = new Droplet("web", DropletArgs.builder() * .image("ubuntu-18-04-x64") + * .name("web-1") * .region("nyc2") * .size("s-1vcpu-1gb") * .userData(bootstrapScript.applyValue(getSpacesBucketObjectResult -> getSpacesBucketObjectResult.body())) @@ -10021,6 +10368,7 @@ public static Output getSpacesBucketObject(GetSpace * * var web = new Droplet("web", DropletArgs.builder() * .image("ubuntu-18-04-x64") + * .name("web-1") * .region("nyc2") * .size("s-1vcpu-1gb") * .userData(bootstrapScript.applyValue(getSpacesBucketObjectResult -> getSpacesBucketObjectResult.body())) @@ -10151,8 +10499,8 @@ public static CompletableFuture getSpacesBucketObj * .values("nyc3") * .build()) * .sorts(GetSpacesBucketsSortArgs.builder() - * .direction("desc") * .key("name") + * .direction("desc") * .build()) * .build()); * @@ -10245,8 +10593,8 @@ public static Output getSpacesBuckets() { * .values("nyc3") * .build()) * .sorts(GetSpacesBucketsSortArgs.builder() - * .direction("desc") * .key("name") + * .direction("desc") * .build()) * .build()); * @@ -10339,8 +10687,8 @@ public static CompletableFuture getSpacesBucketsPlain() * .values("nyc3") * .build()) * .sorts(GetSpacesBucketsSortArgs.builder() - * .direction("desc") * .key("name") + * .direction("desc") * .build()) * .build()); * @@ -10433,8 +10781,8 @@ public static Output getSpacesBuckets(GetSpacesBucketsAr * .values("nyc3") * .build()) * .sorts(GetSpacesBucketsSortArgs.builder() - * .direction("desc") * .key("name") + * .direction("desc") * .build()) * .build()); * @@ -10527,8 +10875,8 @@ public static CompletableFuture getSpacesBucketsPlain(Ge * .values("nyc3") * .build()) * .sorts(GetSpacesBucketsSortArgs.builder() - * .direction("desc") * .key("name") + * .direction("desc") * .build()) * .build()); * @@ -10621,8 +10969,8 @@ public static Output getSpacesBuckets(GetSpacesBucketsAr * .values("nyc3") * .build()) * .sorts(GetSpacesBucketsSortArgs.builder() - * .direction("desc") * .key("name") + * .direction("desc") * .build()) * .build()); * @@ -10673,15 +11021,16 @@ public static CompletableFuture getSpacesBucketsPlain(Ge * } * * public static void stack(Context ctx) { - * final var exampleSshKey = DigitaloceanFunctions.getSshKey(GetSshKeyArgs.builder() + * final var example = DigitaloceanFunctions.getSshKey(GetSshKeyArgs.builder() * .name("example") * .build()); * * var exampleDroplet = new Droplet("exampleDroplet", DropletArgs.builder() * .image("ubuntu-18-04-x64") + * .name("example-1") * .region("nyc2") * .size("s-1vcpu-1gb") - * .sshKeys(exampleSshKey.applyValue(getSshKeyResult -> getSshKeyResult.id())) + * .sshKeys(example.applyValue(getSshKeyResult -> getSshKeyResult.id())) * .build()); * * } @@ -10731,15 +11080,16 @@ public static Output getSshKey(GetSshKeyArgs args) { * } * * public static void stack(Context ctx) { - * final var exampleSshKey = DigitaloceanFunctions.getSshKey(GetSshKeyArgs.builder() + * final var example = DigitaloceanFunctions.getSshKey(GetSshKeyArgs.builder() * .name("example") * .build()); * * var exampleDroplet = new Droplet("exampleDroplet", DropletArgs.builder() * .image("ubuntu-18-04-x64") + * .name("example-1") * .region("nyc2") * .size("s-1vcpu-1gb") - * .sshKeys(exampleSshKey.applyValue(getSshKeyResult -> getSshKeyResult.id())) + * .sshKeys(example.applyValue(getSshKeyResult -> getSshKeyResult.id())) * .build()); * * } @@ -10789,15 +11139,16 @@ public static CompletableFuture getSshKeyPlain(GetSshKeyPlainAr * } * * public static void stack(Context ctx) { - * final var exampleSshKey = DigitaloceanFunctions.getSshKey(GetSshKeyArgs.builder() + * final var example = DigitaloceanFunctions.getSshKey(GetSshKeyArgs.builder() * .name("example") * .build()); * * var exampleDroplet = new Droplet("exampleDroplet", DropletArgs.builder() * .image("ubuntu-18-04-x64") + * .name("example-1") * .region("nyc2") * .size("s-1vcpu-1gb") - * .sshKeys(exampleSshKey.applyValue(getSshKeyResult -> getSshKeyResult.id())) + * .sshKeys(example.applyValue(getSshKeyResult -> getSshKeyResult.id())) * .build()); * * } @@ -10847,15 +11198,16 @@ public static Output getSshKey(GetSshKeyArgs args, InvokeOption * } * * public static void stack(Context ctx) { - * final var exampleSshKey = DigitaloceanFunctions.getSshKey(GetSshKeyArgs.builder() + * final var example = DigitaloceanFunctions.getSshKey(GetSshKeyArgs.builder() * .name("example") * .build()); * * var exampleDroplet = new Droplet("exampleDroplet", DropletArgs.builder() * .image("ubuntu-18-04-x64") + * .name("example-1") * .region("nyc2") * .size("s-1vcpu-1gb") - * .sshKeys(exampleSshKey.applyValue(getSshKeyResult -> getSshKeyResult.id())) + * .sshKeys(example.applyValue(getSshKeyResult -> getSshKeyResult.id())) * .build()); * * } @@ -10906,8 +11258,8 @@ public static CompletableFuture getSshKeyPlain(GetSshKeyPlainAr * public static void stack(Context ctx) { * final var keys = DigitaloceanFunctions.getSshKeys(GetSshKeysArgs.builder() * .sorts(GetSshKeysSortArgs.builder() - * .direction("asc") * .key("name") + * .direction("asc") * .build()) * .build()); * @@ -10999,8 +11351,8 @@ public static Output getSshKeys() { * public static void stack(Context ctx) { * final var keys = DigitaloceanFunctions.getSshKeys(GetSshKeysArgs.builder() * .sorts(GetSshKeysSortArgs.builder() - * .direction("asc") * .key("name") + * .direction("asc") * .build()) * .build()); * @@ -11092,8 +11444,8 @@ public static CompletableFuture getSshKeysPlain() { * public static void stack(Context ctx) { * final var keys = DigitaloceanFunctions.getSshKeys(GetSshKeysArgs.builder() * .sorts(GetSshKeysSortArgs.builder() - * .direction("asc") * .key("name") + * .direction("asc") * .build()) * .build()); * @@ -11185,8 +11537,8 @@ public static Output getSshKeys(GetSshKeysArgs args) { * public static void stack(Context ctx) { * final var keys = DigitaloceanFunctions.getSshKeys(GetSshKeysArgs.builder() * .sorts(GetSshKeysSortArgs.builder() - * .direction("asc") * .key("name") + * .direction("asc") * .build()) * .build()); * @@ -11278,8 +11630,8 @@ public static CompletableFuture getSshKeysPlain(GetSshKeysPlai * public static void stack(Context ctx) { * final var keys = DigitaloceanFunctions.getSshKeys(GetSshKeysArgs.builder() * .sorts(GetSshKeysSortArgs.builder() - * .direction("asc") * .key("name") + * .direction("asc") * .build()) * .build()); * @@ -11371,8 +11723,8 @@ public static Output getSshKeys(GetSshKeysArgs args, InvokeOpt * public static void stack(Context ctx) { * final var keys = DigitaloceanFunctions.getSshKeys(GetSshKeysArgs.builder() * .sorts(GetSshKeysSortArgs.builder() - * .direction("asc") * .key("name") + * .direction("asc") * .build()) * .build()); * @@ -11462,15 +11814,16 @@ public static CompletableFuture getSshKeysPlain(GetSshKeysPlai * } * * public static void stack(Context ctx) { - * final var exampleTag = DigitaloceanFunctions.getTag(GetTagArgs.builder() + * final var example = DigitaloceanFunctions.getTag(GetTagArgs.builder() * .name("example") * .build()); * * var exampleDroplet = new Droplet("exampleDroplet", DropletArgs.builder() * .image("ubuntu-18-04-x64") + * .name("example-1") * .region("nyc2") * .size("s-1vcpu-1gb") - * .tags(exampleTag.applyValue(getTagResult -> getTagResult.name())) + * .tags(example.applyValue(getTagResult -> getTagResult.name())) * .build()); * * } @@ -11519,15 +11872,16 @@ public static Output getTag(GetTagArgs args) { * } * * public static void stack(Context ctx) { - * final var exampleTag = DigitaloceanFunctions.getTag(GetTagArgs.builder() + * final var example = DigitaloceanFunctions.getTag(GetTagArgs.builder() * .name("example") * .build()); * * var exampleDroplet = new Droplet("exampleDroplet", DropletArgs.builder() * .image("ubuntu-18-04-x64") + * .name("example-1") * .region("nyc2") * .size("s-1vcpu-1gb") - * .tags(exampleTag.applyValue(getTagResult -> getTagResult.name())) + * .tags(example.applyValue(getTagResult -> getTagResult.name())) * .build()); * * } @@ -11576,15 +11930,16 @@ public static CompletableFuture getTagPlain(GetTagPlainArgs args) * } * * public static void stack(Context ctx) { - * final var exampleTag = DigitaloceanFunctions.getTag(GetTagArgs.builder() + * final var example = DigitaloceanFunctions.getTag(GetTagArgs.builder() * .name("example") * .build()); * * var exampleDroplet = new Droplet("exampleDroplet", DropletArgs.builder() * .image("ubuntu-18-04-x64") + * .name("example-1") * .region("nyc2") * .size("s-1vcpu-1gb") - * .tags(exampleTag.applyValue(getTagResult -> getTagResult.name())) + * .tags(example.applyValue(getTagResult -> getTagResult.name())) * .build()); * * } @@ -11633,15 +11988,16 @@ public static Output getTag(GetTagArgs args, InvokeOptions options * } * * public static void stack(Context ctx) { - * final var exampleTag = DigitaloceanFunctions.getTag(GetTagArgs.builder() + * final var example = DigitaloceanFunctions.getTag(GetTagArgs.builder() * .name("example") * .build()); * * var exampleDroplet = new Droplet("exampleDroplet", DropletArgs.builder() * .image("ubuntu-18-04-x64") + * .name("example-1") * .region("nyc2") * .size("s-1vcpu-1gb") - * .tags(exampleTag.applyValue(getTagResult -> getTagResult.name())) + * .tags(example.applyValue(getTagResult -> getTagResult.name())) * .build()); * * } @@ -12017,12 +12373,13 @@ public static CompletableFuture getTagsPlain(GetTagsPlainArgs arg * } * * public static void stack(Context ctx) { - * final var exampleVolume = DigitaloceanFunctions.getVolume(GetVolumeArgs.builder() + * final var example = DigitaloceanFunctions.getVolume(GetVolumeArgs.builder() * .name("app-data") * .region("nyc3") * .build()); * * var exampleDroplet = new Droplet("exampleDroplet", DropletArgs.builder() + * .name("foo") * .size("s-1vcpu-1gb") * .image("ubuntu-18-04-x64") * .region("nyc3") @@ -12030,7 +12387,7 @@ public static CompletableFuture getTagsPlain(GetTagsPlainArgs arg * * var foobar = new VolumeAttachment("foobar", VolumeAttachmentArgs.builder() * .dropletId(exampleDroplet.id()) - * .volumeId(exampleVolume.applyValue(getVolumeResult -> getVolumeResult.id())) + * .volumeId(example.applyValue(getVolumeResult -> getVolumeResult.id())) * .build()); * * } @@ -12118,12 +12475,13 @@ public static Output getVolume(GetVolumeArgs args) { * } * * public static void stack(Context ctx) { - * final var exampleVolume = DigitaloceanFunctions.getVolume(GetVolumeArgs.builder() + * final var example = DigitaloceanFunctions.getVolume(GetVolumeArgs.builder() * .name("app-data") * .region("nyc3") * .build()); * * var exampleDroplet = new Droplet("exampleDroplet", DropletArgs.builder() + * .name("foo") * .size("s-1vcpu-1gb") * .image("ubuntu-18-04-x64") * .region("nyc3") @@ -12131,7 +12489,7 @@ public static Output getVolume(GetVolumeArgs args) { * * var foobar = new VolumeAttachment("foobar", VolumeAttachmentArgs.builder() * .dropletId(exampleDroplet.id()) - * .volumeId(exampleVolume.applyValue(getVolumeResult -> getVolumeResult.id())) + * .volumeId(example.applyValue(getVolumeResult -> getVolumeResult.id())) * .build()); * * } @@ -12219,12 +12577,13 @@ public static CompletableFuture getVolumePlain(GetVolumePlainAr * } * * public static void stack(Context ctx) { - * final var exampleVolume = DigitaloceanFunctions.getVolume(GetVolumeArgs.builder() + * final var example = DigitaloceanFunctions.getVolume(GetVolumeArgs.builder() * .name("app-data") * .region("nyc3") * .build()); * * var exampleDroplet = new Droplet("exampleDroplet", DropletArgs.builder() + * .name("foo") * .size("s-1vcpu-1gb") * .image("ubuntu-18-04-x64") * .region("nyc3") @@ -12232,7 +12591,7 @@ public static CompletableFuture getVolumePlain(GetVolumePlainAr * * var foobar = new VolumeAttachment("foobar", VolumeAttachmentArgs.builder() * .dropletId(exampleDroplet.id()) - * .volumeId(exampleVolume.applyValue(getVolumeResult -> getVolumeResult.id())) + * .volumeId(example.applyValue(getVolumeResult -> getVolumeResult.id())) * .build()); * * } @@ -12320,12 +12679,13 @@ public static Output getVolume(GetVolumeArgs args, InvokeOption * } * * public static void stack(Context ctx) { - * final var exampleVolume = DigitaloceanFunctions.getVolume(GetVolumeArgs.builder() + * final var example = DigitaloceanFunctions.getVolume(GetVolumeArgs.builder() * .name("app-data") * .region("nyc3") * .build()); * * var exampleDroplet = new Droplet("exampleDroplet", DropletArgs.builder() + * .name("foo") * .size("s-1vcpu-1gb") * .image("ubuntu-18-04-x64") * .region("nyc3") @@ -12333,7 +12693,7 @@ public static Output getVolume(GetVolumeArgs args, InvokeOption * * var foobar = new VolumeAttachment("foobar", VolumeAttachmentArgs.builder() * .dropletId(exampleDroplet.id()) - * .volumeId(exampleVolume.applyValue(getVolumeResult -> getVolumeResult.id())) + * .volumeId(example.applyValue(getVolumeResult -> getVolumeResult.id())) * .build()); * * } @@ -12379,9 +12739,9 @@ public static CompletableFuture getVolumePlain(GetVolumePlainAr * * public static void stack(Context ctx) { * final var snapshot = DigitaloceanFunctions.getVolumeSnapshot(GetVolumeSnapshotArgs.builder() - * .mostRecent(true) * .nameRegex("^web") * .region("nyc3") + * .mostRecent(true) * .build()); * * } @@ -12425,6 +12785,7 @@ public static CompletableFuture getVolumePlain(GetVolumePlainAr * * var foobar = new Volume("foobar", VolumeArgs.builder() * .region("nyc3") + * .name("baz") * .size(100) * .snapshotId(snapshot.applyValue(getVolumeSnapshotResult -> getVolumeSnapshotResult.id())) * .build()); @@ -12472,9 +12833,9 @@ public static Output getVolumeSnapshot() { * * public static void stack(Context ctx) { * final var snapshot = DigitaloceanFunctions.getVolumeSnapshot(GetVolumeSnapshotArgs.builder() - * .mostRecent(true) * .nameRegex("^web") * .region("nyc3") + * .mostRecent(true) * .build()); * * } @@ -12518,6 +12879,7 @@ public static Output getVolumeSnapshot() { * * var foobar = new Volume("foobar", VolumeArgs.builder() * .region("nyc3") + * .name("baz") * .size(100) * .snapshotId(snapshot.applyValue(getVolumeSnapshotResult -> getVolumeSnapshotResult.id())) * .build()); @@ -12565,9 +12927,9 @@ public static CompletableFuture getVolumeSnapshotPlain( * * public static void stack(Context ctx) { * final var snapshot = DigitaloceanFunctions.getVolumeSnapshot(GetVolumeSnapshotArgs.builder() - * .mostRecent(true) * .nameRegex("^web") * .region("nyc3") + * .mostRecent(true) * .build()); * * } @@ -12611,6 +12973,7 @@ public static CompletableFuture getVolumeSnapshotPlain( * * var foobar = new Volume("foobar", VolumeArgs.builder() * .region("nyc3") + * .name("baz") * .size(100) * .snapshotId(snapshot.applyValue(getVolumeSnapshotResult -> getVolumeSnapshotResult.id())) * .build()); @@ -12658,9 +13021,9 @@ public static Output getVolumeSnapshot(GetVolumeSnapsho * * public static void stack(Context ctx) { * final var snapshot = DigitaloceanFunctions.getVolumeSnapshot(GetVolumeSnapshotArgs.builder() - * .mostRecent(true) * .nameRegex("^web") * .region("nyc3") + * .mostRecent(true) * .build()); * * } @@ -12704,6 +13067,7 @@ public static Output getVolumeSnapshot(GetVolumeSnapsho * * var foobar = new Volume("foobar", VolumeArgs.builder() * .region("nyc3") + * .name("baz") * .size(100) * .snapshotId(snapshot.applyValue(getVolumeSnapshotResult -> getVolumeSnapshotResult.id())) * .build()); @@ -12751,9 +13115,9 @@ public static CompletableFuture getVolumeSnapshotPlain( * * public static void stack(Context ctx) { * final var snapshot = DigitaloceanFunctions.getVolumeSnapshot(GetVolumeSnapshotArgs.builder() - * .mostRecent(true) * .nameRegex("^web") * .region("nyc3") + * .mostRecent(true) * .build()); * * } @@ -12797,6 +13161,7 @@ public static CompletableFuture getVolumeSnapshotPlain( * * var foobar = new Volume("foobar", VolumeArgs.builder() * .region("nyc3") + * .name("baz") * .size(100) * .snapshotId(snapshot.applyValue(getVolumeSnapshotResult -> getVolumeSnapshotResult.id())) * .build()); @@ -12844,9 +13209,9 @@ public static Output getVolumeSnapshot(GetVolumeSnapsho * * public static void stack(Context ctx) { * final var snapshot = DigitaloceanFunctions.getVolumeSnapshot(GetVolumeSnapshotArgs.builder() - * .mostRecent(true) * .nameRegex("^web") * .region("nyc3") + * .mostRecent(true) * .build()); * * } @@ -12890,6 +13255,7 @@ public static Output getVolumeSnapshot(GetVolumeSnapsho * * var foobar = new Volume("foobar", VolumeArgs.builder() * .region("nyc3") + * .name("baz") * .size(100) * .snapshotId(snapshot.applyValue(getVolumeSnapshotResult -> getVolumeSnapshotResult.id())) * .build()); @@ -12978,15 +13344,16 @@ public static CompletableFuture getVolumeSnapshotPlain( * } * * public static void stack(Context ctx) { - * final var exampleVpc = DigitaloceanFunctions.getVpc(GetVpcArgs.builder() + * final var example = DigitaloceanFunctions.getVpc(GetVpcArgs.builder() * .name("example-network") * .build()); * * var exampleDroplet = new Droplet("exampleDroplet", DropletArgs.builder() + * .name("example-01") * .size("s-1vcpu-1gb") * .image("ubuntu-18-04-x64") * .region("nyc3") - * .vpcUuid(exampleVpc.applyValue(getVpcResult -> getVpcResult.id())) + * .vpcUuid(example.applyValue(getVpcResult -> getVpcResult.id())) * .build()); * * } @@ -13073,15 +13440,16 @@ public static Output getVpc() { * } * * public static void stack(Context ctx) { - * final var exampleVpc = DigitaloceanFunctions.getVpc(GetVpcArgs.builder() + * final var example = DigitaloceanFunctions.getVpc(GetVpcArgs.builder() * .name("example-network") * .build()); * * var exampleDroplet = new Droplet("exampleDroplet", DropletArgs.builder() + * .name("example-01") * .size("s-1vcpu-1gb") * .image("ubuntu-18-04-x64") * .region("nyc3") - * .vpcUuid(exampleVpc.applyValue(getVpcResult -> getVpcResult.id())) + * .vpcUuid(example.applyValue(getVpcResult -> getVpcResult.id())) * .build()); * * } @@ -13168,15 +13536,16 @@ public static CompletableFuture getVpcPlain() { * } * * public static void stack(Context ctx) { - * final var exampleVpc = DigitaloceanFunctions.getVpc(GetVpcArgs.builder() + * final var example = DigitaloceanFunctions.getVpc(GetVpcArgs.builder() * .name("example-network") * .build()); * * var exampleDroplet = new Droplet("exampleDroplet", DropletArgs.builder() + * .name("example-01") * .size("s-1vcpu-1gb") * .image("ubuntu-18-04-x64") * .region("nyc3") - * .vpcUuid(exampleVpc.applyValue(getVpcResult -> getVpcResult.id())) + * .vpcUuid(example.applyValue(getVpcResult -> getVpcResult.id())) * .build()); * * } @@ -13263,15 +13632,16 @@ public static Output getVpc(GetVpcArgs args) { * } * * public static void stack(Context ctx) { - * final var exampleVpc = DigitaloceanFunctions.getVpc(GetVpcArgs.builder() + * final var example = DigitaloceanFunctions.getVpc(GetVpcArgs.builder() * .name("example-network") * .build()); * * var exampleDroplet = new Droplet("exampleDroplet", DropletArgs.builder() + * .name("example-01") * .size("s-1vcpu-1gb") * .image("ubuntu-18-04-x64") * .region("nyc3") - * .vpcUuid(exampleVpc.applyValue(getVpcResult -> getVpcResult.id())) + * .vpcUuid(example.applyValue(getVpcResult -> getVpcResult.id())) * .build()); * * } @@ -13358,15 +13728,16 @@ public static CompletableFuture getVpcPlain(GetVpcPlainArgs args) * } * * public static void stack(Context ctx) { - * final var exampleVpc = DigitaloceanFunctions.getVpc(GetVpcArgs.builder() + * final var example = DigitaloceanFunctions.getVpc(GetVpcArgs.builder() * .name("example-network") * .build()); * * var exampleDroplet = new Droplet("exampleDroplet", DropletArgs.builder() + * .name("example-01") * .size("s-1vcpu-1gb") * .image("ubuntu-18-04-x64") * .region("nyc3") - * .vpcUuid(exampleVpc.applyValue(getVpcResult -> getVpcResult.id())) + * .vpcUuid(example.applyValue(getVpcResult -> getVpcResult.id())) * .build()); * * } @@ -13453,15 +13824,16 @@ public static Output getVpc(GetVpcArgs args, InvokeOptions options * } * * public static void stack(Context ctx) { - * final var exampleVpc = DigitaloceanFunctions.getVpc(GetVpcArgs.builder() + * final var example = DigitaloceanFunctions.getVpc(GetVpcArgs.builder() * .name("example-network") * .build()); * * var exampleDroplet = new Droplet("exampleDroplet", DropletArgs.builder() + * .name("example-01") * .size("s-1vcpu-1gb") * .image("ubuntu-18-04-x64") * .region("nyc3") - * .vpcUuid(exampleVpc.applyValue(getVpcResult -> getVpcResult.id())) + * .vpcUuid(example.applyValue(getVpcResult -> getVpcResult.id())) * .build()); * * } diff --git a/sdk/java/src/main/java/com/pulumi/digitalocean/DnsRecord.java b/sdk/java/src/main/java/com/pulumi/digitalocean/DnsRecord.java index ce04926d..8826b9f0 100644 --- a/sdk/java/src/main/java/com/pulumi/digitalocean/DnsRecord.java +++ b/sdk/java/src/main/java/com/pulumi/digitalocean/DnsRecord.java @@ -53,6 +53,7 @@ * var www = new DnsRecord("www", DnsRecordArgs.builder() * .domain(default_.id()) * .type("A") + * .name("www") * .value("192.168.0.11") * .build()); * @@ -60,6 +61,7 @@ * var mx = new DnsRecord("mx", DnsRecordArgs.builder() * .domain(default_.id()) * .type("MX") + * .name("{@literal @}") * .priority(10) * .value("mail.example.com.") * .build()); diff --git a/sdk/java/src/main/java/com/pulumi/digitalocean/Domain.java b/sdk/java/src/main/java/com/pulumi/digitalocean/Domain.java index f8d944de..51f42ef3 100644 --- a/sdk/java/src/main/java/com/pulumi/digitalocean/Domain.java +++ b/sdk/java/src/main/java/com/pulumi/digitalocean/Domain.java @@ -46,7 +46,7 @@ * // Create a new domain * var default_ = new Domain("default", DomainArgs.builder() * .name("example.com") - * .ipAddress(digitalocean_droplet.foo().ipv4_address()) + * .ipAddress(foo.ipv4Address()) * .build()); * * } diff --git a/sdk/java/src/main/java/com/pulumi/digitalocean/Droplet.java b/sdk/java/src/main/java/com/pulumi/digitalocean/Droplet.java index c234072f..80b3c78f 100644 --- a/sdk/java/src/main/java/com/pulumi/digitalocean/Droplet.java +++ b/sdk/java/src/main/java/com/pulumi/digitalocean/Droplet.java @@ -50,6 +50,7 @@ * // Create a new Web Droplet in the nyc2 region * var web = new Droplet("web", DropletArgs.builder() * .image("ubuntu-20-04-x64") + * .name("web-1") * .region("nyc2") * .size("s-1vcpu-1gb") * .build()); diff --git a/sdk/java/src/main/java/com/pulumi/digitalocean/DropletSnapshot.java b/sdk/java/src/main/java/com/pulumi/digitalocean/DropletSnapshot.java index 53b4529c..9ac5a145 100644 --- a/sdk/java/src/main/java/com/pulumi/digitalocean/DropletSnapshot.java +++ b/sdk/java/src/main/java/com/pulumi/digitalocean/DropletSnapshot.java @@ -47,6 +47,7 @@ * * public static void stack(Context ctx) { * var web = new Droplet("web", DropletArgs.builder() + * .name("web-01") * .size("s-1vcpu-1gb") * .image("ubuntu-22-04-x64") * .region("nyc3") @@ -54,10 +55,12 @@ * * var web_snapshot = new DropletSnapshot("web-snapshot", DropletSnapshotArgs.builder() * .dropletId(web.id()) + * .name("web-snapshot-01") * .build()); * * var from_snapshot = new Droplet("from-snapshot", DropletArgs.builder() * .image(web_snapshot.id()) + * .name("web-02") * .region("nyc3") * .size("s-2vcpu-4gb") * .build()); diff --git a/sdk/java/src/main/java/com/pulumi/digitalocean/Firewall.java b/sdk/java/src/main/java/com/pulumi/digitalocean/Firewall.java index 56f7b038..d1cd3e93 100644 --- a/sdk/java/src/main/java/com/pulumi/digitalocean/Firewall.java +++ b/sdk/java/src/main/java/com/pulumi/digitalocean/Firewall.java @@ -52,14 +52,16 @@ * } * * public static void stack(Context ctx) { - * var webDroplet = new Droplet("webDroplet", DropletArgs.builder() + * var web = new Droplet("web", DropletArgs.builder() + * .name("web-1") * .size("s-1vcpu-1gb") * .image("ubuntu-18-04-x64") * .region("nyc3") * .build()); * * var webFirewall = new Firewall("webFirewall", FirewallArgs.builder() - * .dropletIds(webDroplet.id()) + * .name("only-22-80-and-443") + * .dropletIds(web.id()) * .inboundRules( * FirewallInboundRuleArgs.builder() * .protocol("tcp") diff --git a/sdk/java/src/main/java/com/pulumi/digitalocean/FloatingIp.java b/sdk/java/src/main/java/com/pulumi/digitalocean/FloatingIp.java index 0bde6770..d4b14e92 100644 --- a/sdk/java/src/main/java/com/pulumi/digitalocean/FloatingIp.java +++ b/sdk/java/src/main/java/com/pulumi/digitalocean/FloatingIp.java @@ -49,7 +49,8 @@ * } * * public static void stack(Context ctx) { - * var foobarDroplet = new Droplet("foobarDroplet", DropletArgs.builder() + * var foobar = new Droplet("foobar", DropletArgs.builder() + * .name("baz") * .size("s-1vcpu-1gb") * .image("ubuntu-18-04-x64") * .region("sgp1") @@ -58,8 +59,8 @@ * .build()); * * var foobarFloatingIp = new FloatingIp("foobarFloatingIp", FloatingIpArgs.builder() - * .dropletId(foobarDroplet.id()) - * .region(foobarDroplet.region()) + * .dropletId(foobar.id()) + * .region(foobar.region()) * .build()); * * } diff --git a/sdk/java/src/main/java/com/pulumi/digitalocean/FloatingIpAssignment.java b/sdk/java/src/main/java/com/pulumi/digitalocean/FloatingIpAssignment.java index b9261e83..fc3f7a27 100644 --- a/sdk/java/src/main/java/com/pulumi/digitalocean/FloatingIpAssignment.java +++ b/sdk/java/src/main/java/com/pulumi/digitalocean/FloatingIpAssignment.java @@ -50,11 +50,12 @@ * } * * public static void stack(Context ctx) { - * var foobarFloatingIp = new FloatingIp("foobarFloatingIp", FloatingIpArgs.builder() + * var foobar = new FloatingIp("foobar", FloatingIpArgs.builder() * .region("sgp1") * .build()); * * var foobarDroplet = new Droplet("foobarDroplet", DropletArgs.builder() + * .name("baz") * .size("s-1vcpu-1gb") * .image("ubuntu-18-04-x64") * .region("sgp1") @@ -63,7 +64,7 @@ * .build()); * * var foobarFloatingIpAssignment = new FloatingIpAssignment("foobarFloatingIpAssignment", FloatingIpAssignmentArgs.builder() - * .ipAddress(foobarFloatingIp.ipAddress()) + * .ipAddress(foobar.ipAddress()) * .dropletId(foobarDroplet.id()) * .build()); * diff --git a/sdk/java/src/main/java/com/pulumi/digitalocean/KubernetesNodePool.java b/sdk/java/src/main/java/com/pulumi/digitalocean/KubernetesNodePool.java index 31f9d62f..e0f69c17 100644 --- a/sdk/java/src/main/java/com/pulumi/digitalocean/KubernetesNodePool.java +++ b/sdk/java/src/main/java/com/pulumi/digitalocean/KubernetesNodePool.java @@ -55,6 +55,7 @@ * * public static void stack(Context ctx) { * var foo = new KubernetesCluster("foo", KubernetesClusterArgs.builder() + * .name("foo") * .region("nyc1") * .version("1.22.8-do.1") * .nodePool(KubernetesClusterNodePoolArgs.builder() @@ -66,6 +67,7 @@ * * var bar = new KubernetesNodePool("bar", KubernetesNodePoolArgs.builder() * .clusterId(foo.id()) + * .name("backend-pool") * .size("c-2") * .nodeCount(2) * .tags("backend") @@ -115,7 +117,8 @@ * * public static void stack(Context ctx) { * var autoscale_pool_01 = new KubernetesNodePool("autoscale-pool-01", KubernetesNodePoolArgs.builder() - * .clusterId(digitalocean_kubernetes_cluster.foo().id()) + * .clusterId(foo.id()) + * .name("autoscale-pool-01") * .size("s-1vcpu-2gb") * .autoScale(true) * .minNodes(1) diff --git a/sdk/java/src/main/java/com/pulumi/digitalocean/LoadBalancer.java b/sdk/java/src/main/java/com/pulumi/digitalocean/LoadBalancer.java index 3fa0d845..33dbebdb 100644 --- a/sdk/java/src/main/java/com/pulumi/digitalocean/LoadBalancer.java +++ b/sdk/java/src/main/java/com/pulumi/digitalocean/LoadBalancer.java @@ -57,12 +57,14 @@ * * public static void stack(Context ctx) { * var web = new Droplet("web", DropletArgs.builder() + * .name("web-1") * .size("s-1vcpu-1gb") * .image("ubuntu-18-04-x64") * .region("nyc3") * .build()); * * var public_ = new LoadBalancer("public", LoadBalancerArgs.builder() + * .name("loadbalancer-1") * .region("nyc3") * .forwardingRules(LoadBalancerForwardingRuleArgs.builder() * .entryPort(80) @@ -89,68 +91,6 @@ * `Delete old certificate`. When doing so, you must also change the name of the certificate, * as there cannot be multiple certificates with the same name in an account. * - * <!--Start PulumiCodeChooser --> - *
- * {@code
- * package generated_program;
- * 
- * import com.pulumi.Context;
- * import com.pulumi.Pulumi;
- * import com.pulumi.core.Output;
- * import com.pulumi.digitalocean.Certificate;
- * import com.pulumi.digitalocean.CertificateArgs;
- * import com.pulumi.digitalocean.Droplet;
- * import com.pulumi.digitalocean.DropletArgs;
- * import com.pulumi.digitalocean.LoadBalancer;
- * import com.pulumi.digitalocean.LoadBalancerArgs;
- * import com.pulumi.digitalocean.inputs.LoadBalancerForwardingRuleArgs;
- * import com.pulumi.digitalocean.inputs.LoadBalancerHealthcheckArgs;
- * import java.util.List;
- * import java.util.ArrayList;
- * import java.util.Map;
- * import java.io.File;
- * import java.nio.file.Files;
- * import java.nio.file.Paths;
- * 
- * public class App {
- *     public static void main(String[] args) {
- *         Pulumi.run(App::stack);
- *     }
- * 
- *     public static void stack(Context ctx) {
- *         var cert = new Certificate("cert", CertificateArgs.builder()        
- *             .privateKey("file('key.pem')")
- *             .leafCertificate("file('cert.pem')")
- *             .build());
- * 
- *         var web = new Droplet("web", DropletArgs.builder()        
- *             .size("s-1vcpu-1gb")
- *             .image("ubuntu-18-04-x64")
- *             .region("nyc3")
- *             .build());
- * 
- *         var public_ = new LoadBalancer("public", LoadBalancerArgs.builder()        
- *             .region("nyc3")
- *             .forwardingRules(LoadBalancerForwardingRuleArgs.builder()
- *                 .entryPort(443)
- *                 .entryProtocol("https")
- *                 .targetPort(80)
- *                 .targetProtocol("http")
- *                 .certificateName(cert.name())
- *                 .build())
- *             .healthcheck(LoadBalancerHealthcheckArgs.builder()
- *                 .port(22)
- *                 .protocol("tcp")
- *                 .build())
- *             .dropletIds(web.id())
- *             .build());
- * 
- *     }
- * }
- * }
- * 
- * <!--End PulumiCodeChooser --> - * * ## Import * * Load Balancers can be imported using the `id`, e.g. diff --git a/sdk/java/src/main/java/com/pulumi/digitalocean/Project.java b/sdk/java/src/main/java/com/pulumi/digitalocean/Project.java index 1b36e835..fcdb088d 100644 --- a/sdk/java/src/main/java/com/pulumi/digitalocean/Project.java +++ b/sdk/java/src/main/java/com/pulumi/digitalocean/Project.java @@ -66,9 +66,10 @@ * * public static void stack(Context ctx) { * var playground = new Project("playground", ProjectArgs.builder() + * .name("playground") * .description("A project to represent development resources.") - * .environment("Development") * .purpose("Web Application") + * .environment("Development") * .build()); * * } @@ -105,12 +106,14 @@ * * public static void stack(Context ctx) { * var foobar = new Droplet("foobar", DropletArgs.builder() + * .name("example") * .size("s-1vcpu-1gb") * .image("ubuntu-22-04-x64") * .region("nyc3") * .build()); * * var playground = new Project("playground", ProjectArgs.builder() + * .name("playground") * .description("A project to represent development resources.") * .purpose("Web Application") * .environment("Development") diff --git a/sdk/java/src/main/java/com/pulumi/digitalocean/ProjectResources.java b/sdk/java/src/main/java/com/pulumi/digitalocean/ProjectResources.java index 2dc81d83..27a166bc 100644 --- a/sdk/java/src/main/java/com/pulumi/digitalocean/ProjectResources.java +++ b/sdk/java/src/main/java/com/pulumi/digitalocean/ProjectResources.java @@ -66,6 +66,7 @@ * .build()); * * var foobar = new Droplet("foobar", DropletArgs.builder() + * .name("example") * .size("s-1vcpu-1gb") * .image("ubuntu-22-04-x64") * .region("nyc3") diff --git a/sdk/java/src/main/java/com/pulumi/digitalocean/ReservedIp.java b/sdk/java/src/main/java/com/pulumi/digitalocean/ReservedIp.java index 57177b6a..65dca5c4 100644 --- a/sdk/java/src/main/java/com/pulumi/digitalocean/ReservedIp.java +++ b/sdk/java/src/main/java/com/pulumi/digitalocean/ReservedIp.java @@ -47,7 +47,8 @@ * } * * public static void stack(Context ctx) { - * var exampleDroplet = new Droplet("exampleDroplet", DropletArgs.builder() + * var example = new Droplet("example", DropletArgs.builder() + * .name("example") * .size("s-1vcpu-1gb") * .image("ubuntu-22-04-x64") * .region("nyc3") @@ -56,8 +57,8 @@ * .build()); * * var exampleReservedIp = new ReservedIp("exampleReservedIp", ReservedIpArgs.builder() - * .dropletId(exampleDroplet.id()) - * .region(exampleDroplet.region()) + * .dropletId(example.id()) + * .region(example.region()) * .build()); * * } diff --git a/sdk/java/src/main/java/com/pulumi/digitalocean/ReservedIpAssignment.java b/sdk/java/src/main/java/com/pulumi/digitalocean/ReservedIpAssignment.java index 9d1b8fe6..90f6885a 100644 --- a/sdk/java/src/main/java/com/pulumi/digitalocean/ReservedIpAssignment.java +++ b/sdk/java/src/main/java/com/pulumi/digitalocean/ReservedIpAssignment.java @@ -48,11 +48,12 @@ * } * * public static void stack(Context ctx) { - * var exampleReservedIp = new ReservedIp("exampleReservedIp", ReservedIpArgs.builder() + * var example = new ReservedIp("example", ReservedIpArgs.builder() * .region("nyc3") * .build()); * * var exampleDroplet = new Droplet("exampleDroplet", DropletArgs.builder() + * .name("baz") * .size("s-1vcpu-1gb") * .image("ubuntu-22-04-x64") * .region("nyc3") @@ -61,7 +62,7 @@ * .build()); * * var exampleReservedIpAssignment = new ReservedIpAssignment("exampleReservedIpAssignment", ReservedIpAssignmentArgs.builder() - * .ipAddress(exampleReservedIp.ipAddress()) + * .ipAddress(example.ipAddress()) * .dropletId(exampleDroplet.id()) * .build()); * diff --git a/sdk/java/src/main/java/com/pulumi/digitalocean/SpacesBucket.java b/sdk/java/src/main/java/com/pulumi/digitalocean/SpacesBucket.java index ac94da6a..920ce7e0 100644 --- a/sdk/java/src/main/java/com/pulumi/digitalocean/SpacesBucket.java +++ b/sdk/java/src/main/java/com/pulumi/digitalocean/SpacesBucket.java @@ -58,7 +58,6 @@ * public static void stack(Context ctx) { * var static_assets = new SpacesBucket("static-assets"); * - * // ... * } * } * } @@ -95,6 +94,7 @@ * * public static void stack(Context ctx) { * var foobar = new SpacesBucket("foobar", SpacesBucketArgs.builder() + * .name("foobar") * .region("nyc3") * .build()); * @@ -131,6 +131,8 @@ * * public static void stack(Context ctx) { * var foobar = new SpacesBucket("foobar", SpacesBucketArgs.builder() + * .name("foobar") + * .region("nyc3") * .corsRules( * SpacesBucketCorsRuleArgs.builder() * .allowedHeaders("*") @@ -147,7 +149,6 @@ * .allowedOrigins("https://www.example.com") * .maxAgeSeconds(3000) * .build()) - * .region("nyc3") * .build()); * * } diff --git a/sdk/java/src/main/java/com/pulumi/digitalocean/SpacesBucketCorsConfiguration.java b/sdk/java/src/main/java/com/pulumi/digitalocean/SpacesBucketCorsConfiguration.java index ab47440e..f5eab9ec 100644 --- a/sdk/java/src/main/java/com/pulumi/digitalocean/SpacesBucketCorsConfiguration.java +++ b/sdk/java/src/main/java/com/pulumi/digitalocean/SpacesBucketCorsConfiguration.java @@ -47,6 +47,7 @@ * * public static void stack(Context ctx) { * var foobar = new SpacesBucket("foobar", SpacesBucketArgs.builder() + * .name("foobar") * .region("nyc3") * .build()); * diff --git a/sdk/java/src/main/java/com/pulumi/digitalocean/SpacesBucketObject.java b/sdk/java/src/main/java/com/pulumi/digitalocean/SpacesBucketObject.java index c5d64160..3385c8f6 100644 --- a/sdk/java/src/main/java/com/pulumi/digitalocean/SpacesBucketObject.java +++ b/sdk/java/src/main/java/com/pulumi/digitalocean/SpacesBucketObject.java @@ -57,7 +57,6 @@ * public static void stack(Context ctx) { * var static_assets = new SpacesBucket("static-assets"); * - * // ... * } * } * } @@ -96,6 +95,7 @@ * * public static void stack(Context ctx) { * var foobar = new SpacesBucket("foobar", SpacesBucketArgs.builder() + * .name("foobar") * .region("nyc3") * .build()); * diff --git a/sdk/java/src/main/java/com/pulumi/digitalocean/SpacesBucketPolicy.java b/sdk/java/src/main/java/com/pulumi/digitalocean/SpacesBucketPolicy.java index 077052c1..30fb3d43 100644 --- a/sdk/java/src/main/java/com/pulumi/digitalocean/SpacesBucketPolicy.java +++ b/sdk/java/src/main/java/com/pulumi/digitalocean/SpacesBucketPolicy.java @@ -44,16 +44,17 @@ * } * * public static void stack(Context ctx) { - * var foobarSpacesBucket = new SpacesBucket("foobarSpacesBucket", SpacesBucketArgs.builder() + * var foobar = new SpacesBucket("foobar", SpacesBucketArgs.builder() + * .name("foobar") * .region("nyc3") * .build()); * * var foobarSpacesBucketPolicy = new SpacesBucketPolicy("foobarSpacesBucketPolicy", SpacesBucketPolicyArgs.builder() - * .region(foobarSpacesBucket.region()) - * .bucket(foobarSpacesBucket.name()) - * .policy(Output.tuple(foobarSpacesBucket.name(), foobarSpacesBucket.name()).applyValue(values -> { - * var foobarSpacesBucketName = values.t1; - * var foobarSpacesBucketName1 = values.t2; + * .region(foobar.region()) + * .bucket(foobar.name()) + * .policy(Output.tuple(foobar.name(), foobar.name()).applyValue(values -> { + * var foobarName = values.t1; + * var foobarName1 = values.t2; * return serializeJson( * jsonObject( * jsonProperty("Version", "2012-10-17"), @@ -63,8 +64,8 @@ * jsonProperty("Principal", "*"), * jsonProperty("Action", "s3:*"), * jsonProperty("Resource", jsonArray( - * String.format("arn:aws:s3:::%s", foobarSpacesBucketName), - * String.format("arn:aws:s3:::%s/*", foobarSpacesBucketName1) + * String.format("arn:aws:s3:::%s", foobarName), + * String.format("arn:aws:s3:::%s/*", foobarName1) * )), * jsonProperty("Condition", jsonObject( * jsonProperty("NotIpAddress", jsonObject( diff --git a/sdk/java/src/main/java/com/pulumi/digitalocean/SshKey.java b/sdk/java/src/main/java/com/pulumi/digitalocean/SshKey.java index 600582d0..a25df886 100644 --- a/sdk/java/src/main/java/com/pulumi/digitalocean/SshKey.java +++ b/sdk/java/src/main/java/com/pulumi/digitalocean/SshKey.java @@ -48,12 +48,16 @@ * public static void stack(Context ctx) { * // Create a new SSH key * var default_ = new SshKey("default", SshKeyArgs.builder() - * .publicKey(Files.readString(Paths.get("/Users/myuser/.ssh/id_rsa.pub"))) + * .name("Example") + * .publicKey(StdFunctions.file(FileArgs.builder() + * .input("/Users/myuser/.ssh/id_rsa.pub") + * .build()).result()) * .build()); * * // Create a new Droplet using the SSH key * var web = new Droplet("web", DropletArgs.builder() * .image("ubuntu-18-04-x64") + * .name("web-1") * .region("nyc3") * .size("s-1vcpu-1gb") * .sshKeys(default_.fingerprint()) diff --git a/sdk/java/src/main/java/com/pulumi/digitalocean/Tag.java b/sdk/java/src/main/java/com/pulumi/digitalocean/Tag.java index 071c3e6e..4d280cb6 100644 --- a/sdk/java/src/main/java/com/pulumi/digitalocean/Tag.java +++ b/sdk/java/src/main/java/com/pulumi/digitalocean/Tag.java @@ -31,6 +31,7 @@ * import com.pulumi.Pulumi; * import com.pulumi.core.Output; * import com.pulumi.digitalocean.Tag; + * import com.pulumi.digitalocean.TagArgs; * import com.pulumi.digitalocean.Droplet; * import com.pulumi.digitalocean.DropletArgs; * import java.util.List; @@ -47,11 +48,14 @@ * * public static void stack(Context ctx) { * // Create a new tag - * var foobar = new Tag("foobar"); + * var foobar = new Tag("foobar", TagArgs.builder() + * .name("foobar") + * .build()); * * // Create a new Droplet in nyc3 with the foobar tag * var web = new Droplet("web", DropletArgs.builder() * .image("ubuntu-18-04-x64") + * .name("web-1") * .region("nyc3") * .size("s-1vcpu-1gb") * .tags(foobar.id()) diff --git a/sdk/java/src/main/java/com/pulumi/digitalocean/Volume.java b/sdk/java/src/main/java/com/pulumi/digitalocean/Volume.java index 3a89d5c2..1419ce60 100644 --- a/sdk/java/src/main/java/com/pulumi/digitalocean/Volume.java +++ b/sdk/java/src/main/java/com/pulumi/digitalocean/Volume.java @@ -48,14 +48,16 @@ * } * * public static void stack(Context ctx) { - * var foobarVolume = new Volume("foobarVolume", VolumeArgs.builder() + * var foobar = new Volume("foobar", VolumeArgs.builder() * .region("nyc1") + * .name("baz") * .size(100) * .initialFilesystemType("ext4") * .description("an example volume") * .build()); * * var foobarDroplet = new Droplet("foobarDroplet", DropletArgs.builder() + * .name("baz") * .size("s-1vcpu-1gb") * .image("ubuntu-18-04-x64") * .region("nyc1") @@ -63,7 +65,7 @@ * * var foobarVolumeAttachment = new VolumeAttachment("foobarVolumeAttachment", VolumeAttachmentArgs.builder() * .dropletId(foobarDroplet.id()) - * .volumeId(foobarVolume.id()) + * .volumeId(foobar.id()) * .build()); * * } @@ -99,14 +101,15 @@ * } * * public static void stack(Context ctx) { - * final var foobarVolumeSnapshot = DigitaloceanFunctions.getVolumeSnapshot(GetVolumeSnapshotArgs.builder() + * final var foobar = DigitaloceanFunctions.getVolumeSnapshot(GetVolumeSnapshotArgs.builder() * .name("baz") * .build()); * * var foobarVolume = new Volume("foobarVolume", VolumeArgs.builder() * .region("lon1") - * .size(foobarVolumeSnapshot.applyValue(getVolumeSnapshotResult -> getVolumeSnapshotResult.minDiskSize())) - * .snapshotId(foobarVolumeSnapshot.applyValue(getVolumeSnapshotResult -> getVolumeSnapshotResult.id())) + * .name("foo") + * .size(foobar.applyValue(getVolumeSnapshotResult -> getVolumeSnapshotResult.minDiskSize())) + * .snapshotId(foobar.applyValue(getVolumeSnapshotResult -> getVolumeSnapshotResult.id())) * .build()); * * } diff --git a/sdk/java/src/main/java/com/pulumi/digitalocean/VolumeAttachment.java b/sdk/java/src/main/java/com/pulumi/digitalocean/VolumeAttachment.java index c4be0eb5..471ea876 100644 --- a/sdk/java/src/main/java/com/pulumi/digitalocean/VolumeAttachment.java +++ b/sdk/java/src/main/java/com/pulumi/digitalocean/VolumeAttachment.java @@ -48,14 +48,16 @@ * } * * public static void stack(Context ctx) { - * var foobarVolume = new Volume("foobarVolume", VolumeArgs.builder() + * var foobar = new Volume("foobar", VolumeArgs.builder() * .region("nyc1") + * .name("baz") * .size(100) * .initialFilesystemType("ext4") * .description("an example volume") * .build()); * * var foobarDroplet = new Droplet("foobarDroplet", DropletArgs.builder() + * .name("baz") * .size("s-1vcpu-1gb") * .image("ubuntu-18-04-x64") * .region("nyc1") @@ -63,7 +65,7 @@ * * var foobarVolumeAttachment = new VolumeAttachment("foobarVolumeAttachment", VolumeAttachmentArgs.builder() * .dropletId(foobarDroplet.id()) - * .volumeId(foobarVolume.id()) + * .volumeId(foobar.id()) * .build()); * * } diff --git a/sdk/java/src/main/java/com/pulumi/digitalocean/VolumeSnapshot.java b/sdk/java/src/main/java/com/pulumi/digitalocean/VolumeSnapshot.java index 8f354488..2d1307d2 100644 --- a/sdk/java/src/main/java/com/pulumi/digitalocean/VolumeSnapshot.java +++ b/sdk/java/src/main/java/com/pulumi/digitalocean/VolumeSnapshot.java @@ -47,14 +47,16 @@ * } * * public static void stack(Context ctx) { - * var foobarVolume = new Volume("foobarVolume", VolumeArgs.builder() + * var foobar = new Volume("foobar", VolumeArgs.builder() * .region("nyc1") + * .name("baz") * .size(100) * .description("an example volume") * .build()); * * var foobarVolumeSnapshot = new VolumeSnapshot("foobarVolumeSnapshot", VolumeSnapshotArgs.builder() - * .volumeId(foobarVolume.id()) + * .name("foo") + * .volumeId(foobar.id()) * .build()); * * } diff --git a/sdk/java/src/main/java/com/pulumi/digitalocean/Vpc.java b/sdk/java/src/main/java/com/pulumi/digitalocean/Vpc.java index 91f099fa..582b43d0 100644 --- a/sdk/java/src/main/java/com/pulumi/digitalocean/Vpc.java +++ b/sdk/java/src/main/java/com/pulumi/digitalocean/Vpc.java @@ -47,8 +47,9 @@ * * public static void stack(Context ctx) { * var example = new Vpc("example", VpcArgs.builder() - * .ipRange("10.10.10.0/24") + * .name("example-project-network") * .region("nyc3") + * .ipRange("10.10.10.0/24") * .build()); * * } @@ -88,15 +89,17 @@ * } * * public static void stack(Context ctx) { - * var exampleVpc = new Vpc("exampleVpc", VpcArgs.builder() + * var example = new Vpc("example", VpcArgs.builder() + * .name("example-project-network") * .region("nyc3") * .build()); * * var exampleDroplet = new Droplet("exampleDroplet", DropletArgs.builder() + * .name("example-01") * .size("s-1vcpu-1gb") * .image("ubuntu-18-04-x64") * .region("nyc3") - * .vpcUuid(exampleVpc.id()) + * .vpcUuid(example.id()) * .build()); * * } diff --git a/sdk/nodejs/app.ts b/sdk/nodejs/app.ts index f2ac9053..f12fda4f 100644 --- a/sdk/nodejs/app.ts +++ b/sdk/nodejs/app.ts @@ -24,14 +24,14 @@ import * as utilities from "./utilities"; * name: "golang-sample", * region: "ams", * services: [{ + * name: "go-service", * environmentSlug: "go", + * instanceCount: 1, + * instanceSizeSlug: "professional-xs", * git: { - * branch: "main", * repoCloneUrl: "https://github.com/digitalocean/sample-golang.git", + * branch: "main", * }, - * instanceCount: 1, - * instanceSizeSlug: "professional-xs", - * name: "go-service", * }], * }}); * ``` @@ -46,13 +46,13 @@ import * as utilities from "./utilities"; * name: "static-site-example", * region: "ams", * staticSites: [{ + * name: "sample-jekyll", * buildCommand: "bundle exec jekyll build -d ./public", + * outputDir: "/public", * git: { - * branch: "main", * repoCloneUrl: "https://github.com/digitalocean/sample-jekyll.git", + * branch: "main", * }, - * name: "sample-jekyll", - * outputDir: "/public", * }], * }}); * ``` diff --git a/sdk/nodejs/cdn.ts b/sdk/nodejs/cdn.ts index 72e00a7a..e364dd81 100644 --- a/sdk/nodejs/cdn.ts +++ b/sdk/nodejs/cdn.ts @@ -17,6 +17,7 @@ import * as utilities from "./utilities"; * * // Create a new Spaces Bucket * const mybucket = new digitalocean.SpacesBucket("mybucket", { + * name: "example", * region: digitalocean.Region.SFO2, * acl: "public-read", * }); @@ -33,11 +34,13 @@ import * as utilities from "./utilities"; * * // Create a new Spaces Bucket * const mybucket = new digitalocean.SpacesBucket("mybucket", { + * name: "example", * region: digitalocean.Region.SFO2, * acl: "public-read", * }); * // Create a DigitalOcean managed Let's Encrypt Certificate * const cert = new digitalocean.Certificate("cert", { + * name: "cdn-cert", * type: digitalocean.CertificateType.LetsEncrypt, * domains: ["static.example.com"], * }); diff --git a/sdk/nodejs/certificate.ts b/sdk/nodejs/certificate.ts index 400eb937..9633ba48 100644 --- a/sdk/nodejs/certificate.ts +++ b/sdk/nodejs/certificate.ts @@ -22,13 +22,20 @@ import * as utilities from "./utilities"; * ```typescript * import * as pulumi from "@pulumi/pulumi"; * import * as digitalocean from "@pulumi/digitalocean"; - * import * as fs from "fs"; + * import * as std from "@pulumi/std"; * * const cert = new digitalocean.Certificate("cert", { + * name: "custom-example", * type: digitalocean.CertificateType.Custom, - * privateKey: fs.readFileSync("/Users/myuser/certs/privkey.pem", "utf8"), - * leafCertificate: fs.readFileSync("/Users/myuser/certs/cert.pem", "utf8"), - * certificateChain: fs.readFileSync("/Users/myuser/certs/fullchain.pem", "utf8"), + * privateKey: std.file({ + * input: "/Users/myuser/certs/privkey.pem", + * }).then(invoke => invoke.result), + * leafCertificate: std.file({ + * input: "/Users/myuser/certs/cert.pem", + * }).then(invoke => invoke.result), + * certificateChain: std.file({ + * input: "/Users/myuser/certs/fullchain.pem", + * }).then(invoke => invoke.result), * }); * ``` * @@ -39,8 +46,9 @@ import * as utilities from "./utilities"; * import * as digitalocean from "@pulumi/digitalocean"; * * const cert = new digitalocean.Certificate("cert", { - * domains: ["example.com"], + * name: "le-example", * type: digitalocean.CertificateType.LetsEncrypt, + * domains: ["example.com"], * }); * ``` * @@ -54,11 +62,13 @@ import * as utilities from "./utilities"; * import * as digitalocean from "@pulumi/digitalocean"; * * const cert = new digitalocean.Certificate("cert", { + * name: "le-example", * type: digitalocean.CertificateType.LetsEncrypt, * domains: ["example.com"], * }); * // Create a new Load Balancer with TLS termination * const _public = new digitalocean.LoadBalancer("public", { + * name: "secure-loadbalancer-1", * region: digitalocean.Region.NYC3, * dropletTag: "backend", * forwardingRules: [{ diff --git a/sdk/nodejs/containerRegistry.ts b/sdk/nodejs/containerRegistry.ts index 9b1499ce..5d145872 100644 --- a/sdk/nodejs/containerRegistry.ts +++ b/sdk/nodejs/containerRegistry.ts @@ -15,7 +15,10 @@ import * as utilities from "./utilities"; * import * as digitalocean from "@pulumi/digitalocean"; * * // Create a new container registry - * const foobar = new digitalocean.ContainerRegistry("foobar", {subscriptionTierSlug: "starter"}); + * const foobar = new digitalocean.ContainerRegistry("foobar", { + * name: "foobar", + * subscriptionTierSlug: "starter", + * }); * ``` * * ## Import diff --git a/sdk/nodejs/containerRegistryDockerCredentials.ts b/sdk/nodejs/containerRegistryDockerCredentials.ts index 2e07d789..51396c1f 100644 --- a/sdk/nodejs/containerRegistryDockerCredentials.ts +++ b/sdk/nodejs/containerRegistryDockerCredentials.ts @@ -30,10 +30,35 @@ import * as utilities from "./utilities"; * import * as pulumi from "@pulumi/pulumi"; * import * as digitalocean from "@pulumi/digitalocean"; * - * const exampleContainerRegistry = digitalocean.getContainerRegistry({ + * const example = digitalocean.getContainerRegistry({ * name: "example", * }); - * const exampleContainerRegistryDockerCredentials = new digitalocean.ContainerRegistryDockerCredentials("exampleContainerRegistryDockerCredentials", {registryName: "example"}); + * const exampleContainerRegistryDockerCredentials = new digitalocean.ContainerRegistryDockerCredentials("example", {registryName: "example"}); + * ``` + * + * ### Kubernetes Example + * + * Combined with the Kubernetes Provider's `kubernetesSecret` resource, you can + * access the registry from inside your cluster: + * + * ```typescript + * import * as pulumi from "@pulumi/pulumi"; + * import * as digitalocean from "@pulumi/digitalocean"; + * import * as kubernetes from "@pulumi/kubernetes"; + * + * const exampleContainerRegistryDockerCredentials = new digitalocean.ContainerRegistryDockerCredentials("example", {registryName: "example"}); + * const example = digitalocean.getKubernetesCluster({ + * name: "prod-cluster-01", + * }); + * const exampleSecret = new kubernetes.core.v1.Secret("example", { + * metadata: { + * name: "docker-cfg", + * }, + * data: { + * ".dockerconfigjson": exampleContainerRegistryDockerCredentials.dockerCredentials, + * }, + * type: "kubernetes.io/dockerconfigjson", + * }); * ``` */ export class ContainerRegistryDockerCredentials extends pulumi.CustomResource { diff --git a/sdk/nodejs/customImage.ts b/sdk/nodejs/customImage.ts index 66f1bef9..55337175 100644 --- a/sdk/nodejs/customImage.ts +++ b/sdk/nodejs/customImage.ts @@ -24,11 +24,13 @@ import * as utilities from "./utilities"; * import * as digitalocean from "@pulumi/digitalocean"; * * const flatcar = new digitalocean.CustomImage("flatcar", { + * name: "flatcar", * url: "https://stable.release.flatcar-linux.net/amd64-usr/2605.7.0/flatcar_production_digitalocean_image.bin.bz2", * regions: ["nyc3"], * }); * const example = new digitalocean.Droplet("example", { * image: flatcar.id, + * name: "example-01", * region: digitalocean.Region.NYC3, * size: digitalocean.DropletSlug.DropletS1VCPU1GB, * sshKeys: ["12345"], diff --git a/sdk/nodejs/databaseCluster.ts b/sdk/nodejs/databaseCluster.ts index b3f7cfcf..5bac8297 100644 --- a/sdk/nodejs/databaseCluster.ts +++ b/sdk/nodejs/databaseCluster.ts @@ -18,11 +18,12 @@ import * as utilities from "./utilities"; * import * as digitalocean from "@pulumi/digitalocean"; * * const postgres_example = new digitalocean.DatabaseCluster("postgres-example", { + * name: "example-postgres-cluster", * engine: "pg", - * nodeCount: 1, - * region: digitalocean.Region.NYC1, - * size: digitalocean.DatabaseSlug.DB_1VPCU1GB, * version: "15", + * size: digitalocean.DatabaseSlug.DB_1VPCU1GB, + * region: digitalocean.Region.NYC1, + * nodeCount: 1, * }); * ``` * @@ -32,11 +33,12 @@ import * as utilities from "./utilities"; * import * as digitalocean from "@pulumi/digitalocean"; * * const mysql_example = new digitalocean.DatabaseCluster("mysql-example", { + * name: "example-mysql-cluster", * engine: "mysql", - * nodeCount: 1, - * region: digitalocean.Region.NYC1, - * size: digitalocean.DatabaseSlug.DB_1VPCU1GB, * version: "8", + * size: digitalocean.DatabaseSlug.DB_1VPCU1GB, + * region: digitalocean.Region.NYC1, + * nodeCount: 1, * }); * ``` * @@ -46,11 +48,12 @@ import * as utilities from "./utilities"; * import * as digitalocean from "@pulumi/digitalocean"; * * const redis_example = new digitalocean.DatabaseCluster("redis-example", { + * name: "example-redis-cluster", * engine: "redis", - * nodeCount: 1, - * region: digitalocean.Region.NYC1, - * size: digitalocean.DatabaseSlug.DB_1VPCU1GB, * version: "7", + * size: digitalocean.DatabaseSlug.DB_1VPCU1GB, + * region: digitalocean.Region.NYC1, + * nodeCount: 1, * }); * ``` * @@ -60,11 +63,12 @@ import * as utilities from "./utilities"; * import * as digitalocean from "@pulumi/digitalocean"; * * const kafka_example = new digitalocean.DatabaseCluster("kafka-example", { + * name: "example-kafka-cluster", * engine: "kafka", - * nodeCount: 3, - * region: digitalocean.Region.NYC1, - * size: "db-s-2vcpu-2gb", * version: "3.5", + * size: "db-s-2vcpu-2gb", + * region: digitalocean.Region.NYC1, + * nodeCount: 3, * }); * ``` * @@ -74,11 +78,12 @@ import * as utilities from "./utilities"; * import * as digitalocean from "@pulumi/digitalocean"; * * const mongodb_example = new digitalocean.DatabaseCluster("mongodb-example", { + * name: "example-mongo-cluster", * engine: "mongodb", - * nodeCount: 1, - * region: digitalocean.Region.NYC3, - * size: digitalocean.DatabaseSlug.DB_1VPCU1GB, * version: "6", + * size: digitalocean.DatabaseSlug.DB_1VPCU1GB, + * region: digitalocean.Region.NYC3, + * nodeCount: 1, * }); * ``` * @@ -89,6 +94,7 @@ import * as utilities from "./utilities"; * import * as digitalocean from "@pulumi/digitalocean"; * * const doby = new digitalocean.DatabaseCluster("doby", { + * name: "dobydb", * engine: "pg", * version: "15", * size: digitalocean.DatabaseSlug.DB_1VPCU2GB, @@ -96,7 +102,8 @@ import * as utilities from "./utilities"; * nodeCount: 1, * tags: ["production"], * }); - * const dobyBackup = new digitalocean.DatabaseCluster("dobyBackup", { + * const dobyBackup = new digitalocean.DatabaseCluster("doby_backup", { + * name: "dobydupe", * engine: "pg", * version: "15", * size: digitalocean.DatabaseSlug.DB_1VPCU2GB, diff --git a/sdk/nodejs/databaseConnectionPool.ts b/sdk/nodejs/databaseConnectionPool.ts index 45f82782..b67069ad 100644 --- a/sdk/nodejs/databaseConnectionPool.ts +++ b/sdk/nodejs/databaseConnectionPool.ts @@ -15,6 +15,7 @@ import * as utilities from "./utilities"; * import * as digitalocean from "@pulumi/digitalocean"; * * const postgres_example = new digitalocean.DatabaseCluster("postgres-example", { + * name: "example-postgres-cluster", * engine: "pg", * version: "15", * size: digitalocean.DatabaseSlug.DB_1VPCU1GB, @@ -23,6 +24,7 @@ import * as utilities from "./utilities"; * }); * const pool_01 = new digitalocean.DatabaseConnectionPool("pool-01", { * clusterId: postgres_example.id, + * name: "pool-01", * mode: "transaction", * size: 20, * dbName: "defaultdb", diff --git a/sdk/nodejs/databaseDb.ts b/sdk/nodejs/databaseDb.ts index b1c9e4f6..20b5a542 100644 --- a/sdk/nodejs/databaseDb.ts +++ b/sdk/nodejs/databaseDb.ts @@ -15,13 +15,17 @@ import * as utilities from "./utilities"; * import * as digitalocean from "@pulumi/digitalocean"; * * const postgres_example = new digitalocean.DatabaseCluster("postgres-example", { + * name: "example-postgres-cluster", * engine: "pg", * version: "15", * size: digitalocean.DatabaseSlug.DB_1VPCU1GB, * region: digitalocean.Region.NYC1, * nodeCount: 1, * }); - * const database_example = new digitalocean.DatabaseDb("database-example", {clusterId: postgres_example.id}); + * const database_example = new digitalocean.DatabaseDb("database-example", { + * clusterId: postgres_example.id, + * name: "foobar", + * }); * ``` * * ## Import diff --git a/sdk/nodejs/databaseFirewall.ts b/sdk/nodejs/databaseFirewall.ts index 2ba09c60..5767084b 100644 --- a/sdk/nodejs/databaseFirewall.ts +++ b/sdk/nodejs/databaseFirewall.ts @@ -21,6 +21,7 @@ import * as utilities from "./utilities"; * import * as digitalocean from "@pulumi/digitalocean"; * * const postgres_example = new digitalocean.DatabaseCluster("postgres-example", { + * name: "example-postgres-cluster", * engine: "pg", * version: "15", * size: digitalocean.DatabaseSlug.DB_1VPCU1GB, @@ -49,11 +50,13 @@ import * as utilities from "./utilities"; * import * as digitalocean from "@pulumi/digitalocean"; * * const web = new digitalocean.Droplet("web", { + * name: "web-01", * size: digitalocean.DropletSlug.DropletS1VCPU1GB, * image: "ubuntu-22-04-x64", * region: digitalocean.Region.NYC3, * }); * const postgres_example = new digitalocean.DatabaseCluster("postgres-example", { + * name: "example-postgres-cluster", * engine: "pg", * version: "15", * size: digitalocean.DatabaseSlug.DB_1VPCU1GB, @@ -76,6 +79,7 @@ import * as utilities from "./utilities"; * import * as digitalocean from "@pulumi/digitalocean"; * * const postgres_example = new digitalocean.DatabaseCluster("postgres-example", { + * name: "example-postgres-cluster", * engine: "pg", * version: "15", * size: digitalocean.DatabaseSlug.DB_1VPCU1GB, @@ -84,6 +88,7 @@ import * as utilities from "./utilities"; * }); * const replica_example = new digitalocean.DatabaseReplica("replica-example", { * clusterId: postgres_example.id, + * name: "replica-example", * size: digitalocean.DatabaseSlug.DB_1VPCU1GB, * region: digitalocean.Region.NYC1, * }); diff --git a/sdk/nodejs/databaseKafkaTopic.ts b/sdk/nodejs/databaseKafkaTopic.ts index 417d80ba..b4053768 100644 --- a/sdk/nodejs/databaseKafkaTopic.ts +++ b/sdk/nodejs/databaseKafkaTopic.ts @@ -18,6 +18,7 @@ import * as utilities from "./utilities"; * import * as digitalocean from "@pulumi/digitalocean"; * * const kafka_example = new digitalocean.DatabaseCluster("kafka-example", { + * name: "example-kafka-cluster", * engine: "kafka", * version: "3.5", * size: "db-s-2vcpu-2gb", @@ -27,6 +28,7 @@ import * as utilities from "./utilities"; * }); * const topic_01 = new digitalocean.DatabaseKafkaTopic("topic-01", { * clusterId: kafka_example.id, + * name: "topic-01", * partitionCount: 3, * replicationFactor: 2, * configs: [{ diff --git a/sdk/nodejs/databaseMysqlConfig.ts b/sdk/nodejs/databaseMysqlConfig.ts index 922be714..85e626d4 100644 --- a/sdk/nodejs/databaseMysqlConfig.ts +++ b/sdk/nodejs/databaseMysqlConfig.ts @@ -16,14 +16,15 @@ import * as utilities from "./utilities"; * import * as pulumi from "@pulumi/pulumi"; * import * as digitalocean from "@pulumi/digitalocean"; * - * const exampleDatabaseCluster = new digitalocean.DatabaseCluster("exampleDatabaseCluster", { + * const exampleDatabaseCluster = new digitalocean.DatabaseCluster("example", { + * name: "example-mysql-cluster", * engine: "mysql", * version: "8", * size: digitalocean.DatabaseSlug.DB_1VPCU1GB, * region: digitalocean.Region.NYC1, * nodeCount: 1, * }); - * const exampleDatabaseMysqlConfig = new digitalocean.DatabaseMysqlConfig("exampleDatabaseMysqlConfig", { + * const example = new digitalocean.DatabaseMysqlConfig("example", { * clusterId: exampleDatabaseCluster.id, * connectTimeout: 10, * defaultTimeZone: "UTC", diff --git a/sdk/nodejs/databasePostgresqlConfig.ts b/sdk/nodejs/databasePostgresqlConfig.ts index 497fac25..3ace6f31 100644 --- a/sdk/nodejs/databasePostgresqlConfig.ts +++ b/sdk/nodejs/databasePostgresqlConfig.ts @@ -19,14 +19,15 @@ import * as utilities from "./utilities"; * import * as pulumi from "@pulumi/pulumi"; * import * as digitalocean from "@pulumi/digitalocean"; * - * const exampleDatabaseCluster = new digitalocean.DatabaseCluster("exampleDatabaseCluster", { + * const exampleDatabaseCluster = new digitalocean.DatabaseCluster("example", { + * name: "example-postgresql-cluster", * engine: "pg", * version: "15", * size: digitalocean.DatabaseSlug.DB_1VPCU1GB, * region: digitalocean.Region.NYC1, * nodeCount: 1, * }); - * const exampleDatabasePostgresqlConfig = new digitalocean.DatabasePostgresqlConfig("exampleDatabasePostgresqlConfig", { + * const example = new digitalocean.DatabasePostgresqlConfig("example", { * clusterId: exampleDatabaseCluster.id, * timezone: "UTC", * workMem: 16, diff --git a/sdk/nodejs/databaseRedisConfig.ts b/sdk/nodejs/databaseRedisConfig.ts index 78d9bae8..f5f7a146 100644 --- a/sdk/nodejs/databaseRedisConfig.ts +++ b/sdk/nodejs/databaseRedisConfig.ts @@ -16,14 +16,15 @@ import * as utilities from "./utilities"; * import * as pulumi from "@pulumi/pulumi"; * import * as digitalocean from "@pulumi/digitalocean"; * - * const exampleDatabaseCluster = new digitalocean.DatabaseCluster("exampleDatabaseCluster", { + * const exampleDatabaseCluster = new digitalocean.DatabaseCluster("example", { + * name: "example-redis-cluster", * engine: "redis", * version: "7", * size: digitalocean.DatabaseSlug.DB_1VPCU1GB, * region: digitalocean.Region.NYC1, * nodeCount: 1, * }); - * const exampleDatabaseRedisConfig = new digitalocean.DatabaseRedisConfig("exampleDatabaseRedisConfig", { + * const example = new digitalocean.DatabaseRedisConfig("example", { * clusterId: exampleDatabaseCluster.id, * maxmemoryPolicy: "allkeys-lru", * notifyKeyspaceEvents: "KEA", diff --git a/sdk/nodejs/databaseReplica.ts b/sdk/nodejs/databaseReplica.ts index c8c6bfc8..10a5c4cb 100644 --- a/sdk/nodejs/databaseReplica.ts +++ b/sdk/nodejs/databaseReplica.ts @@ -18,6 +18,7 @@ import * as utilities from "./utilities"; * import * as digitalocean from "@pulumi/digitalocean"; * * const postgres_example = new digitalocean.DatabaseCluster("postgres-example", { + * name: "example-postgres-cluster", * engine: "pg", * version: "15", * size: digitalocean.DatabaseSlug.DB_1VPCU1GB, @@ -26,10 +27,11 @@ import * as utilities from "./utilities"; * }); * const replica_example = new digitalocean.DatabaseReplica("replica-example", { * clusterId: postgres_example.id, + * name: "replica-example", * size: digitalocean.DatabaseSlug.DB_1VPCU1GB, * region: digitalocean.Region.NYC1, * }); - * export const uUID = replica_example.uuid; + * export const UUID = replica_example.uuid; * // Create firewall rule for database replica * const example_fw = new digitalocean.DatabaseFirewall("example-fw", { * clusterId: replica_example.uuid, diff --git a/sdk/nodejs/databaseUser.ts b/sdk/nodejs/databaseUser.ts index 79abec4e..aee726b5 100644 --- a/sdk/nodejs/databaseUser.ts +++ b/sdk/nodejs/databaseUser.ts @@ -20,13 +20,17 @@ import * as utilities from "./utilities"; * import * as digitalocean from "@pulumi/digitalocean"; * * const postgres_example = new digitalocean.DatabaseCluster("postgres-example", { + * name: "example-postgres-cluster", * engine: "pg", * version: "15", * size: digitalocean.DatabaseSlug.DB_1VPCU1GB, * region: digitalocean.Region.NYC1, * nodeCount: 1, * }); - * const user_example = new digitalocean.DatabaseUser("user-example", {clusterId: postgres_example.id}); + * const user_example = new digitalocean.DatabaseUser("user-example", { + * clusterId: postgres_example.id, + * name: "foobar", + * }); * ``` * * ### Create a new user for a PostgreSQL database replica @@ -35,6 +39,7 @@ import * as utilities from "./utilities"; * import * as digitalocean from "@pulumi/digitalocean"; * * const postgres_example = new digitalocean.DatabaseCluster("postgres-example", { + * name: "example-postgres-cluster", * engine: "pg", * version: "15", * size: digitalocean.DatabaseSlug.DB_1VPCU1GB, @@ -43,10 +48,14 @@ import * as utilities from "./utilities"; * }); * const replica_example = new digitalocean.DatabaseReplica("replica-example", { * clusterId: postgres_example.id, + * name: "replica-example", * size: digitalocean.DatabaseSlug.DB_1VPCU1GB, * region: digitalocean.Region.NYC1, * }); - * const user_example = new digitalocean.DatabaseUser("user-example", {clusterId: replica_example.uuid}); + * const user_example = new digitalocean.DatabaseUser("user-example", { + * clusterId: replica_example.uuid, + * name: "foobar", + * }); * ``` * * ### Create a new user for a Kafka database cluster @@ -55,15 +64,20 @@ import * as utilities from "./utilities"; * import * as digitalocean from "@pulumi/digitalocean"; * * const kafka_example = new digitalocean.DatabaseCluster("kafka-example", { + * name: "example-kafka-cluster", * engine: "kafka", * version: "3.5", * size: "db-s-2vcpu-2gb", * region: digitalocean.Region.NYC1, * nodeCount: 3, * }); - * const foobarTopic = new digitalocean.DatabaseKafkaTopic("foobarTopic", {clusterId: digitalocean_database_cluster.foobar.id}); - * const foobarUser = new digitalocean.DatabaseUser("foobarUser", { - * clusterId: digitalocean_database_cluster.foobar.id, + * const foobarTopic = new digitalocean.DatabaseKafkaTopic("foobar_topic", { + * clusterId: foobar.id, + * name: "topic-1", + * }); + * const foobarUser = new digitalocean.DatabaseUser("foobar_user", { + * clusterId: foobar.id, + * name: "example-user", * settings: [{ * acls: [ * { diff --git a/sdk/nodejs/dnsRecord.ts b/sdk/nodejs/dnsRecord.ts index f3080781..3c6826bb 100644 --- a/sdk/nodejs/dnsRecord.ts +++ b/sdk/nodejs/dnsRecord.ts @@ -21,12 +21,14 @@ import * as utilities from "./utilities"; * const www = new digitalocean.DnsRecord("www", { * domain: _default.id, * type: digitalocean.RecordType.A, + * name: "www", * value: "192.168.0.11", * }); * // Add a MX record for the example.com domain itself. * const mx = new digitalocean.DnsRecord("mx", { * domain: _default.id, * type: digitalocean.RecordType.MX, + * name: "@", * priority: 10, * value: "mail.example.com.", * }); diff --git a/sdk/nodejs/domain.ts b/sdk/nodejs/domain.ts index a1f26aa1..916a42d8 100644 --- a/sdk/nodejs/domain.ts +++ b/sdk/nodejs/domain.ts @@ -16,7 +16,7 @@ import * as utilities from "./utilities"; * // Create a new domain * const _default = new digitalocean.Domain("default", { * name: "example.com", - * ipAddress: digitalocean_droplet.foo.ipv4_address, + * ipAddress: foo.ipv4Address, * }); * ``` * diff --git a/sdk/nodejs/droplet.ts b/sdk/nodejs/droplet.ts index 1cfb2784..a90da428 100644 --- a/sdk/nodejs/droplet.ts +++ b/sdk/nodejs/droplet.ts @@ -20,6 +20,7 @@ import * as utilities from "./utilities"; * // Create a new Web Droplet in the nyc2 region * const web = new digitalocean.Droplet("web", { * image: "ubuntu-20-04-x64", + * name: "web-1", * region: digitalocean.Region.NYC2, * size: digitalocean.DropletSlug.DropletS1VCPU1GB, * }); diff --git a/sdk/nodejs/dropletSnapshot.ts b/sdk/nodejs/dropletSnapshot.ts index 84d4cfa9..84493535 100644 --- a/sdk/nodejs/dropletSnapshot.ts +++ b/sdk/nodejs/dropletSnapshot.ts @@ -14,13 +14,18 @@ import * as utilities from "./utilities"; * import * as digitalocean from "@pulumi/digitalocean"; * * const web = new digitalocean.Droplet("web", { + * name: "web-01", * size: digitalocean.DropletSlug.DropletS1VCPU1GB, * image: "ubuntu-22-04-x64", * region: digitalocean.Region.NYC3, * }); - * const web_snapshot = new digitalocean.DropletSnapshot("web-snapshot", {dropletId: web.id}); + * const web_snapshot = new digitalocean.DropletSnapshot("web-snapshot", { + * dropletId: web.id, + * name: "web-snapshot-01", + * }); * const from_snapshot = new digitalocean.Droplet("from-snapshot", { * image: web_snapshot.id, + * name: "web-02", * region: digitalocean.Region.NYC3, * size: digitalocean.DropletSlug.DropletS2VCPU4GB, * }); diff --git a/sdk/nodejs/firewall.ts b/sdk/nodejs/firewall.ts index 8c8e08d2..e3dd53f5 100644 --- a/sdk/nodejs/firewall.ts +++ b/sdk/nodejs/firewall.ts @@ -17,13 +17,15 @@ import * as utilities from "./utilities"; * import * as pulumi from "@pulumi/pulumi"; * import * as digitalocean from "@pulumi/digitalocean"; * - * const webDroplet = new digitalocean.Droplet("webDroplet", { + * const web = new digitalocean.Droplet("web", { + * name: "web-1", * size: digitalocean.DropletSlug.DropletS1VCPU1GB, * image: "ubuntu-18-04-x64", * region: digitalocean.Region.NYC3, * }); - * const webFirewall = new digitalocean.Firewall("webFirewall", { - * dropletIds: [webDroplet.id], + * const webFirewall = new digitalocean.Firewall("web", { + * name: "only-22-80-and-443", + * dropletIds: [web.id], * inboundRules: [ * { * protocol: "tcp", diff --git a/sdk/nodejs/floatingIp.ts b/sdk/nodejs/floatingIp.ts index 9325c56d..e942017a 100644 --- a/sdk/nodejs/floatingIp.ts +++ b/sdk/nodejs/floatingIp.ts @@ -17,16 +17,17 @@ import * as utilities from "./utilities"; * import * as pulumi from "@pulumi/pulumi"; * import * as digitalocean from "@pulumi/digitalocean"; * - * const foobarDroplet = new digitalocean.Droplet("foobarDroplet", { + * const foobar = new digitalocean.Droplet("foobar", { + * name: "baz", * size: digitalocean.DropletSlug.DropletS1VCPU1GB, * image: "ubuntu-18-04-x64", * region: digitalocean.Region.SGP1, * ipv6: true, * privateNetworking: true, * }); - * const foobarFloatingIp = new digitalocean.FloatingIp("foobarFloatingIp", { - * dropletId: foobarDroplet.id, - * region: foobarDroplet.region, + * const foobarFloatingIp = new digitalocean.FloatingIp("foobar", { + * dropletId: foobar.id, + * region: foobar.region, * }); * ``` * diff --git a/sdk/nodejs/floatingIpAssignment.ts b/sdk/nodejs/floatingIpAssignment.ts index 08340177..20e87d16 100644 --- a/sdk/nodejs/floatingIpAssignment.ts +++ b/sdk/nodejs/floatingIpAssignment.ts @@ -17,16 +17,17 @@ import * as utilities from "./utilities"; * import * as pulumi from "@pulumi/pulumi"; * import * as digitalocean from "@pulumi/digitalocean"; * - * const foobarFloatingIp = new digitalocean.FloatingIp("foobarFloatingIp", {region: "sgp1"}); - * const foobarDroplet = new digitalocean.Droplet("foobarDroplet", { + * const foobar = new digitalocean.FloatingIp("foobar", {region: "sgp1"}); + * const foobarDroplet = new digitalocean.Droplet("foobar", { + * name: "baz", * size: digitalocean.DropletSlug.DropletS1VCPU1GB, * image: "ubuntu-18-04-x64", * region: digitalocean.Region.SGP1, * ipv6: true, * privateNetworking: true, * }); - * const foobarFloatingIpAssignment = new digitalocean.FloatingIpAssignment("foobarFloatingIpAssignment", { - * ipAddress: foobarFloatingIp.ipAddress, + * const foobarFloatingIpAssignment = new digitalocean.FloatingIpAssignment("foobar", { + * ipAddress: foobar.ipAddress, * dropletId: foobarDroplet.id, * }); * ``` diff --git a/sdk/nodejs/getDomains.ts b/sdk/nodejs/getDomains.ts index 127bd844..34761a9b 100644 --- a/sdk/nodejs/getDomains.ts +++ b/sdk/nodejs/getDomains.ts @@ -29,8 +29,8 @@ import * as utilities from "./utilities"; * const examples = digitalocean.getDomains({ * filters: [{ * key: "name", - * matchBy: "re", * values: ["example\\.com$"], + * matchBy: "re", * }], * }); * ``` @@ -98,8 +98,8 @@ export interface GetDomainsResult { * const examples = digitalocean.getDomains({ * filters: [{ * key: "name", - * matchBy: "re", * values: ["example\\.com$"], + * matchBy: "re", * }], * }); * ``` diff --git a/sdk/nodejs/getDroplet.ts b/sdk/nodejs/getDroplet.ts index 0ecd5ff2..1c5aa3c9 100644 --- a/sdk/nodejs/getDroplet.ts +++ b/sdk/nodejs/getDroplet.ts @@ -45,7 +45,7 @@ import * as utilities from "./utilities"; * import * as digitalocean from "@pulumi/digitalocean"; * * const example = digitalocean.getDroplet({ - * id: digitalocean_kubernetes_cluster.example.node_pool[0].nodes[0].droplet_id, + * id: exampleDigitaloceanKubernetesCluster.nodePool[0].nodes[0].dropletId, * }); * ``` */ @@ -219,7 +219,7 @@ export interface GetDropletResult { * import * as digitalocean from "@pulumi/digitalocean"; * * const example = digitalocean.getDroplet({ - * id: digitalocean_kubernetes_cluster.example.node_pool[0].nodes[0].droplet_id, + * id: exampleDigitaloceanKubernetesCluster.nodePool[0].nodes[0].dropletId, * }); * ``` */ diff --git a/sdk/nodejs/getDropletSnapshot.ts b/sdk/nodejs/getDropletSnapshot.ts index 9d84d6dc..6deb1a6b 100644 --- a/sdk/nodejs/getDropletSnapshot.ts +++ b/sdk/nodejs/getDropletSnapshot.ts @@ -18,9 +18,9 @@ import * as utilities from "./utilities"; * import * as digitalocean from "@pulumi/digitalocean"; * * const web-snapshot = digitalocean.getDropletSnapshot({ - * mostRecent: true, * nameRegex: "^web", * region: "nyc3", + * mostRecent: true, * }); * ``` * @@ -37,6 +37,7 @@ import * as utilities from "./utilities"; * }); * const from_snapshot = new digitalocean.Droplet("from-snapshot", { * image: web_snapshot.then(web_snapshot => web_snapshot.id), + * name: "web-02", * region: digitalocean.Region.NYC3, * size: digitalocean.DropletSlug.DropletS2VCPU4GB, * }); @@ -127,9 +128,9 @@ export interface GetDropletSnapshotResult { * import * as digitalocean from "@pulumi/digitalocean"; * * const web-snapshot = digitalocean.getDropletSnapshot({ - * mostRecent: true, * nameRegex: "^web", * region: "nyc3", + * mostRecent: true, * }); * ``` * @@ -146,6 +147,7 @@ export interface GetDropletSnapshotResult { * }); * const from_snapshot = new digitalocean.Droplet("from-snapshot", { * image: web_snapshot.then(web_snapshot => web_snapshot.id), + * name: "web-02", * region: digitalocean.Region.NYC3, * size: digitalocean.DropletSlug.DropletS2VCPU4GB, * }); diff --git a/sdk/nodejs/getDroplets.ts b/sdk/nodejs/getDroplets.ts index 7d7eb584..c399d469 100644 --- a/sdk/nodejs/getDroplets.ts +++ b/sdk/nodejs/getDroplets.ts @@ -53,8 +53,8 @@ import * as utilities from "./utilities"; * }, * ], * sorts: [{ - * direction: "desc", * key: "created_at", + * direction: "desc", * }], * }); * ``` @@ -146,8 +146,8 @@ export interface GetDropletsResult { * }, * ], * sorts: [{ - * direction: "desc", * key: "created_at", + * direction: "desc", * }], * }); * ``` diff --git a/sdk/nodejs/getImage.ts b/sdk/nodejs/getImage.ts index c6122233..95f3b920 100644 --- a/sdk/nodejs/getImage.ts +++ b/sdk/nodejs/getImage.ts @@ -31,11 +31,12 @@ import * as utilities from "./utilities"; * import * as pulumi from "@pulumi/pulumi"; * import * as digitalocean from "@pulumi/digitalocean"; * - * const exampleImage = digitalocean.getImage({ + * const example = digitalocean.getImage({ * name: "example-1.0.0", * }); - * const exampleDroplet = new digitalocean.Droplet("exampleDroplet", { - * image: exampleImage.then(exampleImage => exampleImage.id), + * const exampleDroplet = new digitalocean.Droplet("example", { + * image: example.then(example => example.id), + * name: "example-1", * region: digitalocean.Region.NYC2, * size: digitalocean.DropletSlug.DropletS1VCPU1GB, * }); @@ -180,11 +181,12 @@ export interface GetImageResult { * import * as pulumi from "@pulumi/pulumi"; * import * as digitalocean from "@pulumi/digitalocean"; * - * const exampleImage = digitalocean.getImage({ + * const example = digitalocean.getImage({ * name: "example-1.0.0", * }); - * const exampleDroplet = new digitalocean.Droplet("exampleDroplet", { - * image: exampleImage.then(exampleImage => exampleImage.id), + * const exampleDroplet = new digitalocean.Droplet("example", { + * image: example.then(example => example.id), + * name: "example-1", * region: digitalocean.Region.NYC2, * size: digitalocean.DropletSlug.DropletS1VCPU1GB, * }); diff --git a/sdk/nodejs/getImages.ts b/sdk/nodejs/getImages.ts index 80e6ffd9..bc4ee47d 100644 --- a/sdk/nodejs/getImages.ts +++ b/sdk/nodejs/getImages.ts @@ -54,8 +54,8 @@ import * as utilities from "./utilities"; * }, * ], * sorts: [{ - * direction: "desc", * key: "created", + * direction: "desc", * }], * }); * ``` @@ -148,8 +148,8 @@ export interface GetImagesResult { * }, * ], * sorts: [{ - * direction: "desc", * key: "created", + * direction: "desc", * }], * }); * ``` diff --git a/sdk/nodejs/getKubernetesCluster.ts b/sdk/nodejs/getKubernetesCluster.ts index 1111b545..eede4ec7 100644 --- a/sdk/nodejs/getKubernetesCluster.ts +++ b/sdk/nodejs/getKubernetesCluster.ts @@ -9,6 +9,17 @@ import * as utilities from "./utilities"; /** * Retrieves information about a DigitalOcean Kubernetes cluster for use in other resources. This data source provides all of the cluster's properties as configured on your DigitalOcean account. This is useful if the cluster in question is not managed by the provider. + * + * ## Example Usage + * + * ```typescript + * import * as pulumi from "@pulumi/pulumi"; + * import * as digitalocean from "@pulumi/digitalocean"; + * + * const example = digitalocean.getKubernetesCluster({ + * name: "prod-cluster-01", + * }); + * ``` */ export function getKubernetesCluster(args: GetKubernetesClusterArgs, opts?: pulumi.InvokeOptions): Promise { @@ -114,6 +125,17 @@ export interface GetKubernetesClusterResult { } /** * Retrieves information about a DigitalOcean Kubernetes cluster for use in other resources. This data source provides all of the cluster's properties as configured on your DigitalOcean account. This is useful if the cluster in question is not managed by the provider. + * + * ## Example Usage + * + * ```typescript + * import * as pulumi from "@pulumi/pulumi"; + * import * as digitalocean from "@pulumi/digitalocean"; + * + * const example = digitalocean.getKubernetesCluster({ + * name: "prod-cluster-01", + * }); + * ``` */ export function getKubernetesClusterOutput(args: GetKubernetesClusterOutputArgs, opts?: pulumi.InvokeOptions): pulumi.Output { return pulumi.output(args).apply((a: any) => getKubernetesCluster(a, opts)) diff --git a/sdk/nodejs/getKubernetesVersions.ts b/sdk/nodejs/getKubernetesVersions.ts index 658fca17..11fb77f1 100644 --- a/sdk/nodejs/getKubernetesVersions.ts +++ b/sdk/nodejs/getKubernetesVersions.ts @@ -31,6 +31,7 @@ import * as utilities from "./utilities"; * * const example = digitalocean.getKubernetesVersions({}); * const example_cluster = new digitalocean.KubernetesCluster("example-cluster", { + * name: "example-cluster", * region: digitalocean.Region.LON1, * version: example.then(example => example.latestVersion), * nodePool: { @@ -51,6 +52,7 @@ import * as utilities from "./utilities"; * versionPrefix: "1.22.", * }); * const example_cluster = new digitalocean.KubernetesCluster("example-cluster", { + * name: "example-cluster", * region: digitalocean.Region.LON1, * version: example.then(example => example.latestVersion), * nodePool: { @@ -125,6 +127,7 @@ export interface GetKubernetesVersionsResult { * * const example = digitalocean.getKubernetesVersions({}); * const example_cluster = new digitalocean.KubernetesCluster("example-cluster", { + * name: "example-cluster", * region: digitalocean.Region.LON1, * version: example.then(example => example.latestVersion), * nodePool: { @@ -145,6 +148,7 @@ export interface GetKubernetesVersionsResult { * versionPrefix: "1.22.", * }); * const example_cluster = new digitalocean.KubernetesCluster("example-cluster", { + * name: "example-cluster", * region: digitalocean.Region.LON1, * version: example.then(example => example.latestVersion), * nodePool: { diff --git a/sdk/nodejs/getProjects.ts b/sdk/nodejs/getProjects.ts index 75779490..9d3e1c53 100644 --- a/sdk/nodejs/getProjects.ts +++ b/sdk/nodejs/getProjects.ts @@ -52,8 +52,8 @@ import * as utilities from "./utilities"; * }, * ], * sorts: [{ - * direction: "asc", * key: "name", + * direction: "asc", * }], * }); * ``` @@ -145,8 +145,8 @@ export interface GetProjectsResult { * }, * ], * sorts: [{ - * direction: "asc", * key: "name", + * direction: "asc", * }], * }); * ``` diff --git a/sdk/nodejs/getRecords.ts b/sdk/nodejs/getRecords.ts index dc0f7457..8a483837 100644 --- a/sdk/nodejs/getRecords.ts +++ b/sdk/nodejs/getRecords.ts @@ -10,6 +10,28 @@ import * as utilities from "./utilities"; /** * Retrieve information about all DNS records within a domain, with the ability to filter and sort the results. * If no filters are specified, all records will be returned. + * + * ## Example Usage + * + * Get data for all MX records in a domain: + * + * ```typescript + * import * as pulumi from "@pulumi/pulumi"; + * import * as digitalocean from "@pulumi/digitalocean"; + * import * as std from "@pulumi/std"; + * + * const example = digitalocean.getRecords({ + * domain: "example.com", + * filters: [{ + * key: "type", + * values: ["MX"], + * }], + * }); + * export const mailServers = example.then(example => std.join({ + * separator: ",", + * input: example.records.map(__item => __item.value), + * })).then(invoke => invoke.result); + * ``` */ export function getRecords(args: GetRecordsArgs, opts?: pulumi.InvokeOptions): Promise { @@ -60,6 +82,28 @@ export interface GetRecordsResult { /** * Retrieve information about all DNS records within a domain, with the ability to filter and sort the results. * If no filters are specified, all records will be returned. + * + * ## Example Usage + * + * Get data for all MX records in a domain: + * + * ```typescript + * import * as pulumi from "@pulumi/pulumi"; + * import * as digitalocean from "@pulumi/digitalocean"; + * import * as std from "@pulumi/std"; + * + * const example = digitalocean.getRecords({ + * domain: "example.com", + * filters: [{ + * key: "type", + * values: ["MX"], + * }], + * }); + * export const mailServers = example.then(example => std.join({ + * separator: ",", + * input: example.records.map(__item => __item.value), + * })).then(invoke => invoke.result); + * ``` */ export function getRecordsOutput(args: GetRecordsOutputArgs, opts?: pulumi.InvokeOptions): pulumi.Output { return pulumi.output(args).apply((a: any) => getRecords(a, opts)) diff --git a/sdk/nodejs/getRegions.ts b/sdk/nodejs/getRegions.ts index d667319b..aacac35d 100644 --- a/sdk/nodejs/getRegions.ts +++ b/sdk/nodejs/getRegions.ts @@ -50,8 +50,8 @@ import * as utilities from "./utilities"; * }, * ], * sorts: [{ - * direction: "desc", * key: "name", + * direction: "desc", * }], * }); * ``` @@ -140,8 +140,8 @@ export interface GetRegionsResult { * }, * ], * sorts: [{ - * direction: "desc", * key: "name", + * direction: "desc", * }], * }); * ``` diff --git a/sdk/nodejs/getSpacesBucketObject.ts b/sdk/nodejs/getSpacesBucketObject.ts index 8efe746c..04d92358 100644 --- a/sdk/nodejs/getSpacesBucketObject.ts +++ b/sdk/nodejs/getSpacesBucketObject.ts @@ -28,6 +28,7 @@ import * as utilities from "./utilities"; * }); * const web = new digitalocean.Droplet("web", { * image: "ubuntu-18-04-x64", + * name: "web-1", * region: digitalocean.Region.NYC2, * size: digitalocean.DropletSlug.DropletS1VCPU1GB, * userData: bootstrapScript.then(bootstrapScript => bootstrapScript.body), @@ -162,6 +163,7 @@ export interface GetSpacesBucketObjectResult { * }); * const web = new digitalocean.Droplet("web", { * image: "ubuntu-18-04-x64", + * name: "web-1", * region: digitalocean.Region.NYC2, * size: digitalocean.DropletSlug.DropletS1VCPU1GB, * userData: bootstrapScript.then(bootstrapScript => bootstrapScript.body), diff --git a/sdk/nodejs/getSpacesBuckets.ts b/sdk/nodejs/getSpacesBuckets.ts index a259a6ef..e4fd6105 100644 --- a/sdk/nodejs/getSpacesBuckets.ts +++ b/sdk/nodejs/getSpacesBuckets.ts @@ -43,8 +43,8 @@ import * as utilities from "./utilities"; * values: ["nyc3"], * }], * sorts: [{ - * direction: "desc", * key: "name", + * direction: "desc", * }], * }); * ``` @@ -126,8 +126,8 @@ export interface GetSpacesBucketsResult { * values: ["nyc3"], * }], * sorts: [{ - * direction: "desc", * key: "name", + * direction: "desc", * }], * }); * ``` diff --git a/sdk/nodejs/getSshKey.ts b/sdk/nodejs/getSshKey.ts index 6ea469bd..97a129c7 100644 --- a/sdk/nodejs/getSshKey.ts +++ b/sdk/nodejs/getSshKey.ts @@ -20,14 +20,15 @@ import * as utilities from "./utilities"; * import * as pulumi from "@pulumi/pulumi"; * import * as digitalocean from "@pulumi/digitalocean"; * - * const exampleSshKey = digitalocean.getSshKey({ + * const example = digitalocean.getSshKey({ * name: "example", * }); - * const exampleDroplet = new digitalocean.Droplet("exampleDroplet", { + * const exampleDroplet = new digitalocean.Droplet("example", { * image: "ubuntu-18-04-x64", + * name: "example-1", * region: digitalocean.Region.NYC2, * size: digitalocean.DropletSlug.DropletS1VCPU1GB, - * sshKeys: [exampleSshKey.then(exampleSshKey => exampleSshKey.id)], + * sshKeys: [example.then(example => example.id)], * }); * ``` */ @@ -83,14 +84,15 @@ export interface GetSshKeyResult { * import * as pulumi from "@pulumi/pulumi"; * import * as digitalocean from "@pulumi/digitalocean"; * - * const exampleSshKey = digitalocean.getSshKey({ + * const example = digitalocean.getSshKey({ * name: "example", * }); - * const exampleDroplet = new digitalocean.Droplet("exampleDroplet", { + * const exampleDroplet = new digitalocean.Droplet("example", { * image: "ubuntu-18-04-x64", + * name: "example-1", * region: digitalocean.Region.NYC2, * size: digitalocean.DropletSlug.DropletS1VCPU1GB, - * sshKeys: [exampleSshKey.then(exampleSshKey => exampleSshKey.id)], + * sshKeys: [example.then(example => example.id)], * }); * ``` */ diff --git a/sdk/nodejs/getSshKeys.ts b/sdk/nodejs/getSshKeys.ts index 3afc9eb0..7f7211d6 100644 --- a/sdk/nodejs/getSshKeys.ts +++ b/sdk/nodejs/getSshKeys.ts @@ -26,8 +26,8 @@ import * as utilities from "./utilities"; * * const keys = digitalocean.getSshKeys({ * sorts: [{ - * direction: "asc", * key: "name", + * direction: "asc", * }], * }); * ``` @@ -109,8 +109,8 @@ export interface GetSshKeysResult { * * const keys = digitalocean.getSshKeys({ * sorts: [{ - * direction: "asc", * key: "name", + * direction: "asc", * }], * }); * ``` diff --git a/sdk/nodejs/getTag.ts b/sdk/nodejs/getTag.ts index a194d234..b7b98cae 100644 --- a/sdk/nodejs/getTag.ts +++ b/sdk/nodejs/getTag.ts @@ -19,14 +19,15 @@ import * as utilities from "./utilities"; * import * as pulumi from "@pulumi/pulumi"; * import * as digitalocean from "@pulumi/digitalocean"; * - * const exampleTag = digitalocean.getTag({ + * const example = digitalocean.getTag({ * name: "example", * }); - * const exampleDroplet = new digitalocean.Droplet("exampleDroplet", { + * const exampleDroplet = new digitalocean.Droplet("example", { * image: "ubuntu-18-04-x64", + * name: "example-1", * region: digitalocean.Region.NYC2, * size: digitalocean.DropletSlug.DropletS1VCPU1GB, - * tags: [exampleTag.then(exampleTag => exampleTag.name)], + * tags: [example.then(example => example.name)], * }); * ``` */ @@ -97,14 +98,15 @@ export interface GetTagResult { * import * as pulumi from "@pulumi/pulumi"; * import * as digitalocean from "@pulumi/digitalocean"; * - * const exampleTag = digitalocean.getTag({ + * const example = digitalocean.getTag({ * name: "example", * }); - * const exampleDroplet = new digitalocean.Droplet("exampleDroplet", { + * const exampleDroplet = new digitalocean.Droplet("example", { * image: "ubuntu-18-04-x64", + * name: "example-1", * region: digitalocean.Region.NYC2, * size: digitalocean.DropletSlug.DropletS1VCPU1GB, - * tags: [exampleTag.then(exampleTag => exampleTag.name)], + * tags: [example.then(example => example.name)], * }); * ``` */ diff --git a/sdk/nodejs/getVolume.ts b/sdk/nodejs/getVolume.ts index a5076998..193d58c3 100644 --- a/sdk/nodejs/getVolume.ts +++ b/sdk/nodejs/getVolume.ts @@ -32,18 +32,19 @@ import * as utilities from "./utilities"; * import * as pulumi from "@pulumi/pulumi"; * import * as digitalocean from "@pulumi/digitalocean"; * - * const exampleVolume = digitalocean.getVolume({ + * const example = digitalocean.getVolume({ * name: "app-data", * region: "nyc3", * }); - * const exampleDroplet = new digitalocean.Droplet("exampleDroplet", { + * const exampleDroplet = new digitalocean.Droplet("example", { + * name: "foo", * size: digitalocean.DropletSlug.DropletS1VCPU1GB, * image: "ubuntu-18-04-x64", * region: digitalocean.Region.NYC3, * }); * const foobar = new digitalocean.VolumeAttachment("foobar", { * dropletId: exampleDroplet.id, - * volumeId: exampleVolume.then(exampleVolume => exampleVolume.id), + * volumeId: example.then(example => example.id), * }); * ``` */ @@ -142,18 +143,19 @@ export interface GetVolumeResult { * import * as pulumi from "@pulumi/pulumi"; * import * as digitalocean from "@pulumi/digitalocean"; * - * const exampleVolume = digitalocean.getVolume({ + * const example = digitalocean.getVolume({ * name: "app-data", * region: "nyc3", * }); - * const exampleDroplet = new digitalocean.Droplet("exampleDroplet", { + * const exampleDroplet = new digitalocean.Droplet("example", { + * name: "foo", * size: digitalocean.DropletSlug.DropletS1VCPU1GB, * image: "ubuntu-18-04-x64", * region: digitalocean.Region.NYC3, * }); * const foobar = new digitalocean.VolumeAttachment("foobar", { * dropletId: exampleDroplet.id, - * volumeId: exampleVolume.then(exampleVolume => exampleVolume.id), + * volumeId: example.then(example => example.id), * }); * ``` */ diff --git a/sdk/nodejs/getVolumeSnapshot.ts b/sdk/nodejs/getVolumeSnapshot.ts index 9217cdf2..298396c2 100644 --- a/sdk/nodejs/getVolumeSnapshot.ts +++ b/sdk/nodejs/getVolumeSnapshot.ts @@ -18,9 +18,9 @@ import * as utilities from "./utilities"; * import * as digitalocean from "@pulumi/digitalocean"; * * const snapshot = digitalocean.getVolumeSnapshot({ - * mostRecent: true, * nameRegex: "^web", * region: "nyc3", + * mostRecent: true, * }); * ``` * @@ -37,6 +37,7 @@ import * as utilities from "./utilities"; * }); * const foobar = new digitalocean.Volume("foobar", { * region: digitalocean.Region.NYC3, + * name: "baz", * size: 100, * snapshotId: snapshot.then(snapshot => snapshot.id), * }); @@ -131,9 +132,9 @@ export interface GetVolumeSnapshotResult { * import * as digitalocean from "@pulumi/digitalocean"; * * const snapshot = digitalocean.getVolumeSnapshot({ - * mostRecent: true, * nameRegex: "^web", * region: "nyc3", + * mostRecent: true, * }); * ``` * @@ -150,6 +151,7 @@ export interface GetVolumeSnapshotResult { * }); * const foobar = new digitalocean.Volume("foobar", { * region: digitalocean.Region.NYC3, + * name: "baz", * size: 100, * snapshotId: snapshot.then(snapshot => snapshot.id), * }); diff --git a/sdk/nodejs/getVpc.ts b/sdk/nodejs/getVpc.ts index e430478b..ca81fc3c 100644 --- a/sdk/nodejs/getVpc.ts +++ b/sdk/nodejs/getVpc.ts @@ -33,14 +33,15 @@ import * as utilities from "./utilities"; * import * as pulumi from "@pulumi/pulumi"; * import * as digitalocean from "@pulumi/digitalocean"; * - * const exampleVpc = digitalocean.getVpc({ + * const example = digitalocean.getVpc({ * name: "example-network", * }); - * const exampleDroplet = new digitalocean.Droplet("exampleDroplet", { + * const exampleDroplet = new digitalocean.Droplet("example", { + * name: "example-01", * size: digitalocean.DropletSlug.DropletS1VCPU1GB, * image: "ubuntu-18-04-x64", * region: digitalocean.Region.NYC3, - * vpcUuid: exampleVpc.then(exampleVpc => exampleVpc.id), + * vpcUuid: example.then(example => example.id), * }); * ``` */ @@ -139,14 +140,15 @@ export interface GetVpcResult { * import * as pulumi from "@pulumi/pulumi"; * import * as digitalocean from "@pulumi/digitalocean"; * - * const exampleVpc = digitalocean.getVpc({ + * const example = digitalocean.getVpc({ * name: "example-network", * }); - * const exampleDroplet = new digitalocean.Droplet("exampleDroplet", { + * const exampleDroplet = new digitalocean.Droplet("example", { + * name: "example-01", * size: digitalocean.DropletSlug.DropletS1VCPU1GB, * image: "ubuntu-18-04-x64", * region: digitalocean.Region.NYC3, - * vpcUuid: exampleVpc.then(exampleVpc => exampleVpc.id), + * vpcUuid: example.then(example => example.id), * }); * ``` */ diff --git a/sdk/nodejs/kubernetesNodePool.ts b/sdk/nodejs/kubernetesNodePool.ts index 4b0f66eb..1ed5c7aa 100644 --- a/sdk/nodejs/kubernetesNodePool.ts +++ b/sdk/nodejs/kubernetesNodePool.ts @@ -19,6 +19,7 @@ import * as utilities from "./utilities"; * import * as digitalocean from "@pulumi/digitalocean"; * * const foo = new digitalocean.KubernetesCluster("foo", { + * name: "foo", * region: digitalocean.Region.NYC1, * version: "1.22.8-do.1", * nodePool: { @@ -29,6 +30,7 @@ import * as utilities from "./utilities"; * }); * const bar = new digitalocean.KubernetesNodePool("bar", { * clusterId: foo.id, + * name: "backend-pool", * size: digitalocean.DropletSlug.DropletC2, * nodeCount: 2, * tags: ["backend"], @@ -54,7 +56,8 @@ import * as utilities from "./utilities"; * import * as digitalocean from "@pulumi/digitalocean"; * * const autoscale_pool_01 = new digitalocean.KubernetesNodePool("autoscale-pool-01", { - * clusterId: digitalocean_kubernetes_cluster.foo.id, + * clusterId: foo.id, + * name: "autoscale-pool-01", * size: digitalocean.DropletSlug.DropletS1VCPU2GB, * autoScale: true, * minNodes: 1, diff --git a/sdk/nodejs/loadBalancer.ts b/sdk/nodejs/loadBalancer.ts index ebb2bdff..2cea9dd7 100644 --- a/sdk/nodejs/loadBalancer.ts +++ b/sdk/nodejs/loadBalancer.ts @@ -18,11 +18,13 @@ import * as utilities from "./utilities"; * import * as digitalocean from "@pulumi/digitalocean"; * * const web = new digitalocean.Droplet("web", { + * name: "web-1", * size: digitalocean.DropletSlug.DropletS1VCPU1GB, * image: "ubuntu-18-04-x64", * region: digitalocean.Region.NYC3, * }); * const _public = new digitalocean.LoadBalancer("public", { + * name: "loadbalancer-1", * region: digitalocean.Region.NYC3, * forwardingRules: [{ * entryPort: 80, @@ -44,36 +46,6 @@ import * as utilities from "./utilities"; * `Delete old certificate`. When doing so, you must also change the name of the certificate, * as there cannot be multiple certificates with the same name in an account. * - * ```typescript - * import * as pulumi from "@pulumi/pulumi"; - * import * as digitalocean from "@pulumi/digitalocean"; - * - * const cert = new digitalocean.Certificate("cert", { - * privateKey: "file('key.pem')", - * leafCertificate: "file('cert.pem')", - * }); - * const web = new digitalocean.Droplet("web", { - * size: digitalocean.DropletSlug.DropletS1VCPU1GB, - * image: "ubuntu-18-04-x64", - * region: digitalocean.Region.NYC3, - * }); - * const _public = new digitalocean.LoadBalancer("public", { - * region: digitalocean.Region.NYC3, - * forwardingRules: [{ - * entryPort: 443, - * entryProtocol: "https", - * targetPort: 80, - * targetProtocol: "http", - * certificateName: cert.name, - * }], - * healthcheck: { - * port: 22, - * protocol: "tcp", - * }, - * dropletIds: [web.id], - * }); - * ``` - * * ## Import * * Load Balancers can be imported using the `id`, e.g. diff --git a/sdk/nodejs/project.ts b/sdk/nodejs/project.ts index 826436a6..46ac3fdd 100644 --- a/sdk/nodejs/project.ts +++ b/sdk/nodejs/project.ts @@ -34,9 +34,10 @@ import * as utilities from "./utilities"; * import * as digitalocean from "@pulumi/digitalocean"; * * const playground = new digitalocean.Project("playground", { + * name: "playground", * description: "A project to represent development resources.", - * environment: "Development", * purpose: "Web Application", + * environment: "Development", * }); * ``` * @@ -47,11 +48,13 @@ import * as utilities from "./utilities"; * import * as digitalocean from "@pulumi/digitalocean"; * * const foobar = new digitalocean.Droplet("foobar", { + * name: "example", * size: digitalocean.DropletSlug.DropletS1VCPU1GB, * image: "ubuntu-22-04-x64", * region: digitalocean.Region.NYC3, * }); * const playground = new digitalocean.Project("playground", { + * name: "playground", * description: "A project to represent development resources.", * purpose: "Web Application", * environment: "Development", diff --git a/sdk/nodejs/projectResources.ts b/sdk/nodejs/projectResources.ts index 567745a9..5bc0e780 100644 --- a/sdk/nodejs/projectResources.ts +++ b/sdk/nodejs/projectResources.ts @@ -32,6 +32,7 @@ import * as utilities from "./utilities"; * name: "playground", * }); * const foobar = new digitalocean.Droplet("foobar", { + * name: "example", * size: digitalocean.DropletSlug.DropletS1VCPU1GB, * image: "ubuntu-22-04-x64", * region: digitalocean.Region.NYC3, diff --git a/sdk/nodejs/reservedIp.ts b/sdk/nodejs/reservedIp.ts index de109053..f1c3835c 100644 --- a/sdk/nodejs/reservedIp.ts +++ b/sdk/nodejs/reservedIp.ts @@ -15,16 +15,17 @@ import * as utilities from "./utilities"; * import * as pulumi from "@pulumi/pulumi"; * import * as digitalocean from "@pulumi/digitalocean"; * - * const exampleDroplet = new digitalocean.Droplet("exampleDroplet", { + * const example = new digitalocean.Droplet("example", { + * name: "example", * size: digitalocean.DropletSlug.DropletS1VCPU1GB, * image: "ubuntu-22-04-x64", * region: digitalocean.Region.NYC3, * ipv6: true, * privateNetworking: true, * }); - * const exampleReservedIp = new digitalocean.ReservedIp("exampleReservedIp", { - * dropletId: exampleDroplet.id, - * region: exampleDroplet.region, + * const exampleReservedIp = new digitalocean.ReservedIp("example", { + * dropletId: example.id, + * region: example.region, * }); * ``` * diff --git a/sdk/nodejs/reservedIpAssignment.ts b/sdk/nodejs/reservedIpAssignment.ts index dd4bfc5d..7fd4e290 100644 --- a/sdk/nodejs/reservedIpAssignment.ts +++ b/sdk/nodejs/reservedIpAssignment.ts @@ -15,16 +15,17 @@ import * as utilities from "./utilities"; * import * as pulumi from "@pulumi/pulumi"; * import * as digitalocean from "@pulumi/digitalocean"; * - * const exampleReservedIp = new digitalocean.ReservedIp("exampleReservedIp", {region: "nyc3"}); - * const exampleDroplet = new digitalocean.Droplet("exampleDroplet", { + * const example = new digitalocean.ReservedIp("example", {region: "nyc3"}); + * const exampleDroplet = new digitalocean.Droplet("example", { + * name: "baz", * size: digitalocean.DropletSlug.DropletS1VCPU1GB, * image: "ubuntu-22-04-x64", * region: digitalocean.Region.NYC3, * ipv6: true, * privateNetworking: true, * }); - * const exampleReservedIpAssignment = new digitalocean.ReservedIpAssignment("exampleReservedIpAssignment", { - * ipAddress: exampleReservedIp.ipAddress, + * const exampleReservedIpAssignment = new digitalocean.ReservedIpAssignment("example", { + * ipAddress: example.ipAddress, * dropletId: exampleDroplet.id, * }); * ``` diff --git a/sdk/nodejs/spacesBucket.ts b/sdk/nodejs/spacesBucket.ts index 1b1f6808..491ed6f3 100644 --- a/sdk/nodejs/spacesBucket.ts +++ b/sdk/nodejs/spacesBucket.ts @@ -27,7 +27,6 @@ import * as utilities from "./utilities"; * import * as digitalocean from "@pulumi/digitalocean"; * * const static_assets = new digitalocean.SpacesBucket("static-assets", {}); - * // ... * ``` * * For more information, See [An Introduction to DigitalOcean Spaces](https://www.digitalocean.com/community/tutorials/an-introduction-to-digitalocean-spaces) @@ -40,7 +39,10 @@ import * as utilities from "./utilities"; * import * as pulumi from "@pulumi/pulumi"; * import * as digitalocean from "@pulumi/digitalocean"; * - * const foobar = new digitalocean.SpacesBucket("foobar", {region: digitalocean.Region.NYC3}); + * const foobar = new digitalocean.SpacesBucket("foobar", { + * name: "foobar", + * region: digitalocean.Region.NYC3, + * }); * ``` * * ### Create a New Bucket With CORS Rules @@ -50,6 +52,8 @@ import * as utilities from "./utilities"; * import * as digitalocean from "@pulumi/digitalocean"; * * const foobar = new digitalocean.SpacesBucket("foobar", { + * name: "foobar", + * region: digitalocean.Region.NYC3, * corsRules: [ * { * allowedHeaders: ["*"], @@ -68,7 +72,6 @@ import * as utilities from "./utilities"; * maxAgeSeconds: 3000, * }, * ], - * region: digitalocean.Region.NYC3, * }); * ``` * diff --git a/sdk/nodejs/spacesBucketCorsConfiguration.ts b/sdk/nodejs/spacesBucketCorsConfiguration.ts index f88c5ff1..5d18eecf 100644 --- a/sdk/nodejs/spacesBucketCorsConfiguration.ts +++ b/sdk/nodejs/spacesBucketCorsConfiguration.ts @@ -16,7 +16,10 @@ import * as utilities from "./utilities"; * import * as pulumi from "@pulumi/pulumi"; * import * as digitalocean from "@pulumi/digitalocean"; * - * const foobar = new digitalocean.SpacesBucket("foobar", {region: digitalocean.Region.NYC3}); + * const foobar = new digitalocean.SpacesBucket("foobar", { + * name: "foobar", + * region: digitalocean.Region.NYC3, + * }); * const test = new digitalocean.SpacesBucketCorsConfiguration("test", { * bucket: foobar.id, * region: "nyc3", diff --git a/sdk/nodejs/spacesBucketObject.ts b/sdk/nodejs/spacesBucketObject.ts index 6922e60a..703b8822 100644 --- a/sdk/nodejs/spacesBucketObject.ts +++ b/sdk/nodejs/spacesBucketObject.ts @@ -26,7 +26,6 @@ import * as utilities from "./utilities"; * import * as digitalocean from "@pulumi/digitalocean"; * * const static_assets = new digitalocean.SpacesBucket("static-assets", {}); - * // ... * ``` * * For more information, See [An Introduction to DigitalOcean Spaces](https://www.digitalocean.com/community/tutorials/an-introduction-to-digitalocean-spaces) @@ -39,7 +38,10 @@ import * as utilities from "./utilities"; * import * as pulumi from "@pulumi/pulumi"; * import * as digitalocean from "@pulumi/digitalocean"; * - * const foobar = new digitalocean.SpacesBucket("foobar", {region: digitalocean.Region.NYC3}); + * const foobar = new digitalocean.SpacesBucket("foobar", { + * name: "foobar", + * region: digitalocean.Region.NYC3, + * }); * const index = new digitalocean.SpacesBucketObject("index", { * region: foobar.region, * bucket: foobar.name, diff --git a/sdk/nodejs/spacesBucketPolicy.ts b/sdk/nodejs/spacesBucketPolicy.ts index 1d417095..e896e5ff 100644 --- a/sdk/nodejs/spacesBucketPolicy.ts +++ b/sdk/nodejs/spacesBucketPolicy.ts @@ -13,10 +13,13 @@ import * as utilities from "./utilities"; * import * as pulumi from "@pulumi/pulumi"; * import * as digitalocean from "@pulumi/digitalocean"; * - * const foobarSpacesBucket = new digitalocean.SpacesBucket("foobarSpacesBucket", {region: digitalocean.Region.NYC3}); - * const foobarSpacesBucketPolicy = new digitalocean.SpacesBucketPolicy("foobarSpacesBucketPolicy", { - * region: foobarSpacesBucket.region, - * bucket: foobarSpacesBucket.name, + * const foobar = new digitalocean.SpacesBucket("foobar", { + * name: "foobar", + * region: digitalocean.Region.NYC3, + * }); + * const foobarSpacesBucketPolicy = new digitalocean.SpacesBucketPolicy("foobar", { + * region: foobar.region, + * bucket: foobar.name, * policy: pulumi.jsonStringify({ * Version: "2012-10-17", * Statement: [{ @@ -25,8 +28,8 @@ import * as utilities from "./utilities"; * Principal: "*", * Action: "s3:*", * Resource: [ - * pulumi.interpolate`arn:aws:s3:::${foobarSpacesBucket.name}`, - * pulumi.interpolate`arn:aws:s3:::${foobarSpacesBucket.name}/*`, + * pulumi.interpolate`arn:aws:s3:::${foobar.name}`, + * pulumi.interpolate`arn:aws:s3:::${foobar.name}/*`, * ], * Condition: { * NotIpAddress: { diff --git a/sdk/nodejs/sshKey.ts b/sdk/nodejs/sshKey.ts index 787795b5..b7163cd9 100644 --- a/sdk/nodejs/sshKey.ts +++ b/sdk/nodejs/sshKey.ts @@ -15,13 +15,19 @@ import * as utilities from "./utilities"; * ```typescript * import * as pulumi from "@pulumi/pulumi"; * import * as digitalocean from "@pulumi/digitalocean"; - * import * as fs from "fs"; + * import * as std from "@pulumi/std"; * * // Create a new SSH key - * const _default = new digitalocean.SshKey("default", {publicKey: fs.readFileSync("/Users/myuser/.ssh/id_rsa.pub", "utf8")}); + * const _default = new digitalocean.SshKey("default", { + * name: "Example", + * publicKey: std.file({ + * input: "/Users/myuser/.ssh/id_rsa.pub", + * }).then(invoke => invoke.result), + * }); * // Create a new Droplet using the SSH key * const web = new digitalocean.Droplet("web", { * image: "ubuntu-18-04-x64", + * name: "web-1", * region: digitalocean.Region.NYC3, * size: digitalocean.DropletSlug.DropletS1VCPU1GB, * sshKeys: [_default.fingerprint], diff --git a/sdk/nodejs/tag.ts b/sdk/nodejs/tag.ts index f9795ad8..c5f904d2 100644 --- a/sdk/nodejs/tag.ts +++ b/sdk/nodejs/tag.ts @@ -17,10 +17,11 @@ import * as utilities from "./utilities"; * import * as digitalocean from "@pulumi/digitalocean"; * * // Create a new tag - * const foobar = new digitalocean.Tag("foobar", {}); + * const foobar = new digitalocean.Tag("foobar", {name: "foobar"}); * // Create a new Droplet in nyc3 with the foobar tag * const web = new digitalocean.Droplet("web", { * image: "ubuntu-18-04-x64", + * name: "web-1", * region: digitalocean.Region.NYC3, * size: digitalocean.DropletSlug.DropletS1VCPU1GB, * tags: [foobar.id], diff --git a/sdk/nodejs/volume.ts b/sdk/nodejs/volume.ts index fcb9f140..d4a417d0 100644 --- a/sdk/nodejs/volume.ts +++ b/sdk/nodejs/volume.ts @@ -16,20 +16,22 @@ import * as utilities from "./utilities"; * import * as pulumi from "@pulumi/pulumi"; * import * as digitalocean from "@pulumi/digitalocean"; * - * const foobarVolume = new digitalocean.Volume("foobarVolume", { + * const foobar = new digitalocean.Volume("foobar", { * region: digitalocean.Region.NYC1, + * name: "baz", * size: 100, * initialFilesystemType: digitalocean.FileSystemType.EXT4, * description: "an example volume", * }); - * const foobarDroplet = new digitalocean.Droplet("foobarDroplet", { + * const foobarDroplet = new digitalocean.Droplet("foobar", { + * name: "baz", * size: digitalocean.DropletSlug.DropletS1VCPU1GB, * image: "ubuntu-18-04-x64", * region: digitalocean.Region.NYC1, * }); - * const foobarVolumeAttachment = new digitalocean.VolumeAttachment("foobarVolumeAttachment", { + * const foobarVolumeAttachment = new digitalocean.VolumeAttachment("foobar", { * dropletId: foobarDroplet.id, - * volumeId: foobarVolume.id, + * volumeId: foobar.id, * }); * ``` * @@ -39,13 +41,14 @@ import * as utilities from "./utilities"; * import * as pulumi from "@pulumi/pulumi"; * import * as digitalocean from "@pulumi/digitalocean"; * - * const foobarVolumeSnapshot = digitalocean.getVolumeSnapshot({ + * const foobar = digitalocean.getVolumeSnapshot({ * name: "baz", * }); - * const foobarVolume = new digitalocean.Volume("foobarVolume", { + * const foobarVolume = new digitalocean.Volume("foobar", { * region: digitalocean.Region.LON1, - * size: foobarVolumeSnapshot.then(foobarVolumeSnapshot => foobarVolumeSnapshot.minDiskSize), - * snapshotId: foobarVolumeSnapshot.then(foobarVolumeSnapshot => foobarVolumeSnapshot.id), + * name: "foo", + * size: foobar.then(foobar => foobar.minDiskSize), + * snapshotId: foobar.then(foobar => foobar.id), * }); * ``` * diff --git a/sdk/nodejs/volumeAttachment.ts b/sdk/nodejs/volumeAttachment.ts index 88ddc0b7..b6bccd70 100644 --- a/sdk/nodejs/volumeAttachment.ts +++ b/sdk/nodejs/volumeAttachment.ts @@ -15,20 +15,22 @@ import * as utilities from "./utilities"; * import * as pulumi from "@pulumi/pulumi"; * import * as digitalocean from "@pulumi/digitalocean"; * - * const foobarVolume = new digitalocean.Volume("foobarVolume", { + * const foobar = new digitalocean.Volume("foobar", { * region: digitalocean.Region.NYC1, + * name: "baz", * size: 100, * initialFilesystemType: digitalocean.FileSystemType.EXT4, * description: "an example volume", * }); - * const foobarDroplet = new digitalocean.Droplet("foobarDroplet", { + * const foobarDroplet = new digitalocean.Droplet("foobar", { + * name: "baz", * size: digitalocean.DropletSlug.DropletS1VCPU1GB, * image: "ubuntu-18-04-x64", * region: digitalocean.Region.NYC1, * }); - * const foobarVolumeAttachment = new digitalocean.VolumeAttachment("foobarVolumeAttachment", { + * const foobarVolumeAttachment = new digitalocean.VolumeAttachment("foobar", { * dropletId: foobarDroplet.id, - * volumeId: foobarVolume.id, + * volumeId: foobar.id, * }); * ``` */ diff --git a/sdk/nodejs/volumeSnapshot.ts b/sdk/nodejs/volumeSnapshot.ts index aefecf6c..39b675e3 100644 --- a/sdk/nodejs/volumeSnapshot.ts +++ b/sdk/nodejs/volumeSnapshot.ts @@ -13,12 +13,16 @@ import * as utilities from "./utilities"; * import * as pulumi from "@pulumi/pulumi"; * import * as digitalocean from "@pulumi/digitalocean"; * - * const foobarVolume = new digitalocean.Volume("foobarVolume", { + * const foobar = new digitalocean.Volume("foobar", { * region: digitalocean.Region.NYC1, + * name: "baz", * size: 100, * description: "an example volume", * }); - * const foobarVolumeSnapshot = new digitalocean.VolumeSnapshot("foobarVolumeSnapshot", {volumeId: foobarVolume.id}); + * const foobarVolumeSnapshot = new digitalocean.VolumeSnapshot("foobar", { + * name: "foo", + * volumeId: foobar.id, + * }); * ``` * * ## Import diff --git a/sdk/nodejs/vpc.ts b/sdk/nodejs/vpc.ts index ff873892..54db95c2 100644 --- a/sdk/nodejs/vpc.ts +++ b/sdk/nodejs/vpc.ts @@ -17,8 +17,9 @@ import * as utilities from "./utilities"; * import * as digitalocean from "@pulumi/digitalocean"; * * const example = new digitalocean.Vpc("example", { - * ipRange: "10.10.10.0/24", + * name: "example-project-network", * region: "nyc3", + * ipRange: "10.10.10.0/24", * }); * ``` * @@ -32,12 +33,16 @@ import * as utilities from "./utilities"; * import * as pulumi from "@pulumi/pulumi"; * import * as digitalocean from "@pulumi/digitalocean"; * - * const exampleVpc = new digitalocean.Vpc("exampleVpc", {region: "nyc3"}); - * const exampleDroplet = new digitalocean.Droplet("exampleDroplet", { + * const example = new digitalocean.Vpc("example", { + * name: "example-project-network", + * region: "nyc3", + * }); + * const exampleDroplet = new digitalocean.Droplet("example", { + * name: "example-01", * size: digitalocean.DropletSlug.DropletS1VCPU1GB, * image: "ubuntu-18-04-x64", * region: digitalocean.Region.NYC3, - * vpcUuid: exampleVpc.id, + * vpcUuid: example.id, * }); * ``` * diff --git a/sdk/python/pulumi_digitalocean/app.py b/sdk/python/pulumi_digitalocean/app.py index 8b18f82a..a27bf7e7 100644 --- a/sdk/python/pulumi_digitalocean/app.py +++ b/sdk/python/pulumi_digitalocean/app.py @@ -230,14 +230,14 @@ def __init__(__self__, name="golang-sample", region="ams", services=[digitalocean.AppSpecServiceArgs( + name="go-service", environment_slug="go", + instance_count=1, + instance_size_slug="professional-xs", git=digitalocean.AppSpecServiceGitArgs( - branch="main", repo_clone_url="https://github.com/digitalocean/sample-golang.git", + branch="main", ), - instance_count=1, - instance_size_slug="professional-xs", - name="go-service", )], )) ``` @@ -252,13 +252,13 @@ def __init__(__self__, name="static-site-example", region="ams", static_sites=[digitalocean.AppSpecStaticSiteArgs( + name="sample-jekyll", build_command="bundle exec jekyll build -d ./public", + output_dir="/public", git=digitalocean.AppSpecStaticSiteGitArgs( - branch="main", repo_clone_url="https://github.com/digitalocean/sample-jekyll.git", + branch="main", ), - name="sample-jekyll", - output_dir="/public", )], )) ``` @@ -303,14 +303,14 @@ def __init__(__self__, name="golang-sample", region="ams", services=[digitalocean.AppSpecServiceArgs( + name="go-service", environment_slug="go", + instance_count=1, + instance_size_slug="professional-xs", git=digitalocean.AppSpecServiceGitArgs( - branch="main", repo_clone_url="https://github.com/digitalocean/sample-golang.git", + branch="main", ), - instance_count=1, - instance_size_slug="professional-xs", - name="go-service", )], )) ``` @@ -325,13 +325,13 @@ def __init__(__self__, name="static-site-example", region="ams", static_sites=[digitalocean.AppSpecStaticSiteArgs( + name="sample-jekyll", build_command="bundle exec jekyll build -d ./public", + output_dir="/public", git=digitalocean.AppSpecStaticSiteGitArgs( - branch="main", repo_clone_url="https://github.com/digitalocean/sample-jekyll.git", + branch="main", ), - name="sample-jekyll", - output_dir="/public", )], )) ``` diff --git a/sdk/python/pulumi_digitalocean/cdn.py b/sdk/python/pulumi_digitalocean/cdn.py index e38dc69f..5883f9a5 100644 --- a/sdk/python/pulumi_digitalocean/cdn.py +++ b/sdk/python/pulumi_digitalocean/cdn.py @@ -254,6 +254,7 @@ def __init__(__self__, # Create a new Spaces Bucket mybucket = digitalocean.SpacesBucket("mybucket", + name="example", region=digitalocean.Region.SFO2, acl="public-read") # Add a CDN endpoint to the Spaces Bucket @@ -269,10 +270,12 @@ def __init__(__self__, # Create a new Spaces Bucket mybucket = digitalocean.SpacesBucket("mybucket", + name="example", region=digitalocean.Region.SFO2, acl="public-read") # Create a DigitalOcean managed Let's Encrypt Certificate cert = digitalocean.Certificate("cert", + name="cdn-cert", type=digitalocean.CertificateType.LETS_ENCRYPT, domains=["static.example.com"]) # Add a CDN endpoint with a custom sub-domain to the Spaces Bucket @@ -317,6 +320,7 @@ def __init__(__self__, # Create a new Spaces Bucket mybucket = digitalocean.SpacesBucket("mybucket", + name="example", region=digitalocean.Region.SFO2, acl="public-read") # Add a CDN endpoint to the Spaces Bucket @@ -332,10 +336,12 @@ def __init__(__self__, # Create a new Spaces Bucket mybucket = digitalocean.SpacesBucket("mybucket", + name="example", region=digitalocean.Region.SFO2, acl="public-read") # Create a DigitalOcean managed Let's Encrypt Certificate cert = digitalocean.Certificate("cert", + name="cdn-cert", type=digitalocean.CertificateType.LETS_ENCRYPT, domains=["static.example.com"]) # Add a CDN endpoint with a custom sub-domain to the Spaces Bucket diff --git a/sdk/python/pulumi_digitalocean/certificate.py b/sdk/python/pulumi_digitalocean/certificate.py index 55a43c87..f8a88b30 100644 --- a/sdk/python/pulumi_digitalocean/certificate.py +++ b/sdk/python/pulumi_digitalocean/certificate.py @@ -335,12 +335,14 @@ def __init__(__self__, ```python import pulumi import pulumi_digitalocean as digitalocean + import pulumi_std as std cert = digitalocean.Certificate("cert", + name="custom-example", type=digitalocean.CertificateType.CUSTOM, - private_key=(lambda path: open(path).read())("/Users/myuser/certs/privkey.pem"), - leaf_certificate=(lambda path: open(path).read())("/Users/myuser/certs/cert.pem"), - certificate_chain=(lambda path: open(path).read())("/Users/myuser/certs/fullchain.pem")) + private_key=std.file(input="/Users/myuser/certs/privkey.pem").result, + leaf_certificate=std.file(input="/Users/myuser/certs/cert.pem").result, + certificate_chain=std.file(input="/Users/myuser/certs/fullchain.pem").result) ``` ### Let's Encrypt Certificate @@ -350,8 +352,9 @@ def __init__(__self__, import pulumi_digitalocean as digitalocean cert = digitalocean.Certificate("cert", - domains=["example.com"], - type=digitalocean.CertificateType.LETS_ENCRYPT) + name="le-example", + type=digitalocean.CertificateType.LETS_ENCRYPT, + domains=["example.com"]) ``` ### Use with Other Resources @@ -364,10 +367,12 @@ def __init__(__self__, import pulumi_digitalocean as digitalocean cert = digitalocean.Certificate("cert", + name="le-example", type=digitalocean.CertificateType.LETS_ENCRYPT, domains=["example.com"]) # Create a new Load Balancer with TLS termination public = digitalocean.LoadBalancer("public", + name="secure-loadbalancer-1", region=digitalocean.Region.NYC3, droplet_tag="backend", forwarding_rules=[digitalocean.LoadBalancerForwardingRuleArgs( @@ -424,12 +429,14 @@ def __init__(__self__, ```python import pulumi import pulumi_digitalocean as digitalocean + import pulumi_std as std cert = digitalocean.Certificate("cert", + name="custom-example", type=digitalocean.CertificateType.CUSTOM, - private_key=(lambda path: open(path).read())("/Users/myuser/certs/privkey.pem"), - leaf_certificate=(lambda path: open(path).read())("/Users/myuser/certs/cert.pem"), - certificate_chain=(lambda path: open(path).read())("/Users/myuser/certs/fullchain.pem")) + private_key=std.file(input="/Users/myuser/certs/privkey.pem").result, + leaf_certificate=std.file(input="/Users/myuser/certs/cert.pem").result, + certificate_chain=std.file(input="/Users/myuser/certs/fullchain.pem").result) ``` ### Let's Encrypt Certificate @@ -439,8 +446,9 @@ def __init__(__self__, import pulumi_digitalocean as digitalocean cert = digitalocean.Certificate("cert", - domains=["example.com"], - type=digitalocean.CertificateType.LETS_ENCRYPT) + name="le-example", + type=digitalocean.CertificateType.LETS_ENCRYPT, + domains=["example.com"]) ``` ### Use with Other Resources @@ -453,10 +461,12 @@ def __init__(__self__, import pulumi_digitalocean as digitalocean cert = digitalocean.Certificate("cert", + name="le-example", type=digitalocean.CertificateType.LETS_ENCRYPT, domains=["example.com"]) # Create a new Load Balancer with TLS termination public = digitalocean.LoadBalancer("public", + name="secure-loadbalancer-1", region=digitalocean.Region.NYC3, droplet_tag="backend", forwarding_rules=[digitalocean.LoadBalancerForwardingRuleArgs( diff --git a/sdk/python/pulumi_digitalocean/container_registry.py b/sdk/python/pulumi_digitalocean/container_registry.py index c1f6d3d0..a540d013 100644 --- a/sdk/python/pulumi_digitalocean/container_registry.py +++ b/sdk/python/pulumi_digitalocean/container_registry.py @@ -206,7 +206,9 @@ def __init__(__self__, import pulumi_digitalocean as digitalocean # Create a new container registry - foobar = digitalocean.ContainerRegistry("foobar", subscription_tier_slug="starter") + foobar = digitalocean.ContainerRegistry("foobar", + name="foobar", + subscription_tier_slug="starter") ``` ## Import @@ -240,7 +242,9 @@ def __init__(__self__, import pulumi_digitalocean as digitalocean # Create a new container registry - foobar = digitalocean.ContainerRegistry("foobar", subscription_tier_slug="starter") + foobar = digitalocean.ContainerRegistry("foobar", + name="foobar", + subscription_tier_slug="starter") ``` ## Import diff --git a/sdk/python/pulumi_digitalocean/container_registry_docker_credentials.py b/sdk/python/pulumi_digitalocean/container_registry_docker_credentials.py index 190cd965..24942dff 100644 --- a/sdk/python/pulumi_digitalocean/container_registry_docker_credentials.py +++ b/sdk/python/pulumi_digitalocean/container_registry_docker_credentials.py @@ -189,8 +189,30 @@ def __init__(__self__, import pulumi import pulumi_digitalocean as digitalocean - example_container_registry = digitalocean.get_container_registry(name="example") - example_container_registry_docker_credentials = digitalocean.ContainerRegistryDockerCredentials("exampleContainerRegistryDockerCredentials", registry_name="example") + example = digitalocean.get_container_registry(name="example") + example_container_registry_docker_credentials = digitalocean.ContainerRegistryDockerCredentials("example", registry_name="example") + ``` + + ### Kubernetes Example + + Combined with the Kubernetes Provider's `kubernetes_secret` resource, you can + access the registry from inside your cluster: + + ```python + import pulumi + import pulumi_digitalocean as digitalocean + import pulumi_kubernetes as kubernetes + + example_container_registry_docker_credentials = digitalocean.ContainerRegistryDockerCredentials("example", registry_name="example") + example = digitalocean.get_kubernetes_cluster(name="prod-cluster-01") + example_secret = kubernetes.core.v1.Secret("example", + metadata=kubernetes.meta.v1.ObjectMetaArgs( + name="docker-cfg", + ), + data={ + ".dockerconfigjson": example_container_registry_docker_credentials.docker_credentials, + }, + type="kubernetes.io/dockerconfigjson") ``` :param str resource_name: The name of the resource. @@ -231,8 +253,30 @@ def __init__(__self__, import pulumi import pulumi_digitalocean as digitalocean - example_container_registry = digitalocean.get_container_registry(name="example") - example_container_registry_docker_credentials = digitalocean.ContainerRegistryDockerCredentials("exampleContainerRegistryDockerCredentials", registry_name="example") + example = digitalocean.get_container_registry(name="example") + example_container_registry_docker_credentials = digitalocean.ContainerRegistryDockerCredentials("example", registry_name="example") + ``` + + ### Kubernetes Example + + Combined with the Kubernetes Provider's `kubernetes_secret` resource, you can + access the registry from inside your cluster: + + ```python + import pulumi + import pulumi_digitalocean as digitalocean + import pulumi_kubernetes as kubernetes + + example_container_registry_docker_credentials = digitalocean.ContainerRegistryDockerCredentials("example", registry_name="example") + example = digitalocean.get_kubernetes_cluster(name="prod-cluster-01") + example_secret = kubernetes.core.v1.Secret("example", + metadata=kubernetes.meta.v1.ObjectMetaArgs( + name="docker-cfg", + ), + data={ + ".dockerconfigjson": example_container_registry_docker_credentials.docker_credentials, + }, + type="kubernetes.io/dockerconfigjson") ``` :param str resource_name: The name of the resource. diff --git a/sdk/python/pulumi_digitalocean/custom_image.py b/sdk/python/pulumi_digitalocean/custom_image.py index 4ea6ed7e..49c6d786 100644 --- a/sdk/python/pulumi_digitalocean/custom_image.py +++ b/sdk/python/pulumi_digitalocean/custom_image.py @@ -377,10 +377,12 @@ def __init__(__self__, import pulumi_digitalocean as digitalocean flatcar = digitalocean.CustomImage("flatcar", + name="flatcar", url="https://stable.release.flatcar-linux.net/amd64-usr/2605.7.0/flatcar_production_digitalocean_image.bin.bz2", regions=["nyc3"]) example = digitalocean.Droplet("example", image=flatcar.id, + name="example-01", region=digitalocean.Region.NYC3, size=digitalocean.DropletSlug.DROPLET_S1_VCPU1_GB, ssh_keys=["12345"]) @@ -421,10 +423,12 @@ def __init__(__self__, import pulumi_digitalocean as digitalocean flatcar = digitalocean.CustomImage("flatcar", + name="flatcar", url="https://stable.release.flatcar-linux.net/amd64-usr/2605.7.0/flatcar_production_digitalocean_image.bin.bz2", regions=["nyc3"]) example = digitalocean.Droplet("example", image=flatcar.id, + name="example-01", region=digitalocean.Region.NYC3, size=digitalocean.DropletSlug.DROPLET_S1_VCPU1_GB, ssh_keys=["12345"]) diff --git a/sdk/python/pulumi_digitalocean/database_cluster.py b/sdk/python/pulumi_digitalocean/database_cluster.py index 588b752c..25cc0c20 100644 --- a/sdk/python/pulumi_digitalocean/database_cluster.py +++ b/sdk/python/pulumi_digitalocean/database_cluster.py @@ -741,11 +741,12 @@ def __init__(__self__, import pulumi_digitalocean as digitalocean postgres_example = digitalocean.DatabaseCluster("postgres-example", + name="example-postgres-cluster", engine="pg", - node_count=1, - region=digitalocean.Region.NYC1, + version="15", size=digitalocean.DatabaseSlug.D_B_1_VPCU1_GB, - version="15") + region=digitalocean.Region.NYC1, + node_count=1) ``` ### Create a new MySQL database cluster @@ -754,11 +755,12 @@ def __init__(__self__, import pulumi_digitalocean as digitalocean mysql_example = digitalocean.DatabaseCluster("mysql-example", + name="example-mysql-cluster", engine="mysql", - node_count=1, - region=digitalocean.Region.NYC1, + version="8", size=digitalocean.DatabaseSlug.D_B_1_VPCU1_GB, - version="8") + region=digitalocean.Region.NYC1, + node_count=1) ``` ### Create a new Redis database cluster @@ -767,11 +769,12 @@ def __init__(__self__, import pulumi_digitalocean as digitalocean redis_example = digitalocean.DatabaseCluster("redis-example", + name="example-redis-cluster", engine="redis", - node_count=1, - region=digitalocean.Region.NYC1, + version="7", size=digitalocean.DatabaseSlug.D_B_1_VPCU1_GB, - version="7") + region=digitalocean.Region.NYC1, + node_count=1) ``` ### Create a new Kafka database cluster @@ -780,11 +783,12 @@ def __init__(__self__, import pulumi_digitalocean as digitalocean kafka_example = digitalocean.DatabaseCluster("kafka-example", + name="example-kafka-cluster", engine="kafka", - node_count=3, - region=digitalocean.Region.NYC1, + version="3.5", size="db-s-2vcpu-2gb", - version="3.5") + region=digitalocean.Region.NYC1, + node_count=3) ``` ### Create a new MongoDB database cluster @@ -793,11 +797,12 @@ def __init__(__self__, import pulumi_digitalocean as digitalocean mongodb_example = digitalocean.DatabaseCluster("mongodb-example", + name="example-mongo-cluster", engine="mongodb", - node_count=1, - region=digitalocean.Region.NYC3, + version="6", size=digitalocean.DatabaseSlug.D_B_1_VPCU1_GB, - version="6") + region=digitalocean.Region.NYC3, + node_count=1) ``` ## Create a new database cluster based on a backup of an existing cluster. @@ -807,13 +812,15 @@ def __init__(__self__, import pulumi_digitalocean as digitalocean doby = digitalocean.DatabaseCluster("doby", + name="dobydb", engine="pg", version="15", size=digitalocean.DatabaseSlug.D_B_1_VPCU2_GB, region=digitalocean.Region.NYC1, node_count=1, tags=["production"]) - doby_backup = digitalocean.DatabaseCluster("dobyBackup", + doby_backup = digitalocean.DatabaseCluster("doby_backup", + name="dobydupe", engine="pg", version="15", size=digitalocean.DatabaseSlug.D_B_1_VPCU2_GB, @@ -868,11 +875,12 @@ def __init__(__self__, import pulumi_digitalocean as digitalocean postgres_example = digitalocean.DatabaseCluster("postgres-example", + name="example-postgres-cluster", engine="pg", - node_count=1, - region=digitalocean.Region.NYC1, + version="15", size=digitalocean.DatabaseSlug.D_B_1_VPCU1_GB, - version="15") + region=digitalocean.Region.NYC1, + node_count=1) ``` ### Create a new MySQL database cluster @@ -881,11 +889,12 @@ def __init__(__self__, import pulumi_digitalocean as digitalocean mysql_example = digitalocean.DatabaseCluster("mysql-example", + name="example-mysql-cluster", engine="mysql", - node_count=1, - region=digitalocean.Region.NYC1, + version="8", size=digitalocean.DatabaseSlug.D_B_1_VPCU1_GB, - version="8") + region=digitalocean.Region.NYC1, + node_count=1) ``` ### Create a new Redis database cluster @@ -894,11 +903,12 @@ def __init__(__self__, import pulumi_digitalocean as digitalocean redis_example = digitalocean.DatabaseCluster("redis-example", + name="example-redis-cluster", engine="redis", - node_count=1, - region=digitalocean.Region.NYC1, + version="7", size=digitalocean.DatabaseSlug.D_B_1_VPCU1_GB, - version="7") + region=digitalocean.Region.NYC1, + node_count=1) ``` ### Create a new Kafka database cluster @@ -907,11 +917,12 @@ def __init__(__self__, import pulumi_digitalocean as digitalocean kafka_example = digitalocean.DatabaseCluster("kafka-example", + name="example-kafka-cluster", engine="kafka", - node_count=3, - region=digitalocean.Region.NYC1, + version="3.5", size="db-s-2vcpu-2gb", - version="3.5") + region=digitalocean.Region.NYC1, + node_count=3) ``` ### Create a new MongoDB database cluster @@ -920,11 +931,12 @@ def __init__(__self__, import pulumi_digitalocean as digitalocean mongodb_example = digitalocean.DatabaseCluster("mongodb-example", + name="example-mongo-cluster", engine="mongodb", - node_count=1, - region=digitalocean.Region.NYC3, + version="6", size=digitalocean.DatabaseSlug.D_B_1_VPCU1_GB, - version="6") + region=digitalocean.Region.NYC3, + node_count=1) ``` ## Create a new database cluster based on a backup of an existing cluster. @@ -934,13 +946,15 @@ def __init__(__self__, import pulumi_digitalocean as digitalocean doby = digitalocean.DatabaseCluster("doby", + name="dobydb", engine="pg", version="15", size=digitalocean.DatabaseSlug.D_B_1_VPCU2_GB, region=digitalocean.Region.NYC1, node_count=1, tags=["production"]) - doby_backup = digitalocean.DatabaseCluster("dobyBackup", + doby_backup = digitalocean.DatabaseCluster("doby_backup", + name="dobydupe", engine="pg", version="15", size=digitalocean.DatabaseSlug.D_B_1_VPCU2_GB, diff --git a/sdk/python/pulumi_digitalocean/database_connection_pool.py b/sdk/python/pulumi_digitalocean/database_connection_pool.py index d6597dbb..52413713 100644 --- a/sdk/python/pulumi_digitalocean/database_connection_pool.py +++ b/sdk/python/pulumi_digitalocean/database_connection_pool.py @@ -334,6 +334,7 @@ def __init__(__self__, import pulumi_digitalocean as digitalocean postgres_example = digitalocean.DatabaseCluster("postgres-example", + name="example-postgres-cluster", engine="pg", version="15", size=digitalocean.DatabaseSlug.D_B_1_VPCU1_GB, @@ -341,6 +342,7 @@ def __init__(__self__, node_count=1) pool_01 = digitalocean.DatabaseConnectionPool("pool-01", cluster_id=postgres_example.id, + name="pool-01", mode="transaction", size=20, db_name="defaultdb", @@ -383,6 +385,7 @@ def __init__(__self__, import pulumi_digitalocean as digitalocean postgres_example = digitalocean.DatabaseCluster("postgres-example", + name="example-postgres-cluster", engine="pg", version="15", size=digitalocean.DatabaseSlug.D_B_1_VPCU1_GB, @@ -390,6 +393,7 @@ def __init__(__self__, node_count=1) pool_01 = digitalocean.DatabaseConnectionPool("pool-01", cluster_id=postgres_example.id, + name="pool-01", mode="transaction", size=20, db_name="defaultdb", diff --git a/sdk/python/pulumi_digitalocean/database_db.py b/sdk/python/pulumi_digitalocean/database_db.py index 38e97565..708adb02 100644 --- a/sdk/python/pulumi_digitalocean/database_db.py +++ b/sdk/python/pulumi_digitalocean/database_db.py @@ -109,12 +109,15 @@ def __init__(__self__, import pulumi_digitalocean as digitalocean postgres_example = digitalocean.DatabaseCluster("postgres-example", + name="example-postgres-cluster", engine="pg", version="15", size=digitalocean.DatabaseSlug.D_B_1_VPCU1_GB, region=digitalocean.Region.NYC1, node_count=1) - database_example = digitalocean.DatabaseDb("database-example", cluster_id=postgres_example.id) + database_example = digitalocean.DatabaseDb("database-example", + cluster_id=postgres_example.id, + name="foobar") ``` ## Import @@ -149,12 +152,15 @@ def __init__(__self__, import pulumi_digitalocean as digitalocean postgres_example = digitalocean.DatabaseCluster("postgres-example", + name="example-postgres-cluster", engine="pg", version="15", size=digitalocean.DatabaseSlug.D_B_1_VPCU1_GB, region=digitalocean.Region.NYC1, node_count=1) - database_example = digitalocean.DatabaseDb("database-example", cluster_id=postgres_example.id) + database_example = digitalocean.DatabaseDb("database-example", + cluster_id=postgres_example.id, + name="foobar") ``` ## Import diff --git a/sdk/python/pulumi_digitalocean/database_firewall.py b/sdk/python/pulumi_digitalocean/database_firewall.py index 6c2b2e90..3ac2b6eb 100644 --- a/sdk/python/pulumi_digitalocean/database_firewall.py +++ b/sdk/python/pulumi_digitalocean/database_firewall.py @@ -113,6 +113,7 @@ def __init__(__self__, import pulumi_digitalocean as digitalocean postgres_example = digitalocean.DatabaseCluster("postgres-example", + name="example-postgres-cluster", engine="pg", version="15", size=digitalocean.DatabaseSlug.D_B_1_VPCU1_GB, @@ -139,10 +140,12 @@ def __init__(__self__, import pulumi_digitalocean as digitalocean web = digitalocean.Droplet("web", + name="web-01", size=digitalocean.DropletSlug.DROPLET_S1_VCPU1_GB, image="ubuntu-22-04-x64", region=digitalocean.Region.NYC3) postgres_example = digitalocean.DatabaseCluster("postgres-example", + name="example-postgres-cluster", engine="pg", version="15", size=digitalocean.DatabaseSlug.D_B_1_VPCU1_GB, @@ -163,6 +166,7 @@ def __init__(__self__, import pulumi_digitalocean as digitalocean postgres_example = digitalocean.DatabaseCluster("postgres-example", + name="example-postgres-cluster", engine="pg", version="15", size=digitalocean.DatabaseSlug.D_B_1_VPCU1_GB, @@ -170,6 +174,7 @@ def __init__(__self__, node_count=1) replica_example = digitalocean.DatabaseReplica("replica-example", cluster_id=postgres_example.id, + name="replica-example", size=digitalocean.DatabaseSlug.D_B_1_VPCU1_GB, region=digitalocean.Region.NYC1) # Create firewall rule for database replica @@ -216,6 +221,7 @@ def __init__(__self__, import pulumi_digitalocean as digitalocean postgres_example = digitalocean.DatabaseCluster("postgres-example", + name="example-postgres-cluster", engine="pg", version="15", size=digitalocean.DatabaseSlug.D_B_1_VPCU1_GB, @@ -242,10 +248,12 @@ def __init__(__self__, import pulumi_digitalocean as digitalocean web = digitalocean.Droplet("web", + name="web-01", size=digitalocean.DropletSlug.DROPLET_S1_VCPU1_GB, image="ubuntu-22-04-x64", region=digitalocean.Region.NYC3) postgres_example = digitalocean.DatabaseCluster("postgres-example", + name="example-postgres-cluster", engine="pg", version="15", size=digitalocean.DatabaseSlug.D_B_1_VPCU1_GB, @@ -266,6 +274,7 @@ def __init__(__self__, import pulumi_digitalocean as digitalocean postgres_example = digitalocean.DatabaseCluster("postgres-example", + name="example-postgres-cluster", engine="pg", version="15", size=digitalocean.DatabaseSlug.D_B_1_VPCU1_GB, @@ -273,6 +282,7 @@ def __init__(__self__, node_count=1) replica_example = digitalocean.DatabaseReplica("replica-example", cluster_id=postgres_example.id, + name="replica-example", size=digitalocean.DatabaseSlug.D_B_1_VPCU1_GB, region=digitalocean.Region.NYC1) # Create firewall rule for database replica diff --git a/sdk/python/pulumi_digitalocean/database_kafka_topic.py b/sdk/python/pulumi_digitalocean/database_kafka_topic.py index e2c5a95f..b8668814 100644 --- a/sdk/python/pulumi_digitalocean/database_kafka_topic.py +++ b/sdk/python/pulumi_digitalocean/database_kafka_topic.py @@ -230,6 +230,7 @@ def __init__(__self__, import pulumi_digitalocean as digitalocean kafka_example = digitalocean.DatabaseCluster("kafka-example", + name="example-kafka-cluster", engine="kafka", version="3.5", size="db-s-2vcpu-2gb", @@ -238,6 +239,7 @@ def __init__(__self__, tags=["production"]) topic_01 = digitalocean.DatabaseKafkaTopic("topic-01", cluster_id=kafka_example.id, + name="topic-01", partition_count=3, replication_factor=2, configs=[digitalocean.DatabaseKafkaTopicConfigArgs( @@ -301,6 +303,7 @@ def __init__(__self__, import pulumi_digitalocean as digitalocean kafka_example = digitalocean.DatabaseCluster("kafka-example", + name="example-kafka-cluster", engine="kafka", version="3.5", size="db-s-2vcpu-2gb", @@ -309,6 +312,7 @@ def __init__(__self__, tags=["production"]) topic_01 = digitalocean.DatabaseKafkaTopic("topic-01", cluster_id=kafka_example.id, + name="topic-01", partition_count=3, replication_factor=2, configs=[digitalocean.DatabaseKafkaTopicConfigArgs( diff --git a/sdk/python/pulumi_digitalocean/database_mysql_config.py b/sdk/python/pulumi_digitalocean/database_mysql_config.py index a47466da..e8a5c607 100644 --- a/sdk/python/pulumi_digitalocean/database_mysql_config.py +++ b/sdk/python/pulumi_digitalocean/database_mysql_config.py @@ -968,13 +968,14 @@ def __init__(__self__, import pulumi import pulumi_digitalocean as digitalocean - example_database_cluster = digitalocean.DatabaseCluster("exampleDatabaseCluster", + example_database_cluster = digitalocean.DatabaseCluster("example", + name="example-mysql-cluster", engine="mysql", version="8", size=digitalocean.DatabaseSlug.D_B_1_VPCU1_GB, region=digitalocean.Region.NYC1, node_count=1) - example_database_mysql_config = digitalocean.DatabaseMysqlConfig("exampleDatabaseMysqlConfig", + example = digitalocean.DatabaseMysqlConfig("example", cluster_id=example_database_cluster.id, connect_timeout=10, default_time_zone="UTC") @@ -1037,13 +1038,14 @@ def __init__(__self__, import pulumi import pulumi_digitalocean as digitalocean - example_database_cluster = digitalocean.DatabaseCluster("exampleDatabaseCluster", + example_database_cluster = digitalocean.DatabaseCluster("example", + name="example-mysql-cluster", engine="mysql", version="8", size=digitalocean.DatabaseSlug.D_B_1_VPCU1_GB, region=digitalocean.Region.NYC1, node_count=1) - example_database_mysql_config = digitalocean.DatabaseMysqlConfig("exampleDatabaseMysqlConfig", + example = digitalocean.DatabaseMysqlConfig("example", cluster_id=example_database_cluster.id, connect_timeout=10, default_time_zone="UTC") diff --git a/sdk/python/pulumi_digitalocean/database_postgresql_config.py b/sdk/python/pulumi_digitalocean/database_postgresql_config.py index b26efead..e2a0dcb0 100644 --- a/sdk/python/pulumi_digitalocean/database_postgresql_config.py +++ b/sdk/python/pulumi_digitalocean/database_postgresql_config.py @@ -1762,13 +1762,14 @@ def __init__(__self__, import pulumi import pulumi_digitalocean as digitalocean - example_database_cluster = digitalocean.DatabaseCluster("exampleDatabaseCluster", + example_database_cluster = digitalocean.DatabaseCluster("example", + name="example-postgresql-cluster", engine="pg", version="15", size=digitalocean.DatabaseSlug.D_B_1_VPCU1_GB, region=digitalocean.Region.NYC1, node_count=1) - example_database_postgresql_config = digitalocean.DatabasePostgresqlConfig("exampleDatabasePostgresqlConfig", + example = digitalocean.DatabasePostgresqlConfig("example", cluster_id=example_database_cluster.id, timezone="UTC", work_mem=16) @@ -1857,13 +1858,14 @@ def __init__(__self__, import pulumi import pulumi_digitalocean as digitalocean - example_database_cluster = digitalocean.DatabaseCluster("exampleDatabaseCluster", + example_database_cluster = digitalocean.DatabaseCluster("example", + name="example-postgresql-cluster", engine="pg", version="15", size=digitalocean.DatabaseSlug.D_B_1_VPCU1_GB, region=digitalocean.Region.NYC1, node_count=1) - example_database_postgresql_config = digitalocean.DatabasePostgresqlConfig("exampleDatabasePostgresqlConfig", + example = digitalocean.DatabasePostgresqlConfig("example", cluster_id=example_database_cluster.id, timezone="UTC", work_mem=16) diff --git a/sdk/python/pulumi_digitalocean/database_redis_config.py b/sdk/python/pulumi_digitalocean/database_redis_config.py index 99ff8bb8..1352c14d 100644 --- a/sdk/python/pulumi_digitalocean/database_redis_config.py +++ b/sdk/python/pulumi_digitalocean/database_redis_config.py @@ -440,13 +440,14 @@ def __init__(__self__, import pulumi import pulumi_digitalocean as digitalocean - example_database_cluster = digitalocean.DatabaseCluster("exampleDatabaseCluster", + example_database_cluster = digitalocean.DatabaseCluster("example", + name="example-redis-cluster", engine="redis", version="7", size=digitalocean.DatabaseSlug.D_B_1_VPCU1_GB, region=digitalocean.Region.NYC1, node_count=1) - example_database_redis_config = digitalocean.DatabaseRedisConfig("exampleDatabaseRedisConfig", + example = digitalocean.DatabaseRedisConfig("example", cluster_id=example_database_cluster.id, maxmemory_policy="allkeys-lru", notify_keyspace_events="KEA", @@ -494,13 +495,14 @@ def __init__(__self__, import pulumi import pulumi_digitalocean as digitalocean - example_database_cluster = digitalocean.DatabaseCluster("exampleDatabaseCluster", + example_database_cluster = digitalocean.DatabaseCluster("example", + name="example-redis-cluster", engine="redis", version="7", size=digitalocean.DatabaseSlug.D_B_1_VPCU1_GB, region=digitalocean.Region.NYC1, node_count=1) - example_database_redis_config = digitalocean.DatabaseRedisConfig("exampleDatabaseRedisConfig", + example = digitalocean.DatabaseRedisConfig("example", cluster_id=example_database_cluster.id, maxmemory_policy="allkeys-lru", notify_keyspace_events="KEA", diff --git a/sdk/python/pulumi_digitalocean/database_replica.py b/sdk/python/pulumi_digitalocean/database_replica.py index e77d7c8a..581a465e 100644 --- a/sdk/python/pulumi_digitalocean/database_replica.py +++ b/sdk/python/pulumi_digitalocean/database_replica.py @@ -411,6 +411,7 @@ def __init__(__self__, import pulumi_digitalocean as digitalocean postgres_example = digitalocean.DatabaseCluster("postgres-example", + name="example-postgres-cluster", engine="pg", version="15", size=digitalocean.DatabaseSlug.D_B_1_VPCU1_GB, @@ -418,9 +419,10 @@ def __init__(__self__, node_count=1) replica_example = digitalocean.DatabaseReplica("replica-example", cluster_id=postgres_example.id, + name="replica-example", size=digitalocean.DatabaseSlug.D_B_1_VPCU1_GB, region=digitalocean.Region.NYC1) - pulumi.export("uUID", replica_example.uuid) + pulumi.export("UUID", replica_example.uuid) # Create firewall rule for database replica example_fw = digitalocean.DatabaseFirewall("example-fw", cluster_id=replica_example.uuid, @@ -466,6 +468,7 @@ def __init__(__self__, import pulumi_digitalocean as digitalocean postgres_example = digitalocean.DatabaseCluster("postgres-example", + name="example-postgres-cluster", engine="pg", version="15", size=digitalocean.DatabaseSlug.D_B_1_VPCU1_GB, @@ -473,9 +476,10 @@ def __init__(__self__, node_count=1) replica_example = digitalocean.DatabaseReplica("replica-example", cluster_id=postgres_example.id, + name="replica-example", size=digitalocean.DatabaseSlug.D_B_1_VPCU1_GB, region=digitalocean.Region.NYC1) - pulumi.export("uUID", replica_example.uuid) + pulumi.export("UUID", replica_example.uuid) # Create firewall rule for database replica example_fw = digitalocean.DatabaseFirewall("example-fw", cluster_id=replica_example.uuid, diff --git a/sdk/python/pulumi_digitalocean/database_user.py b/sdk/python/pulumi_digitalocean/database_user.py index 15c386d6..0611d313 100644 --- a/sdk/python/pulumi_digitalocean/database_user.py +++ b/sdk/python/pulumi_digitalocean/database_user.py @@ -247,12 +247,15 @@ def __init__(__self__, import pulumi_digitalocean as digitalocean postgres_example = digitalocean.DatabaseCluster("postgres-example", + name="example-postgres-cluster", engine="pg", version="15", size=digitalocean.DatabaseSlug.D_B_1_VPCU1_GB, region=digitalocean.Region.NYC1, node_count=1) - user_example = digitalocean.DatabaseUser("user-example", cluster_id=postgres_example.id) + user_example = digitalocean.DatabaseUser("user-example", + cluster_id=postgres_example.id, + name="foobar") ``` ### Create a new user for a PostgreSQL database replica @@ -261,6 +264,7 @@ def __init__(__self__, import pulumi_digitalocean as digitalocean postgres_example = digitalocean.DatabaseCluster("postgres-example", + name="example-postgres-cluster", engine="pg", version="15", size=digitalocean.DatabaseSlug.D_B_1_VPCU1_GB, @@ -268,9 +272,12 @@ def __init__(__self__, node_count=1) replica_example = digitalocean.DatabaseReplica("replica-example", cluster_id=postgres_example.id, + name="replica-example", size=digitalocean.DatabaseSlug.D_B_1_VPCU1_GB, region=digitalocean.Region.NYC1) - user_example = digitalocean.DatabaseUser("user-example", cluster_id=replica_example.uuid) + user_example = digitalocean.DatabaseUser("user-example", + cluster_id=replica_example.uuid, + name="foobar") ``` ### Create a new user for a Kafka database cluster @@ -279,14 +286,18 @@ def __init__(__self__, import pulumi_digitalocean as digitalocean kafka_example = digitalocean.DatabaseCluster("kafka-example", + name="example-kafka-cluster", engine="kafka", version="3.5", size="db-s-2vcpu-2gb", region=digitalocean.Region.NYC1, node_count=3) - foobar_topic = digitalocean.DatabaseKafkaTopic("foobarTopic", cluster_id=digitalocean_database_cluster["foobar"]["id"]) - foobar_user = digitalocean.DatabaseUser("foobarUser", - cluster_id=digitalocean_database_cluster["foobar"]["id"], + foobar_topic = digitalocean.DatabaseKafkaTopic("foobar_topic", + cluster_id=foobar["id"], + name="topic-1") + foobar_user = digitalocean.DatabaseUser("foobar_user", + cluster_id=foobar["id"], + name="example-user", settings=[digitalocean.DatabaseUserSettingArgs( acls=[ digitalocean.DatabaseUserSettingAclArgs( @@ -342,12 +353,15 @@ def __init__(__self__, import pulumi_digitalocean as digitalocean postgres_example = digitalocean.DatabaseCluster("postgres-example", + name="example-postgres-cluster", engine="pg", version="15", size=digitalocean.DatabaseSlug.D_B_1_VPCU1_GB, region=digitalocean.Region.NYC1, node_count=1) - user_example = digitalocean.DatabaseUser("user-example", cluster_id=postgres_example.id) + user_example = digitalocean.DatabaseUser("user-example", + cluster_id=postgres_example.id, + name="foobar") ``` ### Create a new user for a PostgreSQL database replica @@ -356,6 +370,7 @@ def __init__(__self__, import pulumi_digitalocean as digitalocean postgres_example = digitalocean.DatabaseCluster("postgres-example", + name="example-postgres-cluster", engine="pg", version="15", size=digitalocean.DatabaseSlug.D_B_1_VPCU1_GB, @@ -363,9 +378,12 @@ def __init__(__self__, node_count=1) replica_example = digitalocean.DatabaseReplica("replica-example", cluster_id=postgres_example.id, + name="replica-example", size=digitalocean.DatabaseSlug.D_B_1_VPCU1_GB, region=digitalocean.Region.NYC1) - user_example = digitalocean.DatabaseUser("user-example", cluster_id=replica_example.uuid) + user_example = digitalocean.DatabaseUser("user-example", + cluster_id=replica_example.uuid, + name="foobar") ``` ### Create a new user for a Kafka database cluster @@ -374,14 +392,18 @@ def __init__(__self__, import pulumi_digitalocean as digitalocean kafka_example = digitalocean.DatabaseCluster("kafka-example", + name="example-kafka-cluster", engine="kafka", version="3.5", size="db-s-2vcpu-2gb", region=digitalocean.Region.NYC1, node_count=3) - foobar_topic = digitalocean.DatabaseKafkaTopic("foobarTopic", cluster_id=digitalocean_database_cluster["foobar"]["id"]) - foobar_user = digitalocean.DatabaseUser("foobarUser", - cluster_id=digitalocean_database_cluster["foobar"]["id"], + foobar_topic = digitalocean.DatabaseKafkaTopic("foobar_topic", + cluster_id=foobar["id"], + name="topic-1") + foobar_user = digitalocean.DatabaseUser("foobar_user", + cluster_id=foobar["id"], + name="example-user", settings=[digitalocean.DatabaseUserSettingArgs( acls=[ digitalocean.DatabaseUserSettingAclArgs( diff --git a/sdk/python/pulumi_digitalocean/dns_record.py b/sdk/python/pulumi_digitalocean/dns_record.py index 391e3af7..a08ab4cc 100644 --- a/sdk/python/pulumi_digitalocean/dns_record.py +++ b/sdk/python/pulumi_digitalocean/dns_record.py @@ -391,11 +391,13 @@ def __init__(__self__, www = digitalocean.DnsRecord("www", domain=default.id, type=digitalocean.RecordType.A, + name="www", value="192.168.0.11") # Add a MX record for the example.com domain itself. mx = digitalocean.DnsRecord("mx", domain=default.id, type=digitalocean.RecordType.MX, + name="@", priority=10, value="mail.example.com.") pulumi.export("wwwFqdn", www.fqdn) @@ -445,11 +447,13 @@ def __init__(__self__, www = digitalocean.DnsRecord("www", domain=default.id, type=digitalocean.RecordType.A, + name="www", value="192.168.0.11") # Add a MX record for the example.com domain itself. mx = digitalocean.DnsRecord("mx", domain=default.id, type=digitalocean.RecordType.MX, + name="@", priority=10, value="mail.example.com.") pulumi.export("wwwFqdn", www.fqdn) diff --git a/sdk/python/pulumi_digitalocean/domain.py b/sdk/python/pulumi_digitalocean/domain.py index 58d871b6..10877d06 100644 --- a/sdk/python/pulumi_digitalocean/domain.py +++ b/sdk/python/pulumi_digitalocean/domain.py @@ -146,7 +146,7 @@ def __init__(__self__, # Create a new domain default = digitalocean.Domain("default", name="example.com", - ip_address=digitalocean_droplet["foo"]["ipv4_address"]) + ip_address=foo["ipv4Address"]) ``` ## Import @@ -181,7 +181,7 @@ def __init__(__self__, # Create a new domain default = digitalocean.Domain("default", name="example.com", - ip_address=digitalocean_droplet["foo"]["ipv4_address"]) + ip_address=foo["ipv4Address"]) ``` ## Import diff --git a/sdk/python/pulumi_digitalocean/droplet.py b/sdk/python/pulumi_digitalocean/droplet.py index 2056e684..cc610a0c 100644 --- a/sdk/python/pulumi_digitalocean/droplet.py +++ b/sdk/python/pulumi_digitalocean/droplet.py @@ -878,6 +878,7 @@ def __init__(__self__, # Create a new Web Droplet in the nyc2 region web = digitalocean.Droplet("web", image="ubuntu-20-04-x64", + name="web-1", region=digitalocean.Region.NYC2, size=digitalocean.DropletSlug.DROPLET_S1_VCPU1_GB) ``` @@ -952,6 +953,7 @@ def __init__(__self__, # Create a new Web Droplet in the nyc2 region web = digitalocean.Droplet("web", image="ubuntu-20-04-x64", + name="web-1", region=digitalocean.Region.NYC2, size=digitalocean.DropletSlug.DROPLET_S1_VCPU1_GB) ``` diff --git a/sdk/python/pulumi_digitalocean/droplet_snapshot.py b/sdk/python/pulumi_digitalocean/droplet_snapshot.py index 068a1908..83f11cea 100644 --- a/sdk/python/pulumi_digitalocean/droplet_snapshot.py +++ b/sdk/python/pulumi_digitalocean/droplet_snapshot.py @@ -172,12 +172,16 @@ def __init__(__self__, import pulumi_digitalocean as digitalocean web = digitalocean.Droplet("web", + name="web-01", size=digitalocean.DropletSlug.DROPLET_S1_VCPU1_GB, image="ubuntu-22-04-x64", region=digitalocean.Region.NYC3) - web_snapshot = digitalocean.DropletSnapshot("web-snapshot", droplet_id=web.id) + web_snapshot = digitalocean.DropletSnapshot("web-snapshot", + droplet_id=web.id, + name="web-snapshot-01") from_snapshot = digitalocean.Droplet("from-snapshot", image=web_snapshot.id, + name="web-02", region=digitalocean.Region.NYC3, size=digitalocean.DropletSlug.DROPLET_S2_VCPU4_GB) ``` @@ -211,12 +215,16 @@ def __init__(__self__, import pulumi_digitalocean as digitalocean web = digitalocean.Droplet("web", + name="web-01", size=digitalocean.DropletSlug.DROPLET_S1_VCPU1_GB, image="ubuntu-22-04-x64", region=digitalocean.Region.NYC3) - web_snapshot = digitalocean.DropletSnapshot("web-snapshot", droplet_id=web.id) + web_snapshot = digitalocean.DropletSnapshot("web-snapshot", + droplet_id=web.id, + name="web-snapshot-01") from_snapshot = digitalocean.Droplet("from-snapshot", image=web_snapshot.id, + name="web-02", region=digitalocean.Region.NYC3, size=digitalocean.DropletSlug.DROPLET_S2_VCPU4_GB) ``` diff --git a/sdk/python/pulumi_digitalocean/firewall.py b/sdk/python/pulumi_digitalocean/firewall.py index 281126e3..91c1d013 100644 --- a/sdk/python/pulumi_digitalocean/firewall.py +++ b/sdk/python/pulumi_digitalocean/firewall.py @@ -280,12 +280,14 @@ def __init__(__self__, import pulumi import pulumi_digitalocean as digitalocean - web_droplet = digitalocean.Droplet("webDroplet", + web = digitalocean.Droplet("web", + name="web-1", size=digitalocean.DropletSlug.DROPLET_S1_VCPU1_GB, image="ubuntu-18-04-x64", region=digitalocean.Region.NYC3) - web_firewall = digitalocean.Firewall("webFirewall", - droplet_ids=[web_droplet.id], + web_firewall = digitalocean.Firewall("web", + name="only-22-80-and-443", + droplet_ids=[web.id], inbound_rules=[ digitalocean.FirewallInboundRuleArgs( protocol="tcp", @@ -381,12 +383,14 @@ def __init__(__self__, import pulumi import pulumi_digitalocean as digitalocean - web_droplet = digitalocean.Droplet("webDroplet", + web = digitalocean.Droplet("web", + name="web-1", size=digitalocean.DropletSlug.DROPLET_S1_VCPU1_GB, image="ubuntu-18-04-x64", region=digitalocean.Region.NYC3) - web_firewall = digitalocean.Firewall("webFirewall", - droplet_ids=[web_droplet.id], + web_firewall = digitalocean.Firewall("web", + name="only-22-80-and-443", + droplet_ids=[web.id], inbound_rules=[ digitalocean.FirewallInboundRuleArgs( protocol="tcp", diff --git a/sdk/python/pulumi_digitalocean/floating_ip.py b/sdk/python/pulumi_digitalocean/floating_ip.py index 85cd996c..e07e5cc3 100644 --- a/sdk/python/pulumi_digitalocean/floating_ip.py +++ b/sdk/python/pulumi_digitalocean/floating_ip.py @@ -160,15 +160,16 @@ def __init__(__self__, import pulumi import pulumi_digitalocean as digitalocean - foobar_droplet = digitalocean.Droplet("foobarDroplet", + foobar = digitalocean.Droplet("foobar", + name="baz", size=digitalocean.DropletSlug.DROPLET_S1_VCPU1_GB, image="ubuntu-18-04-x64", region=digitalocean.Region.SGP1, ipv6=True, private_networking=True) - foobar_floating_ip = digitalocean.FloatingIp("foobarFloatingIp", - droplet_id=foobar_droplet.id, - region=foobar_droplet.region) + foobar_floating_ip = digitalocean.FloatingIp("foobar", + droplet_id=foobar.id, + region=foobar.region) ``` ## Import @@ -204,15 +205,16 @@ def __init__(__self__, import pulumi import pulumi_digitalocean as digitalocean - foobar_droplet = digitalocean.Droplet("foobarDroplet", + foobar = digitalocean.Droplet("foobar", + name="baz", size=digitalocean.DropletSlug.DROPLET_S1_VCPU1_GB, image="ubuntu-18-04-x64", region=digitalocean.Region.SGP1, ipv6=True, private_networking=True) - foobar_floating_ip = digitalocean.FloatingIp("foobarFloatingIp", - droplet_id=foobar_droplet.id, - region=foobar_droplet.region) + foobar_floating_ip = digitalocean.FloatingIp("foobar", + droplet_id=foobar.id, + region=foobar.region) ``` ## Import diff --git a/sdk/python/pulumi_digitalocean/floating_ip_assignment.py b/sdk/python/pulumi_digitalocean/floating_ip_assignment.py index 4679a88f..fe84091c 100644 --- a/sdk/python/pulumi_digitalocean/floating_ip_assignment.py +++ b/sdk/python/pulumi_digitalocean/floating_ip_assignment.py @@ -110,15 +110,16 @@ def __init__(__self__, import pulumi import pulumi_digitalocean as digitalocean - foobar_floating_ip = digitalocean.FloatingIp("foobarFloatingIp", region="sgp1") - foobar_droplet = digitalocean.Droplet("foobarDroplet", + foobar = digitalocean.FloatingIp("foobar", region="sgp1") + foobar_droplet = digitalocean.Droplet("foobar", + name="baz", size=digitalocean.DropletSlug.DROPLET_S1_VCPU1_GB, image="ubuntu-18-04-x64", region=digitalocean.Region.SGP1, ipv6=True, private_networking=True) - foobar_floating_ip_assignment = digitalocean.FloatingIpAssignment("foobarFloatingIpAssignment", - ip_address=foobar_floating_ip.ip_address, + foobar_floating_ip_assignment = digitalocean.FloatingIpAssignment("foobar", + ip_address=foobar.ip_address, droplet_id=foobar_droplet.id) ``` @@ -156,15 +157,16 @@ def __init__(__self__, import pulumi import pulumi_digitalocean as digitalocean - foobar_floating_ip = digitalocean.FloatingIp("foobarFloatingIp", region="sgp1") - foobar_droplet = digitalocean.Droplet("foobarDroplet", + foobar = digitalocean.FloatingIp("foobar", region="sgp1") + foobar_droplet = digitalocean.Droplet("foobar", + name="baz", size=digitalocean.DropletSlug.DROPLET_S1_VCPU1_GB, image="ubuntu-18-04-x64", region=digitalocean.Region.SGP1, ipv6=True, private_networking=True) - foobar_floating_ip_assignment = digitalocean.FloatingIpAssignment("foobarFloatingIpAssignment", - ip_address=foobar_floating_ip.ip_address, + foobar_floating_ip_assignment = digitalocean.FloatingIpAssignment("foobar", + ip_address=foobar.ip_address, droplet_id=foobar_droplet.id) ``` diff --git a/sdk/python/pulumi_digitalocean/get_domains.py b/sdk/python/pulumi_digitalocean/get_domains.py index 538eddfb..c551a3ad 100644 --- a/sdk/python/pulumi_digitalocean/get_domains.py +++ b/sdk/python/pulumi_digitalocean/get_domains.py @@ -100,8 +100,8 @@ def get_domains(filters: Optional[Sequence[pulumi.InputType['GetDomainsFilterArg examples = digitalocean.get_domains(filters=[digitalocean.GetDomainsFilterArgs( key="name", - match_by="re", values=["example\\\\.com$"], + match_by="re", )]) ``` @@ -149,8 +149,8 @@ def get_domains_output(filters: Optional[pulumi.Input[Optional[Sequence[pulumi.I examples = digitalocean.get_domains(filters=[digitalocean.GetDomainsFilterArgs( key="name", - match_by="re", values=["example\\\\.com$"], + match_by="re", )]) ``` diff --git a/sdk/python/pulumi_digitalocean/get_droplet.py b/sdk/python/pulumi_digitalocean/get_droplet.py index 3664e5d9..71425df9 100644 --- a/sdk/python/pulumi_digitalocean/get_droplet.py +++ b/sdk/python/pulumi_digitalocean/get_droplet.py @@ -375,7 +375,7 @@ def get_droplet(id: Optional[int] = None, import pulumi import pulumi_digitalocean as digitalocean - example = digitalocean.get_droplet(id=digitalocean_kubernetes_cluster["example"]["node_pool"][0]["nodes"][0]["droplet_id"]) + example = digitalocean.get_droplet(id=example_digitalocean_kubernetes_cluster["nodePool"][0]["nodes"][0]["dropletId"]) ``` @@ -460,7 +460,7 @@ def get_droplet_output(id: Optional[pulumi.Input[Optional[int]]] = None, import pulumi import pulumi_digitalocean as digitalocean - example = digitalocean.get_droplet(id=digitalocean_kubernetes_cluster["example"]["node_pool"][0]["nodes"][0]["droplet_id"]) + example = digitalocean.get_droplet(id=example_digitalocean_kubernetes_cluster["nodePool"][0]["nodes"][0]["dropletId"]) ``` diff --git a/sdk/python/pulumi_digitalocean/get_droplet_snapshot.py b/sdk/python/pulumi_digitalocean/get_droplet_snapshot.py index 6e2b5d8d..5f643987 100644 --- a/sdk/python/pulumi_digitalocean/get_droplet_snapshot.py +++ b/sdk/python/pulumi_digitalocean/get_droplet_snapshot.py @@ -158,9 +158,9 @@ def get_droplet_snapshot(most_recent: Optional[bool] = None, import pulumi import pulumi_digitalocean as digitalocean - web_snapshot = digitalocean.get_droplet_snapshot(most_recent=True, - name_regex="^web", - region="nyc3") + web_snapshot = digitalocean.get_droplet_snapshot(name_regex="^web", + region="nyc3", + most_recent=True) ``` Create image from snapshot: @@ -174,6 +174,7 @@ def get_droplet_snapshot(most_recent: Optional[bool] = None, most_recent=True) from_snapshot = digitalocean.Droplet("from-snapshot", image=web_snapshot.id, + name="web-02", region=digitalocean.Region.NYC3, size=digitalocean.DropletSlug.DROPLET_S2_VCPU4_GB) ``` @@ -228,9 +229,9 @@ def get_droplet_snapshot_output(most_recent: Optional[pulumi.Input[Optional[bool import pulumi import pulumi_digitalocean as digitalocean - web_snapshot = digitalocean.get_droplet_snapshot(most_recent=True, - name_regex="^web", - region="nyc3") + web_snapshot = digitalocean.get_droplet_snapshot(name_regex="^web", + region="nyc3", + most_recent=True) ``` Create image from snapshot: @@ -244,6 +245,7 @@ def get_droplet_snapshot_output(most_recent: Optional[pulumi.Input[Optional[bool most_recent=True) from_snapshot = digitalocean.Droplet("from-snapshot", image=web_snapshot.id, + name="web-02", region=digitalocean.Region.NYC3, size=digitalocean.DropletSlug.DROPLET_S2_VCPU4_GB) ``` diff --git a/sdk/python/pulumi_digitalocean/get_droplets.py b/sdk/python/pulumi_digitalocean/get_droplets.py index 3c590374..894806e9 100644 --- a/sdk/python/pulumi_digitalocean/get_droplets.py +++ b/sdk/python/pulumi_digitalocean/get_droplets.py @@ -122,8 +122,8 @@ def get_droplets(filters: Optional[Sequence[pulumi.InputType['GetDropletsFilterA ), ], sorts=[digitalocean.GetDropletsSortArgs( - direction="desc", key="created_at", + direction="desc", )]) ``` @@ -193,8 +193,8 @@ def get_droplets_output(filters: Optional[pulumi.Input[Optional[Sequence[pulumi. ), ], sorts=[digitalocean.GetDropletsSortArgs( - direction="desc", key="created_at", + direction="desc", )]) ``` diff --git a/sdk/python/pulumi_digitalocean/get_image.py b/sdk/python/pulumi_digitalocean/get_image.py index 5293f36e..6e40e2e8 100644 --- a/sdk/python/pulumi_digitalocean/get_image.py +++ b/sdk/python/pulumi_digitalocean/get_image.py @@ -250,9 +250,10 @@ def get_image(id: Optional[int] = None, import pulumi import pulumi_digitalocean as digitalocean - example_image = digitalocean.get_image(name="example-1.0.0") - example_droplet = digitalocean.Droplet("exampleDroplet", - image=example_image.id, + example = digitalocean.get_image(name="example-1.0.0") + example_droplet = digitalocean.Droplet("example", + image=example.id, + name="example-1", region=digitalocean.Region.NYC2, size=digitalocean.DropletSlug.DROPLET_S1_VCPU1_GB) ``` @@ -332,9 +333,10 @@ def get_image_output(id: Optional[pulumi.Input[Optional[int]]] = None, import pulumi import pulumi_digitalocean as digitalocean - example_image = digitalocean.get_image(name="example-1.0.0") - example_droplet = digitalocean.Droplet("exampleDroplet", - image=example_image.id, + example = digitalocean.get_image(name="example-1.0.0") + example_droplet = digitalocean.Droplet("example", + image=example.id, + name="example-1", region=digitalocean.Region.NYC2, size=digitalocean.DropletSlug.DROPLET_S1_VCPU1_GB) ``` diff --git a/sdk/python/pulumi_digitalocean/get_images.py b/sdk/python/pulumi_digitalocean/get_images.py index ff5be026..cba88e71 100644 --- a/sdk/python/pulumi_digitalocean/get_images.py +++ b/sdk/python/pulumi_digitalocean/get_images.py @@ -123,8 +123,8 @@ def get_images(filters: Optional[Sequence[pulumi.InputType['GetImagesFilterArgs' ), ], sorts=[digitalocean.GetImagesSortArgs( - direction="desc", key="created", + direction="desc", )]) ``` @@ -195,8 +195,8 @@ def get_images_output(filters: Optional[pulumi.Input[Optional[Sequence[pulumi.In ), ], sorts=[digitalocean.GetImagesSortArgs( - direction="desc", key="created", + direction="desc", )]) ``` diff --git a/sdk/python/pulumi_digitalocean/get_kubernetes_cluster.py b/sdk/python/pulumi_digitalocean/get_kubernetes_cluster.py index 0540fea9..44bfd1ab 100644 --- a/sdk/python/pulumi_digitalocean/get_kubernetes_cluster.py +++ b/sdk/python/pulumi_digitalocean/get_kubernetes_cluster.py @@ -273,6 +273,15 @@ def get_kubernetes_cluster(name: Optional[str] = None, """ Retrieves information about a DigitalOcean Kubernetes cluster for use in other resources. This data source provides all of the cluster's properties as configured on your DigitalOcean account. This is useful if the cluster in question is not managed by the provider. + ## Example Usage + + ```python + import pulumi + import pulumi_digitalocean as digitalocean + + example = digitalocean.get_kubernetes_cluster(name="prod-cluster-01") + ``` + :param str name: The name of Kubernetes cluster. :param Sequence[str] tags: A list of tag names applied to the node pool. @@ -313,6 +322,15 @@ def get_kubernetes_cluster_output(name: Optional[pulumi.Input[str]] = None, """ Retrieves information about a DigitalOcean Kubernetes cluster for use in other resources. This data source provides all of the cluster's properties as configured on your DigitalOcean account. This is useful if the cluster in question is not managed by the provider. + ## Example Usage + + ```python + import pulumi + import pulumi_digitalocean as digitalocean + + example = digitalocean.get_kubernetes_cluster(name="prod-cluster-01") + ``` + :param str name: The name of Kubernetes cluster. :param Sequence[str] tags: A list of tag names applied to the node pool. diff --git a/sdk/python/pulumi_digitalocean/get_kubernetes_versions.py b/sdk/python/pulumi_digitalocean/get_kubernetes_versions.py index bdb80a79..05ecf6ae 100644 --- a/sdk/python/pulumi_digitalocean/get_kubernetes_versions.py +++ b/sdk/python/pulumi_digitalocean/get_kubernetes_versions.py @@ -102,6 +102,7 @@ def get_kubernetes_versions(version_prefix: Optional[str] = None, example = digitalocean.get_kubernetes_versions() example_cluster = digitalocean.KubernetesCluster("example-cluster", + name="example-cluster", region=digitalocean.Region.LON1, version=example.latest_version, node_pool=digitalocean.KubernetesClusterNodePoolArgs( @@ -119,6 +120,7 @@ def get_kubernetes_versions(version_prefix: Optional[str] = None, example = digitalocean.get_kubernetes_versions(version_prefix="1.22.") example_cluster = digitalocean.KubernetesCluster("example-cluster", + name="example-cluster", region=digitalocean.Region.LON1, version=example.latest_version, node_pool=digitalocean.KubernetesClusterNodePoolArgs( @@ -169,6 +171,7 @@ def get_kubernetes_versions_output(version_prefix: Optional[pulumi.Input[Optiona example = digitalocean.get_kubernetes_versions() example_cluster = digitalocean.KubernetesCluster("example-cluster", + name="example-cluster", region=digitalocean.Region.LON1, version=example.latest_version, node_pool=digitalocean.KubernetesClusterNodePoolArgs( @@ -186,6 +189,7 @@ def get_kubernetes_versions_output(version_prefix: Optional[pulumi.Input[Optiona example = digitalocean.get_kubernetes_versions(version_prefix="1.22.") example_cluster = digitalocean.KubernetesCluster("example-cluster", + name="example-cluster", region=digitalocean.Region.LON1, version=example.latest_version, node_pool=digitalocean.KubernetesClusterNodePoolArgs( diff --git a/sdk/python/pulumi_digitalocean/get_projects.py b/sdk/python/pulumi_digitalocean/get_projects.py index 6b799d80..f7d7fda0 100644 --- a/sdk/python/pulumi_digitalocean/get_projects.py +++ b/sdk/python/pulumi_digitalocean/get_projects.py @@ -122,8 +122,8 @@ def get_projects(filters: Optional[Sequence[pulumi.InputType['GetProjectsFilterA ), ], sorts=[digitalocean.GetProjectsSortArgs( - direction="asc", key="name", + direction="asc", )]) ``` @@ -192,8 +192,8 @@ def get_projects_output(filters: Optional[pulumi.Input[Optional[Sequence[pulumi. ), ], sorts=[digitalocean.GetProjectsSortArgs( - direction="asc", key="name", + direction="asc", )]) ``` diff --git a/sdk/python/pulumi_digitalocean/get_records.py b/sdk/python/pulumi_digitalocean/get_records.py index 75608710..c74d7443 100644 --- a/sdk/python/pulumi_digitalocean/get_records.py +++ b/sdk/python/pulumi_digitalocean/get_records.py @@ -93,6 +93,24 @@ def get_records(domain: Optional[str] = None, Retrieve information about all DNS records within a domain, with the ability to filter and sort the results. If no filters are specified, all records will be returned. + ## Example Usage + + Get data for all MX records in a domain: + + ```python + import pulumi + import pulumi_digitalocean as digitalocean + import pulumi_std as std + + example = digitalocean.get_records(domain="example.com", + filters=[digitalocean.GetRecordsFilterArgs( + key="type", + values=["MX"], + )]) + pulumi.export("mailServers", std.join(separator=",", + input=[__item.value for __item in example.records]).result) + ``` + :param str domain: The domain name to search for DNS records :param Sequence[pulumi.InputType['GetRecordsFilterArgs']] filters: Filter the results. @@ -124,6 +142,24 @@ def get_records_output(domain: Optional[pulumi.Input[str]] = None, Retrieve information about all DNS records within a domain, with the ability to filter and sort the results. If no filters are specified, all records will be returned. + ## Example Usage + + Get data for all MX records in a domain: + + ```python + import pulumi + import pulumi_digitalocean as digitalocean + import pulumi_std as std + + example = digitalocean.get_records(domain="example.com", + filters=[digitalocean.GetRecordsFilterArgs( + key="type", + values=["MX"], + )]) + pulumi.export("mailServers", std.join(separator=",", + input=[__item.value for __item in example.records]).result) + ``` + :param str domain: The domain name to search for DNS records :param Sequence[pulumi.InputType['GetRecordsFilterArgs']] filters: Filter the results. diff --git a/sdk/python/pulumi_digitalocean/get_regions.py b/sdk/python/pulumi_digitalocean/get_regions.py index eb0a544c..49593ce6 100644 --- a/sdk/python/pulumi_digitalocean/get_regions.py +++ b/sdk/python/pulumi_digitalocean/get_regions.py @@ -119,8 +119,8 @@ def get_regions(filters: Optional[Sequence[pulumi.InputType['GetRegionsFilterArg ), ], sorts=[digitalocean.GetRegionsSortArgs( - direction="desc", key="name", + direction="desc", )]) ``` @@ -187,8 +187,8 @@ def get_regions_output(filters: Optional[pulumi.Input[Optional[Sequence[pulumi.I ), ], sorts=[digitalocean.GetRegionsSortArgs( - direction="desc", key="name", + direction="desc", )]) ``` diff --git a/sdk/python/pulumi_digitalocean/get_spaces_bucket_object.py b/sdk/python/pulumi_digitalocean/get_spaces_bucket_object.py index 4556a245..08e2618e 100644 --- a/sdk/python/pulumi_digitalocean/get_spaces_bucket_object.py +++ b/sdk/python/pulumi_digitalocean/get_spaces_bucket_object.py @@ -276,6 +276,7 @@ def get_spaces_bucket_object(bucket: Optional[str] = None, key="droplet-bootstrap-script.sh") web = digitalocean.Droplet("web", image="ubuntu-18-04-x64", + name="web-1", region=digitalocean.Region.NYC2, size=digitalocean.DropletSlug.DROPLET_S1_VCPU1_GB, user_data=bootstrap_script.body) @@ -347,6 +348,7 @@ def get_spaces_bucket_object_output(bucket: Optional[pulumi.Input[str]] = None, key="droplet-bootstrap-script.sh") web = digitalocean.Droplet("web", image="ubuntu-18-04-x64", + name="web-1", region=digitalocean.Region.NYC2, size=digitalocean.DropletSlug.DROPLET_S1_VCPU1_GB, user_data=bootstrap_script.body) diff --git a/sdk/python/pulumi_digitalocean/get_spaces_buckets.py b/sdk/python/pulumi_digitalocean/get_spaces_buckets.py index 8172aab4..84742647 100644 --- a/sdk/python/pulumi_digitalocean/get_spaces_buckets.py +++ b/sdk/python/pulumi_digitalocean/get_spaces_buckets.py @@ -112,8 +112,8 @@ def get_spaces_buckets(filters: Optional[Sequence[pulumi.InputType['GetSpacesBuc values=["nyc3"], )], sorts=[digitalocean.GetSpacesBucketsSortArgs( - direction="desc", key="name", + direction="desc", )]) ``` @@ -173,8 +173,8 @@ def get_spaces_buckets_output(filters: Optional[pulumi.Input[Optional[Sequence[p values=["nyc3"], )], sorts=[digitalocean.GetSpacesBucketsSortArgs( - direction="desc", key="name", + direction="desc", )]) ``` diff --git a/sdk/python/pulumi_digitalocean/get_ssh_key.py b/sdk/python/pulumi_digitalocean/get_ssh_key.py index 7acc79b7..7e4dddc1 100644 --- a/sdk/python/pulumi_digitalocean/get_ssh_key.py +++ b/sdk/python/pulumi_digitalocean/get_ssh_key.py @@ -95,12 +95,13 @@ def get_ssh_key(name: Optional[str] = None, import pulumi import pulumi_digitalocean as digitalocean - example_ssh_key = digitalocean.get_ssh_key(name="example") - example_droplet = digitalocean.Droplet("exampleDroplet", + example = digitalocean.get_ssh_key(name="example") + example_droplet = digitalocean.Droplet("example", image="ubuntu-18-04-x64", + name="example-1", region=digitalocean.Region.NYC2, size=digitalocean.DropletSlug.DROPLET_S1_VCPU1_GB, - ssh_keys=[example_ssh_key.id]) + ssh_keys=[example.id]) ``` @@ -137,12 +138,13 @@ def get_ssh_key_output(name: Optional[pulumi.Input[str]] = None, import pulumi import pulumi_digitalocean as digitalocean - example_ssh_key = digitalocean.get_ssh_key(name="example") - example_droplet = digitalocean.Droplet("exampleDroplet", + example = digitalocean.get_ssh_key(name="example") + example_droplet = digitalocean.Droplet("example", image="ubuntu-18-04-x64", + name="example-1", region=digitalocean.Region.NYC2, size=digitalocean.DropletSlug.DROPLET_S1_VCPU1_GB, - ssh_keys=[example_ssh_key.id]) + ssh_keys=[example.id]) ``` diff --git a/sdk/python/pulumi_digitalocean/get_ssh_keys.py b/sdk/python/pulumi_digitalocean/get_ssh_keys.py index 101254c5..59a8385f 100644 --- a/sdk/python/pulumi_digitalocean/get_ssh_keys.py +++ b/sdk/python/pulumi_digitalocean/get_ssh_keys.py @@ -97,8 +97,8 @@ def get_ssh_keys(filters: Optional[Sequence[pulumi.InputType['GetSshKeysFilterAr import pulumi_digitalocean as digitalocean keys = digitalocean.get_ssh_keys(sorts=[digitalocean.GetSshKeysSortArgs( - direction="asc", key="name", + direction="asc", )]) ``` @@ -158,8 +158,8 @@ def get_ssh_keys_output(filters: Optional[pulumi.Input[Optional[Sequence[pulumi. import pulumi_digitalocean as digitalocean keys = digitalocean.get_ssh_keys(sorts=[digitalocean.GetSshKeysSortArgs( - direction="asc", key="name", + direction="asc", )]) ``` diff --git a/sdk/python/pulumi_digitalocean/get_tag.py b/sdk/python/pulumi_digitalocean/get_tag.py index 0a1c8c65..ead769af 100644 --- a/sdk/python/pulumi_digitalocean/get_tag.py +++ b/sdk/python/pulumi_digitalocean/get_tag.py @@ -142,12 +142,13 @@ def get_tag(name: Optional[str] = None, import pulumi import pulumi_digitalocean as digitalocean - example_tag = digitalocean.get_tag(name="example") - example_droplet = digitalocean.Droplet("exampleDroplet", + example = digitalocean.get_tag(name="example") + example_droplet = digitalocean.Droplet("example", image="ubuntu-18-04-x64", + name="example-1", region=digitalocean.Region.NYC2, size=digitalocean.DropletSlug.DROPLET_S1_VCPU1_GB, - tags=[example_tag.name]) + tags=[example.name]) ``` @@ -187,12 +188,13 @@ def get_tag_output(name: Optional[pulumi.Input[str]] = None, import pulumi import pulumi_digitalocean as digitalocean - example_tag = digitalocean.get_tag(name="example") - example_droplet = digitalocean.Droplet("exampleDroplet", + example = digitalocean.get_tag(name="example") + example_droplet = digitalocean.Droplet("example", image="ubuntu-18-04-x64", + name="example-1", region=digitalocean.Region.NYC2, size=digitalocean.DropletSlug.DROPLET_S1_VCPU1_GB, - tags=[example_tag.name]) + tags=[example.name]) ``` diff --git a/sdk/python/pulumi_digitalocean/get_volume.py b/sdk/python/pulumi_digitalocean/get_volume.py index 09000cf0..49f44fdb 100644 --- a/sdk/python/pulumi_digitalocean/get_volume.py +++ b/sdk/python/pulumi_digitalocean/get_volume.py @@ -176,15 +176,16 @@ def get_volume(description: Optional[str] = None, import pulumi import pulumi_digitalocean as digitalocean - example_volume = digitalocean.get_volume(name="app-data", + example = digitalocean.get_volume(name="app-data", region="nyc3") - example_droplet = digitalocean.Droplet("exampleDroplet", + example_droplet = digitalocean.Droplet("example", + name="foo", size=digitalocean.DropletSlug.DROPLET_S1_VCPU1_GB, image="ubuntu-18-04-x64", region=digitalocean.Region.NYC3) foobar = digitalocean.VolumeAttachment("foobar", droplet_id=example_droplet.id, - volume_id=example_volume.id) + volume_id=example.id) ``` @@ -243,15 +244,16 @@ def get_volume_output(description: Optional[pulumi.Input[Optional[str]]] = None, import pulumi import pulumi_digitalocean as digitalocean - example_volume = digitalocean.get_volume(name="app-data", + example = digitalocean.get_volume(name="app-data", region="nyc3") - example_droplet = digitalocean.Droplet("exampleDroplet", + example_droplet = digitalocean.Droplet("example", + name="foo", size=digitalocean.DropletSlug.DROPLET_S1_VCPU1_GB, image="ubuntu-18-04-x64", region=digitalocean.Region.NYC3) foobar = digitalocean.VolumeAttachment("foobar", droplet_id=example_droplet.id, - volume_id=example_volume.id) + volume_id=example.id) ``` diff --git a/sdk/python/pulumi_digitalocean/get_volume_snapshot.py b/sdk/python/pulumi_digitalocean/get_volume_snapshot.py index 9af949bc..1532e7e7 100644 --- a/sdk/python/pulumi_digitalocean/get_volume_snapshot.py +++ b/sdk/python/pulumi_digitalocean/get_volume_snapshot.py @@ -170,9 +170,9 @@ def get_volume_snapshot(most_recent: Optional[bool] = None, import pulumi import pulumi_digitalocean as digitalocean - snapshot = digitalocean.get_volume_snapshot(most_recent=True, - name_regex="^web", - region="nyc3") + snapshot = digitalocean.get_volume_snapshot(name_regex="^web", + region="nyc3", + most_recent=True) ``` Reuse the data about a volume snapshot to create a new volume based on it: @@ -186,6 +186,7 @@ def get_volume_snapshot(most_recent: Optional[bool] = None, most_recent=True) foobar = digitalocean.Volume("foobar", region=digitalocean.Region.NYC3, + name="baz", size=100, snapshot_id=snapshot.id) ``` @@ -241,9 +242,9 @@ def get_volume_snapshot_output(most_recent: Optional[pulumi.Input[Optional[bool] import pulumi import pulumi_digitalocean as digitalocean - snapshot = digitalocean.get_volume_snapshot(most_recent=True, - name_regex="^web", - region="nyc3") + snapshot = digitalocean.get_volume_snapshot(name_regex="^web", + region="nyc3", + most_recent=True) ``` Reuse the data about a volume snapshot to create a new volume based on it: @@ -257,6 +258,7 @@ def get_volume_snapshot_output(most_recent: Optional[pulumi.Input[Optional[bool] most_recent=True) foobar = digitalocean.Volume("foobar", region=digitalocean.Region.NYC3, + name="baz", size=100, snapshot_id=snapshot.id) ``` diff --git a/sdk/python/pulumi_digitalocean/get_vpc.py b/sdk/python/pulumi_digitalocean/get_vpc.py index 307a21f0..78069dcb 100644 --- a/sdk/python/pulumi_digitalocean/get_vpc.py +++ b/sdk/python/pulumi_digitalocean/get_vpc.py @@ -159,12 +159,13 @@ def get_vpc(id: Optional[str] = None, import pulumi import pulumi_digitalocean as digitalocean - example_vpc = digitalocean.get_vpc(name="example-network") - example_droplet = digitalocean.Droplet("exampleDroplet", + example = digitalocean.get_vpc(name="example-network") + example_droplet = digitalocean.Droplet("example", + name="example-01", size=digitalocean.DropletSlug.DROPLET_S1_VCPU1_GB, image="ubuntu-18-04-x64", region=digitalocean.Region.NYC3, - vpc_uuid=example_vpc.id) + vpc_uuid=example.id) ``` @@ -222,12 +223,13 @@ def get_vpc_output(id: Optional[pulumi.Input[Optional[str]]] = None, import pulumi import pulumi_digitalocean as digitalocean - example_vpc = digitalocean.get_vpc(name="example-network") - example_droplet = digitalocean.Droplet("exampleDroplet", + example = digitalocean.get_vpc(name="example-network") + example_droplet = digitalocean.Droplet("example", + name="example-01", size=digitalocean.DropletSlug.DROPLET_S1_VCPU1_GB, image="ubuntu-18-04-x64", region=digitalocean.Region.NYC3, - vpc_uuid=example_vpc.id) + vpc_uuid=example.id) ``` diff --git a/sdk/python/pulumi_digitalocean/kubernetes_node_pool.py b/sdk/python/pulumi_digitalocean/kubernetes_node_pool.py index c1d1502c..968c7e91 100644 --- a/sdk/python/pulumi_digitalocean/kubernetes_node_pool.py +++ b/sdk/python/pulumi_digitalocean/kubernetes_node_pool.py @@ -416,6 +416,7 @@ def __init__(__self__, import pulumi_digitalocean as digitalocean foo = digitalocean.KubernetesCluster("foo", + name="foo", region=digitalocean.Region.NYC1, version="1.22.8-do.1", node_pool=digitalocean.KubernetesClusterNodePoolArgs( @@ -425,6 +426,7 @@ def __init__(__self__, )) bar = digitalocean.KubernetesNodePool("bar", cluster_id=foo.id, + name="backend-pool", size=digitalocean.DropletSlug.DROPLET_C2, node_count=2, tags=["backend"], @@ -449,7 +451,8 @@ def __init__(__self__, import pulumi_digitalocean as digitalocean autoscale_pool_01 = digitalocean.KubernetesNodePool("autoscale-pool-01", - cluster_id=digitalocean_kubernetes_cluster["foo"]["id"], + cluster_id=foo["id"], + name="autoscale-pool-01", size=digitalocean.DropletSlug.DROPLET_S1_VCPU2_GB, auto_scale=True, min_nodes=1, @@ -507,6 +510,7 @@ def __init__(__self__, import pulumi_digitalocean as digitalocean foo = digitalocean.KubernetesCluster("foo", + name="foo", region=digitalocean.Region.NYC1, version="1.22.8-do.1", node_pool=digitalocean.KubernetesClusterNodePoolArgs( @@ -516,6 +520,7 @@ def __init__(__self__, )) bar = digitalocean.KubernetesNodePool("bar", cluster_id=foo.id, + name="backend-pool", size=digitalocean.DropletSlug.DROPLET_C2, node_count=2, tags=["backend"], @@ -540,7 +545,8 @@ def __init__(__self__, import pulumi_digitalocean as digitalocean autoscale_pool_01 = digitalocean.KubernetesNodePool("autoscale-pool-01", - cluster_id=digitalocean_kubernetes_cluster["foo"]["id"], + cluster_id=foo["id"], + name="autoscale-pool-01", size=digitalocean.DropletSlug.DROPLET_S1_VCPU2_GB, auto_scale=True, min_nodes=1, diff --git a/sdk/python/pulumi_digitalocean/load_balancer.py b/sdk/python/pulumi_digitalocean/load_balancer.py index 9ec1d983..42a524a2 100644 --- a/sdk/python/pulumi_digitalocean/load_balancer.py +++ b/sdk/python/pulumi_digitalocean/load_balancer.py @@ -873,10 +873,12 @@ def __init__(__self__, import pulumi_digitalocean as digitalocean web = digitalocean.Droplet("web", + name="web-1", size=digitalocean.DropletSlug.DROPLET_S1_VCPU1_GB, image="ubuntu-18-04-x64", region=digitalocean.Region.NYC3) public = digitalocean.LoadBalancer("public", + name="loadbalancer-1", region=digitalocean.Region.NYC3, forwarding_rules=[digitalocean.LoadBalancerForwardingRuleArgs( entry_port=80, @@ -897,33 +899,6 @@ def __init__(__self__, `Delete old certificate`. When doing so, you must also change the name of the certificate, as there cannot be multiple certificates with the same name in an account. - ```python - import pulumi - import pulumi_digitalocean as digitalocean - - cert = digitalocean.Certificate("cert", - private_key="file('key.pem')", - leaf_certificate="file('cert.pem')") - web = digitalocean.Droplet("web", - size=digitalocean.DropletSlug.DROPLET_S1_VCPU1_GB, - image="ubuntu-18-04-x64", - region=digitalocean.Region.NYC3) - public = digitalocean.LoadBalancer("public", - region=digitalocean.Region.NYC3, - forwarding_rules=[digitalocean.LoadBalancerForwardingRuleArgs( - entry_port=443, - entry_protocol="https", - target_port=80, - target_protocol="http", - certificate_name=cert.name, - )], - healthcheck=digitalocean.LoadBalancerHealthcheckArgs( - port=22, - protocol="tcp", - ), - droplet_ids=[web.id]) - ``` - ## Import Load Balancers can be imported using the `id`, e.g. @@ -985,10 +960,12 @@ def __init__(__self__, import pulumi_digitalocean as digitalocean web = digitalocean.Droplet("web", + name="web-1", size=digitalocean.DropletSlug.DROPLET_S1_VCPU1_GB, image="ubuntu-18-04-x64", region=digitalocean.Region.NYC3) public = digitalocean.LoadBalancer("public", + name="loadbalancer-1", region=digitalocean.Region.NYC3, forwarding_rules=[digitalocean.LoadBalancerForwardingRuleArgs( entry_port=80, @@ -1009,33 +986,6 @@ def __init__(__self__, `Delete old certificate`. When doing so, you must also change the name of the certificate, as there cannot be multiple certificates with the same name in an account. - ```python - import pulumi - import pulumi_digitalocean as digitalocean - - cert = digitalocean.Certificate("cert", - private_key="file('key.pem')", - leaf_certificate="file('cert.pem')") - web = digitalocean.Droplet("web", - size=digitalocean.DropletSlug.DROPLET_S1_VCPU1_GB, - image="ubuntu-18-04-x64", - region=digitalocean.Region.NYC3) - public = digitalocean.LoadBalancer("public", - region=digitalocean.Region.NYC3, - forwarding_rules=[digitalocean.LoadBalancerForwardingRuleArgs( - entry_port=443, - entry_protocol="https", - target_port=80, - target_protocol="http", - certificate_name=cert.name, - )], - healthcheck=digitalocean.LoadBalancerHealthcheckArgs( - port=22, - protocol="tcp", - ), - droplet_ids=[web.id]) - ``` - ## Import Load Balancers can be imported using the `id`, e.g. diff --git a/sdk/python/pulumi_digitalocean/project.py b/sdk/python/pulumi_digitalocean/project.py index 52e6ebd0..2e6dc7bb 100644 --- a/sdk/python/pulumi_digitalocean/project.py +++ b/sdk/python/pulumi_digitalocean/project.py @@ -325,9 +325,10 @@ def __init__(__self__, import pulumi_digitalocean as digitalocean playground = digitalocean.Project("playground", + name="playground", description="A project to represent development resources.", - environment="Development", - purpose="Web Application") + purpose="Web Application", + environment="Development") ``` The following example demonstrates the creation of a project with a Droplet resource: @@ -337,10 +338,12 @@ def __init__(__self__, import pulumi_digitalocean as digitalocean foobar = digitalocean.Droplet("foobar", + name="example", size=digitalocean.DropletSlug.DROPLET_S1_VCPU1_GB, image="ubuntu-22-04-x64", region=digitalocean.Region.NYC3) playground = digitalocean.Project("playground", + name="playground", description="A project to represent development resources.", purpose="Web Application", environment="Development", @@ -400,9 +403,10 @@ def __init__(__self__, import pulumi_digitalocean as digitalocean playground = digitalocean.Project("playground", + name="playground", description="A project to represent development resources.", - environment="Development", - purpose="Web Application") + purpose="Web Application", + environment="Development") ``` The following example demonstrates the creation of a project with a Droplet resource: @@ -412,10 +416,12 @@ def __init__(__self__, import pulumi_digitalocean as digitalocean foobar = digitalocean.Droplet("foobar", + name="example", size=digitalocean.DropletSlug.DROPLET_S1_VCPU1_GB, image="ubuntu-22-04-x64", region=digitalocean.Region.NYC3) playground = digitalocean.Project("playground", + name="playground", description="A project to represent development resources.", purpose="Web Application", environment="Development", diff --git a/sdk/python/pulumi_digitalocean/project_resources.py b/sdk/python/pulumi_digitalocean/project_resources.py index 86cb03da..9ecebf0c 100644 --- a/sdk/python/pulumi_digitalocean/project_resources.py +++ b/sdk/python/pulumi_digitalocean/project_resources.py @@ -123,6 +123,7 @@ def __init__(__self__, playground = digitalocean.get_project(name="playground") foobar = digitalocean.Droplet("foobar", + name="example", size=digitalocean.DropletSlug.DROPLET_S1_VCPU1_GB, image="ubuntu-22-04-x64", region=digitalocean.Region.NYC3) @@ -172,6 +173,7 @@ def __init__(__self__, playground = digitalocean.get_project(name="playground") foobar = digitalocean.Droplet("foobar", + name="example", size=digitalocean.DropletSlug.DROPLET_S1_VCPU1_GB, image="ubuntu-22-04-x64", region=digitalocean.Region.NYC3) diff --git a/sdk/python/pulumi_digitalocean/reserved_ip.py b/sdk/python/pulumi_digitalocean/reserved_ip.py index 559d27a2..82f7ba45 100644 --- a/sdk/python/pulumi_digitalocean/reserved_ip.py +++ b/sdk/python/pulumi_digitalocean/reserved_ip.py @@ -158,15 +158,16 @@ def __init__(__self__, import pulumi import pulumi_digitalocean as digitalocean - example_droplet = digitalocean.Droplet("exampleDroplet", + example = digitalocean.Droplet("example", + name="example", size=digitalocean.DropletSlug.DROPLET_S1_VCPU1_GB, image="ubuntu-22-04-x64", region=digitalocean.Region.NYC3, ipv6=True, private_networking=True) - example_reserved_ip = digitalocean.ReservedIp("exampleReservedIp", - droplet_id=example_droplet.id, - region=example_droplet.region) + example_reserved_ip = digitalocean.ReservedIp("example", + droplet_id=example.id, + region=example.region) ``` ## Import @@ -200,15 +201,16 @@ def __init__(__self__, import pulumi import pulumi_digitalocean as digitalocean - example_droplet = digitalocean.Droplet("exampleDroplet", + example = digitalocean.Droplet("example", + name="example", size=digitalocean.DropletSlug.DROPLET_S1_VCPU1_GB, image="ubuntu-22-04-x64", region=digitalocean.Region.NYC3, ipv6=True, private_networking=True) - example_reserved_ip = digitalocean.ReservedIp("exampleReservedIp", - droplet_id=example_droplet.id, - region=example_droplet.region) + example_reserved_ip = digitalocean.ReservedIp("example", + droplet_id=example.id, + region=example.region) ``` ## Import diff --git a/sdk/python/pulumi_digitalocean/reserved_ip_assignment.py b/sdk/python/pulumi_digitalocean/reserved_ip_assignment.py index c16e5c51..3ef04692 100644 --- a/sdk/python/pulumi_digitalocean/reserved_ip_assignment.py +++ b/sdk/python/pulumi_digitalocean/reserved_ip_assignment.py @@ -108,15 +108,16 @@ def __init__(__self__, import pulumi import pulumi_digitalocean as digitalocean - example_reserved_ip = digitalocean.ReservedIp("exampleReservedIp", region="nyc3") - example_droplet = digitalocean.Droplet("exampleDroplet", + example = digitalocean.ReservedIp("example", region="nyc3") + example_droplet = digitalocean.Droplet("example", + name="baz", size=digitalocean.DropletSlug.DROPLET_S1_VCPU1_GB, image="ubuntu-22-04-x64", region=digitalocean.Region.NYC3, ipv6=True, private_networking=True) - example_reserved_ip_assignment = digitalocean.ReservedIpAssignment("exampleReservedIpAssignment", - ip_address=example_reserved_ip.ip_address, + example_reserved_ip_assignment = digitalocean.ReservedIpAssignment("example", + ip_address=example.ip_address, droplet_id=example_droplet.id) ``` @@ -152,15 +153,16 @@ def __init__(__self__, import pulumi import pulumi_digitalocean as digitalocean - example_reserved_ip = digitalocean.ReservedIp("exampleReservedIp", region="nyc3") - example_droplet = digitalocean.Droplet("exampleDroplet", + example = digitalocean.ReservedIp("example", region="nyc3") + example_droplet = digitalocean.Droplet("example", + name="baz", size=digitalocean.DropletSlug.DROPLET_S1_VCPU1_GB, image="ubuntu-22-04-x64", region=digitalocean.Region.NYC3, ipv6=True, private_networking=True) - example_reserved_ip_assignment = digitalocean.ReservedIpAssignment("exampleReservedIpAssignment", - ip_address=example_reserved_ip.ip_address, + example_reserved_ip_assignment = digitalocean.ReservedIpAssignment("example", + ip_address=example.ip_address, droplet_id=example_droplet.id) ``` diff --git a/sdk/python/pulumi_digitalocean/spaces_bucket.py b/sdk/python/pulumi_digitalocean/spaces_bucket.py index d7e489e1..411e82cf 100644 --- a/sdk/python/pulumi_digitalocean/spaces_bucket.py +++ b/sdk/python/pulumi_digitalocean/spaces_bucket.py @@ -347,7 +347,6 @@ def __init__(__self__, import pulumi_digitalocean as digitalocean static_assets = digitalocean.SpacesBucket("static-assets") - # ... ``` For more information, See [An Introduction to DigitalOcean Spaces](https://www.digitalocean.com/community/tutorials/an-introduction-to-digitalocean-spaces) @@ -360,7 +359,9 @@ def __init__(__self__, import pulumi import pulumi_digitalocean as digitalocean - foobar = digitalocean.SpacesBucket("foobar", region=digitalocean.Region.NYC3) + foobar = digitalocean.SpacesBucket("foobar", + name="foobar", + region=digitalocean.Region.NYC3) ``` ### Create a New Bucket With CORS Rules @@ -370,6 +371,8 @@ def __init__(__self__, import pulumi_digitalocean as digitalocean foobar = digitalocean.SpacesBucket("foobar", + name="foobar", + region=digitalocean.Region.NYC3, cors_rules=[ digitalocean.SpacesBucketCorsRuleArgs( allowed_headers=["*"], @@ -387,8 +390,7 @@ def __init__(__self__, allowed_origins=["https://www.example.com"], max_age_seconds=3000, ), - ], - region=digitalocean.Region.NYC3) + ]) ``` ## Import @@ -435,7 +437,6 @@ def __init__(__self__, import pulumi_digitalocean as digitalocean static_assets = digitalocean.SpacesBucket("static-assets") - # ... ``` For more information, See [An Introduction to DigitalOcean Spaces](https://www.digitalocean.com/community/tutorials/an-introduction-to-digitalocean-spaces) @@ -448,7 +449,9 @@ def __init__(__self__, import pulumi import pulumi_digitalocean as digitalocean - foobar = digitalocean.SpacesBucket("foobar", region=digitalocean.Region.NYC3) + foobar = digitalocean.SpacesBucket("foobar", + name="foobar", + region=digitalocean.Region.NYC3) ``` ### Create a New Bucket With CORS Rules @@ -458,6 +461,8 @@ def __init__(__self__, import pulumi_digitalocean as digitalocean foobar = digitalocean.SpacesBucket("foobar", + name="foobar", + region=digitalocean.Region.NYC3, cors_rules=[ digitalocean.SpacesBucketCorsRuleArgs( allowed_headers=["*"], @@ -475,8 +480,7 @@ def __init__(__self__, allowed_origins=["https://www.example.com"], max_age_seconds=3000, ), - ], - region=digitalocean.Region.NYC3) + ]) ``` ## Import diff --git a/sdk/python/pulumi_digitalocean/spaces_bucket_cors_configuration.py b/sdk/python/pulumi_digitalocean/spaces_bucket_cors_configuration.py index 991c6560..e7538b3e 100644 --- a/sdk/python/pulumi_digitalocean/spaces_bucket_cors_configuration.py +++ b/sdk/python/pulumi_digitalocean/spaces_bucket_cors_configuration.py @@ -140,7 +140,9 @@ def __init__(__self__, import pulumi import pulumi_digitalocean as digitalocean - foobar = digitalocean.SpacesBucket("foobar", region=digitalocean.Region.NYC3) + foobar = digitalocean.SpacesBucket("foobar", + name="foobar", + region=digitalocean.Region.NYC3) test = digitalocean.SpacesBucketCorsConfiguration("test", bucket=foobar.id, region="nyc3", @@ -185,7 +187,9 @@ def __init__(__self__, import pulumi import pulumi_digitalocean as digitalocean - foobar = digitalocean.SpacesBucket("foobar", region=digitalocean.Region.NYC3) + foobar = digitalocean.SpacesBucket("foobar", + name="foobar", + region=digitalocean.Region.NYC3) test = digitalocean.SpacesBucketCorsConfiguration("test", bucket=foobar.id, region="nyc3", diff --git a/sdk/python/pulumi_digitalocean/spaces_bucket_object.py b/sdk/python/pulumi_digitalocean/spaces_bucket_object.py index f589d35f..64a44a77 100644 --- a/sdk/python/pulumi_digitalocean/spaces_bucket_object.py +++ b/sdk/python/pulumi_digitalocean/spaces_bucket_object.py @@ -616,7 +616,6 @@ def __init__(__self__, import pulumi_digitalocean as digitalocean static_assets = digitalocean.SpacesBucket("static-assets") - # ... ``` For more information, See [An Introduction to DigitalOcean Spaces](https://www.digitalocean.com/community/tutorials/an-introduction-to-digitalocean-spaces) @@ -629,7 +628,9 @@ def __init__(__self__, import pulumi import pulumi_digitalocean as digitalocean - foobar = digitalocean.SpacesBucket("foobar", region=digitalocean.Region.NYC3) + foobar = digitalocean.SpacesBucket("foobar", + name="foobar", + region=digitalocean.Region.NYC3) index = digitalocean.SpacesBucketObject("index", region=foobar.region, bucket=foobar.name, @@ -694,7 +695,6 @@ def __init__(__self__, import pulumi_digitalocean as digitalocean static_assets = digitalocean.SpacesBucket("static-assets") - # ... ``` For more information, See [An Introduction to DigitalOcean Spaces](https://www.digitalocean.com/community/tutorials/an-introduction-to-digitalocean-spaces) @@ -707,7 +707,9 @@ def __init__(__self__, import pulumi import pulumi_digitalocean as digitalocean - foobar = digitalocean.SpacesBucket("foobar", region=digitalocean.Region.NYC3) + foobar = digitalocean.SpacesBucket("foobar", + name="foobar", + region=digitalocean.Region.NYC3) index = digitalocean.SpacesBucketObject("index", region=foobar.region, bucket=foobar.name, diff --git a/sdk/python/pulumi_digitalocean/spaces_bucket_policy.py b/sdk/python/pulumi_digitalocean/spaces_bucket_policy.py index 3fc942e7..7ed4f5ed 100644 --- a/sdk/python/pulumi_digitalocean/spaces_bucket_policy.py +++ b/sdk/python/pulumi_digitalocean/spaces_bucket_policy.py @@ -139,10 +139,12 @@ def __init__(__self__, import json import pulumi_digitalocean as digitalocean - foobar_spaces_bucket = digitalocean.SpacesBucket("foobarSpacesBucket", region=digitalocean.Region.NYC3) - foobar_spaces_bucket_policy = digitalocean.SpacesBucketPolicy("foobarSpacesBucketPolicy", - region=foobar_spaces_bucket.region, - bucket=foobar_spaces_bucket.name, + foobar = digitalocean.SpacesBucket("foobar", + name="foobar", + region=digitalocean.Region.NYC3) + foobar_spaces_bucket_policy = digitalocean.SpacesBucketPolicy("foobar", + region=foobar.region, + bucket=foobar.name, policy=pulumi.Output.json_dumps({ "Version": "2012-10-17", "Statement": [{ @@ -151,8 +153,8 @@ def __init__(__self__, "Principal": "*", "Action": "s3:*", "Resource": [ - foobar_spaces_bucket.name.apply(lambda name: f"arn:aws:s3:::{name}"), - foobar_spaces_bucket.name.apply(lambda name: f"arn:aws:s3:::{name}/*"), + foobar.name.apply(lambda name: f"arn:aws:s3:::{name}"), + foobar.name.apply(lambda name: f"arn:aws:s3:::{name}/*"), ], "Condition": { "NotIpAddress": { @@ -195,10 +197,12 @@ def __init__(__self__, import json import pulumi_digitalocean as digitalocean - foobar_spaces_bucket = digitalocean.SpacesBucket("foobarSpacesBucket", region=digitalocean.Region.NYC3) - foobar_spaces_bucket_policy = digitalocean.SpacesBucketPolicy("foobarSpacesBucketPolicy", - region=foobar_spaces_bucket.region, - bucket=foobar_spaces_bucket.name, + foobar = digitalocean.SpacesBucket("foobar", + name="foobar", + region=digitalocean.Region.NYC3) + foobar_spaces_bucket_policy = digitalocean.SpacesBucketPolicy("foobar", + region=foobar.region, + bucket=foobar.name, policy=pulumi.Output.json_dumps({ "Version": "2012-10-17", "Statement": [{ @@ -207,8 +211,8 @@ def __init__(__self__, "Principal": "*", "Action": "s3:*", "Resource": [ - foobar_spaces_bucket.name.apply(lambda name: f"arn:aws:s3:::{name}"), - foobar_spaces_bucket.name.apply(lambda name: f"arn:aws:s3:::{name}/*"), + foobar.name.apply(lambda name: f"arn:aws:s3:::{name}"), + foobar.name.apply(lambda name: f"arn:aws:s3:::{name}/*"), ], "Condition": { "NotIpAddress": { diff --git a/sdk/python/pulumi_digitalocean/ssh_key.py b/sdk/python/pulumi_digitalocean/ssh_key.py index b500003a..b4e9284a 100644 --- a/sdk/python/pulumi_digitalocean/ssh_key.py +++ b/sdk/python/pulumi_digitalocean/ssh_key.py @@ -129,12 +129,16 @@ def __init__(__self__, ```python import pulumi import pulumi_digitalocean as digitalocean + import pulumi_std as std # Create a new SSH key - default = digitalocean.SshKey("default", public_key=(lambda path: open(path).read())("/Users/myuser/.ssh/id_rsa.pub")) + default = digitalocean.SshKey("default", + name="Example", + public_key=std.file(input="/Users/myuser/.ssh/id_rsa.pub").result) # Create a new Droplet using the SSH key web = digitalocean.Droplet("web", image="ubuntu-18-04-x64", + name="web-1", region=digitalocean.Region.NYC3, size=digitalocean.DropletSlug.DROPLET_S1_VCPU1_GB, ssh_keys=[default.fingerprint]) @@ -171,12 +175,16 @@ def __init__(__self__, ```python import pulumi import pulumi_digitalocean as digitalocean + import pulumi_std as std # Create a new SSH key - default = digitalocean.SshKey("default", public_key=(lambda path: open(path).read())("/Users/myuser/.ssh/id_rsa.pub")) + default = digitalocean.SshKey("default", + name="Example", + public_key=std.file(input="/Users/myuser/.ssh/id_rsa.pub").result) # Create a new Droplet using the SSH key web = digitalocean.Droplet("web", image="ubuntu-18-04-x64", + name="web-1", region=digitalocean.Region.NYC3, size=digitalocean.DropletSlug.DROPLET_S1_VCPU1_GB, ssh_keys=[default.fingerprint]) diff --git a/sdk/python/pulumi_digitalocean/tag.py b/sdk/python/pulumi_digitalocean/tag.py index 3040cd31..17c0a4ee 100644 --- a/sdk/python/pulumi_digitalocean/tag.py +++ b/sdk/python/pulumi_digitalocean/tag.py @@ -175,10 +175,11 @@ def __init__(__self__, import pulumi_digitalocean as digitalocean # Create a new tag - foobar = digitalocean.Tag("foobar") + foobar = digitalocean.Tag("foobar", name="foobar") # Create a new Droplet in nyc3 with the foobar tag web = digitalocean.Droplet("web", image="ubuntu-18-04-x64", + name="web-1", region=digitalocean.Region.NYC3, size=digitalocean.DropletSlug.DROPLET_S1_VCPU1_GB, tags=[foobar.id]) @@ -215,10 +216,11 @@ def __init__(__self__, import pulumi_digitalocean as digitalocean # Create a new tag - foobar = digitalocean.Tag("foobar") + foobar = digitalocean.Tag("foobar", name="foobar") # Create a new Droplet in nyc3 with the foobar tag web = digitalocean.Droplet("web", image="ubuntu-18-04-x64", + name="web-1", region=digitalocean.Region.NYC3, size=digitalocean.DropletSlug.DROPLET_S1_VCPU1_GB, tags=[foobar.id]) diff --git a/sdk/python/pulumi_digitalocean/volume.py b/sdk/python/pulumi_digitalocean/volume.py index dc177bc2..ad669ca6 100644 --- a/sdk/python/pulumi_digitalocean/volume.py +++ b/sdk/python/pulumi_digitalocean/volume.py @@ -398,18 +398,20 @@ def __init__(__self__, import pulumi import pulumi_digitalocean as digitalocean - foobar_volume = digitalocean.Volume("foobarVolume", + foobar = digitalocean.Volume("foobar", region=digitalocean.Region.NYC1, + name="baz", size=100, initial_filesystem_type=digitalocean.FileSystemType.EXT4, description="an example volume") - foobar_droplet = digitalocean.Droplet("foobarDroplet", + foobar_droplet = digitalocean.Droplet("foobar", + name="baz", size=digitalocean.DropletSlug.DROPLET_S1_VCPU1_GB, image="ubuntu-18-04-x64", region=digitalocean.Region.NYC1) - foobar_volume_attachment = digitalocean.VolumeAttachment("foobarVolumeAttachment", + foobar_volume_attachment = digitalocean.VolumeAttachment("foobar", droplet_id=foobar_droplet.id, - volume_id=foobar_volume.id) + volume_id=foobar.id) ``` You can also create a volume from an existing snapshot. @@ -418,11 +420,12 @@ def __init__(__self__, import pulumi import pulumi_digitalocean as digitalocean - foobar_volume_snapshot = digitalocean.get_volume_snapshot(name="baz") - foobar_volume = digitalocean.Volume("foobarVolume", + foobar = digitalocean.get_volume_snapshot(name="baz") + foobar_volume = digitalocean.Volume("foobar", region=digitalocean.Region.LON1, - size=foobar_volume_snapshot.min_disk_size, - snapshot_id=foobar_volume_snapshot.id) + name="foo", + size=foobar.min_disk_size, + snapshot_id=foobar.id) ``` ## Import @@ -460,18 +463,20 @@ def __init__(__self__, import pulumi import pulumi_digitalocean as digitalocean - foobar_volume = digitalocean.Volume("foobarVolume", + foobar = digitalocean.Volume("foobar", region=digitalocean.Region.NYC1, + name="baz", size=100, initial_filesystem_type=digitalocean.FileSystemType.EXT4, description="an example volume") - foobar_droplet = digitalocean.Droplet("foobarDroplet", + foobar_droplet = digitalocean.Droplet("foobar", + name="baz", size=digitalocean.DropletSlug.DROPLET_S1_VCPU1_GB, image="ubuntu-18-04-x64", region=digitalocean.Region.NYC1) - foobar_volume_attachment = digitalocean.VolumeAttachment("foobarVolumeAttachment", + foobar_volume_attachment = digitalocean.VolumeAttachment("foobar", droplet_id=foobar_droplet.id, - volume_id=foobar_volume.id) + volume_id=foobar.id) ``` You can also create a volume from an existing snapshot. @@ -480,11 +485,12 @@ def __init__(__self__, import pulumi import pulumi_digitalocean as digitalocean - foobar_volume_snapshot = digitalocean.get_volume_snapshot(name="baz") - foobar_volume = digitalocean.Volume("foobarVolume", + foobar = digitalocean.get_volume_snapshot(name="baz") + foobar_volume = digitalocean.Volume("foobar", region=digitalocean.Region.LON1, - size=foobar_volume_snapshot.min_disk_size, - snapshot_id=foobar_volume_snapshot.id) + name="foo", + size=foobar.min_disk_size, + snapshot_id=foobar.id) ``` ## Import diff --git a/sdk/python/pulumi_digitalocean/volume_attachment.py b/sdk/python/pulumi_digitalocean/volume_attachment.py index da4a24dc..68c711f1 100644 --- a/sdk/python/pulumi_digitalocean/volume_attachment.py +++ b/sdk/python/pulumi_digitalocean/volume_attachment.py @@ -108,18 +108,20 @@ def __init__(__self__, import pulumi import pulumi_digitalocean as digitalocean - foobar_volume = digitalocean.Volume("foobarVolume", + foobar = digitalocean.Volume("foobar", region=digitalocean.Region.NYC1, + name="baz", size=100, initial_filesystem_type=digitalocean.FileSystemType.EXT4, description="an example volume") - foobar_droplet = digitalocean.Droplet("foobarDroplet", + foobar_droplet = digitalocean.Droplet("foobar", + name="baz", size=digitalocean.DropletSlug.DROPLET_S1_VCPU1_GB, image="ubuntu-18-04-x64", region=digitalocean.Region.NYC1) - foobar_volume_attachment = digitalocean.VolumeAttachment("foobarVolumeAttachment", + foobar_volume_attachment = digitalocean.VolumeAttachment("foobar", droplet_id=foobar_droplet.id, - volume_id=foobar_volume.id) + volume_id=foobar.id) ``` :param str resource_name: The name of the resource. @@ -144,18 +146,20 @@ def __init__(__self__, import pulumi import pulumi_digitalocean as digitalocean - foobar_volume = digitalocean.Volume("foobarVolume", + foobar = digitalocean.Volume("foobar", region=digitalocean.Region.NYC1, + name="baz", size=100, initial_filesystem_type=digitalocean.FileSystemType.EXT4, description="an example volume") - foobar_droplet = digitalocean.Droplet("foobarDroplet", + foobar_droplet = digitalocean.Droplet("foobar", + name="baz", size=digitalocean.DropletSlug.DROPLET_S1_VCPU1_GB, image="ubuntu-18-04-x64", region=digitalocean.Region.NYC1) - foobar_volume_attachment = digitalocean.VolumeAttachment("foobarVolumeAttachment", + foobar_volume_attachment = digitalocean.VolumeAttachment("foobar", droplet_id=foobar_droplet.id, - volume_id=foobar_volume.id) + volume_id=foobar.id) ``` :param str resource_name: The name of the resource. diff --git a/sdk/python/pulumi_digitalocean/volume_snapshot.py b/sdk/python/pulumi_digitalocean/volume_snapshot.py index ec986e87..0578aeeb 100644 --- a/sdk/python/pulumi_digitalocean/volume_snapshot.py +++ b/sdk/python/pulumi_digitalocean/volume_snapshot.py @@ -204,11 +204,14 @@ def __init__(__self__, import pulumi import pulumi_digitalocean as digitalocean - foobar_volume = digitalocean.Volume("foobarVolume", + foobar = digitalocean.Volume("foobar", region=digitalocean.Region.NYC1, + name="baz", size=100, description="an example volume") - foobar_volume_snapshot = digitalocean.VolumeSnapshot("foobarVolumeSnapshot", volume_id=foobar_volume.id) + foobar_volume_snapshot = digitalocean.VolumeSnapshot("foobar", + name="foo", + volume_id=foobar.id) ``` ## Import @@ -240,11 +243,14 @@ def __init__(__self__, import pulumi import pulumi_digitalocean as digitalocean - foobar_volume = digitalocean.Volume("foobarVolume", + foobar = digitalocean.Volume("foobar", region=digitalocean.Region.NYC1, + name="baz", size=100, description="an example volume") - foobar_volume_snapshot = digitalocean.VolumeSnapshot("foobarVolumeSnapshot", volume_id=foobar_volume.id) + foobar_volume_snapshot = digitalocean.VolumeSnapshot("foobar", + name="foo", + volume_id=foobar.id) ``` ## Import diff --git a/sdk/python/pulumi_digitalocean/vpc.py b/sdk/python/pulumi_digitalocean/vpc.py index 13fb9d70..46d9c0a8 100644 --- a/sdk/python/pulumi_digitalocean/vpc.py +++ b/sdk/python/pulumi_digitalocean/vpc.py @@ -225,8 +225,9 @@ def __init__(__self__, import pulumi_digitalocean as digitalocean example = digitalocean.Vpc("example", - ip_range="10.10.10.0/24", - region="nyc3") + name="example-project-network", + region="nyc3", + ip_range="10.10.10.0/24") ``` ### Resource Assignment @@ -239,12 +240,15 @@ def __init__(__self__, import pulumi import pulumi_digitalocean as digitalocean - example_vpc = digitalocean.Vpc("exampleVpc", region="nyc3") - example_droplet = digitalocean.Droplet("exampleDroplet", + example = digitalocean.Vpc("example", + name="example-project-network", + region="nyc3") + example_droplet = digitalocean.Droplet("example", + name="example-01", size=digitalocean.DropletSlug.DROPLET_S1_VCPU1_GB, image="ubuntu-18-04-x64", region=digitalocean.Region.NYC3, - vpc_uuid=example_vpc.id) + vpc_uuid=example.id) ``` ## Import @@ -281,8 +285,9 @@ def __init__(__self__, import pulumi_digitalocean as digitalocean example = digitalocean.Vpc("example", - ip_range="10.10.10.0/24", - region="nyc3") + name="example-project-network", + region="nyc3", + ip_range="10.10.10.0/24") ``` ### Resource Assignment @@ -295,12 +300,15 @@ def __init__(__self__, import pulumi import pulumi_digitalocean as digitalocean - example_vpc = digitalocean.Vpc("exampleVpc", region="nyc3") - example_droplet = digitalocean.Droplet("exampleDroplet", + example = digitalocean.Vpc("example", + name="example-project-network", + region="nyc3") + example_droplet = digitalocean.Droplet("example", + name="example-01", size=digitalocean.DropletSlug.DROPLET_S1_VCPU1_GB, image="ubuntu-18-04-x64", region=digitalocean.Region.NYC3, - vpc_uuid=example_vpc.id) + vpc_uuid=example.id) ``` ## Import