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

No output; error in logs #8

Open
ipfaffy opened this issue Dec 2, 2018 · 8 comments
Open

No output; error in logs #8

ipfaffy opened this issue Dec 2, 2018 · 8 comments

Comments

@ipfaffy
Copy link

ipfaffy commented Dec 2, 2018

Hi, after installing the rbac and deployment from the docs, I see this in the pod logs:

> [email protected] server /usr/src/app
> nodemon src/server/server.js

[nodemon] 1.18.6
[nodemon] to restart at any time, enter `rs`
[nodemon] watching: *.*
[nodemon] starting `node src/server/server.js`
Listening on port 3000....
(node:39) UnhandledPromiseRejectionWarning: #<Object>
(node:39) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). (rejection id: 1)
(node:39) [DEP0018] DeprecationWarning: Unhandled promise rejections are deprecated. In the future, promise rejections that are not handled will terminate the Node.js process with a non-zero exit code.
(node:39) UnhandledPromiseRejectionWarning: #<Object>
(node:39) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). (rejection id: 2)
(node:39) UnhandledPromiseRejectionWarning: #<Object>
(node:39) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). (rejection id: 3)
(node:39) UnhandledPromiseRejectionWarning: #<Object>
(node:39) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). (rejection id: 4)
(node:39) UnhandledPromiseRejectionWarning: #<Object>
(node:39) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). (rejection id: 5)

The site works and serves a UI, but has no pods/ingresses/services. Am I doing something wrong?

@ipfaffy
Copy link
Author

ipfaffy commented Dec 2, 2018

To install I literally copy/pasted the spekt8-deployment.yaml and fabric8-rbac.yaml from the docs and then apply with kubectl create -f $file.

@elliotxkim
Copy link
Contributor

Hi, do you mind providing me with a little bit more information? Are you just saving the yaml files to your own code base and then applying it to your own cluster? Or are you using our code base? It looks like some promises are not being caught. If the UI is being served but has no pods/ingresses/services, it means it's not fetching from the Kubernetes api server properly and that could be because of various reasons.

@ipfaffy
Copy link
Author

ipfaffy commented Dec 14, 2018

Ran these commands with an activated kubeconfig.

git clone https://github.com/spekt8/spekt8.git
cd spekt8
kubectl apply -f fabric8-rbac.yaml
kubectl apply -f spekt8-deployment.yaml
kubectl port-forward deployment/spekt8 3000:3000
kubectl port-forward deployment/spekt8 3000:3000

This started the service, but only brought up a white screen.

@ipfaffy
Copy link
Author

ipfaffy commented Dec 14, 2018

Also after running kubectl logs -f $pod_id I got:

> [email protected] server /usr/src/app
> nodemon src/server/server.js

[nodemon] 1.18.7
[nodemon] to restart at any time, enter `rs`
[nodemon] watching: *.*
[nodemon] starting `node src/server/server.js`
Listening on port 3000....
(node:39) UnhandledPromiseRejectionWarning: #<Object>
(node:39) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). (rejection id: 1)
(node:39) [DEP0018] DeprecationWarning: Unhandled promise rejections are deprecated. In the future, promise rejections that are not handled will terminate the Node.js process with a non-zero exit code.

@bpatton00
Copy link

bpatton00 commented Jun 27, 2019

update, for anyone that runs into this. As expected it's a permissions error that can be seen if you go directly to localhost:3000/pods and view the json object

"response":{"statusCode":403,"body":{"kind":"Status","apiVersion":"v1","metadata":{},"status":"Failure","message":"pods is forbidden: User "system:serviceaccount:default:default" cannot list resource "pods" in API group "" in the namespace "default"","reason":"Forbidden","details":{"kind":"pods"},"code":403}

My issue was related to the fact that I was trying to use something other than default:default and fabric8 didn't seem to get that information.

@grzesuav
Copy link

@bpatton00 so what is the resolution ?

@bpatton00
Copy link

@bpatton00 so what is the resolution ?

I ended up reverting to default:default for the user.

I also modified the source code to meet our needs. Changed hard coded localhost:3000 to pickup window.location.href so I could serve it from a dns to our team. See my fork for the code

I also have on the roadmap to convert the k8sApi.listNamespacedService('default') value to a parameter that can be set and leveraged based on where it currently is deployed. Ideally I'd like to see spekt8 have a selectable namespace option with a dynamically populated list.

@ITBeyder
Copy link

is the issue resolved for you ? im getting those erros from the pod log

Listening on port 3000....
(node:39) UnhandledPromiseRejectionWarning: #<Object>
(node:39) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). (rejection id: 1)
(node:39) [DEP0018] DeprecationWarning: Unhandled promise rejections are deprecated. In the future, promise rejections that are not handled will terminate the Node.js process with a non-zero exit code.
(node:39) UnhandledPromiseRejectionWarning: #<Object>
(node:39) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). (rejection id: 2)
(node:39) UnhandledPromiseRejectionWarning: #<Object>
(node:39) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). (rejection id: 3)
(node:39) UnhandledPromiseRejectionWarning: #<Object>
(node:39) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). (rejection id: 4)
(node:39) UnhandledPromiseRejectionWarning: #<Object>
(node:39) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). (rejection id: 5)
(node:39) UnhandledPromiseRejectionWarning: #<Object>
(node:39) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). (rejection id: 6)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants