Skip to content

Failed workspaces cannot be deleted, because the delete fails too #2313

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
sharkymark opened this issue Jun 14, 2022 · 2 comments
Closed

Failed workspaces cannot be deleted, because the delete fails too #2313

sharkymark opened this issue Jun 14, 2022 · 2 comments
Labels
api Area: HTTP API site Area: frontend dashboard

Comments

@sharkymark
Copy link
Contributor

sharkymark commented Jun 14, 2022

Addition from @kylecarbs 👋

If infrastructure fails to delete, it's impossible to remove a workspace from Coder forcefully.

image

It's unclear what to do at this point because I'm happy forcefully drop the infrastructure here (in this case a Docker image reference). Maybe after build failure, we allow a force deletion if you're an admin?

@mafredri I'd love your thoughts!


image

Expected state: Rollback and do not create metadata for the workspace in Coder if the create fails.

@misskniss misskniss added needs grooming site Area: frontend dashboard api Area: HTTP API labels Jun 14, 2022
@ketang
Copy link
Contributor

ketang commented Jun 14, 2022

I wonder if on the back end we want to allow replacing an existing workspace if we pass in the equivalent of --force. The initial issue here should be fixed cleanly, but I wonder about other inconsistent state issues that may arise.

@kylecarbs kylecarbs changed the title Workspace failed during creation, but still creates a workspace in Coder's database, which prevents me from re-creating without deleting the dead workspace Failed workspaces cannot be deleted, because the delete fails too Aug 24, 2022
@bpmct
Copy link
Member

bpmct commented Sep 19, 2022

We've introduced coder workspace delete <name> --orphan to address this: #3849

@bpmct bpmct closed this as completed Sep 19, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
api Area: HTTP API site Area: frontend dashboard
Projects
None yet
Development

No branches or pull requests

5 participants