Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Pod reboot loop with "One or more Ingress objects are invalid" #779

Closed
sokoow opened this issue Dec 27, 2017 · 5 comments

Comments

Projects
None yet
2 participants
@sokoow
Copy link

commented Dec 27, 2017

Hi All, I've created a following ingress:

Name:         test-ing
Namespace:    default
Labels:       <none>
Annotations:  kubectl.kubernetes.io/last-applied-configuration={"apiVersion":"voyager.appscode.com/v1beta1","kind":"Ingress","metadata":{"annotations":{},"name":"test-ing","namespace":"default"},"spec":{"rules":[{"...
API Version:  voyager.appscode.com/v1beta1
Kind:         Ingress
Metadata:
  Cluster Name:
  Creation Timestamp:             2017-12-05T14:01:58Z
  Deletion Grace Period Seconds:  <nil>
  Deletion Timestamp:             <nil>
  Generation:                     0
  Initializers:                   <nil>
  Resource Version:               4689211
  Self Link:                      /apis/voyager.appscode.com/v1beta1/namespaces/default/ingresses/test-ing
  UID:                            dbec79f6-d9c4-11e7-91ec-0e384d78c79c
Spec:
  Rules:
    Http:
      Paths:
        Backend:
          Service Name:  deployment-svc
          Service Port:  80
        Path:            /testpath
Events:                  <none>

and now my voyager-operator pod crash loops with:

I1227 10:07:57.343055       1 logs.go:19] FLAG: --resync-period="5m0s"
I1227 10:07:57.343084       1 logs.go:19] FLAG: --stderrthreshold="2"
I1227 10:07:57.343092       1 logs.go:19] FLAG: --v="3"
I1227 10:07:57.343100       1 logs.go:19] FLAG: --vmodule=""
W1227 10:07:57.521294       1 client_config.go:529] Neither --kubeconfig nor --master was specified.  Using the inClusterConfig.  This might not work.
I1227 10:07:57.522100       1 run.go:121] Starting Voyager operator...
I1227 10:07:57.522162       1 operator.go:55] Ensuring CRD registration
I1227 10:08:00.562172       1 validator.go:52] Checking ingress test-ing@default
F1227 10:08:00.562235       1 run.go:136] One or more Ingress objects are invalid: test-ing@default

It... shouldn't be doing that. Even when there's something wrong with the ingress, it's not logical. Can this be fixed please?

@tamalsaha

This comment has been minimized.

Copy link
Member

commented Dec 27, 2017

Hi,
Can you please share the following info?

  • Voyager version:
  • kubectl version:
  • Ingress YAML for for test-ing in default namespace
@sokoow

This comment has been minimized.

Copy link
Author

commented Dec 27, 2017

Hey Tamal,

Here it goes:

Voyager version: 5.0.0-rc.8
kubectl version: Client Version: version.Info{Major:"1", Minor:"8", GitVersion:"v1.8.2+coreos.0", GitCommit:"4c0769e81ab01f47eec6f34d7f1bb80873ae5c2b", GitTreeState:"clean", BuildDate:"2017-10-25T16:24:46Z", GoVersion:"go1.8.3", Compiler:"gc", Platform:"linux/amd64"}
Server Version: version.Info{Major:"1", Minor:"8", GitVersion:"v1.8.2+coreos.0", GitCommit:"4c0769e81ab01f47eec6f34d7f1bb80873ae5c2b", GitTreeState:"clean", BuildDate:"2017-10-25T16:24:46Z", GoVersion:"go1.8.3", Compiler:"gc", Platform:"linux/amd64"}

apiVersion: voyager.appscode.com/v1beta1
kind: Ingress
metadata:
  name: test-ing
  namespace: default
spec:
  - rules:
    http:
      paths:
        - backend:
            serviceName:  deployment-svc
            servicePort:  80
          path: /testpath
@tamalsaha

This comment has been minimized.

Copy link
Member

commented Dec 27, 2017

Hi,
Please try the following YAML. The issue is rule is an array.

apiVersion: voyager.appscode.com/v1beta1
kind: Ingress
metadata:
  name: test-ing
  namespace: default
spec:
  rules:
  - http:
      paths:
        - backend:
            serviceName:  deployment-svc
            servicePort:  80
          path: /testpath
@sokoow

This comment has been minimized.

Copy link
Author

commented Dec 27, 2017

I know that :) but the real issue is that a single bad ingress shouldn't pull down the whole voyager pod. It should tell you in the logs that its definition is bad, not crash loop backoff

@tamalsaha

This comment has been minimized.

Copy link
Member

commented Dec 27, 2017

Currently voyager operator will check for bad existing Ingress when the operator pod starts.

// https://github.com/appscode/voyager/issues/346

Once the operator is running, if you create bad Ingress, that will not cause crash loops. Instead, we just write events for the Ingress object.

The Voyager Ingress CRD format has changed over time. This ensures that when user runs a new version of voyager operator pod, they have fixed the yaml format .

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.