-
Notifications
You must be signed in to change notification settings - Fork 3
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
Lazymc Docker Proxy doesnt allow me to connect to the Minecraft Game Server #134
Comments
Ping @joesturge |
Debug logs |
which port your server is really using? like if you are not using lazy-mc, which port you use to connect to your server? it seems like a port exposing issue |
@otomay you can literally see it in the compose. The image itself needs 25565 but the actual host port is 49152. But that isnt the issue. I had switched to 25565 on all sides and same issue. So its smth else but i guess nobody knows why. |
yeah, I was thinking if had something to do with
but if you tested with 25565, doesn't seems like it's the issue. do you server are really able to start in less than 500s? what mc container shows before lazy-mc killing it bc of timeout? |
yes my server starts b4 500s. Im thinking its just an issue with the proxy in general that it cant proxy the lazy mc docker proxy to my mc docker. I just cant troubleshoot on my own with real help |
The version you would want to try with is |
Hey @joesturge Can i provide other logs or anything to help? |
@joesturge on 2.6.0 i get this error now: This makes the mc server docker container INSTANTLY start up without connecting to it. |
I fixed that error (and ensuring that that my mc server docker container doesnt start up instantly) by adding:
this wasnt needed before but now it is mandatory? Testing the connection issue now... |
@joesturge Same issue. |
@joesturge I may have the issue. Can you explain me how the proxy even works? This is confusing me
Like i get it that we are binding the MC Game Port to the proxy container of lazy mc, but since we are NOT binding the port the minecraft docker, there isnt the port accessible on the actual game server? that may explain my issue, but thats why im confused how this proxy would work. I enabled TRACE logs and its stuck here:
IP is right, but as you see the port doesnt exist on the mc docker server (because you cant bind it). Am i having a wrong thought? |
Hey so it works like so: Any port you "expose" in docker compose allows connections to that container on that port from outside the docker network. Lets assume for simplicity sake, you have just a standalone minecraft container deployed, you would run the server on port 25565 and you would have to add a port mapping to the containers docker compose so that you can connect to the container and play minecraft... However when using lazymc-docker-proxy, you do not have to expose a port on the minecraft container itself, but instead you expose the port on the lazymc container. Containers in the same compose environment can communicate with eachother without having to expose any ports using the ports mapping, this is because both containers share the same network. So in your situation you have two containers, a mc server running on port 25565 (by the looks of it) and the lazymc container which proxies the mc server. So you have to expose a port on the lazymc container and connect to that. By setting the You do need to expose port 25565 on the mc container as lazymc can connect to it as it shares the same network. By setting ports in the ports list, you punch a hole into the docker network from the outside. Hope this helps |
Got it, but then i still dont see my mistake. What can i do or share to find the core issue? |
This looks like it could be working to me? can you connect to the game server through lazymc? |
im confused what you mean. I was never able to connect to my minecraft server running the proxy. The issue i had above was that the moment i started my docker compose, lazymc never killed my mc server. But adding
|
im trying to make a naked mc enviroment and see, maybe my prod one is breaking smth... |
Hey that logline
on the lazy mc container and attach the full logs here please? |
the error was not there once i added but sure ill add the logs in a bit. |
I might be responsible for this one. I noticed this warning message since #126. @FurkanVG, could you please post the result of a |
Could you also try to set |
ok i did a naked config with no plugins mods etc and that worked... it was also a stripped down version of my yaml so there may be smth which furks it up. i will switch back to my prod one and send the infos u guys want |
I think i found the issue as im also experiencing strange behavior on the latest version |
Will have a PR soon for a possible fix |
The Log with DEBUG |
Could you also provide logs of you mc container ? So we can see what happens on its side, if it is really starting in time. |
ugh, the logs are crazy on the main server because i have lots of plugins and may show too many infos. Relevant log times:
And final part of logs loading plugins and server being up:
|
Which port is your mc server listening on ? |
I Have a fix for the server starting when it shouldnt here: #140 |
"Starting Minecraft server on *:25565" - like always |
ok update, i removed all my plugins on my prod server, and now it works lol. so it must be a plugin breaking it |
ill add slowly each plugin and update. |
intresting, let us know which one break it, I also think once that PR is released it will help you too |
Your PR is about the issue that if - lazymc.join.forward.address=172.58.0.3:25565 isnt set that the server auto starts. I fixed that but i will update |
This project works by generating bespoke configs for lazymc, kinda hacked to work with docker. I think Your issue may be related, if the config is borked, it could have unexpected side effects, such as what you are experiencing |
Hi could you try now with version 2.6.1 now? It works again for my stack can confirm |
just for reference this is what the logs should look like when starting (I have it running with 4 servers):
|
To sum it up: @joesturge BEFORE 2.6.0, I did NOT USE Now, to the initial issue, where i was never able to connect to my minecraft server with this lazymc proxy. Issue is found! It looks like the Plugin https://hangar.papermc.io/jmp/MiniMOTD is NOT allowing the LAZY MC Docker Proxy to do the final process. I guess this has to do because Lazy MC itself is trying to show some MOTD and this created a conflict which then avoided the proxy to be fully initalized. My knowledge ends here to find out WHY this happens, but i can confirm to 100% that lazy mc is not compatible. I have tested this by adding all plugins each by each and then found out that MINITMOTD was causing the issue. All of my other plugins are successfully loaded and its working with this. This was done successfully ON 2.6.0 AND i also tested it now successfully also on 2.6.1! |
I see performance issues with this sadly, but that is smth else i may analyze later. If you dont have anything more to add @joesturge or you think its not worth to investigate the conflict wiht MiniMOTD, this issue can be closed. |
ooo thats a good find, good job on locating it. Glad it works on 2.6.1 without that plugin. Ill add a section to the readme about plugins which affect the MOTD suggesting not to use them for now. There is another open issue about MOTD configurations here: #98 Dont know if that would also be similar to your use case? |
Dont think its the same case. I was using a specific plugin that handles MOTD, the guy didnt try it from my understanding. |
This issue has also been experienced by someone else here: #135 |
Hmm, but the incompatible messsage is coming from your MOTD, no? Because i never had this before without your Proxy. |
Could you contribute to that issue i linked about this? I think its the same problem |
yea np |
I also created a new issue here for the MOTD plugin issue: #142 Could you add any relavent detail to that if i missed anything please, in the meantime i think i can close this issue if you are happy? |
Yeah i will close this issue, thanks for helping :) I will add some infos on both issues you mentioned! |
Thanks for the help with this 😄 |
Hi,
i am trying to combine this docker image with my itzg minecraft container.
The docker compose:
i removes some ENV variables not related to this, so as fyi.
The current scenario:
Now i had thought it would be related to how long my mc server takes time to boot up, so i increased the timeout to 500s, but that didnt help. I dont know where the issue is? Is it the port changing i did? I have adapted this in the compose and it shouldnt be an issue.
The text was updated successfully, but these errors were encountered: