Run Spotify inside an Ubuntu container, sharing the X11 and PulseAudio sockets from the host.
- Clone this repository and
cd
into it:
git clone git@github.com:slezica/docker-spotify.git && cd docker-spotify
- Build the Docker container:
docker build -t spotify .
- Run the start-up script:
bin/spotify
Two external folders are linked inside the container:
-
The
$HOME/.docker-volumes/spotifyconfig
directory is mounted into/data/config
inside the container, to persist sessions and configuration. -
The
$HOME/music
directory is made available as/data/music
inside the container, for use with the Local Files feature.
To change these paths, edit bin/spotify
.
Place this file (editing the relevant paths) into ~/.local/shares/application
:
#!/usr/bin/env xdg-open
[Desktop Entry]
Version=1.0
Terminal=false
Type=Application
Name=Spotify
Icon=docker-spotify/icon.png
Exec=docker-spotify/bin/spotify