[RFC] Improving hardware access for snaps

Sergio Schvezov sergio.schvezov at canonical.com
Fri Jan 30 22:42:10 UTC 2015


On viernes 30 de enero de 2015 19h'31:44 ART, Jamie Strandboge wrote:
> On 01/30/2015 04:18 PM, Jamie Strandboge wrote:
>
> ...
>
>> = UX =
>> Relevant packaging yaml:
>> name: foo
>> version: 0.1
>> ...
>  ...
>
> Hmm, one thing that occurred to me is that while we want to give the 
device
> access to a particular service/cli binary, I don't think users 
> have a way to see
> what services/cli binaries a snap provides, do they? In other words:
>
> $ snappy install foo
> ...
> $ snappy add-hw foo.bar /dev/ttyS0
>
>
> How does the user know to specify 'foo.bar'? Does the new 
> snappy cli UX cover
> this anywhere? If not, we'll can leave the original proposal, 
> but prompt when
> the user specifies only the package name and when there is more than one
> service/cli binary to choose from (like in the above yaml example). Eg:
>
> $ snappy install foo
> ...
>
> $ snappy add-hw foo /dev/ttyS0             <=== only package name 
specified
> Add access to '/dev/ttyS0' for which of the following:
> [1] foo.bar
> [2] foo.baz
> [3] all of the above
>
>> 1
> 'foo.bar' is now allowed to access /dev/ttyS0

It should be foo_bar though, foo.bar would be akin to camlistore.sergiusens 
or pastebinit.mvo (full package names).


>
> $ snappy add-hw foo.bar /dev/ttyS1         <=== package name + 
> service specified
> 'foo.bar' is now allowed to access /dev/ttyS1
>
>
>




More information about the snappy-devel mailing list