2.7-rc5: juju run does not return command output

Bug #1853500 reported by John George
8
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Canonical Juju
Fix Released
High
Ian Booth

Bug Description

There is a regression with 2.7-rc5 where juju run does not return the output of the command it executes on the unit. We noted that the output is presented when the --format yaml option is passed and also if 'juju exec' is called rather than 'juju run'. Please see the demonstrated out put below:

alexb@blackFire:~$ juju run -u fio/leader pwd
/var/lib/juju/agents/unit-fio-0/charm

$ juju run -u fio/leader pwd --format yaml
- Stdout: |
    /var/lib/juju/agents/unit-fio-0/charm
  UnitId: fio/0

alexb@blackFire:~$ juju show-controller
localhost-localhost:
  details:
    uuid: 33a9125b-6c54-436f-838d-3185b48431be
    controller-uuid: 33a9125b-6c54-436f-838d-3185b48431be
    api-endpoints: ['10.80.4.33:17070']
    cloud: localhost
    region: localhost
    agent-version: 2.6.10
    mongo-version: 3.6.3

ubuntu@prodymcprodface-cpe-e3efd0c9-d965-4cdc-a990-6f77a56368c5:~/cpe/foundation$ juju run -m openstack -u vault/leader 'pwd'

ubuntu@prodymcprodface-cpe-e3efd0c9-d965-4cdc-a990-6f77a56368c5:~/cpe/foundation$ juju run --format yaml -m openstack -u vault/leader 'pwd'
- Stdout: |
    /var/lib/juju/agents/unit-vault-0/charm
  UnitId: vault/0

ubuntu@prodymcprodface-cpe-e3efd0c9-d965-4cdc-a990-6f77a56368c5:~/cpe/foundation$ juju show-controller
foundations-maas:
  details:
    uuid: 52dcd6f4-c171-4bca-8bac-48c3ccec2f49
    controller-uuid: 52dcd6f4-c171-4bca-8bac-48c3ccec2f49
    api-endpoints: ['10.246.64.200:17070', '10.246.64.202:17070', '10.246.64.201:17070']
    cloud: maas_cloud
    region: default
    agent-version: 2.7-rc5
    controller-model-version: 2.7-rc5
    mongo-version: 3.6.3

ubuntu@prodymcprodface-cpe-e3efd0c9-d965-4cdc-a990-6f77a56368c5:~/cpe/foundation$ juju exec -m openstack -u vault/leader 'pwd'
/var/lib/juju/agents/unit-vault-0/charm

tags: added: cdo-release-blocker
removed: cdo-qa-blocker
Ian Booth (wallyworld)
Changed in juju:
milestone: none → 2.7-rc6
assignee: nobody → Ian Booth (wallyworld)
importance: Undecided → High
status: New → In Progress
Revision history for this message
Ian Booth (wallyworld) wrote :

There was a typo in the code to support backwards compatibility with juju run vs juju exec

https://github.com/juju/juju/pull/10937

Ian Booth (wallyworld)
Changed in juju:
status: In Progress → Fix Committed
Ian Booth (wallyworld)
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.