nsacyber / WALKOFF

A flexible, easy to use, automation framework allowing users to integrate their capabilities and devices to cut through the repetitive, tedious tasks slowing them down. #nsacyber
https://nsacyber.github.io/WALKOFF/
Other
1.2k stars 222 forks source link

When you update an apps config or code, it's not detected unless you make a whole new dir #208

Closed juliedavila closed 5 years ago

coreyjrobins commented 5 years ago

Hi Jonathan,

Can you provide us with more details on the issue? Did you see any error messages in the terminal window?

Currently, the WALKOFF server needs to be restarted if you make any updates to the code, including app python files and app YAML configuration files.

juliedavila commented 5 years ago

Yes, that part is understood. So given an app that has already been picked up by walkoff, modify the YAML to change it's label for example, restart the server, you'll notice the label is not changed.

adpham95 commented 5 years ago

Could you give a more concrete example? For example I'm changing an action's name in the YAML from:

actions:
  connect:  # before
    run: app.Walkoff.connect
    description: Connect to walkoff
    parameters:
      - name: timeout
        description: Timeout on the request (in seconds)
        type: number
        default: 2.0

to:

actions:
  foobar:  # after
    run: app.Walkoff.connect
    description: Connect to walkoff
    parameters:
      - name: timeout
        description: Timeout on the request (in seconds)
        type: number
        default: 2.0

Upon a restart of the WALKOFF server, the action's name is updated from "connect" to "foobar."

The reason Corey asked if there were any errors on startup, is if there is a validation error in an app (say a typo in the YAML or referencing an action that no longer exists in Python), then it will not load the app at all, but it will still start the server successfully otherwise.

juliedavila commented 5 years ago

Hm ok interesting, i'll chalk this up to PEBKAC/user-error. It would nice if a linter of sorts could be whipped up to handle this validation prior to starting the server back up.

Unfortunately, I don't have any further time to dedicate to this. I appreciate the responses and will close this issue.