[2.6-rc2] juju debug-hooks doesn't trigger on juju run --unit <unitname> 'exit 0'

Bug #1828624 reported by Dmitrii Shcherbakov
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Canonical Juju
Triaged
Low
Unassigned

Bug Description

It used to be that one could restart a unit agent and get a config-changed event.

Another useful way of simulating an event and getting a non-relation scoped event context while blocking other event execution is by running

juju run --unit <unitname> 'hooks/<hookname>'

Juju treats this as an action execution:

2019-05-10 20:16:11 TRACE juju.worker.uniter.resolver loop.go:69 running op: run action f82136fc-566b-44fb-871f-43caa3bafec1
2019-05-10 20:16:11 TRACE juju.worker.uniter.resolver loop.go:122 charmdir: available=true opState: started=true stopped=false changing=false

Unfortunately, having `juju debug-hooks` initialized for a unit does catch a `juju run --unit <unitname> 'hooks/<hookname>'` execution.

It would be quite useful to have that capability.

The expected behavior is that any command specified in `juju run` will not be actually run and the execution will be intercepted by debug-hooks as usual by using an alternative hook execution code-path and setting up a new tmux window.

Revision history for this message
Richard Harding (rharding) wrote :

This came up a bit during the sprint latetly and we agree that the idea of "juju run this hook and let me debug it" via manual triggering is a really useful development idea.

We won't go back to retrigging the old event that was intentionally turned off though.

Changed in juju:
status: New → Triaged
importance: Undecided → Wishlist
Revision history for this message
Canonical Juju QA Bot (juju-qa-bot) wrote :

This bug has not been updated in 2 years, so we're marking it Low importance. If you believe this is incorrect, please update the importance.

Changed in juju:
importance: Wishlist → Low
tags: added: expirebugs-bot
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.