unofficial mirror of help-guix@gnu.org 
 help / color / mirror / Atom feed
From: kiasoc5 <kiasoc5@disroot.org>
To: Elias Kueny <elias.kueny@posteo.net>, help-guix@gnu.org
Subject: Re: How to make audio devices available with guix shell --container
Date: Mon, 5 Dec 2022 22:47:18 -0500	[thread overview]
Message-ID: <e79f20d6-b70f-6e31-42e4-7d4f71681d15@disroot.org> (raw)
In-Reply-To: <87o7shsld3.fsf@posteo.net>

On 12/5/22 12:41, Elias Kueny wrote:
> Hello,
> 
> I'm trying to run an online videoconferencing tool in chromium in a guix 
> shell with a container, so I expose my system as little as possible. All 
> is well without the --container option, but I'm not sure what to expose 
> to make it work in the container too.
> 
> I'm on guix system. I'm starting the software with: `guix shell 
> --container -N -P --no-cwd --preserve='^DISPLAY$' 
> --preserve='^XAUTHORITY$' --share=$XAUTHORITY --share=/dev/video0 
> ungoogled-chromium -- chromium --app="https://meet.jit.si"`.
> 
> `--preserve='^DISPLAY$' --preserve='^XAUTHORITY$' --share=$XAUTHORITY` 
> lets chromium open an X window and share the scren.
> `--share=/dev/video0` gives access to the webcam.
> What is the step to allow the microphone and speakers?

About the sound, I believe you will need to expose the pulseaudio and/or 
pipewire sockets. You can reference bubblewrap configuration since it 
also works by sharing/exposing files.

https://wiki.archlinux.org/title/Bubblewrap/Examples#Chromium

> I'm not particularly familiar with how audio devices are working. I read 
> they are in /dev/snd, but sharing this or even the whole of /dev/ 
> doesn't make the microphone and speakers available (although the browser 
> is now asking me for the permission to access them, so it seems aware I 
> have them). I also tried adding tinyalsa and pulseaudio to the container 
> in case that's what's missing, but to no avail. I didn't explicitely 
> install anything related to audio (but I have %desktop-services in my 
> operating-system definition), so if it's a software that is missing, I 
> don't know which one.

I believe in the case of ungoogled-chromium that pulseaudio is part of 
the inputs already.

> Thank you in advance!
> 

It would be nice to have a tool for defining guix containers by 
permissions (with camera, with audio, etc) like bubblejail/firejail. 
That is a topic for a later mail.


  reply	other threads:[~2022-12-06  3:48 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-12-05 17:41 How to make audio devices available with guix shell --container Elias Kueny
2022-12-06  3:47 ` kiasoc5 [this message]
2022-12-06 17:01   ` Elias Kueny
2023-01-08 11:19     ` Gabriel Wicki

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://guix.gnu.org/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=e79f20d6-b70f-6e31-42e4-7d4f71681d15@disroot.org \
    --to=kiasoc5@disroot.org \
    --cc=elias.kueny@posteo.net \
    --cc=help-guix@gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).