Skip to content

Kubernetes builds are difficult to debug #4767

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

Closed
Tracked by #4628
bpmct opened this issue Oct 26, 2022 · 6 comments · Fixed by #6903
Closed
Tracked by #4628

Kubernetes builds are difficult to debug #4767

bpmct opened this issue Oct 26, 2022 · 6 comments · Fixed by #6903
Assignees

Comments

@bpmct
Copy link
Member

bpmct commented Oct 26, 2022

If I enter an invalid image as a parameter or something, the build logs will just say the resource is stuck on Creating until it eventually times out. If I inspect the pod manually, I will find the error.

You can use the TF_LOG=debug to get more info, but for some reason that makes builds take a very long time: #4766.

Additionally, there is a lot of noise with this log level. Perhaps it's only helpful to the user when an error occurs or when someone is modifying the template. Something @kylecarbs suggested was a "Run with debug logging" option when building workspaces, but that could make it difficult to debug race conditions.

@bpmct bpmct mentioned this issue Oct 26, 2022
13 tasks
@github-actions
Copy link

This issue is becoming stale. In order to keep the tracker readable and actionable, I'm going close to this issue in 7 days if there isn't more activity.

@github-actions github-actions bot added the stale This issue is like stale bread. label Dec 29, 2022
@github-actions github-actions bot closed this as not planned Won't fix, can't repro, duplicate, stale Jan 5, 2023
@bpmct bpmct reopened this Feb 13, 2023
@coadler coadler removed the stale This issue is like stale bread. label Feb 13, 2023
@mtojek mtojek self-assigned this Mar 20, 2023
@mtojek
Copy link
Member

mtojek commented Mar 23, 2023

I’d like to do some baby steps first, so TF_LOG=debug looks like a perfect candidate.

@bpmct Do you have any vision for this feature? I see references to a debug mode, so we can either add a new button “Build with debug mode” or a template setting “Debug mode enabled”?

@bpmct
Copy link
Member Author

bpmct commented Mar 23, 2023

I was thinking "Try again with debug mode" button or CLI prompt when a build fails. This would just run the build again with the increased TF_LOG=debug

I'm also open to do something in the template settings, but it may not be obvious for the admin to go there to turn it on when they see a failed build.

@mtojek
Copy link
Member

mtojek commented Mar 24, 2023

I like the idea of retrying with debugging on. We can start with that!

@mtojek
Copy link
Member

mtojek commented Mar 24, 2023

UI improvements are merged, I will focus on enabling debug mode dynamically.

@mtojek
Copy link
Member

mtojek commented Mar 30, 2023

@BrunoQuaresma I have just merged the backend side, so feel free to look into frontend 👍 .

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 a pull request may close this issue.

4 participants