# RancherOS and sound module (missing /dev/snd)

**URL:** <https://forums.suse.com/t/rancheros-and-sound-module-missing-dev-snd/1799>\
**Category:** RancherOS\
**Created:** [February 21, 2016, 5:28pm UTC](https://forums.suse.com/t/rancheros-and-sound-module-missing-dev-snd/1799 "2016-02-21T17:28:28Z")\
**Posts on this page:** 20\
**Page:** 1

<div class="post-metadata">

**Author:** ![pwFoo](https://sea2.discourse-cdn.com/flex022/user_avatar/forums.suse.com/pwfoo/32/2884_2.png) [@pwFoo](https://forums.suse.com/u/pwFoo)\
**Post date:** [February 21, 2016, 5:28pm UTC](https://forums.suse.com/t/rancheros-and-sound-module-missing-dev-snd/1799/1 "2016-02-21T17:28:28Z")

</div>

Hi,

at the moment I playing with RancherOS as Desktop OS 🙂

Created xorg / fluxbox container and starting terminal, file manager, chromium, … as container works fine, but how to setup pulseaudio, because /dev/snd is missing.

How to load needed modules with RancherOS?

---

<div class="post-metadata">

**Author:** ![proteusguy](https://sea2.discourse-cdn.com/flex022/user_avatar/forums.suse.com/proteusguy/32/14_2.png) [@proteusguy](https://forums.suse.com/u/proteusguy)\
**Post date:** [February 23, 2016, 11:56pm UTC](https://forums.suse.com/t/rancheros-and-sound-module-missing-dev-snd/1799/2 "2016-02-23T23:56:18Z")

</div>

I’m not entirely sure of the difficulties you’re running into but this person has posted a bunch of useful docker files for desktop users. Here’s her pulseaudio setup: [https://github.com/jfrazelle/dockerfiles/tree/master/pulseaudio](https://github.com/jfrazelle/dockerfiles/tree/master/pulseaudio)

Good luck,

– Ben Scherrey

---

<div class="post-metadata">

**Author:** ![ibuildthecloud](https://sea2.discourse-cdn.com/flex022/user_avatar/forums.suse.com/ibuildthecloud/32/8_2.png) [@ibuildthecloud](https://forums.suse.com/u/ibuildthecloud)\
**Post date:** [February 24, 2016, 12:48am UTC](https://forums.suse.com/t/rancheros-and-sound-module-missing-dev-snd/1799/3 "2016-02-24T00:48:54Z")

</div>

To run as a Desktop OS (which I personally do), you need to use a different kernel. The best starting place is typically a ubuntu kernel. In fact I wrote a script that will take the debs and convert them into a tag.gz needed for the RancherOS build. [https://github.com/rancher/os/blob/master/scripts/mk-kernel-tar-from-deb.sh](https://github.com/rancher/os/blob/master/scripts/mk-kernel-tar-from-deb.sh)

---

<div class="post-metadata">

**Author:** ![pwFoo](https://sea2.discourse-cdn.com/flex022/user_avatar/forums.suse.com/pwfoo/32/2884_2.png) [@pwFoo](https://forums.suse.com/u/pwFoo)\
**Post date:** [February 24, 2016, 6:34am UTC](https://forums.suse.com/t/rancheros-and-sound-module-missing-dev-snd/1799/4 "2016-02-24T06:34:02Z")

</div>

Thanks, @ibuildthecloud. Wie take a look.

@proteusguy  
Thanks, I know her builds. Tested some and also built own based on repos dockerfiles 😉

---

<div class="post-metadata">

**Author:** ![pwFoo](https://sea2.discourse-cdn.com/flex022/user_avatar/forums.suse.com/pwfoo/32/2884_2.png) [@pwFoo](https://forums.suse.com/u/pwFoo)\
**Post date:** [February 25, 2016, 6:52am UTC](https://forums.suse.com/t/rancheros-and-sound-module-missing-dev-snd/1799/5 "2016-02-25T06:52:57Z")

</div>

Is it possible to get hw detection by udev working inside a container? Pulseaudio uses udev to detect the sound card.

Do you have an example dockerfile for pulseaudio support, @ibuildthecloud?

_UPDATE_  
Found that blog post about udev support and have to test it…

> **[udev events in containers](https://dummdida.tumblr.com/post/118770655240/udev-events-in-containers#_=_)**
>
> You can monitor events related to udev by using:
> $ udevadm monitor And for fun you can trigger events by calling:
> $ udevadm trigger --subsystem=net --action=change udev has actually two types of...

  

> **[Re: udev events in a container](https://dummdida.tumblr.com/post/121087781445/re-udev-events-in-a-container)**
>
> It is possible to get udev events into the container. Just use --net=host -v /dev:/dev.
> That’s it.

---

<div class="post-metadata">

**Author:** ![pwFoo](https://sea2.discourse-cdn.com/flex022/user_avatar/forums.suse.com/pwfoo/32/2884_2.png) [@pwFoo](https://forums.suse.com/u/pwFoo)\
**Post date:** [April 6, 2016, 7:51pm UTC](https://forums.suse.com/t/rancheros-and-sound-module-missing-dev-snd/1799/6 "2016-04-06T19:51:17Z")

</div>

We have working sound (alsa, without pulseaudio) and wlan with a custom kernel and additional firmware by build a own iso.

@ibuildthecloud  
Any plans to ship RancherOS with a more desktop friendly kernel? Would be great to Upgrade our “RancherOS Desktop” fun build with `ros os upgrade` instead of custom scripts / ISOs to upgrade / reinstall.

---

<div class="post-metadata">

**Author:** ![pwFoo](https://sea2.discourse-cdn.com/flex022/user_avatar/forums.suse.com/pwfoo/32/2884_2.png) [@pwFoo](https://forums.suse.com/u/pwFoo)\
**Post date:** [April 6, 2016, 7:56pm UTC](https://forums.suse.com/t/rancheros-and-sound-module-missing-dev-snd/1799/7 "2016-04-06T19:56:43Z")

</div>

😀

[https://github.com/rancher/os-kernel/pull/12/commits/0e505d2f7dac1707057acf9e01c1c6211c34787c](https://github.com/rancher/os-kernel/pull/12/commits/0e505d2f7dac1707057acf9e01c1c6211c34787c)

---

<div class="post-metadata">

**Author:** ![hobertony\_7](https://avatars.discourse-cdn.com/v4/letter/h/4bbf92/32.png) [@hobertony\_7](https://forums.suse.com/u/hobertony_7)\
**Post date:** [April 7, 2016, 8:18am UTC](https://forums.suse.com/t/rancheros-and-sound-module-missing-dev-snd/1799/8 "2016-04-07T08:18:14Z")

</div>

@pwFoo can you tell me how ro create xorg/fluxbox container? thank you

---

<div class="post-metadata">

**Author:** ![pwFoo](https://sea2.discourse-cdn.com/flex022/user_avatar/forums.suse.com/pwfoo/32/2884_2.png) [@pwFoo](https://forums.suse.com/u/pwFoo)\
**Post date:** [April 8, 2016, 5:34am UTC](https://forums.suse.com/t/rancheros-and-sound-module-missing-dev-snd/1799/9 "2016-04-08T05:34:29Z")

</div>

Hi @hobertony_7,

we try to separate services / images.

First one is a image with xorg with video drivers and a custom 10-input.conf to get keyboard and mouse working. Maybe you have to do some configuration to get x-server starting dependent on your distribution you use (alpine works fine, debian needs a xwrapper modification, …).

Based on that xorg image we build a fluxbox one with just fluxbox installed and a prepared xinitrc like that  
`[…]  
xinput enable Mouse0  
xinput enable Keyboard0

exec startfluxbox`

“Mouse0” and “Keyboard0” matches the 10-input.conf xorg configuration. WIthout a working configuration you will have no keyboard and mouse. 😉

A graphical docker container needs

1. display env variable set “-e DISPLAY=$DISPLAY”
2. each X Cointainer needs also shared /tmp/.X11-unix (share it as docker volume) to open a new app like chromium, keepassx, … which we all create as separated images / containers.
3. Access to /dev/tty | /dev. To simplify we start with “–privileged” at the moment

We also install some additional packages like usb-utils (usb devices…), xhost (needed to allow containers like chromium, keepass to use the x-server!), xrandr (dual monitor setup), xterm (basic terminal support inside), …

---

<div class="post-metadata">

**Author:** ![hobertony\_7](https://avatars.discourse-cdn.com/v4/letter/h/4bbf92/32.png) [@hobertony\_7](https://forums.suse.com/u/hobertony_7)\
**Post date:** [April 8, 2016, 7:01am UTC](https://forums.suse.com/t/rancheros-and-sound-module-missing-dev-snd/1799/10 "2016-04-08T07:01:13Z")

</div>

@pwFoo thank you for your reply, now we also try to separate services into different containers。  
I already know the approximate method：  
1, create a image with xorg, of course, need some special configuration, and the x windows system run in this container。  
2, base the image of xorg ,we craete a image with fluxbox, now in image we had install xorh and fluxbox.

when we run the image we should add “-e DISPLAY=$DISPLAY” "-v /tmp/.X11-unix:/tmp/.X11-unix “–privileged”.  
but according to what you say, the xorg and fluxbox run in docker container, but "-v /tmp/.X11-unix:/tmp/.X11-unix "  
mount “/tmp/.X11-unix” is on host.  
May I have a look at your Dockerfile file？

---

<div class="post-metadata">

**Author:** ![pwFoo](https://sea2.discourse-cdn.com/flex022/user_avatar/forums.suse.com/pwfoo/32/2884_2.png) [@pwFoo](https://forums.suse.com/u/pwFoo)\
**Post date:** [April 8, 2016, 7:28am UTC](https://forums.suse.com/t/rancheros-and-sound-module-missing-dev-snd/1799/11 "2016-04-08T07:28:54Z")

</div>

Instead of `-v /tmp/.X11-unix/:/tmp/.X11-unix` just use `-v /tmp/.X11-unix` to create the volume which isn’t mounted at the host. Application containers can use it by `--volumes-from <fluxbox container>`.  
/tmp/.X11-unix permissions have to be 1777 (with sticky bit!).

Would be great to separate also the fluxbox and xorg processes (for example connected by tcp), but I don’t know how to do that.

---

<div class="post-metadata">

**Author:** ![hobertony\_7](https://avatars.discourse-cdn.com/v4/letter/h/4bbf92/32.png) [@hobertony\_7](https://forums.suse.com/u/hobertony_7)\
**Post date:** [April 8, 2016, 8:16am UTC](https://forums.suse.com/t/rancheros-and-sound-module-missing-dev-snd/1799/12 "2016-04-08T08:16:43Z")

</div>

yea, I also want to know how do you playing rancheros as desktop os, if I can understand that the xorg/fluxbox and chromium in same container?

---

<div class="post-metadata">

**Author:** ![pwFoo](https://sea2.discourse-cdn.com/flex022/user_avatar/forums.suse.com/pwfoo/32/2884_2.png) [@pwFoo](https://forums.suse.com/u/pwFoo)\
**Post date:** [April 22, 2016, 10:01pm UTC](https://forums.suse.com/t/rancheros-and-sound-module-missing-dev-snd/1799/13 "2016-04-22T22:01:44Z")

</div>

xorg, dbus, fluxbox, volumeicon, chromium and other apps running in separated containers. Basic Desktop (xorg, dbus, fluxbox, volumeicon is started as a RancherOS service.

---

<div class="post-metadata">

**Author:** ![Cobraeti](https://avatars.discourse-cdn.com/v4/letter/c/9de0a6/32.png) [@Cobraeti](https://forums.suse.com/u/Cobraeti)\
**Post date:** [May 10, 2016, 9:23pm UTC](https://forums.suse.com/t/rancheros-and-sound-module-missing-dev-snd/1799/14 "2016-05-10T21:23:46Z")

</div>

Hi @pwFoo,  
Your “Basic Desktop” (not so basic from my point of view…) seems amazing. This is exactly what I can’t manage to realise for my project, but I can’t find your’s on docker hub.  
Have you already shared it?  
If not, is it plained?  
If also not, could you please give us (as I’m sure that others should be interested) a hint concerning the elements you mount as data volumes to be able to access the host’s hardware with xorg, dbus and fluxbox containers?  
I am trying to build a container that will use the host’s screen to display apps like Xbmc/Kobi, so I could build a NAS that would also be a Media Center when needed ^^

---

<div class="post-metadata">

**Author:** ![pwFoo](https://sea2.discourse-cdn.com/flex022/user_avatar/forums.suse.com/pwfoo/32/2884_2.png) [@pwFoo](https://forums.suse.com/u/pwFoo)\
**Post date:** [May 12, 2016, 10:30am UTC](https://forums.suse.com/t/rancheros-and-sound-module-missing-dev-snd/1799/15 "2016-05-12T10:30:23Z")

</div>

At the moment I build some images which should be pushed soon to docker hub.

Local build works with xorg, fluxbox, dbus and volumeicon (with console alsamixer). A shared passwd / shadow inside a docker volume. Terminator (terminal with ssh, docker), pcmanfm (sftp, smb support) and chromium.

Display manager is replaced with a simple i3lock login 🙂  
slock, xlock or xscreensaver also could used instead of i3lock.

---

<div class="post-metadata">

**Author:** ![pwFoo](https://sea2.discourse-cdn.com/flex022/user_avatar/forums.suse.com/pwfoo/32/2884_2.png) [@pwFoo](https://forums.suse.com/u/pwFoo)\
**Post date:** [May 22, 2016, 8:50am UTC](https://forums.suse.com/t/rancheros-and-sound-module-missing-dev-snd/1799/16 "2016-05-22T08:50:03Z")

</div>

I have problems with missing --group-add and --tmpfs support within rancher-compose… So it will need a workaround and can’t run as RancherOS os-service.

---

<div class="post-metadata">

**Author:** ![hobertony\_7](https://avatars.discourse-cdn.com/v4/letter/h/4bbf92/32.png) [@hobertony\_7](https://forums.suse.com/u/hobertony_7)\
**Post date:** [May 24, 2016, 4:06am UTC](https://forums.suse.com/t/rancheros-and-sound-module-missing-dev-snd/1799/17 "2016-05-24T04:06:26Z")

</div>

Hi，have you push some images to docker hub?thank you

---

<div class="post-metadata">

**Author:** ![bela](https://avatars.discourse-cdn.com/v4/letter/b/ecb155/32.png) [@bela](https://forums.suse.com/u/bela)\
**Post date:** [June 12, 2016, 1:50pm UTC](https://forums.suse.com/t/rancheros-and-sound-module-missing-dev-snd/1799/18 "2016-06-12T13:50:47Z")

</div>

@pwFoo & @ibuildthecloud if you actually have a running Desktop build on containers/ros … I think that would make an interesting showcase for rancherOS & docker in general …

any plans you publish a how-to or something similar on this?

---

<div class="post-metadata">

**Author:** ![joshwget](https://sea2.discourse-cdn.com/flex022/user_avatar/forums.suse.com/joshwget/32/704_2.png) [@joshwget](https://forums.suse.com/u/joshwget)\
**Post date:** [June 16, 2016, 4:28pm UTC](https://forums.suse.com/t/rancheros-and-sound-module-missing-dev-snd/1799/19 "2016-06-16T16:28:27Z")

</div>

The next version of RancherOS will definitely have better support for desktop systems. As soon as the release comes out and I get a working desktop setup for myself, I’ll add a page about it in the docs!

---

<div class="post-metadata">

**Author:** ![pwFoo](https://sea2.discourse-cdn.com/flex022/user_avatar/forums.suse.com/pwfoo/32/2884_2.png) [@pwFoo](https://forums.suse.com/u/pwFoo)\
**Post date:** [June 16, 2016, 6:38pm UTC](https://forums.suse.com/t/rancheros-and-sound-module-missing-dev-snd/1799/20 "2016-06-16T18:38:04Z")

</div>

Great! Can’t wait to get the next RancherOS release!!! 🙂

We build images (dbus, xorg, fluxbox, chromium, …) and try to use unmodified RancherOS as base.

[Next page](https://forums.suse.com/t/rancheros-and-sound-module-missing-dev-snd/1799.md?page=2)
