snappy services - auto restart

Myles Caley myles at
Thu Apr 30 14:36:00 UTC 2015

Thanks Sergio. Confirmed that restart is not enabled by default. I modified
the .service file which is definitely a hack. For our needs, just having
auto-restart by default when installing the snap package is fine. Having
additional controls exposed through the snappy utils is not necessary for us
if this is enabled.

From:  Sergio Schvezov <sergio.schvezov at>
Date:  Saturday, April 25, 2015 at 11:56 AM
To:  Dustin Kirkland <kirkland at>
Cc:  Myles Caley <myles at>, Steve Langasek
<steve.langasek at>, Snappy Dev List
<snappy-app-devel at>
Subject:  Re: snappy services - auto restart

On Thu, Apr 23, 2015 at 12:20 PM, Dustin Kirkland <kirkland at>
> On Mon, Apr 20, 2015 at 11:05 AM, Myles Caley <myles at> wrote:
>> > Is there a way to configure services in snapps to auto-restart if the
>> > process dies? Along the same lines, is there a way via snappy CLI to
>> > manually restart a service if it does die?
> Hmm, that should be a systemd thing, I suspect.
> Sergio, et al, any ideas?

>From my point of view we should be autorestarting services, if that's not
the case, I guess we want to fix that.

For the latter, we don't have a snappy interface to restart services (we
could expose one, not sure about the granularity though), for now here's a

Manage and check state:
sudo systemctl [start|stop|restart|status]

eg; webdm 0.6 has a service called avahi, so I would

sudo systemctl start webdm_avahi_0.6.service

Check logs
sudo journalctl -u [package_name]_[service_name]_[package_version].service

e.g.; to check the aforementioned service's logs:

sudo journalctl -u  webdm_avahi_0.6.service

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <>

More information about the snappy-app-devel mailing list