unmojang / drasl

Yggdrasil-compatible API server for Minecraft
GNU General Public License v3.0
118 stars 19 forks source link

Drasl webserver doesn't work (Docker) #44

Closed GoodGameInfinity closed 11 months ago

GoodGameInfinity commented 11 months ago

Hello! I have tried to set up Drasl on my server using Docker, but when I try to access the web UI or even ping the HTTP server it's running on the port is closed. And the thing is that I am not even connecting from the internet, but from my local network. I made sure that the port is accessible from the computer I'm trying to reach the HTTP server from, so I think that it must by an issue with Drasl. According to the logs which I have supplied below the webserver starts normally.

What I have tried to do (but it didn't help)

Here is my config file:

# Drasl default config file

# Example: drasl.example.com
Domain = "mcauth.frnsrv.ru"

# Example: My Drasl Instance
InstanceName = "REDACTED"

# Example: My Organization
ApplicationOwner = "REDACTED"

# Example: 127.0.0.1:25585
ListenAddress = "127.0.0.1:15585"

# Example: https://drasl.example.com
BaseURL = "https://mcauth.frnsrv.ru"

# List of usernames who automatically become admins of the Drasl instance
DefaultAdmins = ["GoodGameInfinity"]

# Amount of time until token expires in seconds, example: 604800 (1 week)
TokenExpireSec = 604800

[RegistrationNewPlayer]
Allow = true
AllowChoosingUUID = false
RequireInvite = true

Here are the logs copied from docker:

2023/12/23 20:24:42 Loading config from /etc/drasl/config.toml

2023/12/23 20:24:42 No users found! Here's an invite URL: https://mcauth.frnsrv.ru/drasl/registration?invite=REDACTED

⇨ http server started on 127.0.0.1:15585

Also some info: I used Portainer to set up the docker container, it publishes the port 15585/TCP and mounts two binds. The Docker image I used is unmojang/drasl:latest from the Docker Hub.

GoodGameInfinity commented 11 months ago

Also just saying that I have tried running it on my main machine with the same config using the AUR version, and it doesn't work on it either.

evan-goode commented 11 months ago

Hi, sounds like a configuration error. I'm not familiar with Portainer, but if you stop by the #help channel on Matrix: https://matrix.to/#/#unmojang:matrix.org, I can try to help. My first thought is you may be missing the reverse proxy to handle the HTTPS.

GoodGameInfinity commented 11 months ago

For anyone who encounters the issue: the thing that fixed it for me, was changing the ListenAddress IP from 127.0.0.1 to 0.0.0.0