mirror of
https://github.com/devgianlu/go-librespot.git
synced 2026-04-26 05:15:49 +03:00
[GH-ISSUE #156] Minimal container based on Alpine Linux #98
Labels
No labels
bug
enhancement
pull-request
spotify-side
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
starred/go-librespot#98
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @odiroot on GitHub (Dec 31, 2024).
Original GitHub issue: https://github.com/devgianlu/go-librespot/issues/156
You might find it useful, if not please just close this issue.
I managed to build a very lightweight container starting with an Alpine Linux 3.20 base.
The result
See it published here.
Here's the Dockerfile I used
@praul commented on GitHub (Jan 1, 2025):
Tested it and its working great for me. Thanks, this is more elegant than my own dockerfile.
@devgianlu commented on GitHub (Jan 1, 2025):
Have you used any particular flag to run the container? It is not able to talk to ALSA on my setup.
@odiroot commented on GitHub (Jan 1, 2025):
My bad, only tested with pulse (well, pipewire).
I could look into the alsa problem.
@odiroot commented on GitHub (Jan 1, 2025):
I also forgot to mention how I run this one.
Minimal compose file would be
Naturally
<your username>has to be replaced with e.g.whoamiand<your uid>withid -u.Now for running with ALSA I believe this should work:
@devgianlu commented on GitHub (Jan 1, 2025):
Can confirm that the PulseAudio setup works, I was not able to get ALSA to work, but nontheless I'll add this to the repo and make official docker images!
@odiroot commented on GitHub (Jan 1, 2025):
Sorry about the ALSA thing. I also couldn't get it to work but for a completely unrelated reason (config being ignored).
I might need to look into the build step. Could be that not all required libraries are provided.
@devgianlu commented on GitHub (Jan 1, 2025):
Build fines for me and on the CI too: https://github.com/devgianlu/go-librespot/actions/runs/12573825057/job/35047226348
I'll leave this open if you think there are possible improvements, feel free to make a PR too!
@odiroot commented on GitHub (Jan 1, 2025):
Hey @devgianlu
Just one small nitpick. You link to your other project's containers in Readme: https://github.com/devgianlu/go-librespot?tab=readme-ov-file#using-docker
@devgianlu commented on GitHub (Jan 1, 2025):
Oops, copy pasted too much, thanks for noticing :^)
@praul commented on GitHub (Jan 2, 2025):
My bad, sorry - I only used it with pipe output which should be the most easy scenario for a docker setup
@marco79cgn commented on GitHub (Jan 15, 2025):
I'm trying to build this on a Raspberry Pi 4 (bookworm, linux/arm64/v8) but unfortunately the docker build always quits with an error. Any idea how I could fix this? Btw. I only need the pipe output (like @praul).
docker-build-log.txt
@devgianlu commented on GitHub (Jan 15, 2025):
You can use this Dockerfile or a prebuild image
@marco79cgn commented on GitHub (Jan 15, 2025):
I already tried both. The prebuild image doesn't exist for my platform:
Whereas with the original Dockerfile I get this error:
@devgianlu commented on GitHub (Jan 15, 2025):
In order to use the Dockerfile you need to clone the repository and do
docker build -t go-librespot .inside of it.@marco79cgn commented on GitHub (Jan 15, 2025):
Thanks, I tried. The repo is cloned, the go compiler is on the classpath but still I get an error in a later step: