diff --git a/Dockerfile b/Dockerfile index 1d6dd1f..a400e41 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,14 +1,16 @@ +# Use alpine linux as base image. FROM alpine:3.20 -# Install dependencies +# Install mumble-server. RUN apk add --no-cache \ - bash \ - curl \ - murmur + murmur \ + curl +# Create mumble user and group environment variables. ARG MUMBLE_UID=1000 ARG MUMBLE_GID=1000 +# Create mumble user and group. RUN addgroup \ --gid $MUMBLE_GID \ mumble && \ @@ -19,15 +21,22 @@ RUN addgroup \ --ingroup mumble \ mumble +# Set the mumble-server configuration directory owner. RUN mkdir -p /config && \ chown -R mumble:mumble /config +# Set the mumble-server configuration directory +# as the working directory with mumbe user. USER mumble WORKDIR /config + +# Expose mumble-server ports. EXPOSE 64738/tcp 64738/udp + +# Copy entrypoint script. COPY entrypoint.sh /entrypoint.sh -# Start mumble-server +# Start mumble-server. VOLUME ["/config"] ENTRYPOINT ["/entrypoint.sh"] CMD ["/usr/bin/mumble-server", "-fg"]