Comment 4 for bug 1876104

Revision history for this message
Trent Lloyd (lathiat) wrote :

There is still an issue here.

Tested on juju 2.8.3 with the openstack provider

= Scenario 1: non-force destroy =
Test:
juju destroy-model k8s

Result:
You get a surfaced ERROR:
> ERROR cannot destroy model "k8s"
>
> The model has persistent storage remaining:
> 3 volumes
>
> To destroy the storage, run the destroy-model
> command again with the "--destroy-storage" option.

= Scenario 2: destroy with force =

Test:
juju destroy-model k8s --force

Result:
The client just sits there with the message "Waiting for model to be removed, 10 machine(s), 10 application(s), 3 volume(s)..." with no error and no progress made on destroying the model.

But from "juju debug-log -m controller" we see the error:
machine-0: 06:46:26 WARNING juju.apiserver.common failed destroying model a41433cc-ae36-49cf-899e-45bbf5b22786: failed to destroy model: model contains persistent storage

*Expected Results*

The client should surface the failure to destroy error the same as it does without --force. Then the user knows they can re-run with both --force and --destroy storage per Scenario 3 below

= Scenario 3: destroy with force and destroy-storage =

Test:
juju destroy-model k8s --force --destroy-storage

Result:
The model successfully destroys