forked from googleforgames/agones
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Integrates upgrades tests into Cloud Build (googleforgames#4037)
* Integrates upgrades tests into Cloud Build * Templates current build version to pass through to test containers * Use sed for variable replacement as envsubst not found in cloud build * Upgrade tests wait to be oldest builds before running * Bumps versions * Allows the Helm install of the current Agones development build during the upgrade test * Changes per linter * Bumps retry timeout by 10s * Deletes all dangling agones resources * Updates evictable pods to have the same pod affinity rules as the test game servers * Removes unnecessary check from the cloudbuild file * Changes watch events to AddFunc rather than UpdateFunc The same events are covered by AddFunc as by UpdateFunc with less overhead. Any container crashes are caught by the Game Server Unhealthy watch, and are not needed in this watch.
- Loading branch information
Showing
12 changed files
with
502 additions
and
209 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,67 @@ | ||
# Copyright 2024 Google LLC All Rights Reserved. | ||
# | ||
# Licensed under the Apache License, Version 2.0 (the "License"); | ||
# you may not use this file except in compliance with the License. | ||
# You may obtain a copy of the License at | ||
# | ||
# http://www.apache.org/licenses/LICENSE-2.0 | ||
# | ||
# Unless required by applicable law or agreed to in writing, software | ||
# distributed under the License is distributed on an "AS IS" BASIS, | ||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
# See the License for the specific language governing permissions and | ||
# limitations under the License. | ||
|
||
# Create evictable pods to prevent Autopilot clusters from completely scaling down. | ||
# https://cloud.google.com/kubernetes-engine/docs/how-to/capacity-provisioning | ||
--- | ||
apiVersion: scheduling.k8s.io/v1 | ||
kind: PriorityClass | ||
metadata: | ||
name: low-priority | ||
value: -10 | ||
preemptionPolicy: Never | ||
globalDefault: false | ||
description: "Low priority workloads" | ||
--- | ||
apiVersion: apps/v1 | ||
kind: Deployment | ||
metadata: | ||
name: evictable-pods-deployment | ||
spec: | ||
replicas: 200 | ||
selector: | ||
matchLabels: | ||
app: evictable-pods | ||
template: | ||
metadata: | ||
labels: | ||
app: evictable-pods | ||
# Label for use with packed game server pod affinity rules | ||
agones.dev/role: gameserver | ||
spec: | ||
priorityClassName: low-priority | ||
terminationGracePeriodSeconds: 0 | ||
containers: | ||
- name: ubuntu | ||
image: ubuntu | ||
imagePullPolicy: IfNotPresent | ||
command: ["sleep"] | ||
args: ["infinity"] | ||
resources: | ||
requests: | ||
memory: 52Mi | ||
cpu: 30m | ||
limits: | ||
memory: 52Mi | ||
cpu: 30m | ||
# Use same affinity as packed game server pods | ||
affinity: | ||
podAffinity: | ||
preferredDuringSchedulingIgnoredDuringExecution: | ||
- podAffinityTerm: | ||
labelSelector: | ||
matchLabels: | ||
agones.dev/role: gameserver | ||
topologyKey: kubernetes.io/hostname | ||
weight: 100 |
Oops, something went wrong.