I'm trying to create a web application that runs salt commands. Calling the
commands was no problem but I now want to display the output back into the
web app which is the part I'm having trouble with. Once the high state has
completed I would like to display which packages successfully installed and
which have failed but getting this is proving difficult.

def thread_state(test):
     client = salt.client.LocalClient()
     test['id'] = client.cmd('*','state.highstate')

test = {
         "id": 1

thread.start_new_thread(thread_state, (test,))


print test['id']

This is my code currently, the output I receive is the job ID and that it
is running. Does anyone have any experience working with Salt and the
client api, who might know how to retrieve and save the highstates final
output ( successful and failed packages) to a variable/dictionary so that I
can display it to an html page?


You received this message because you are subscribed to the Google Groups "Salt-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to salt-users+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Search Discussions

Related Discussions

Discussion Navigation
viewthread | post
Discussion Overview
groupsalt-users @
postedApr 16, '15 at 9:45p
activeApr 16, '15 at 9:45p

1 user in discussion

Charles Moore: 1 post



site design / logo © 2022 Grokbase