juju status: add ability to filter by machine

Bug #1748915 reported by James Troup
16
This bug affects 2 people
Affects Status Importance Assigned to Milestone
Canonical Juju
Fix Released
Medium
Unassigned

Bug Description

It's very common to want to know what services are deployed to a particular machine. 'juju status' currently provides no convenient short cut to this information. It would be nice if it did.

Tim Penhey (thumper)
tags: added: status
Changed in juju:
status: New → Triaged
importance: Undecided → Medium
tags: added: bitesize
Revision history for this message
John A Meinel (jameinel) wrote : Re: [Bug 1748915] [NEW] juju status: add ability to filter by machine

juju status 0

should do exactly that (filter by machines that match the identifier)

John
=:->

On Feb 12, 2018 19:55, "James Troup" <email address hidden> wrote:

> Public bug reported:
>
> It's very common to want to know what services are deployed to a
> particular machine. 'juju status' currently provides no convenient
> short cut to this information. It would be nice if it did.
>
> ** Affects: juju
> Importance: Undecided
> Status: New
>
> --
> You received this bug notification because you are subscribed to juju.
> Matching subscriptions: juju bugs
> https://bugs.launchpad.net/bugs/1748915
>
> Title:
> juju status: add ability to filter by machine
>
> To manage notifications about this bug go to:
> https://bugs.launchpad.net/juju/+bug/1748915/+subscriptions
>

Revision history for this message
James Troup (elmo) wrote :

John A Meinel <email address hidden> writes:

> juju status 0
>
> should do exactly that (filter by machines that match the identifier)

Well, that works sometimes. e.g. 'juju status 10' mostly works
(modulo the relations spew, which is a separate bug), but 'juju status
1' does not do what I would expect or want; it appears to match a 1 in
the application name for example.

To be honest, the lack of explicit typing in the filter seems
dangerous; it feels like we need something like a "$TYPE:" prefix?

So you could do 'juju status machine:1' and not have it match on a
bunch of different things.

--
James

Revision history for this message
Anastasia (anastasia-macmood) wrote :

We have fixed this, possibly as a drive-by to another fix.

I have ran against 2.3 tip (heading into 2.3.8) and have got an exact match output only. I have added a test to ensure that we do not regress: https://github.com/juju/juju/pull/8724

The test adds 11 machines numbered 0 through to 11 and puts units on machines 0, 1 and 10. When asking for machine 1 in status, 'juju status 1', I only get unit and application for that machine. Nor machine 10 or 0 in sight.

Marking this report as Fixed Released.

Changed in juju:
status: Triaged → 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.