HTML Output

39 views
Skip to first unread message

Roger McCarrick

unread,
May 16, 2025, 4:19:48 PM5/16/25
to rundeck-discuss
I was asked to create a Rundeck job that retrieves data from a database.
I pull the data with powershell and dump it into a CSV file on a dfs share.
Then the user has to go to that share to read the file, import it .. do whatever they need to do.

The output in the Rundeck console is not great for viewing lots of entries from a DB. It would be great if we could format the output into an HTML table. Can this be done?

I currently dump to a csv file as I mentioned but I also output to a html table in a file that gets served from a separate Apache server. 

rac...@rundeck.com

unread,
May 16, 2025, 5:25:55 PM5/16/25
to rundeck-discuss
Hi Roger,

This thread will probably help you. More info here.

Regards.
Message has been deleted

Roger McCarrick

unread,
May 20, 2025, 10:28:45 AM5/20/25
to rundeck-discuss
I don't follow .. seems I need a plugin more plugins? Which ones? where do i get them.
The documentation at times can be hard to follow at times

Roger McCarrick

unread,
May 20, 2025, 12:04:53 PM5/20/25
to rundeck-discuss
I uploaded the example from that thread "HTMLExample", set the node to local, ran it and got this:

Result: 1
chmod: cannot access '/home/rundeck/C:ScriptsUploads/0-346393-RUNDECK01-dispatch-script.tmp.sh': No such file or directory
Failed: NonZeroResultCode: Result code was 1
Execution failed: 346393 in project Staging-Windows: [Workflow result: , step failures: {1=Dispatch failed on 1 nodes: [ RUNDECK01: NonZeroResultCode: Result code was 1 + {dataContext=MultiDataContextImpl(map={ContextView(step:1, node: RUNDECK01 )=BaseDataContext{{exec={exitCode=1}}}, ContextView(node: RUNDECK01)=BaseDataContext{{exec={exitCode=1}}}}, base=null)} ]}, Node failures: { RUNDECK01=[NonZeroResultCode: Result code was 1 + {dataContext=MultiDataContextImpl(map={ContextView(step:1, node:NYMGMTRDECK01)=BaseDataContext{{exec={exitCode=1}}}, ContextView(node: RUNDECK01)=BaseDataContext{{exec={exitCode=1}}}}, base=null)} ]}, status: failed]

rac...@rundeck.com

unread,
May 22, 2025, 11:09:16 AM5/22/25
to rundeck-discuss

Hi Roger,

It isn’t a plugin, it’s a Render Formatted Data Output filter.

Regarding the chmod: cannot access '/home/rundeck/C:ScriptsUploads/0-346393-RUNDECK01-dispatch-script.tmp.sh': No such file or directory error. It seems that you’re using Rundeck on Windows, the /bin/bash invocation string and .sh script extension don’t work, change it to powershell.exe  and .ps1.

There is the Windows version:

- defaultTab: nodes description: '' executionEnabled: true id: 7e99966c-5ef6-46ad-bc7c-a2dcf2a02e11 loglevel: INFO name: HTMLExample nodeFilterEditable: false options: - name: age required: true value: '18' plugins: ExecutionLifecycle: {} scheduleEnabled: true sequence: commands: - autoSecureInput: 'false' fileExtension: .ps1 interpreterArgsQuoted: false passSecureInput: 'false' plugins: LogFilter: - config: datatype: text/html sanitizeHtml: 'true' striped: 'false' type: render-datatype script: |- echo "<strong>USER:</strong> @job.username@" echo "<strong>AGE:</strong> @option.age@" scriptInterpreter: powershell.exe keepgoing: false strategy: node-first uuid: 7e99966c-5ef6-46ad-bc7c-a2dcf2a02e11

I’ve tested it on Rundeck 5.12 successfully.

Regards.

Reply all
Reply to author
Forward
0 new messages