Skip to content

octopus deployment-target delete --no-prompt doesn't work #490

@borland

Description

@borland

The bug

I'm trying to use the CLI to bulk-delete 400 deployment targets; this is exceedingly tedious to do by hand in the web portal

This powershell should get rid of every target in the system

octopus deployment-target list -f basic | %{ octopus deployment-target delete $_ --no-prompt }

However it just prints prompt disabled 400 times.

To delete an individual target this should work, but also fails

Command to reproduce

octopus deployment-target delete TARGETNAME --no-prompt 

Outcome

prompt-disabled is printed. The deployment target is not deleted and there is no error mressage or indication of anything else that might have gone wrong.

Note: If I don't specify --no-prompt then the CLI interactively prompts me to confirm the deletion. This works and the target is deleted, but it is of no use when scripting to delete 400 things.

Versions

cli: 2.1.5

Octopus Server: 2025.2.933 (cloud preprod instance)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions