You are not logged in.

#1 2017-01-01 13:16:22

Head_on_a_Stick
Member
From: London
Registered: 2015-09-29
Posts: 9,093
Website

Spotify in BunsenLabs

There is a Debian repository made available by the Spotify developers:

Spotify for Linux is released as a Debian package. Our aim is that it should work with the latest Long Term Support release of Ubuntu, but we will try to make it work for other releases of Ubuntu and Debian as well.

https://www.spotify.com/uk/download/linux/

However, this is a generalised package (ie, not built specifically for Debian jessie) and any mistakes on behalf of the repository maintainers have the potential to break the system completely.

Any custom repositories can also cause major problems if a `dist-upgrade` to the next release is attempted.

To overcome these issues, it is possible to run the Spotify desktop client as a Flatpak application.

http://flatpak.org/index.html#about

This approach contains the application by using a kernel feature called "namespaces" (read `man namespaces` for more on this) and, most importantly, the dependency tree of the host system is left undisturbed.

Unfortunately, flatpak is only available from the (Debian) jessie-backports repository and so this must be added first by using this command:

sudo apt edit-sources

Then add this line and save the file:

deb http://httpredir.debian.org/debian jessie-backports main contrib non-free

Finally, update the package database and install the package:

sudo apt update
sudo aptitude install -t jessie-backports flatpak

Flatpak is now installed and can be used for many different programs:

http://flatpak.org/apps.html

The flatpak system works by sharing runtime libraries between applications so first we need to add some remote repositories for the libraries:

flatpak remote-add --user --from gnome https://sdk.gnome.org/gnome.flatpakrepo

Then the actual Spotify client can be installed from Alex Larsson's repository:

flatpak install --user --from https://flathub.org/repo/appstream/com.spotify.Client.flatpakref

The required runtime libraries will be downloaded and installed automatically and these will be shared with any other flatpaks that are installed.

Once the client is installed, run it with:

flatpak run com.spotify.Client

This can be added to the Multimedia sub-menu on the BunsenLabs desktop by first creating a wrapper to launch the program:

echo "flatpak run com.spotify.Client" > ~/bin/Spotify && chmod +x ~/bin/Spotify

Then edit the file at ~/.config/openbox/pipemenus.rc (as your normal user!) and change this line (mutatis mutandis):

# Multimedia pipemenu (bl-multimedia-pipemenu)
MM_APPS=( 'vlc' 'Spotify' 'audacious' 'smplayer' 'gnome-mplayer' )

https://github.com/BunsenLabs/bunsen-co … enus.rc#L6

2017-01-01-131009_1920x1080_scrot.th.png

The `Spotify` command (with a capital S) should also be available via the dmenu & gmrun program launchers and the command line.

The client can be updated with:

flatpak update --user com.spotify.Client

Last edited by Head_on_a_Stick (2017-11-08 21:37:16)

Offline

#2 2017-07-16 21:56:18

kols
Member
From: Norway
Registered: 2017-07-16
Posts: 21

Re: Spotify in BunsenLabs

Bump for later reference

Offline

#3 2017-11-08 21:30:56

cloverskull
Member
Registered: 2015-10-01
Posts: 348

Re: Spotify in BunsenLabs

Hey HOAS, the Spotify flatpakref was moved, so now to install you need to run

flatpak install --user --from https://flathub.org/repo/appstream/com.spotify.Client.flatpakref

Offline

#4 2017-11-08 21:37:35

Head_on_a_Stick
Member
From: London
Registered: 2015-09-29
Posts: 9,093
Website

Re: Spotify in BunsenLabs

^ Thanks!

I have edited the OP.

Offline

#5 2017-11-08 22:47:57

Plebeu
Member
Registered: 2017-08-01
Posts: 10

Re: Spotify in BunsenLabs

Head_on_a_Stick wrote:

However, this is a generalised package (ie, not built specifically for Debian jessie) and any mistakes on behalf of the repository maintainers have the potential to break the system completely.

That's pretty worrying. I knew there was something wrong when I first installed Spotify from the website just by the words the developers used to describe the package. Thanks to making this thread.

Offline

Board footer

Powered by FluxBB