JACOBSMILE / tmodloader1.4

An easy to configure Docker Image for tModLoader 1.4 servers.
Other
139 stars 33 forks source link

Missing latest stable version of tModLoader v2023.09.3.0 #44

Closed Nincodedo closed 9 months ago

Nincodedo commented 11 months ago

https://github.com/tModLoader/tModLoader/releases/tag/v2023.09.3.0

LaoArchAngel commented 11 months ago

In the meantime, you can clone the repo, make the change I have in the pull request, and then rebuild it with this:

docker build . --build-arg="TMOD_VERSION=v2023.09.3.0" -t jacobsmile/tmodloader1.4:v2023.09.3.0

You'll then have to update your docker run or docker compose to run specifically the jacobsmile/tmodloader1.4:v2023.09.3.0 tag you built.

Skyyofficial commented 11 months ago

In the meantime, you can clone the repo, make the change I have in the pull request, and then rebuild it with this:

docker build . --build-arg="TMOD_VERSION=v2023.09.3.0" -t jacobsmile/tmodloader1.4:v2023.09.3.0

You'll then have to update your docker run or docker compose to run specifically the jacobsmile/tmodloader1.4:v2023.09.3.0 tag you built.

would you mind to explain how to do this? I have no idea where even where to start. I tried cloning the image with IntelliJ but i don't see where to put the docker build command.

LaoArchAngel commented 11 months ago

@Skyyofficial The docker build command is something you run, not something you add to the repository. I'll try to give as thorough step-by-step instructions below. Let me know if you get stuck again.

  1. Make sure you have cloned the repo at the machine where you intend to run the container. This is important, as docker images are built into local repos.
  2. Once you've cloned the repo, open the Dockerfile file. On line 117, add libicu60 after libsdl2-2.0-0. Save and close this file.
  3. Open a terminal and cd into the directory that has the Dockerfile. If you're using Intellij, it comes with a Terminal tool that should open in the correct directory.
  4. Once in the correct directory, run the docker build command. Please note that this is assuming that you are running this command from the same machine that is hosting the docker container. Otherwise, the image you are building will not be available on your target machine:
    docker build . --build-arg="TMOD_VERSION=v2023.09.3.0" -t jacobsmile/tmodloader1.4:v2023.09.3.0
  5. Verify that your new image is built using docker image ls | grep "v2023.09.3.0". This should output a line similar to this:
    jacobsmile/tmodloader1.4                                             v2023.09.3.0       ...

    If there was no output, something in the build failed.

  6. If you run your docker container using docker run, you will need to update the image you're running from jacobsmile/tmodloader1.4:latest (or similar) to jacobsmile/tmodloader1.4:v2023.09.3.0. If you run your container using docker compose, you'll need to edit your docker-compose.yml, and replace image: jacobsmile/tmodloader1.4:latest with image: jacobsmile/tmodloader1.4:v2023.09.3.0
  7. Start your server as per usual.
Fairy- commented 11 months ago

@LaoArchAngel That doesn't seem to be working tough. Building the image fails with Unable to locate package libicu60.

JACOBSMILE commented 11 months ago

Hi all, I am just commenting here to note I will be taking a look today and begin tracking the issue.

Skyyofficial commented 11 months ago

@Skyyofficial The docker build command is something you run, not something you add to the repository. I'll try to give as thorough step-by-step instructions below. Let me know if you get stuck again.

  1. Make sure you have cloned the repo at the machine where you intend to run the container. This is important, as docker images are built into local repos.
  2. Once you've cloned the repo, open the Dockerfile file. On line 117, add libicu60 after libsdl2-2.0-0. Save and close this file.
  3. Open a terminal and cd into the directory that has the Dockerfile. If you're using Intellij, it comes with a Terminal tool that should open in the correct directory.
  4. Once in the correct directory, run the docker build command. Please note that this is assuming that you are running this command from the same machine that is hosting the docker container. Otherwise, the image you are building will not be available on your target machine:
docker build . --build-arg="TMOD_VERSION=v2023.09.3.0" -t jacobsmile/tmodloader1.4:v2023.09.3.0
  1. Verify that your new image is built using docker image ls | grep "v2023.09.3.0". This should output a line similar to this:
jacobsmile/tmodloader1.4                                             v2023.09.3.0       ...

If there was no output, something in the build failed. 5. If you run your docker container using docker run, you will need to update the image you're running from jacobsmile/tmodloader1.4:latest (or similar) to jacobsmile/tmodloader1.4:v2023.09.3.0. If you run your container using docker compose, you'll need to edit your docker-compose.yml, and replace image: jacobsmile/tmodloader1.4:latest with image: jacobsmile/tmodloader1.4:v2023.09.3.0 6. Start your server as per usual.

Hey thanks. As Fairy mentioned i can't build it with your change too but if I just rebuild it with just your command it still works and uses the newest update.

JACOBSMILE commented 11 months ago

Hi all, I updated the repository with a new workflow action - this allows me to ad-hoc download and build specific tModLoader verisons. In this case, I did an ad-hoc build of v2023.09.3.0, so this should now be available. Please try and let me know.

Skyyofficial commented 11 months ago

Hi all, I updated the repository with a new workflow action - this allows me to ad-hoc download and build specific tModLoader verisons. In this case, I did an ad-hoc build of v2023.09.3.0, so this should now be available. Please try and let me know.

Works fine! Thank you very much :)

kynapse commented 10 months ago

Ran into the issue again, latest stable version isn't in the repo. There's a race condition where if tmodloader makes more than one tag a day the github action only pulls the latest.

I believe changing this line should always pull the latest stable: https://github.com/JACOBSMILE/tmodloader1.4/blob/36871de884f4ae08a22a2ab804081f567eb5b1e8/.github/workflows/tmodloader-check.yml#L18

curl -sL https://api.github.com/repos/tModLoader/tModLoader/releases | jq -r "map(select(.prerelease==false)) | first | .tag_name"
xrh0905 commented 10 months ago

Same issues occured with v2023.10.3.0.

kynapse commented 10 months ago

For those using docker compose, you can modify your compose file to manually specify the tmodloader version by replacing the image: line with

build: 
  context: https://github.com/JACOBSMILE/tmodloader1.4.git
  args: 
    - TMOD_VERSION=v2023.10.3.0
jcnorkus commented 10 months ago

Is there any way to resolve this when using the app from the Unraid appstore? I don't see a compose file to edit and a variable didn't do the trick. I set the variable in the screenshot but in the container log it still shows 9.3.3 as the running tmodLoader vesion image image

JACOBSMILE commented 10 months ago

I'll take a look here today.

Skyyofficial commented 10 months ago

Ran into the issue again, latest stable version isn't in the repo. There's a race condition where if tmodloader makes more than one tag a day the github action only pulls the latest.

I believe changing this line should always pull the latest stable:

https://github.com/JACOBSMILE/tmodloader1.4/blob/36871de884f4ae08a22a2ab804081f567eb5b1e8/.github/workflows/tmodloader-check.yml#L18

curl -sL https://api.github.com/repos/tModLoader/tModLoader/releases | jq -r "map(select(.prerelease==false)) | first | .tag_name"

even with this change my server still runs on v2023.9.3.2 with "image: 'jacobsmile/tmodloader1.4:latest'"

Also using:

build: context: https://github.com/JACOBSMILE/tmodloader1.4.git args:

  • TMOD_VERSION=v2023.10.3.0

gives me the following error failed to deploy a stack: failed to solve: process "/bin/bash -o pipefail -c apt-get update && apt-get install -y --no-install-recommends curl tar" did not complete successfully: exit code: 100

EDIT: using "image: 'jacobsmile/tmodloader1.4:v2023.10.3.0" does work. Changing back to :latest reverts back to v2023.9.3.2 tho.

JACOBSMILE commented 10 months ago

Let me check why the docker image isn't updating latest. I'll check after work today.

JACOBSMILE commented 10 months ago

This should be updated to :latest now. I've added some more tools for me to ad-hoc update these, as well as to repair the :latest pushing of the automated workflow hopefully. I'll monitor for a couple days before closing this issue, but 10.3.0 should be :latest now.

Skyyofficial commented 10 months ago

This should be updated to :latest now. I've added some more tools for me to ad-hoc update these, as well as to repair the :latest pushing of the automated workflow hopefully. I'll monitor for a couple days before closing this issue, but 10.3.0 should be :latest now.

Works now but after repulling the image. Thanks again! :)

JACOBSMILE commented 9 months ago

I'm closing this now, I've monitored for some time and can confirm this issue is fixed with the changes to the workflows. Thanks everyone for being patient!