Closed portlek closed 1 year ago
The ports part fill in the ports you want to expose. If your game service wants to be exposed through the proxy service, you should fill in the ports of the proxy in ports. You can run multiple containers in one pod.
Take for example
apiVersion: agones.dev/v1
kind: Fleet
metadata:
name: hub-fleet
namespace: minecraft
spec:
replicas: 2
scheduling: Packed
template:
spec:
ports:
- name: proxy-port
containerPort: 1234
protocol: TCP
template:
spec:
serviceAccountName: minecraft-account
containers:
- name: proxy # port: 1234
image: MY_IMAGE
- name: hub-gameserver # port: 25565
image: MY_IMAGE
interesting concept but proxy and hub are separate servers, proxies will be like 2 or 3 but hub servers will be like 10-20 so i don't want to combine these two gameserver types. it's not like 1 proxy server for 1 hub server. it's like all proxy servers will manage all gameservers.
Several options:
Thanks for the info, will take a look at 1. and 2. options and try. 3. option is not for me since i use custom dedicated servers.
I'm going to close this now as I think this question is answered.
So basically, i'm creating a Minecraft server which has Proxies and also gameplay servers. I don't want to expose gameplay servers to players but proxies do. Proxies are registering gameplay servers internally to move the player whenever it connects to the proxy. My gameserver fleet yaml looks like this:
I know 'ports' is nullable since 1.30.0 (i guess?) but when i remove the ports, how i supposed to send people to this gameplay server? Or if there is a way to make the port something like 'ClusterIp' rather than like a NodeIp would be great too.
I've tried to create a new container port within the gameserver pod, i guess kubernetes does not allow that.