Mantenha tudo organizado com as coleções
Salve e categorize o conteúdo com base nas suas preferências.
O Terraform é uma ferramenta para criar,
alterar e controlar versões de infraestrutura. Ele usa arquivos de configuração para descrever
os componentes necessários para executar um único aplicativo ou toda a infraestrutura.
Use o
Google Cloud provedor Terraform para criar
instâncias e bancos de dados do Spanner e modificar ou excluir recursos do
Spanner.
O Google Cloud provedor do Terraform oferece os seguintes recursos do Spanner:
Para mais informações sobre como usar esses recursos para criar e gerenciar
instâncias e bancos de dados do Spanner, consulte
Como usar o Terraform com Google Cloud ou consulte a
referência do provedorGoogle Cloud do Terraform.
[[["Fácil de entender","easyToUnderstand","thumb-up"],["Meu problema foi resolvido","solvedMyProblem","thumb-up"],["Outro","otherUp","thumb-up"]],[["Difícil de entender","hardToUnderstand","thumb-down"],["Informações incorretas ou exemplo de código","incorrectInformationOrSampleCode","thumb-down"],["Não contém as informações/amostras de que eu preciso","missingTheInformationSamplesINeed","thumb-down"],["Problema na tradução","translationIssue","thumb-down"],["Outro","otherDown","thumb-down"]],["Última atualização 2025-09-03 UTC."],[],[],null,["# Use Terraform with Spanner\n\n[Terraform](https://www.terraform.io/) is a tool for building,\nchanging, and versioning infrastructure. It uses configuration files to describe\nthe components needed to run a single application or your entire infrastructure.\n\nYou can use the\n[Google Cloud Terraform Provider](https://www.terraform.io/docs/providers/google/index.html) to create\nSpanner instances and databases, and to modify or delete Spanner\nresources.\n\n\n| **PostgreSQL interface note:** For PostgreSQL-dialect databases, Terraform doesn't support submitting DDL while creating a database. You must submit DDL in a separate operation.\n\n\u003cbr /\u003e\n\nThe Google Cloud Terraform Provider offers the following Spanner resources:\n\n- [google_spanner_instance](https://www.terraform.io/docs/providers/google/r/spanner_instance)\n- [google_spanner_database](https://www.terraform.io/docs/providers/google/r/spanner_database)\n- [google_spanner_instance_iam](https://www.terraform.io/docs/providers/google/r/spanner_instance_iam)\n- [google_spanner_database_iam](https://www.terraform.io/docs/providers/google/r/spanner_database_iam)\n\nFor more information about using these resources to create and manage\nSpanner instances and databases, see\n[Using Terraform with Google Cloud](https://cloud.google.com/docs/terraform) or consult the\nGoogle Cloud Terraform Provider [reference](https://registry.terraform.io/providers/hashicorp/google/latest/docs).\n\nWhat's next\n-----------\n\n- Learn more about [Terraform](https://www.terraform.io/).\n- Try out [code examples](https://github.com/cloudspannerecosystem/spanner-terraform#examples) that use the Google Cloud Terraform Provider with Spanner.\n- For a step-by-step tutorial, try the Spanner with Terraform [codelab](https://codelabs.developers.google.com/codelabs/cloud-spanner-terraform#0).\n- View the Google Cloud Terraform Provider [repository on GitHub](https://github.com/hashicorp/terraform-provider-google).\n- [File a GitHub issue](https://github.com/hashicorp/terraform-provider-google/issues) to report a bug or ask a question about Terraform."]]