Airplay Password or Disable Airplay

Hi there,

I just purchased a Raspberry Pi to install Volumio to. It works great, but the problem is that I live in a building with a single WiFi network and about 30 people live here. Unfortunately, that means that anyone can connect to my speakers and play whatever they want through Airplay.

That being said, I know that Apple’s Airplay products have a way to password protect the Airplay feature so that in order to connect, you have to input the password. I was wondering if Volumio has a similar feature.

If not, I was wondering if there was a way to disable Airplay from Volumio. Although this would not be ideal, I have a spare hard drive that I can upload music to and connect to the Pi so that I can just play the music off that but control it with my phone or computer.

Please let me know. Any help would be appreciated.


I have no idea about password protecting it, but it should be easy enough to disable airplay completely by stopping the “shairport” daemon:

$ ssh pi@volumio (name if registered in dns, otherwise ip address) $ sudo update-rc.d shairport remove -f defaults $ sudo /etc/init.d/shairport stop
That’s the linux way of doing it (or at least one of them), I don’t know if there’s a volumio way of doing it.

This would definitely be a nice feature to add :slight_smile:

it’s quite easy. SSH into your RPi and

Type: sudo nano /etc/init.d/shairport

In Nano, change this line:

    /usr/local/bin/shairport -d -a "$NAME"

to look like this:

 /usr/local/bin/shairport -d -a "$NAME" -k "YourPassword"

Hit Ctrl+X to exit and reboot your pi

This method seems to not work anymore. Is there any workaround for it?
I really need AirPlay password for my Pi, but I am such Linux newbie… :unamused:

Thanks in advance!

I’ve just gotten this to work under version 2.031. Things have changed, as Shairport ( is now managed via a Node.js module, so the solutions above will no longer work.

Here’s what to do:

ssh to your pi, and open up the template for the shairport config file in a text editor:

sudo nano  /volumio/app/plugins/music_service/airplay_emulation/shairport-sync.conf.tmpl

In the “general” stanza, add a password, like this:

general =
    name = "${name}";
    log_verbosity = 0;
    password = "<your airplay password here>";

Save, quit, restart your pi, and you should be prompted for a password when airplaying to it.

On startup, this template will be used to overwrite the contents of /etc/shairport-sync.conf. Don’t directly edit that file in /etc – nothing will happen!

Good luck!

Perfect answer!