Hi Simon and Jamie, Thank you for the explanations. I would prefer to have all testings of a snap be done locally before I upload it to the store. Another scenario is a developer/company does not want to publish a snap which has a slot. How can they deal this?
BR, Robert On Thu, Oct 27, 2016 at 10:07 PM Jamie Strandboge <ja...@canonical.com> wrote: > On Thu, 2016-10-27 at 13:36 +0200, Simon Fels wrote: > > Hey Robert, > > > > the bluez plug and slot are now auto-connected as we put a > snap-declaration > > for it on the store side in place. That assertion tells snapd that the > > bluez snap should get its slots/plugs automatically connected. But this > > only applies for the bluez snap coming from the store. If you install one > > you built locally you don't have the signed assertion from the store > which > > would tell snapd to auto-connect the relevant plugs and slots. > > > > However I am not sure why the interface connection is denied when you do > it > > manually. @Samuele, Jamie: Any idea? > > > Robert and Simon, interfaces typically give privileged access to the > system to > slot implementations and the idea is that slot implementations need store > approval to protect against bad slot implementations that can be used to > harm > the system. As such the base declaration will typically deny connections > to slot > implementations which means a snap declaration from the store is required > for > your snap in order to allow plugging snaps to connect to it. > > Gustavo, while the base and snap declarations are working as designed and > with > the intended purpose, it seems that there is a rough edge for slot > implementation snap developers-- namely, it seems local installs of the > snap > block connections when we have something like this in the base declaration: > > foo: > deny-connection: true > deny-auto-connection: true > > The only way I can see for a slot implementation developer to work within > the > system as implemented is to a) upload to the store and request a snap > declaration and b) upload snaps to edge so as to 'snap refresh --edge ...' > to > test their changes. Perhaps I am missing something... should --dangerous > (or > something else) try to do something smart here so Robert can develop the > bluez > snap locally before uploading to the store? Should we provide a way for the > developer to sign a snap declaration for this sort of thing? > > Thanks! > > > regards, > > Simon > > > > On Thu, Oct 27, 2016 at 6:54 AM, Robert Liu <robert....@canonical.com> > > wrote: > > > > > > > > Hi list, > > > > > > I have 2 questions about connecting bluez interface. > > > In Interfaces reference [1], it said the bluez is not auto-connected. > But > > > after I installed the bluez snap, the bluez interface is connected. Do > I > > > misunderstnad the definition? > > > > > > root@localhost:/tmp# snap install --edge bluez > > > bluez (edge) 5.37-2 from 'canonical' installed > > > root@localhost:/tmp# snap interfaces > > > Slot Plug > > > bluez:service bluez:client > > > > > > > > > The other question is that I cannot connect the interface when using my > > > own bluez snap. Should I sign my snap to make this work? > > > > > > root@localhost:/tmp# snap install --dangerous bluez_5.37-2_amd64.snap > > > bluez 5.37-2 installed > > > root@localhost:/tmp# snap interfaces > > > Slot Plug > > > bluez:service - > > > [snipped] > > > - bluez:client > > > root@localhost:/tmp# snap connect bluez:client bluez:service > > > error: cannot perform the following tasks: > > > - Connect bluez:client to bluez:service (connection denied by slot > rule of > > > interface "bluez") > > > > > > [1] http://snapcraft.io/docs/reference/interfaces > > > > > > BR, > > > Robert > > > > > > -- > > > Snapcraft mailing list > > > Snapcraft@lists.snapcraft.io > > > Modify settings or unsubscribe at: https://lists.ubuntu.com/ > > > mailman/listinfo/snapcraft > > > > > > > -- > Jamie Strandboge | http://www.canonical.com > > -- > Snapcraft mailing list > Snapcraft@lists.snapcraft.io > Modify settings or unsubscribe at: > https://lists.ubuntu.com/mailman/listinfo/snapcraft >
-- Snapcraft mailing list Snapcraft@lists.snapcraft.io Modify settings or unsubscribe at: https://lists.ubuntu.com/mailman/listinfo/snapcraft