Git Product home page Git Product logo

Comments (5)

KAllan357 avatar KAllan357 commented on June 27, 2024 1

I think we can probably close this.

image

It looks like enabling the feature gate gets it to function the way I expect.

from agones.

markmandel avatar markmandel commented on June 27, 2024 1

func (gss *GameServerSpec) validateFeatureGates(fldPath *field.Path) field.ErrorList {
var allErrs field.ErrorList
if !runtime.FeatureEnabled(runtime.FeaturePlayerTracking) {
if gss.Players != nil {
allErrs = append(allErrs, field.Forbidden(fldPath.Child("players"), fmt.Sprintf("Value cannot be set unless feature flag %s is enabled", runtime.FeaturePlayerTracking)))
}
}
if !runtime.FeatureEnabled(runtime.FeatureCountsAndLists) {
if gss.Counters != nil {
allErrs = append(allErrs, field.Forbidden(fldPath.Child("counters"), fmt.Sprintf("Value cannot be set unless feature flag %s is enabled", runtime.FeatureCountsAndLists)))
}
if gss.Lists != nil {
allErrs = append(allErrs, field.Forbidden(fldPath.Child("lists"), fmt.Sprintf("Value cannot be set unless feature flag %s is enabled", runtime.FeatureCountsAndLists)))
}
}
return allErrs
}

Is where the validation should be added (in case people are looking).

from agones.

daniellee avatar daniellee commented on June 27, 2024

Just to double check, it is behind a feature gate - have you enabled it?

https://agones.dev/site/docs/installation/install-agones/helm/#configuration - the value should be something like:"PortPolicyNone=true"

And could you show a bit more of your gameserver spec (with the sensitive info removed)?

from agones.

KAllan357 avatar KAllan357 commented on June 27, 2024

Okay, I did not use the feature gate. I would maybe expect to receive an error if I was trying to use an gated feature. Let me try that later to see if the behavior changes.

Here is more of my Fleet definition:

apiVersion: "agones.dev/v1"
kind: Fleet
metadata:
  name: game-server
  labels:
    dev/changelist: "2024-06-12-6166-232"
spec:
  replicas: 1
  scheduling: Packed
  strategy:
    type: RollingUpdate
    rollingUpdate:
      maxSurge: 25%
      maxUnavailable: 25%
  template:
    metadata:
      labels:
        dev/changelist: "2024-06-12-6166-232"
        app.kubernetes.io/name: game-server
        app.kubernetes.io/managed-by: Helm
    spec:
      container: game-server
      ports:
        - containerPort: 7777
          name: game
          portPolicy: None
          protocol: UDP
      health:
        initialDelaySeconds: 30
        periodSeconds: 20
        failureThreshold: 5
      sdkServer:
        logLevel: Info
        grpcPort: 9357
        httpPort: 9358
      template:
        metadata:
          labels:
            dev/changelist: "2024-06-12-6166-232"
            app.kubernetes.io/managed-by: Helm
        spec:
          containers:
            - name: game-server
              securityContext: {}
              image: "ECR"
              imagePullPolicy: Always
              env:
              resources: {}
              volumeMounts:
                - name: ini-overrides
                  mountPath: "blah"
                  subPath: FizzBuzz.ini
          imagePullSecrets:
            - name: ecr
          serviceAccountName: game-server
          securityContext: {}
          volumes:
            - name: ini-overrides
              configMap:
                name: game-server
                items:
                  - key: FizzBuzz.ini
                    path: FizzBuzz.ini
          nodeSelector:
            serverType: gameservers
          tolerations:
            - effect: NoSchedule
              key: serverType
              operator: Equal
              value: game

from agones.

markmandel avatar markmandel commented on June 27, 2024

Okay, I did not use the feature gate. I would maybe expect to receive an error if I was trying to use an gated feature.

That is a bug though, if the feature gate is not enabled, we should throw a validation error. I'll leave this open, as we should fix this part.

from agones.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.