diff --git a/factorio/Dockerfile b/factorio/Dockerfile index 95e6e4e..8ca094d 100644 --- a/factorio/Dockerfile +++ b/factorio/Dockerfile @@ -2,9 +2,14 @@ FROM alpine ARG VERSION RUN mkdir -p /opt/factorio WORKDIR /opt/factorio -RUN apk add jq curl wget +RUN wget -q -O /etc/apk/keys/sgerrand.rsa.pub https://alpine-pkgs.sgerrand.com/sgerrand.rsa.pub && \ + wget https://github.com/sgerrand/alpine-pkg-glibc/releases/download/2.35-r1/glibc-2.35-r1.apk && \ + apk add glibc-2.35-r1.apk jq curl wget && apk add gcompat || echo this is ok RUN cd /opt && \ wget -O /opt/server.tar.xz https://www.factorio.com/get-download/1.1.100/headless/linux64 && \ tar -xf /opt/server.tar.xz && \ rm /opt/server.tar.xz -ENTRYPOINT [ "executable" ] \ No newline at end of file +RUN bin/x64/factorio --create saves/default.zip +EXPOSE 34197 +ENTRYPOINT [ "/opt/factorio/bin/x64/factorio", "--port", "34197" ] +CMD [ "--start-server", "saves/default.zip" ] \ No newline at end of file diff --git a/factorio/create.sh b/factorio/create.sh old mode 100644 new mode 100755 index a58eb2a..79b5b6e --- a/factorio/create.sh +++ b/factorio/create.sh @@ -5,3 +5,4 @@ if [[ -z $VERSION ]] ; jq -r .stable.headless\ ); fi; +docker build -t factorio:${VERSION} --build-arg VERSION=${VERSION} --label type=GAME . \ No newline at end of file diff --git a/minecraft/paper/create.sh b/minecraft/paper/create.sh old mode 100644 new mode 100755 index 3df59a7..7e6803e --- a/minecraft/paper/create.sh +++ b/minecraft/paper/create.sh @@ -4,4 +4,4 @@ then VERSION=$(curl https://api.papermc.io/v2/projects/paper | \ jq -r .versions[-1]); fi; -docker build -t minecraft:paper-${VERSION} . --arg VERSION=${VERSION} +docker build -t minecraft:paper-${VERSION} . --build-arg VERSION=${VERSION} diff --git a/steam/gmod/Dockerfile b/steam/gmod/Dockerfile new file mode 100644 index 0000000..eb23a65 --- /dev/null +++ b/steam/gmod/Dockerfile @@ -0,0 +1,5 @@ +FROM i386/ubuntu +RUN apt-get update && apt-get install -y wget && mkdir -p /opt/steamcmd && cd /opt/steamcmd && wget http://media.steampowered.com/client/steamcmd_linux.tar.gz && tar -xvzf steamcmd_linux.tar.gz +RUN mkdir -p /opt/server +WORKDIR /opt/server +RUN /opt/steamcmd/steamcmd.sh +force_install_dir . +login anonymous +force_install_dir . +app_update 4020 validate +quit diff --git a/steam/gmod/create.sh b/steam/gmod/create.sh new file mode 100755 index 0000000..5ec06b5 --- /dev/null +++ b/steam/gmod/create.sh @@ -0,0 +1,2 @@ +#!/bin/zsh +docker build -t garrys-mod:latest . \ No newline at end of file