GameServerManagers / docker-linuxgsm

LinuxGSM base docker image
MIT License
13 stars 10 forks source link

dockerized instance in a K8 cluster network isnt ready #41

Open ncraig419 opened 8 months ago

ncraig419 commented 8 months ago

Have an issue with linuxgsm failing because the entrypoint.sh tries to download and install before the network is initialized.

can a delay be added to wait for a full response from the internet before it begins the processes in entrypoint-user.sh?

a simple while loop works but obviously not if I have to reload the docker image

#pause for network start
while ! ping -c 4 google.com > /dev/null;
do 
  echo -e "Waiting for internet connection."
  sleep 10
done
compdude22 commented 7 months ago

When run in a Kubernetes cluster, does the LinuxGSM container remain running after failing to connect to the internet in entrypoint-user.sh? If not, I would have expected the cluster controller to restart the container, but retain the same pod, at which point networking should be present and the connections should succeed on the 2nd try.

It does seem problematic for the Kubernetes cluster if it is starting containers before networking is available.