Update Dockerfile

This commit is contained in:
Alexandre
2021-08-26 08:01:09 +02:00
committed by GitHub
parent cf452be638
commit dea77a2855

View File

@@ -11,14 +11,13 @@ RUN \
# Install apps # # Install apps #
################ ################
apt-get update \ apt-get update \
&& apt-get install -y \ && apt-get install -y --no-install-recommends \
jq \ jq \
curl \ cifs-utils \
cifs-utils \ keyutils \
keyutils \ samba \
samba \
\ \
################### ##################
# Install bashio # # Install bashio #
################## ##################
&& mkdir -p /tmp/bashio \ && mkdir -p /tmp/bashio \
@@ -26,9 +25,26 @@ RUN \
| tar -xzf - --strip 1 -C /tmp/bashio \ | tar -xzf - --strip 1 -C /tmp/bashio \
&& mv /tmp/bashio/lib /usr/lib/bashio \ && mv /tmp/bashio/lib /usr/lib/bashio \
&& ln -s /usr/lib/bashio/bashio /usr/bin/bashio \ && ln -s /usr/lib/bashio/bashio /usr/bin/bashio \
&& rm -rf /tmp/bashio && rm -rf /tmp/bashio \
\
RUN grep -rl '/config' /etc/cont-init.d/ | xargs sed -i 's|/config|/config/plex|g' #change config folder /var/{cache,log}/* \
/var/lib/apt/lists/* \
\
#############################
# Allow UID and GID setting #
#############################
\
&& sed -i 's/bash/bashio/g' /etc/cont-init.d/10-adduser \
&& sed -i 's/{PUID:-911}/(bashio::config "PUID")/g' /etc/cont-init.d/10-adduser \
&& sed -i 's/{PGID:-911}/(bashio::config "PGID")/g' /etc/cont-init.d/10-adduser \
&& sed -i "s|chown abc:abc /config||g" /etc/cont-init.d/10-adduser \
\
###########
# FOLDERS #
###########
\
&& sed -i "s|/config|/data/plex|g" /etc/services.d/plex/run \
&& sed -i "s|/config|/data/plex|g" /etc/cont-init.d/30-config
# copy local files # copy local files
COPY root/ / COPY root/ /