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

Ensure that version is not part of the state if not explicitly in the tf file #181

Merged
merged 1 commit into from
Sep 5, 2024

Conversation

erikzaadi
Copy link
Member

Description

What - When altering an integrations version outside of terraform, it would affect the state even if not specified in a port_integration section
Why - Allows updating versions of integrations outside of terraform, keep terraform for updating configuration and mappings
How - Make version both optionable and computed

Type of change

Please leave one option from the following and delete the rest:

  • Bug fix (non-breaking change which fixes an issue)
  • Documentation (added/updated documentation)

Copy link
Contributor

@Tankilevitch Tankilevitch left a comment

Choose a reason for hiding this comment

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

I am suggesting having an example without version, and also an example with version with a note/warning that this value is computed and based on the running integration

Comment on lines 32 to 38
title = "My Custom Integration with version managed by Terraform"
installation_app_type = "WEBHOOK"
# NOTE: This property is by default not used, since it can change outside of terraform
# Include this only if you explicitly want to control the version with Terraform
version = "1.33.7"
config = jsonencode({
createMissingRelatedEntitiesboolean = true
Copy link
Contributor

Choose a reason for hiding this comment

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

lets use an actuall real one, like an ocean one, which isn't a webhook

@@ -73,7 +74,7 @@ Docs about how to import existing integrations and manage their mappings can be
resource "port_integration" "my_custom_integration" {
installation_id = "my-custom-integration-id"
title = "My Custom Integration"
version = "1.33.7"
version = "1.33.7" # Optional, can be omitted
Copy link
Contributor

Choose a reason for hiding this comment

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

should be removed?

@erikzaadi erikzaadi merged commit c027225 into main Sep 5, 2024
3 checks passed
@erikzaadi erikzaadi deleted the PORT-10295 branch September 5, 2024 15:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants