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

Zarf destroy panic #2700

Open
Tracked by #2953
phillebaba opened this issue Jul 8, 2024 · 1 comment
Open
Tracked by #2953

Zarf destroy panic #2700

phillebaba opened this issue Jul 8, 2024 · 1 comment
Assignees
Labels
bug 🐞 Something isn't working
Milestone

Comments

@phillebaba
Copy link
Member

phillebaba commented Jul 8, 2024

Environment

Device and OS: Arch Linux
App version: v0.35.0
Kubernetes distro being used: N/A
Other:

Steps to reproduce

  1. Run zarf destroy --confirm against a cluster where Zarf is not installed.

Expected result

The command should either error or should exit immediatly.

Actual Result

Panics due to a nil pointer in the state.

Visual Proof (screenshots, videos, text, etc)

Severity/Priority

Low/Medium

Additional Context

N/A

@phillebaba phillebaba added possible-bug 🐛 bug 🐞 Something isn't working and removed possible-bug 🐛 labels Jul 8, 2024
@phillebaba
Copy link
Member Author

The easy solution to this problem is to just to check if state is nil before the other state check. I do however think it is slightly weird to delete a k3s cluster blindly without any user input just because the scripts are located at a specific file location.

https://github.com/defenseunicorns/zarf/blob/7288cf2b6c40570d84128fd4ec6673a3277aedee/src/cmd/destroy.go#L42-L56

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug 🐞 Something isn't working
Projects
Status: Triage
Development

No branches or pull requests

3 participants