Juju charm hook vs. state
fengxia
fxia1 at lenovo.com
Fri Apr 14 19:19:44 UTC 2017
I'm learning charm development and confused about state vs. hook.
I used @when_not("state.0") to mark the very first function that gets
executed. In document it also says "install" hook will be the first to
execute. Tried @hooks.hook("install") but it just failed at charm
installation.
So what is the right way to determine the "entry" point in a charm? I
mean the first function block that will be executed. I'm thinking to use
chained state from that point on to guide execution process. Is this the
right approach?
--
Feng xia
Engineer
Lenovo USA
Phone: 5088011794
fxia1 at lenovo.com
Lenovo.com
Twitter | Facebook | Instagram | Blogs | Forums
More information about the Juju
mailing list