1

I installed firefox via snap install firefox

I went to my Downloads folder: cd ~/Downloads/ and executed:

firefox "www.duckduckgo.com"

firefox opens with the website duckduckgo.

Than I went to my nfs-share: cd /mnt/my-nfs-share/ and executed the same command:

firefox "www.duckduckgo.com"

I got following error:

cannot open path of the current working directory: Permission denied

If I install firefox via apt install firefox everything works as usually.

  • I'm new to snaps (and kind a like them) but how can I give the correct permission to it and why do I need to this by myself?
  • Is there a "bug" in the snap-configuration?
lordnik22
  • 13
  • 4
  • snap packages run confined (higher security) and they don't have full access to your whole file-system having access to $HOME or your user directory; and only limited other directories if permitted (which do include /mnt & /media but not at snap startup). You're requesting access at startup where only $HOME is allowed; your issue is close to https://bugs.launchpad.net/ubuntu/+source/chromium-browser/+bug/1832711 but I can confirm still exists in kinetic - but you cannot access /mnt or /media at startup. – guiverc Sep 08 '22 at 22:45

1 Answers1

2

snap packages run confined (higher security) and they don't have full access to your whole file-system having access to $HOME or your user directory; and only limited other directories if permitted (which do include /mnt & /media but not at snap startup).

You're requesting access at startup where only $HOME is allowed; you didn't provide release details, but I'm getting the same with my kinetic box (the issue issue reminds me of https://bugs.launchpad.net/ubuntu/+source/chromium-browser/+bug/1832711 but description won't match, is not chromium-browser based but all snaps & exists in kinetic).

You cannot access /mnt or /media at snap startup.


I had a brief discussion with ogra (Oliver Grawert) who said to file a bug... https://bugs.launchpad.net/ubuntu/+source/snapd/+bug/1989156

guiverc
  • 30,396
  • I'll likely amend this answer... I had a brief discussion with ogra (Oliver Grawert) who said to file a bug... I'll do that.. – guiverc Sep 08 '22 at 23:59
  • Ah thanks! I tried to fix it by changing my mount-point to the home-directory. This dosn't work because he dosn't has access to the whole mounted directory-tree (only to the first level). The Idea of chaning mount-points I got from this question https://askubuntu.com/questions/1033344/how-to-give-snaps-access-to-somedir – lordnik22 Sep 09 '22 at 00:04