On Tue, 2016-12-13 at 15:32 -0300, Sergio Cazzolato wrote: > I am trying to access to dbus from a python script in my snap and I am > getting the error dbus.exceptions.DBusException: > org.freedesktop.DBus.Error.AccessDenied: Failed to connect to socket > /var/run/dbus/system_bus_socket: Permission denied, it happens when I do > bus = dbus.SystemBus(mainloop=DBusGMainLoop()) > > Any idea how to fix it? >
To unblock yourself, you can install your snap with --devmode and then you shouldn't be blocked. If you are trying to make your snap work in strict confinement, you need to plug an interface that uses the system bus. If your script is trying to use a well- known service like network-manager, you need only 'plugs: [ network-manager ]' and then connect your snap to it with the 'snap connect' command. If you are implementing a new system service, a new interface will need to be created for it or you can soon try out the about-to-land 'dbus' interface[1]. [1]https://bugs.launchpad.net/snappy/+bug/1590679 -- Jamie Strandboge | http://www.canonical.com
signature.asc
Description: This is a digitally signed message part
-- Snapcraft mailing list Snapcraft@lists.snapcraft.io Modify settings or unsubscribe at: https://lists.ubuntu.com/mailman/listinfo/snapcraft