Skip to content

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

Closed

Description

@sharkymark

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.

Activity

  1. ketang commented on Jun 14, 2022

    @ketang
    Contributor

    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.

  2. 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[/+] on Aug 24, 2022
  3. bpmct commented on Sep 19, 2022

    @bpmct
    Member

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

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    apiArea: HTTP APIsiteArea: frontend dashboard

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions