Rework image to use s6-overlay to run TMServer and Xaseco
- Adds S6-Overlay - Bundles Xaseco into the image
This commit is contained in:
parent
6ea355fb89
commit
f50397562e
29
Dockerfile
29
Dockerfile
|
@ -1,17 +1,24 @@
|
||||||
FROM debian:buster-slim
|
FROM php:5.6-alpine
|
||||||
|
ARG S6_OVERLAY_VERSION=3.1.1.1
|
||||||
|
|
||||||
COPY tmserver/ /opt/tmserver
|
RUN apk add --no-cache pwgen gettext xmlstarlet bash xz
|
||||||
COPY entrypoint-tmserver.sh /opt/tmserver/
|
RUN docker-php-ext-install mysql
|
||||||
|
|
||||||
RUN apt update \
|
COPY tmserver/ /var/lib/tmserver
|
||||||
&& apt install -y pwgen gettext-base xmlstarlet
|
COPY xaseco/ /var/lib/xaseco
|
||||||
|
|
||||||
RUN groupadd trackmania
|
RUN addgroup -S trackmania && adduser -D -H -S trackmania -G trackmania
|
||||||
RUN useradd -M -g trackmania trackmania
|
RUN chown -R trackmania:trackmania /var/lib/tmserver /var/lib/xaseco
|
||||||
RUN chown -R trackmania:trackmania /opt/tmserver
|
|
||||||
|
|
||||||
USER trackmania
|
|
||||||
|
|
||||||
EXPOSE 5000
|
EXPOSE 5000
|
||||||
|
|
||||||
CMD ["/opt/tmserver/entrypoint-tmserver.sh"]
|
CMD ["/var/lib/tmserver/entrypoint.sh"]
|
||||||
|
|
||||||
|
ADD https://github.com/just-containers/s6-overlay/releases/download/v${S6_OVERLAY_VERSION}/s6-overlay-noarch.tar.xz /tmp
|
||||||
|
RUN tar -C / -Jxpf /tmp/s6-overlay-noarch.tar.xz
|
||||||
|
ADD https://github.com/just-containers/s6-overlay/releases/download/v${S6_OVERLAY_VERSION}/s6-overlay-x86_64.tar.xz /tmp
|
||||||
|
RUN tar -C / -Jxpf /tmp/s6-overlay-x86_64.tar.xz
|
||||||
|
ENTRYPOINT ["/init"]
|
||||||
|
|
||||||
|
RUN touch /etc/s6-overlay/s6-rc.d/user/contents.d/xaseco
|
||||||
|
COPY services.d/xaseco/ /etc/s6-overlay/s6-rc.d/xaseco/
|
||||||
|
|
Loading…
Reference in New Issue