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

Apply applicable ASM_OPTS in config_map #1183

Merged
merged 1 commit into from
Mar 21, 2022
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions modules/asm/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,7 @@ resource "kubernetes_config_map" "asm_options" {

data = {
multicluster_mode = var.multicluster_mode
ASM_OPTS = var.enable_cni ? "CNI=on" : null
Copy link
Contributor

@Monkeyanator Monkeyanator Mar 17, 2022

Choose a reason for hiding this comment

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

nit: should this be

Suggested change
ASM_OPTS = var.enable_cni ? "CNI=on" : null
ASM_OPTS = var.enable_cni ? "CNI=on" : ""

?

Copy link
Contributor

Choose a reason for hiding this comment

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

Do we want it to be set to "" or excluded entirely? Usually I think excluding is better.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

When set to null the value is not applied to the configMap. Empty value could trigger unintended behavior.

Copy link
Contributor

Choose a reason for hiding this comment

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

Agreed, let's stick to null.

}

depends_on = [google_gke_hub_membership.membership, google_gke_hub_feature.mesh]
Expand Down