On 21.11.2017 15:58, Junien Fridrick wrote:
> The only way I can think of is to use @hook('stop'), but as far as I
> remember, using hooks is not something one should do in the reactive
> world.

No, just fine. Most of the time when you think hook, reactive will have
a abstract handler for it. But not for all things.

Very simple example
https://github.com/tbaumann/charm-logstash-conf-d/blob/master/reactive/logstash_conf-d.py#L36


> 
> Does anyone have any advice for doing that properly ?
> 
> I was also thinking that maybe the snap layer could save which
> application installed which snap, and if said application is removed,
> then remove said snap. Would that be a good idea ?

Totally. At least if you are sure that you where the only one who could
have installed the snap.

-- 
Juju mailing list
[email protected]
Modify settings or unsubscribe at: 
https://lists.ubuntu.com/mailman/listinfo/juju

Reply via email to