Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Verbose and Terse Output Inconsistent #272

Closed
niall-munnelly opened this issue Dec 3, 2019 · 1 comment
Closed

Verbose and Terse Output Inconsistent #272

niall-munnelly opened this issue Dec 3, 2019 · 1 comment

Comments

@niall-munnelly
Copy link

This may be true for everything in rd-cli, but here's what I'm seeing for executions:

The terse command clearly identifies an execution as a job or adhoc:

Terse:
[rundeck_service_account@my_server rundeck]$ RD_FORMAT=yaml RD_DATE_FORMAT="MM-dd-yyyy HH:mm:ss.SSS" rd executions info -e 136134
136134 succeeded 11-21-2019 19:01:48.000 11-21-2019 19:01:49.000 https://my_server.my_domain.com:4443/project/my_project/execution/show/136134 adhoc chmod -R o-rx /opt/rundeck/etc

Verbose, however, does not:

[rundeck_service_account@my_server rundeck]$ RD_FORMAT=yaml RD_DATE_FORMAT="MM-dd-yyyy HH:mm:ss.SSS" rd executions info -e 136134 -v

  • failedNodes: null
    description: chmod -R o-rx /opt/rundeck/etc
    project: my_project
    successfulNodes:
    • localhost
      argstring: null
      serverUUID: null
      dateStarted: 11-21-2019 19:01:48.000
      dateEnded: 11-21-2019 19:01:49.000
      id: '136134'
      href: https://my_server.my_domain.com:4443/api/31/execution/136134
      permalink: https://my_server.my_domain.com:4443/project/my_project/execution/show/136134
      user: rundeck_user
      status: succeeded

Sort-of related,
Using output filters, I've been able to print all this out in key-value pairs without having to use YAML or JSON formats, which is great, but I am unable to find the key for execution type that would expand to "job" or "adhoc." - that same information which is missing from verbose output. I reckon I'll know that that is when these two outputs are in parity, but perhaps you could advise what that key is called in the meantime. It's not documented:

Input error for [info]: Option must have a value: [--outformat -% value] : Output format specifier for execution data. You can use "%key" where key is one of:id, project, description, argstring, permalink, href, status, job, job.*, user, serverUUID, dateStarted, dateEnded, successfulNodes, failedNodes. E.g. "%id %href"

@gschueler
Copy link
Member

i can add "adhoc: true/false" format option. in the terse output it checks if the job data is empty which indicates it is an adhoc execution, but that isn't explicitly exposed in the verbose data

gschueler added a commit that referenced this issue Aug 11, 2020
Fix #272 execution info includes adhoc flag
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants