'juju add-cloud' has no meaning

Bug #1830407 reported by Peter Matulis
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Canonical Juju
Fix Released
Medium
Anastasia

Bug Description

Since the introduction of the `--local` option the invocation of `juju add-cloud` has lost all meaning and the command should error out with an appropriate message. The current output is confusing, especially given that this is how this command used to work.

$ juju add-cloud
ERROR cloud "" not found

Other examples:

$ juju deploy
ERROR no charm or bundle specified

$ juju remove-machine
ERROR no machines specified

So what about,

$ juju add-cloud
ERROR no cloud specified

The problem here is that currently (v.2.6.2) for this to work a feature flag is required:

$ juju add-cloud aws
ERROR feature flag "multi-cloud" needs to be enabled to add a "ec2" cloud

We may want to mention the `--local` option until that is no longer the case:

$ juju add-cloud
ERROR option '--local' missing

Or a combination:

$ juju add-cloud
ERROR use option '--local' to add a cloud to the client's cache or enable feature flag "multi-cloud" and include a cloud name as argument.

tags: added: multi-cloud
tags: added: usability
Changed in juju:
status: New → Triaged
Changed in juju:
importance: Undecided → Medium
Revision history for this message
Anastasia (anastasia-macmood) wrote :

Since this bug was filed, things have changed.

On develop, heading into 2.7-b1 I do not observe this behavior and 'juju add-cloud', with no argmuents as you have shown here, goes straight into interactive mode.

If I keep going and avoid specifying cloud name, I do get a very descriptive and helpful error message:

$ juju add-cloud
Cloud Types
  lxd
  maas
  manual
  openstack
  vsphere

Select cloud type: lxd

Enter a name for your lxd cloud:
Invalid name. Valid names start with a letter, and use only letters, numbers, hyphens, and underscores:
....

So, I think that this has been resolved as part of another work in the area. I am marking this as Fix Committed for 2.7-b1.

Changed in juju:
status: Triaged → Fix Committed
milestone: none → 2.7-beta1
Revision history for this message
Anastasia (anastasia-macmood) wrote :

Ah, the bit that was missing form the description is the fact that there is a bootstrapped controller present. In other words, the command is picking up 'current' controller.

Changed in juju:
status: Fix Committed → In Progress
assignee: nobody → Anastasia (anastasia-macmood)
Revision history for this message
Anastasia (anastasia-macmood) wrote :

PR to improve 'add-cloud' experience and messaging is: https://github.com/juju/juju/pull/10580

Changed in juju:
status: In Progress → Fix Committed
Changed in juju:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.