Request to publish snap "Freeshow" with `system-files` interface

Hi all,

Freeshow is attempting to access /usr/share/alsa/alsa.conf when accessing MIDI interfaces (is crashing when it cannot). To try to mitigate this, I have added the following to the snap:

plugs:
  usr-share-alsa:
    interface: system-files
    read:
      - /usr/share/alsa/alsa.conf
----(snip)----
    plugs:
      - alsa
      - usr-share-alsa

As such it now needs a manual review. With that, can I get a manual review for Freeshow? Thanks!

Hi @Eickmeyer

To make this file accessible, could this instead use a snap layout like:

layout:
  /usr/share/alsa/alsa.conf:
    bind-file: $SNAP_DATA/usr/share/alsa/alsa.conf

That might indeed work better. Let me give it a try as we’ve been having a large degree of difficulty with it actually working. Either way I believe this will still require a special publication permissions.

roger that - let me know how you go

Went with the layout / bind-file option as it solved the problem but presented a new one:

ALSA lib seq.c:935:(snd_seq_open_noupdate) Unknown SEQ default
ALSA lib control.c:1570:(snd_ctl_open_noupdate) Invalid CTL hw:0
ALSA lib control.c:1570:(snd_ctl_open_noupdate) Invalid CTL hw:1
Segmentation fault (core dumped)

Alsa is connected. Either way, it’s progress.

What if instead you change this to the whole /usr/share/alsa directory?

layout:
  /usr/share/alsa:
    bind: $SNAP_DATA/usr/share/alsa

Same result, unfortunately.

I doubt a layout alone in SNAP_DATA works, that only creates an empty file…

You’d need to stage the file from a Deb package and copy it in place from an install hook to actually have any content in it…

But I also assume it does not need to be writable anyway, so try staging and then change the layout to point to $SNAP instead…

Ah of course - thanks for pointing that out @ogra - apologies we sent you down the wrong path @Eickmeyer - indeed it should be $SNAP not $SNAP_DATA.

That actually did the trick! I’ll get that uploaded shortly.

1 Like

And now, with that, there’s no need for this thread, but I might need to change it to a permission to autoconnect the alsa interface.