Uploaded image for project: 'Couchbase Kubernetes'
  1. Couchbase Kubernetes
  2. K8S-301

cbopctl does not validate the version field in couchbase-cluster.yaml

    XMLWordPrintable

Details

    • Bug
    • Resolution: Won't Fix
    • Major
    • 0.8.0
    • None
    • kubernetes
    • None

    Description

      Does the cbopctl validate the "version" field in couchbase-cluster.yaml? Is it intentional not to validate this field?

      • When an invalid field is provided in the couchbase-cluster.yaml file which is as follows:

      Observe the "version" field:

      apiVersion: couchbase.database.couchbase.com/v1beta1
      kind: CouchbaseCluster
      metadata:
        name: cb-example
      spec:
        baseImage: couchbase/server
        version: oiwefenterprise-5.0.1
        authSecret: cb-example-auth
        exposeAdminConsole: true

      • The couchbase cluster seems to be created successfully using cbopctl create command:

       

      [root@ip-172-31-28-231 example]# /root/go/src/github.com/couchbase/couchbase-operator/build/bin/cbopctl create -f couchbase-cluster.yaml
      couchbaseclusters "cb-example" created

       

      • Get pod output shows that it is unable to pull the invalid image and hence the pod deployment fails.

       

      [root@ip-172-31-28-231 example]# oc get pods
      NAME                                  READY     STATUS             RESTARTS   AGE
      cb-example-0000                       0/1       ImagePullBackOff   0          7m
      couchbase-operator-7978ffc45f-k9scl   1/1       Running            0          2h

      • Events:

        Normal   BackOff                4m (x18 over 8m)  kubelet, ip-172-31-20-176.us-west-1.compute.internal  Back-off pulling image "couchbase/server:oiwefenterprise-5.0.1"

      • pod logs:

        [root@ip-172-31-28-231 example]# oc logs cb-example-0000
        Error from server (BadRequest): container "couchbase-server" in pod "cb-example-0000" is waiting to start: trying and failing to pull image

         

      Attachments

        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

        Activity

          People

            mikew Mike Wiederhold [X] (Inactive)
            sindhura.palakodety Sindhura Palakodety (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes

                PagerDuty