juju run doesn't have an option to trigger debug-hooks

Bug #1275745 reported by Michael Nelson
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
juju-core
Expired
Medium
Unassigned

Bug Description

juju run provides a great way to do not just small one-off commands, but also enables doing more complicated things - for example, applying an ansible playbook to do a rolling upgrade (ie. just upgrade the application service on one unit).

With that in mind, it'd be very helpful to be able to do:

juju run --unit elasticsearch/0 hooks/my-custom-hook --debug-hooks

I realise it's not really a hook, but given that it runs in a hook context, I can only test/debug it by triggering some other hook (config-changed).

Tags: run
Curtis Hovey (sinzui)
Changed in juju-core:
status: New → Triaged
importance: Undecided → High
tags: added: run
Revision history for this message
Andrew Wilkins (axwalk) wrote :

Can you please expand on the use case a bit? You can run hooks from juju run --unit. What do you want with debug-hooks?

Revision history for this message
Michael Nelson (michael.nelson) wrote : Re: [Bug 1275745] Re: juju run doesn't have an option to trigger debug-hooks

On Fri, Feb 14, 2014 at 5:05 AM, Andrew Wilkins
<email address hidden> wrote:
> Can you please expand on the use case a bit? You can run hooks from juju
> run --unit. What do you want with debug-hooks?

I want to debug a custom command that i run via juju run. ie. I want
to be able to do:

In terminal 1:
juju debug-hooks elasticsearch/0

In terminal 2:
juju run --unit elasticsearch/0 scripts/my-custom-command --debug-hooks

and have terminal 1 pick up the trigger and drop me into a screen for
scripts/my-custom-command so I can run it by hand and test the
environment. It's not a priority at all for me - I can always trigger
a hook context for debug-hooks via `juju set` and run my custom
command from there to debug, it was just a small thought of an
improvement.

Changed in juju-core:
importance: High → Medium
Revision history for this message
Stuart Bishop (stub) wrote :

Has this been solved with actions? Or has the scope of this bug changed?

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

It looks like it may have been solved with actions. Marking as Incomplete until we get contrary feedback.

Changed in juju-core:
status: Triaged → Incomplete
Revision history for this message
Launchpad Janitor (janitor) wrote :

[Expired for juju-core because there has been no activity for 60 days.]

Changed in juju-core:
status: Incomplete → Expired
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.