googleforgames / agones

Dedicated Game Server Hosting and Scaling for Multiplayer Games on Kubernetes
https://agones.dev
Apache License 2.0
5.91k stars 778 forks source link

[e2e] Document the best path for making changes to simple-game-server for e2e tests #3836

Open markmandel opened 1 month ago

markmandel commented 1 month ago

Is your feature request related to a problem? Please describe.

There is lots of confusion on the best path for how to make changes to simple game server in a safe way.

Describe the solution you'd like

Make the ImagePullPolicy a variable, so it can easily be set to Always:

Variables:

https://github.com/googleforgames/agones/blob/bff72b1161492d7386e0bf39ca0753802c4b3e3a/test/e2e/framework/framework.go#L152-L169

Line:

https://github.com/googleforgames/agones/blob/bff72b1161492d7386e0bf39ca0753802c4b3e3a/test/e2e/framework/framework.go#L802

Write a new section in https://github.com/googleforgames/agones/blob/main/build/README.md#testing-and-building called "Making changes to Simple Game Server with e2e Tests", with the following documentation:

  1. How to create your own local image for Simple Game Server, and point to https://github.com/googleforgames/agones/blob/main/build/README.md#running-individual-end-to-end-tests for beginning of making changes.
  2. For moving to CI - set the image tag to a 0.xx-dev tag (so -dev with the version number), and imagePullPolicy to Always, and create a draft PR.
  3. With this approach the developer (or maintainer who is helping) can publish the -dev version multiple times without polluting the production version space, can can fix issues with CI's help without any risk.
  4. Once CI is passing and review has occured, the PR can be edited to remove the -dev tag, move imagePullPolicy back to IfNotPresent, and the production version 0.xx can be published -- and the PR merged.
  5. The -dev can also be manually cleaned up if required as well.

Describe alternatives you've considered

Rather than a -dev suffix, we could guide people to use the us-docker.pkg.dev/agones-images/ci repository, that will have a 40 day cleanup rule (eventually - I need to check the audit logs for some previous cleanup work), so no manual cleanup step is required.

So, for example - us-docker.pkg.dev/agones-images/examples/simple-game-server:0.32 would become us-docker.pkg.dev/agones-images/ci/simple-game-server:0.32

I think I like this better - but would like consensus.

Additional context

N/A

markmandel commented 1 month ago

@ashutosji - since you are working on this, would love your feedback.