Home > Blockchain >  knative service deployed fails with reason RevisionMissing when image is used from docker hub(public
knative service deployed fails with reason RevisionMissing when image is used from docker hub(public

Time:11-29

I'm trying to deploy a knative service in my local Kubernetes cluster (Docker Desktop for windows). I could create a knative service when I use images from the google cloud container registry (gcr.io/knative-samples/helloworld-go) but I'm facing an issue when I use images from the docker hub. Please note that I not using any private repository in the Docker registry.

The revision.serving will be in status unknown for the first 10 minutes and later changes to false with the reason ProgressDeadlineExceeded. The knative service fails with reason RevisionMissing. I have tried using the official hello-world image from docker hub and the response is the same. The issue is only when I'm using images from the docker official registry but now when GCR is used.

Below is the Kubernetes manifest file I used to create a knative service.

apiVersion: serving.knative.dev/v1
kind: Service
metadata:
  name: flowbuilder
spec:
  template:
    metadata:
      # This is the name of our new "Revision," it must follow the convention {service-name}-{revision-name}
      name: flowbuilder-rev1
    spec:
      containers:
        - image: docker.io/vinaycheguri/flowbuilder:v1
          imagePullPolicy: IfNotPresent
          ports:
            - containerPort: 3007

screenshot of kubernetes resources

Note: I'm using knative-serving version 1.0

status of revision.serving

CodePudding user response:

Finally, I resolved the issue by removing the ports session in the YAML file. If the container port is included, the application gets started in a container (I have verified the logs) but it never receives the traffic and fails with the ProgressDeadlineExceeded error.

CodePudding user response:

Due to how docker hub does authentication, you need to follow the procedure of using a private registry, creating secrets and so on. Here are the steps: https://knative.dev/docs/serving/deploying-from-private-registry/

  • Related