mirror of
https://github.com/hoellen/dockerfiles.git
synced 2025-07-01 06:35:38 +00:00
initial commit
This commit is contained in:
28
subsonic/Dockerfile
Normal file
28
subsonic/Dockerfile
Normal file
@ -0,0 +1,28 @@
|
||||
FROM alpine:3.3
|
||||
MAINTAINER Wonderfall <wonderfall@mondedie.fr>
|
||||
|
||||
ENV VER=6.0.beta2 GID=1000 UID=1000
|
||||
|
||||
RUN echo "@community http://dl-4.alpinelinux.org/alpine/v3.3/community/" >> /etc/apk/repositories \
|
||||
&& echo "@commuedge http://nl.alpinelinux.org/alpine/edge/community" >> /etc/apk/repositories \
|
||||
&& echo "@edge http://nl.alpinelinux.org/alpine/edge/main" >> /etc/apk/repositories \
|
||||
&& apk -U add \
|
||||
libva@edge \ #libva was missing
|
||||
ffmpeg \
|
||||
openjdk8-jre@community \
|
||||
tini@commuedge \
|
||||
&& rm -f /var/cache/apk/*
|
||||
|
||||
WORKDIR /subsonic
|
||||
RUN wget -qO- http://subsonic.org/download/subsonic-$VER-standalone.tar.gz | tar zxf -
|
||||
|
||||
COPY run.sh /usr/local/bin/run.sh
|
||||
RUN chmod +x /usr/local/bin/run.sh
|
||||
|
||||
EXPOSE 4040
|
||||
VOLUME /data /musics /playlists /podcasts
|
||||
|
||||
LABEL description "Open source media streamer" \
|
||||
subsonisc "Subsonic v$VER"
|
||||
|
||||
CMD ["tini","--","run.sh"]
|
51
subsonic/README.md
Normal file
51
subsonic/README.md
Normal file
@ -0,0 +1,51 @@
|
||||
## wonderfall/subsonic
|
||||
[](https://imagelayers.io/?images=wonderfall/subsonic:latest 'Get your own badge on imagelayers.io')
|
||||
|
||||

|
||||
|
||||
#### What is Subsonic?
|
||||
Subsonic is an open-source web-based media streamer and jukebox. Supports MP3, OGG, AAC and other streamable audio and video formats. Indeed, this build comes with **transcoding abilities**.
|
||||
|
||||
#### Tags
|
||||
- **Stable 5.x** : `5.3`, `latest`, `old-5.3`
|
||||
- **Beta 6.0** : `6.0b1`, `6`
|
||||
|
||||
#### Environment variables
|
||||
- **GID** : subsonic group id.
|
||||
- **UID** : subsonic user id.
|
||||
|
||||
#### Volumes
|
||||
- **/musics** : your music files
|
||||
- **/data** : subsonic data
|
||||
- **/playlists** : subsonic playlists
|
||||
|
||||
#### Known issues (only with alpine) :
|
||||
- Can't retrieve pictures through TLS (although it's not automatic, you have to choose clear-HTTP sources only when picking a cover picture) -> **fixed !**
|
||||
- "Default covers" (when no cover image is detected) are not generated (not sure it's a problem since I find this feature useless... such ugly fonts/colors)
|
||||
|
||||
#### Docker Compose (example)
|
||||
```
|
||||
subsonic:
|
||||
image: wonderfall/subsonic
|
||||
volumes:
|
||||
- /mnt/music:/musics
|
||||
- /mnt/subsonic:/data
|
||||
- /mnt/playlists:/playlists
|
||||
environment:
|
||||
- GID=1000
|
||||
- UID=1000
|
||||
```
|
||||
|
||||
#### Reverse proxy
|
||||
https://github.com/Wonderfall/dockerfiles/tree/master/reverse
|
||||
Fully working configuration with TLS :
|
||||
|
||||
```
|
||||
location / {
|
||||
proxy_pass http://subsonic:4040;
|
||||
proxy_set_header X-Real-IP $remote_addr;
|
||||
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
||||
proxy_set_header X-Remote-Port $remote_port;
|
||||
proxy_set_header X-Forwarded-Proto $scheme;
|
||||
}
|
||||
```
|
22
subsonic/run.sh
Normal file
22
subsonic/run.sh
Normal file
@ -0,0 +1,22 @@
|
||||
#!/bin/sh
|
||||
addgroup -g ${GID} subsonic && adduser -h /subsonic -s /bin/sh -D -G subsonic -u ${UID} subsonic
|
||||
|
||||
mkdir -p /data/transcode
|
||||
ln -s /usr/bin/ffmpeg /data/transcode/ffmpeg
|
||||
ln -s /usr/bin/lame /data/transcode/lame
|
||||
|
||||
chown -R subsonic:subsonic /data /playlists /subsonic
|
||||
|
||||
su subsonic << EOF
|
||||
java -Xmx200m \
|
||||
-Dsubsonic.home=/data \
|
||||
-Dsubsonic.host=0.0.0.0 \
|
||||
-Dsubsonic.port=4040 \
|
||||
-Dsubsonic.httpsPort=0 \
|
||||
-Dsubsonic.contextPath=/ \
|
||||
-Dsubsonic.defaultMusicFolder=/musics \
|
||||
-Dsubsonic.defaultPodcastFolder=/podcasts \
|
||||
-Dsubsonic.defaultPlaylistFolder=/playlists \
|
||||
-Djava.awt.headless=true \
|
||||
-jar subsonic-booter-jar-with-dependencies.jar
|
||||
EOF
|
Reference in New Issue
Block a user