mirror of
https://github.com/luzifer-docker/teamspeak3.git
synced 2024-11-09 12:30:01 +00:00
Run as unprivileged user
This commit is contained in:
parent
0bef82b1e9
commit
6a7884c1fb
1 changed files with 6 additions and 3 deletions
|
@ -6,7 +6,6 @@ LABEL maintainer Knut Ahlers <knut@ahlers.me>
|
|||
ENV TEAMSPEAK_VERSION=3.13.7 \
|
||||
TEAMSPEAK_SHA256=775a5731a9809801e4c8f9066cd9bc562a1b368553139c1249f2a0740d50041e
|
||||
|
||||
SHELL ["/bin/bash", "-exo", "pipefail", "-c"]
|
||||
RUN apt-get update \
|
||||
&& apt-get install -y curl bzip2 ca-certificates dumb-init --no-install-recommends \
|
||||
&& curl -sSfLo teamspeak3-server_linux-amd64.tar.bz2 \
|
||||
|
@ -16,13 +15,17 @@ RUN apt-get update \
|
|||
&& rm teamspeak3-server_linux-amd64.tar.bz2 \
|
||||
&& apt-get purge -y curl bzip2 && apt-get autoremove -y \
|
||||
&& apt-get clean \
|
||||
&& rm -rf /var/lib/apt/lists/*
|
||||
&& rm -rf /var/lib/apt/lists/* \
|
||||
&& groupadd -g 1000 teamspeak \
|
||||
&& useradd -u 1000 -g 1000 teamspeak \
|
||||
&& chown -R teamspeak:teamspeak /opt/teamspeak3-server_linux_amd64
|
||||
|
||||
COPY docker-ts3.sh /opt/docker-ts3.sh
|
||||
|
||||
# Inject a Volume for any TS3-Data that needs to be persisted or to be accessible from the host. (e.g. for Backups)
|
||||
VOLUME ["/teamspeak3"]
|
||||
|
||||
USER teamspeak
|
||||
ENTRYPOINT ["/usr/bin/dumb-init", "--"]
|
||||
CMD ["/opt/docker-ts3.sh"]
|
||||
|
||||
|
|
Loading…
Reference in a new issue