Comment 2 for bug 1689944

Oliver Grawert (ogra) wrote :

the cleanest way is to check /etc/os-release, it has been changed to reflect ubuntu-core (iirc in the late 15.04 images) and will not change, so this should be the preferred way.
if you dont have rootfs access when needing the info, then parsing /proc/cmdline for snap_* vars should be ok too.