forked from ldericher/tmodloader-docker
-
Notifications
You must be signed in to change notification settings - Fork 46
Updating to Latest Terraria Release #2
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Draft
JoeStratton
wants to merge
20
commits into
rfvgyhn:master
Choose a base branch
from
JoeStratton:master
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Draft
Changes from all commits
Commits
Show all changes
20 commits
Select commit
Hold shift + click to select a range
741874e
updating to new terraria and tmod version
JoeStratton 9cc702c
addingt travis testing back in
JoeStratton 77fda3a
adding unzip rather than tar for tmod files
JoeStratton c45e6bd
adding zip arguments to tmodload server
JoeStratton c15b1d1
fixng new file structure for tmodloader 11.7
JoeStratton 4776926
updated base image version to solve error code
JoeStratton e5da61c
fixed unzip error with forced overwrite -o
JoeStratton 4dc3406
updating tmod and terraria - still broken until tmod updates
JoeStratton 2ebcec7
updating tmod and terraria - still broken until tmod updates
JoeStratton 029228d
updating tmod and terraria - still broken until tmod updates
JoeStratton b8ac335
updated terraria server download url, note this will still not work u…
JoeStratton c01090c
fixed variable note- still needs tmodloader update to function
JoeStratton 598548c
simplyfing travis pipeline
JoeStratton c16fd80
simplyfing travis pipeline
JoeStratton 0c49a50
Update README.md
JoeStratton 61bc54c
cleanup before hibernating for tmod upates
JoeStratton e4785f3
Merge branch 'master' of github.com:JoeStratton/tmodloader-docker
JoeStratton f85553c
updating to working versions
JoeStratton 7e6e4e5
updating to working versions
JoeStratton 7b799ef
updating to working versions
JoeStratton File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,18 @@ | ||
| language: python | ||
|
|
||
| services: | ||
| - docker | ||
|
|
||
| jobs: | ||
| include: | ||
| - stage: Build and Push Docker Image | ||
| script: | ||
| - echo "$DOCKER_PASSWORD" | docker login -u "$DOCKER_USERNAME" --password-stdin | ||
| - docker build -t tmodloader-docker . | ||
| - docker images | ||
| - docker tag tmodloader-docker $DOCKER_USERNAME/tmodloader-docker | ||
| - docker push $DOCKER_USERNAME/tmodloader-docker | ||
| - stage: Run Docker Image | ||
| script: | ||
| - docker run -d --name Terraria -p 7777:7777 -v /etc/localtime:/etc/localtime:ro $DOCKER_USERNAME/tmodloader-docker | ||
| - docker ps -a | ||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,46 +1,46 @@ | ||
| FROM frolvlad/alpine-glibc:alpine-3.10 as build | ||
|
|
||
| ARG TMOD_VERSION=0.11.6.2 | ||
| ARG TERRARIA_VERSION=1353 | ||
|
|
||
| RUN apk update &&\ | ||
| apk add --no-cache --virtual build curl unzip &&\ | ||
| apk add --no-cache -X http://dl-cdn.alpinelinux.org/alpine/edge/testing mono | ||
|
|
||
| WORKDIR /terraria-server | ||
|
|
||
| RUN cp /usr/lib/libMonoPosixHelper.so . | ||
|
|
||
| RUN curl -SLO "http://terraria.org/server/terraria-server-${TERRARIA_VERSION}.zip" &&\ | ||
| unzip terraria-server-*.zip &&\ | ||
| rm terraria-server-*.zip &&\ | ||
| cp --verbose -a "${TERRARIA_VERSION}/Linux/." . &&\ | ||
| rm -rf "${TERRARIA_VERSION}" &&\ | ||
| rm TerrariaServer.bin.x86 TerrariaServer.exe | ||
|
|
||
| RUN curl -SL "https://github.com/tModLoader/tModLoader/releases/download/v${TMOD_VERSION}/tModLoader.Linux.v${TMOD_VERSION}.tar.gz" | tar -xvz &&\ | ||
| chmod u+x tModLoaderServer* Terraria TerrariaServer.* &&\ | ||
| mv TerrariaServer.bin.x86_64 tModLoaderServer.bin.x86_64 &&\ | ||
| rm *.txt *.jar | ||
|
|
||
| FROM frolvlad/alpine-glibc:alpine-3.10 | ||
|
|
||
| WORKDIR /terraria-server | ||
| COPY --from=build /terraria-server ./ | ||
|
|
||
| RUN apk update &&\ | ||
| apk add --no-cache procps tmux | ||
| RUN ln -s ${HOME}/.local/share/Terraria/ /terraria | ||
| COPY inject.sh /usr/local/bin/inject | ||
| COPY handle-idle.sh /usr/local/bin/handle-idle | ||
|
|
||
| EXPOSE 7777 | ||
| ENV TMOD_SHUTDOWN_MSG="Shutting down!" | ||
| ENV TMOD_AUTOSAVE_INTERVAL="*/10 * * * *" | ||
| ENV TMOD_IDLE_CHECK_INTERVAL="" | ||
| ENV TMOD_IDLE_CHECK_OFFSET=0 | ||
|
|
||
| COPY config.txt entrypoint.sh ./ | ||
| RUN chmod +x entrypoint.sh /usr/local/bin/inject /usr/local/bin/handle-idle | ||
|
|
||
| ENTRYPOINT [ "/terraria-server/entrypoint.sh" ] | ||
| FROM frolvlad/alpine-glibc:alpine-3.11 as build | ||
| ARG TMOD_VERSION=0.11.7.5 | ||
| ARG TERRARIA_VERSION=1405 | ||
| RUN apk update &&\ | ||
| apk add --no-cache --virtual build curl unzip &&\ | ||
| apk add --no-cache -X http://dl-cdn.alpinelinux.org/alpine/edge/testing mono | ||
| WORKDIR /terraria-server | ||
| RUN cp /usr/lib/libMonoPosixHelper.so . | ||
| RUN curl -SLO "https://www.terraria.org/system/dedicated_servers/archives/000/000/039/original/terraria-server-${TERRARIA_VERSION}.zip" &&\ | ||
| unzip terraria-server-*.zip &&\ | ||
| rm terraria-server-*.zip &&\ | ||
| cp --verbose -a "${TERRARIA_VERSION}/Linux/." . &&\ | ||
| rm -rf "${TERRARIA_VERSION}" &&\ | ||
| rm TerrariaServer.bin.x86 TerrariaServer.exe | ||
| RUN curl -SLO "https://github.com/tModLoader/tModLoader/releases/download/v${TMOD_VERSION}/tModLoader.Linux.v${TMOD_VERSION}.zip" &&\ | ||
| unzip -o tModLoader.Linux.v*.zip &&\ | ||
| rm tModLoader.Linux.v*.zip &&\ | ||
| chmod u+x tModLoaderServer* | ||
| FROM frolvlad/alpine-glibc:alpine-3.11 | ||
| WORKDIR /terraria-server | ||
| COPY --from=build /terraria-server ./ | ||
| RUN apk update &&\ | ||
| apk add --no-cache procps tmux | ||
| RUN ln -s ${HOME}/.local/share/Terraria/ /terraria | ||
| COPY inject.sh /usr/local/bin/inject | ||
| COPY handle-idle.sh /usr/local/bin/handle-idle | ||
| EXPOSE 7777 | ||
| ENV TMOD_SHUTDOWN_MSG="Shutting down!" | ||
| ENV TMOD_AUTOSAVE_INTERVAL="*/10 * * * *" | ||
| ENV TMOD_IDLE_CHECK_INTERVAL="" | ||
| ENV TMOD_IDLE_CHECK_OFFSET=0 | ||
| COPY config.txt entrypoint.sh ./ | ||
| RUN chmod +x entrypoint.sh /usr/local/bin/inject /usr/local/bin/handle-idle | ||
| ENTRYPOINT [ "/terraria-server/entrypoint.sh" ] |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I haven't used travis before. Does this push to docker hub or does travis have it's own private registry used for testing?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
you have to set your environment variables you see referenced in the travis UI itself with your docker hub credentials. It does not have a local registry. This builds the container and pushes it, then tests it by pulling and running it.