Skip to content
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

Online status #242

Closed
zboinek opened this issue Dec 14, 2023 · 9 comments
Closed

Online status #242

zboinek opened this issue Dec 14, 2023 · 9 comments

Comments

@zboinek
Copy link

zboinek commented Dec 14, 2023

I can't find this answer anywhere. Which service

  • login HTTP
  • login GRPC
  • world

should be pointed in config.php to show online status?

@slawkens
Copy link
Owner

There are 4 variables in config.php for status:

	'status_enabled' => true, // you can disable status checking by settings this to "false"
	'status_ip' => '',
	'status_port' => '',
	'status_timeout' => 2, // how long to wait for the initial response from the server (default: 2 seconds)

If you mean the port, then it should be set to 7171 (standard).

And IP can be set to '127.0.0.1'

@zboinek
Copy link
Author

zboinek commented Dec 14, 2023

Ok, so it's game world port. I'm developing it in docker-compose so can't be set to localhost ;) Thanks for an answer

@zboinek
Copy link
Author

zboinek commented Dec 14, 2023

It's probably not a case for an issue. It's my mistake somewhere but as I can see even setting it to false shows Server OFFLINE in top right corner :/
image

@slawkens
Copy link
Owner

slawkens commented Dec 14, 2023

You may want to look into mine docker setup: #236

I set there the ip to ip = "192.168.176.1" in config.lua, so the status checks this IP. I am unsure how docker resolves IPs tho. So it may be different IP in your case.

@zboinek
Copy link
Author

zboinek commented Dec 17, 2023

In files I can see that status is made from some socket response, but is there a way to debug status from curl maybe?
Is it your IP of docker machine? It looks like gateway

@slawkens
Copy link
Owner

You can't debug with curl, because its custom protocol AFAIK. It responds with XML however.

Yes its IP of the docker machine. But I think every Docker user will have different IP for their container. That one was from my setup.

@zboinek
Copy link
Author

zboinek commented Dec 17, 2023

Yeap. But if you bind IP of container to host you can use it as a local IP. Any way, something else is broken in my setup :P As I can see number of players if serwer is online is taken from data base. I put true as default and now I can see that there is always 0 players, but if I click I can see of online folks :p strange

@zboinek
Copy link
Author

zboinek commented Dec 18, 2023

hmm, that's strange. I bet that server info is some kind auto populated from files?
image
Name is correct because I didn't change it but all the rest is wrong

@slawkens
Copy link
Owner

serverInfo is populated from config.lua

It will be probably removed in future versions or moved to admin panel.

Anyway, I am closing this, as initial issue has been probably resolved (?).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants