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

Support Probe-level terminationGracePeriodSeconds #2697

Open
wants to merge 6 commits into
base: main
Choose a base branch
from

Conversation

andrewpage
Copy link

@andrewpage andrewpage commented Feb 27, 2025

Description

Support Probe-level termination_grace_period_seconds field in liveness_probe and startup_probe.

Acceptance tests

  • Have you added an acceptance test for the functionality being added?
  • Have you run the acceptance tests on this branch?

Output from acceptance testing:

$ make testacc TESTARGS="-run ^TestAccKubernetes\(Pod\|Deployment\)V1_\(.+\)probe"

==> Checking that code complies with gofmt requirements...
go vet ./...
TF_ACC=1 go test "/Users/andrewpage/Developer/hightouch/terraform-provider-kubernetes/kubernetes" -v -vet=off -run ^TestAccKubernetes\(Pod\|Deployment\)V1_\(.+\)probe -parallel 8 -timeout 3h
=== RUN   TestAccKubernetesDeploymentV1_with_container_liveness_probe_using_exec
=== PAUSE TestAccKubernetesDeploymentV1_with_container_liveness_probe_using_exec
=== RUN   TestAccKubernetesDeploymentV1_with_container_liveness_probe_using_http_get
=== PAUSE TestAccKubernetesDeploymentV1_with_container_liveness_probe_using_http_get
=== RUN   TestAccKubernetesDeploymentV1_with_container_liveness_probe_using_tcp
=== PAUSE TestAccKubernetesDeploymentV1_with_container_liveness_probe_using_tcp
=== RUN   TestAccKubernetesDeploymentV1_with_container_liveness_probe_using_termination_grace_period_seconds
=== PAUSE TestAccKubernetesDeploymentV1_with_container_liveness_probe_using_termination_grace_period_seconds
=== RUN   TestAccKubernetesPodV1_with_container_liveness_probe_using_exec
=== PAUSE TestAccKubernetesPodV1_with_container_liveness_probe_using_exec
=== RUN   TestAccKubernetesPodV1_with_container_liveness_probe_using_http_get
=== PAUSE TestAccKubernetesPodV1_with_container_liveness_probe_using_http_get
=== RUN   TestAccKubernetesPodV1_with_container_liveness_probe_using_termination_grace_period_seconds
=== PAUSE TestAccKubernetesPodV1_with_container_liveness_probe_using_termination_grace_period_seconds
=== RUN   TestAccKubernetesPodV1_with_container_liveness_probe_using_tcp
=== PAUSE TestAccKubernetesPodV1_with_container_liveness_probe_using_tcp
=== RUN   TestAccKubernetesPodV1_with_container_liveness_probe_using_grpc
=== PAUSE TestAccKubernetesPodV1_with_container_liveness_probe_using_grpc
=== RUN   TestAccKubernetesPodV1_config_container_startup_probe
=== PAUSE TestAccKubernetesPodV1_config_container_startup_probe
=== RUN   TestAccKubernetesPodV1_config_container_startup_probe_termination_grace_period_seconds
=== PAUSE TestAccKubernetesPodV1_config_container_startup_probe_termination_grace_period_seconds
=== CONT  TestAccKubernetesDeploymentV1_with_container_liveness_probe_using_exec
=== CONT  TestAccKubernetesPodV1_with_container_liveness_probe_using_termination_grace_period_seconds
=== CONT  TestAccKubernetesPodV1_config_container_startup_probe
=== CONT  TestAccKubernetesPodV1_config_container_startup_probe_termination_grace_period_seconds
=== CONT  TestAccKubernetesPodV1_with_container_liveness_probe_using_grpc
=== CONT  TestAccKubernetesPodV1_with_container_liveness_probe_using_tcp
=== CONT  TestAccKubernetesDeploymentV1_with_container_liveness_probe_using_termination_grace_period_seconds
=== CONT  TestAccKubernetesPodV1_with_container_liveness_probe_using_http_get
--- PASS: TestAccKubernetesDeploymentV1_with_container_liveness_probe_using_exec (3.11s)
=== CONT  TestAccKubernetesPodV1_with_container_liveness_probe_using_exec
--- PASS: TestAccKubernetesPodV1_with_container_liveness_probe_using_termination_grace_period_seconds (3.88s)
=== CONT  TestAccKubernetesDeploymentV1_with_container_liveness_probe_using_tcp
--- PASS: TestAccKubernetesPodV1_config_container_startup_probe (4.84s)
=== CONT  TestAccKubernetesDeploymentV1_with_container_liveness_probe_using_http_get
--- PASS: TestAccKubernetesPodV1_with_container_liveness_probe_using_grpc (4.88s)
--- PASS: TestAccKubernetesPodV1_with_container_liveness_probe_using_http_get (4.88s)
--- PASS: TestAccKubernetesPodV1_config_container_startup_probe_termination_grace_period_seconds (4.89s)
--- PASS: TestAccKubernetesDeploymentV1_with_container_liveness_probe_using_termination_grace_period_seconds (4.89s)
--- PASS: TestAccKubernetesPodV1_with_container_liveness_probe_using_tcp (6.16s)
--- PASS: TestAccKubernetesDeploymentV1_with_container_liveness_probe_using_tcp (2.57s)
--- PASS: TestAccKubernetesPodV1_with_container_liveness_probe_using_exec (6.28s)
--- PASS: TestAccKubernetesDeploymentV1_with_container_liveness_probe_using_http_get (4.63s)
PASS
ok  	github.com/hashicorp/terraform-provider-kubernetes/kubernetes	10.041s

Release Note

Release note for CHANGELOG:

Add Probe-level `terminationGracePeriodSeconds` fields to Liveness and Readiness probes.

References

Community Note

  • Please vote on this issue by adding a 👍 reaction to the original issue to help the community and maintainers prioritize this request
  • If you are interested in working on this issue or have submitted a pull request, please leave a comment

Copy link

hashicorp-cla-app bot commented Feb 27, 2025

CLA assistant check
All committers have signed the CLA.

Copy link

CLA assistant check

Thank you for your submission! We require that all contributors sign our Contributor License Agreement ("CLA") before we can accept the contribution. Read and sign the agreement

Learn more about why HashiCorp requires a CLA and what the CLA includes

Have you signed the CLA already but the status is still pending? Recheck it.

@andrewpage andrewpage changed the title Andrew/probe tgp Support Probe-level terminationGracePeriodSeconds Feb 27, 2025
@andrewpage andrewpage marked this pull request as ready for review February 27, 2025 20:16
@andrewpage andrewpage requested a review from a team as a code owner February 27, 2025 20:16
@andrewpage
Copy link
Author

I ran go generate locally to generate the docs, but it yielded a lot of changes, many of which were completely unrelated to this change. I'd appreciate guidance on the right way to generate updated docs.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant