snappy services - auto restart

Jamie Strandboge jamie at canonical.com
Wed May 20 20:21:03 UTC 2015


On 05/20/2015 02:13 AM, Martin Pitt wrote:
> Alexander Sack [2015-05-19 12:40 +0200]:
>>> In a systemd unit this is the "Restart=" option, see man
>>> systemd.service(5). In paticular, Restart=on-failure is the most
>>> popular option.
>>>
>>> However, TTBOMK this option isn't exposed in the snap's YAML, so this
>>> needs to be added there.
>>
>> Shouldn't this be the default in almost all cases?
> 
> For snaps? Starting with adding Restart=on-failure to the synthesized
> .services for snaps sounds like a good first approach which avoids
> adding/exposing more metadata.
> 
> Auto-restarting on failure does not make much sense for socket/D-BUS
> activated services, i. e. if something is Type=dbus or ships a .socket
> unit. But neither is currently the case for snaps, right?
> 
Frameworks may use 'bus-name' in their services yaml which when specified adds
Type=dbus[1] to the autogenerated .service file. Eg 'hello-dbus-fwk' from the store.

[1]https://developer.ubuntu.com/en/snappy/guides/package-metadata/

-- 
Jamie Strandboge                 http://www.ubuntu.com/

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 819 bytes
Desc: OpenPGP digital signature
URL: <https://lists.ubuntu.com/archives/snappy-app-devel/attachments/20150520/e646e121/attachment.pgp>


More information about the snappy-app-devel mailing list