Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Docs terraform context #53242

Merged
merged 14 commits into from
Feb 27, 2025
Merged

Docs terraform context #53242

merged 14 commits into from
Feb 27, 2025

Conversation

ian-at-airbyte
Copy link
Contributor

What

Expand our Terraform stub article and add new Terraform tutorial. Resolves the docs component of #11525.

How

Expands our stub Terraform topic to be a fully-fledged Terraform tutorial. Includes new discussions and code samples, specifically around the use of JSON strings as alternatives to strongly typed configurations to help deal with Terraform drift.

Not included in this PR are two decisions we need to make about previously created resources:

  • The existing Terraform guide in the API docs
  • The exceptional YouTube series on this from our DevRel team

Both of these resources are out of date compared to this content, and I expect they will be replaced by it. This is a fuller discussion about current challenges and, unlike those other resources, should be technically correct to the latest version of the Terraform provider.

Review guide

  • /docs/terraform-documentation.md.

For the nice version, just open the linked Vercel build as usual and scroll down to Terraform Provider in the menu.

User Impact

  • An accurate, up to date Terraform tutorial, as a companion to the autogenerated reference docs.
  • A way to help deal with Terraform drift.

Can this PR be safely reverted and rolled back?

  • YES 💚
  • NO ❌

Copy link

vercel bot commented Feb 8, 2025

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
airbyte-docs ✅ Ready (Inspect) Visit Preview 💬 Add feedback Feb 26, 2025 10:45pm

Copy link

@Charlesnorris509 Charlesnorris509 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great job with pull requests your changes make the markdown file much more readable and engaging for new users like me. Now i still have a remark. I would increase the possibility for test driven development in this project and for future contributors. By a bulk test procedure for the most important feature of the project.

@ian-at-airbyte
Copy link
Contributor Author

Thanks, everyone, for your feedback. I've applied them.

  • Everyone including OSS uses a client ID and client secret. This allowed me to remove several tab sets and go from 2 code samples to 1.
  • JSON is the default code sample for sources and destinations.
  • Removed some unnecessary code blocks around creating .tf files.

@Charlesnorris509 I did not incorporate your request as it was outside the scope of this particular contribution but I've noted it for the future.


```hcl title="main.tf"
resource "airbyte_destination_custom" "my_destination_bigquery_custom" {
configuration = <<-EOF
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Would it be better to use jsonencode here instead of a heredoc?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes. I did originally try that and it was my preferred option too, but something about the way Terraform interacts with the API created encoding problems that caused terraform apply to fail. This seemed to be a problem with BigQuery specifically, not with other destinations, although the exact nature of the issue escapes me now.

@ian-at-airbyte ian-at-airbyte merged commit 49d80cf into master Feb 27, 2025
23 checks passed
@ian-at-airbyte ian-at-airbyte deleted the docs-terraform-context branch February 27, 2025 01:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/documentation Improvements or additions to documentation
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants