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

add terraform module #1049

Closed
wants to merge 6 commits into from
Closed

add terraform module #1049

wants to merge 6 commits into from

Conversation

wasaga
Copy link
Collaborator

@wasaga wasaga commented Oct 10, 2024

Summary

Related issues

https://github.com/pomerium/internal/issues/1970

Checklist

  • reference any related issues
  • updated docs
  • updated unit tests
  • updated UPGRADING.md
  • add appropriate tag (improvement / bug / etc)
  • ready for review

source = "git:https://github.com/pomerium/ingress-controller//terraform?ref=v0.28.0"
}

resource "kubernetes_manifest" "pomerium_config" {
Copy link
Collaborator Author

Choose a reason for hiding this comment

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

the installation and configuration need be split into separate steps, due to hashicorp/terraform-provider-kubernetes#1367

Copy link

@grandmogbarkin grandmogbarkin Oct 24, 2024

Choose a reason for hiding this comment

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

Can also use kubectl_manifest instead of kubernetes_manifest, which doesn't have this issue.

resource "kubectl_manifest" "pomerium_config" {
  yaml_body = <<YAML
apiVersion: ingress.pomerium.io/v1
kind: Pomerium
metadata:
  name: global
spec:
  secrets: pomerium-ingress-controller/bootstrap
YAML
}

@wasaga wasaga requested a review from gaurdro October 17, 2024 20:42
run_as_non_root = true
}

node_selector = merge(local.default_node_selector, var.node_selector)
Copy link

Choose a reason for hiding this comment

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

optional: It's sometimes nicer to do a merge in the local variable.

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

do you mean :

node_selector = local.node_selector

and then have

locals {
  default_node_selector = {...}
  node_selector = merge(local.default_node_selector, var.node_selector)
}

Copy link

Choose a reason for hiding this comment

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

Yes, Or local.computed_node_selector to denote it's not a single-sourced value.

…roxy_node_port_https option for NodePort service type
@wasaga wasaga marked this pull request as ready for review October 23, 2024 23:41
@wasaga wasaga requested a review from a team as a code owner October 23, 2024 23:41
@wasaga wasaga requested review from calebdoxsey and wrmedford and removed request for a team October 23, 2024 23:41
Copy link

@wrmedford wrmedford left a comment

Choose a reason for hiding this comment

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

LGTM

@wasaga
Copy link
Collaborator Author

wasaga commented Oct 30, 2024

pomerium/install#1

@wasaga wasaga closed this Oct 30, 2024
@wasaga wasaga deleted the wasaga/terraform branch October 30, 2024 22:31
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.

4 participants