rebase to alpine
This commit is contained in:
parent
f8b035f733
commit
09912ed66e
8 changed files with 30 additions and 34 deletions
31
Dockerfile
Executable file → Normal file
31
Dockerfile
Executable file → Normal file
|
@ -1,23 +1,18 @@
|
||||||
FROM linuxserver/baseimage.python
|
FROM lsiobase/alpine.python
|
||||||
MAINTAINER smdion <me@seandion.com>
|
MAINTAINER smdion <me@seandion.com> ,sparklyballs
|
||||||
|
|
||||||
ENV PYTHONIOENCODING="UTF-8"
|
# install packages
|
||||||
ENV APTLIST="ffmpeg mc shntool"
|
RUN \
|
||||||
|
apk add --no-cache \
|
||||||
|
ffmpeg \
|
||||||
|
mc && \
|
||||||
|
apk add --no-cache --repository \
|
||||||
|
http://nl.alpinelinux.org/alpine/edge/testing \
|
||||||
|
shntool
|
||||||
|
|
||||||
# Install Dependencies
|
# add local files
|
||||||
RUN add-apt-repository ppa:mc3man/trusty-media && \
|
COPY root/ /
|
||||||
apt-get update && \
|
|
||||||
apt-get install -qy $APTLIST && \
|
|
||||||
apt-get clean && rm -rf /var/lib/apt/lists/* /var/tmp/*
|
|
||||||
|
|
||||||
#Adding Custom files
|
# ports and volumes
|
||||||
ADD init/ /etc/my_init.d/
|
|
||||||
ADD services/ /etc/service/
|
|
||||||
ADD defaults/ /defaults
|
|
||||||
RUN chmod -v +x /etc/service/*/run /etc/my_init.d/*.sh
|
|
||||||
|
|
||||||
#Volumes and Ports
|
|
||||||
EXPOSE 8181
|
EXPOSE 8181
|
||||||
VOLUME ["/config", "/downloads", "/music"]
|
VOLUME ["/config", "/downloads", "/music"]
|
||||||
|
|
||||||
|
|
||||||
|
|
10
README.md
10
README.md
|
@ -15,7 +15,8 @@ docker create \
|
||||||
-v /path/to/headphones/data:/config \
|
-v /path/to/headphones/data:/config \
|
||||||
-v /path/to/downloads:/downloads \
|
-v /path/to/downloads:/downloads \
|
||||||
-v /path/to/music:/music \
|
-v /path/to/music:/music \
|
||||||
-v /etc/localtime:/etc/localtime:ro \
|
-e PGID=<gid> -e PUID=<uid> \
|
||||||
|
-e TZ=<timezone> \
|
||||||
-p 8181:8181 \
|
-p 8181:8181 \
|
||||||
linuxserver/headphones
|
linuxserver/headphones
|
||||||
```
|
```
|
||||||
|
@ -23,14 +24,14 @@ docker create \
|
||||||
**Parameters**
|
**Parameters**
|
||||||
|
|
||||||
* `-p 8181` - the port(s)
|
* `-p 8181` - the port(s)
|
||||||
* `-v /etc/localtime` for timesync - *optional*
|
|
||||||
* `-v /config` - Configuration file location
|
* `-v /config` - Configuration file location
|
||||||
* `-v /music` - Location of music. (i.e. /opt/downloads/music or /var/music)
|
* `-v /music` - Location of music. (i.e. /opt/downloads/music or /var/music)
|
||||||
* `-v /downloads` - Location of downloads folder
|
* `-v /downloads` - Location of downloads folder
|
||||||
* `-e PGID` for for GroupID - see below for explanation - *optional*
|
* `-e PGID` for for GroupID - see below for explanation - *optional*
|
||||||
* `-e PUID` for for UserID - see below for explanation - *optional*
|
* `-e PUID` for for UserID - see below for explanation - *optional*
|
||||||
|
* `-e TZ` for setting timezone information, eg Europe/London
|
||||||
|
|
||||||
It is based on phusion-baseimage with ssh removed, for shell access whilst the container is running do `docker exec -it Headphones /bin/bash`.
|
It is based on alpine linux with s6 overlay, for shell access whilst the container is running do `docker exec -it Headphones /bin/bash`.
|
||||||
|
|
||||||
### User / Group Identifiers
|
### User / Group Identifiers
|
||||||
|
|
||||||
|
@ -51,4 +52,5 @@ Access WebUI at http://localhost:8181 and walk through the wizard.
|
||||||
|
|
||||||
## Version History
|
## Version History
|
||||||
|
|
||||||
+ **18.07.2015:** Inital Release
|
+ **04.07.16:** Rebase to alpine for smaller image size
|
||||||
|
+ **18.07.15:** Inital Release
|
||||||
|
|
|
@ -1,8 +0,0 @@
|
||||||
#!/bin/bash
|
|
||||||
|
|
||||||
|
|
||||||
if [ ! -f /config/config.ini ]; then
|
|
||||||
cp /defaults/config.ini /config/config.ini
|
|
||||||
chown abc:abc /config/config.ini
|
|
||||||
fi
|
|
||||||
|
|
2
init/30_update.sh → root/etc/cont-init.d/30-update
Executable file → Normal file
2
init/30_update.sh → root/etc/cont-init.d/30-update
Executable file → Normal file
|
@ -1,4 +1,4 @@
|
||||||
#!/bin/bash
|
#!/usr/bin/with-contenv bash
|
||||||
|
|
||||||
[[ ! -d /app/headphones/.git ]] && (git clone https://github.com/rembo10/headphones.git /app/headphones && \
|
[[ ! -d /app/headphones/.git ]] && (git clone https://github.com/rembo10/headphones.git /app/headphones && \
|
||||||
chown -R abc:abc /app)
|
chown -R abc:abc /app)
|
7
root/etc/cont-init.d/40-config
Normal file
7
root/etc/cont-init.d/40-config
Normal file
|
@ -0,0 +1,7 @@
|
||||||
|
#!/usr/bin/with-contenv bash
|
||||||
|
|
||||||
|
[[ ! -e /config/config.ini ]] && cp /defaults/config.ini /config/config.ini
|
||||||
|
|
||||||
|
chown abc:abc /config/*
|
||||||
|
|
||||||
|
|
3
root/etc/services.d/headphones/run
Normal file
3
root/etc/services.d/headphones/run
Normal file
|
@ -0,0 +1,3 @@
|
||||||
|
#!/usr/bin/with-contenv bash
|
||||||
|
|
||||||
|
exec s6-setuidgid abc python /app/headphones/Headphones.py -p 8181 --datadir=/config
|
|
@ -1,3 +0,0 @@
|
||||||
#!/bin/bash
|
|
||||||
|
|
||||||
exec /sbin/setuser abc python /app/headphones/Headphones.py -p 8181 --datadir=/config
|
|
Loading…
Add table
Reference in a new issue