Hi guys, I'm Bodie Solomon, an outsider on contract -- I've spoken to a few of you in IRC. Gustavo suggested I email this list to clear up some difficulties with our progress on implementing Actions.
Our job is to implement some new functionality to trigger execution of "actions" on units and services. For example, "juju do mysql snapshot". James Harshaw and I have spent a few days documenting and understanding the command-line code, so we're looking to get a good foothold and crank out some code. However, I'm getting some conflicting pointers. Gustavo said we should start with charm/config.go, but as I'm looking through /cmd/juju/run.go, it looks almost like Actions should be implemented there. I asked about this in freenode #juju-dev and dimitern confirmed what I was thinking (but again, I'm new to the project) -- this almost seems like it should be an API feature. <bodie_> OK, I think that makes sense :) we had talked about doing it via hooks but I'm not positive that's the right way <dimitern> bodie_, things hooks can do are very limited compared to the api <dimitern> sounds like you could use a plugin that calls juju run internally <dimitern> juju run allows you to run scripts remotely on a unit or all machines inside the same context (env vars etc.) that a hook runs I'm not certain it's the right way, and again I'm quite new to the codebase so I'm not aware of the intricacies and all of what's out there; to my brain it's mostly still a jungle. I'm not sure how to begin approaching the hooks problem in the code (I assume through charm/config.go, but this has so far not been a productive direction to investigate. Perhaps I just need to spend more time looking at that.) Gustavo's indication was that we should be implementing this through hooks, so I'm at a loss here. I agree with him that this is probably the best place to start. Any input is welcome. :) Bodie
-- Juju-dev mailing list Juju-dev@lists.ubuntu.com Modify settings or unsubscribe at: https://lists.ubuntu.com/mailman/listinfo/juju-dev