mirror of
https://github.com/DerTyp7/docker_minecraft_server_auto_starter.git
synced 2025-10-29 12:42:09 +01:00
Fix placeholder server IP handling
This commit is contained in:
@@ -68,6 +68,9 @@ class RequestHandler(threading.Thread):
|
|||||||
print('Container is starting. Using starting placeholder IP')
|
print('Container is starting. Using starting placeholder IP')
|
||||||
ip = os.environ.get('PLACEHOLDER_SERVER_STARTING_IP')
|
ip = os.environ.get('PLACEHOLDER_SERVER_STARTING_IP')
|
||||||
|
|
||||||
|
if not ip:
|
||||||
|
print('No placeholder server IP found')
|
||||||
|
return
|
||||||
server_socket.connect(
|
server_socket.connect(
|
||||||
(ip, 25565))
|
(ip, 25565))
|
||||||
server_socket.sendall(request)
|
server_socket.sendall(request)
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
version: "3.9"
|
version: "3.9"
|
||||||
|
|
||||||
networks:
|
networks:
|
||||||
# You need to have a network with static ips for the servers.
|
# You need to have a network with static ips for the servers
|
||||||
mc_network:
|
mc_network:
|
||||||
driver: bridge
|
driver: bridge
|
||||||
ipam:
|
ipam:
|
||||||
@@ -25,7 +25,7 @@ services:
|
|||||||
# Port mapping for the servers
|
# Port mapping for the servers
|
||||||
# The key is the external port of the placeholder server
|
# The key is the external port of the placeholder server
|
||||||
# The value is the internal ip of the actual server
|
# The value is the internal ip of the actual server
|
||||||
# Don't change the server port in the actual server. Use this instead.
|
# Don't change the server port in the actual server. Use this instead
|
||||||
PORT_IP_MAP: |
|
PORT_IP_MAP: |
|
||||||
25565: 172.20.0.5
|
25565: 172.20.0.5
|
||||||
25566: 172.20.0.6
|
25566: 172.20.0.6
|
||||||
|
|||||||
Reference in New Issue
Block a user