node-red-contrib-nest icon indicating copy to clipboard operation
node-red-contrib-nest copied to clipboard

Generate token not working in bluemix

Open willcampos opened this issue 10 years ago • 9 comments

Hi, I have been use the node for some tests, I notice when I upload to bluemix, it does not allow to authenticate the PIN.

Is there any instruction I am missing on bluemix?

Thanks,

W

willcampos avatar Jul 11 '15 21:07 willcampos

Hi there, I've also got a similar issue, where I cannot generate the access token using the button. When I create the access token manually via a HTTP POST request and copy & paste it in I still don't have ability to click the 'Add' button Thanks, J

jambo13 avatar Jan 11 '16 14:01 jambo13

Same issue here. Tried multiple browsers. Will let you generate pincode but that's as far as it goes

yamtam avatar Feb 08 '16 01:02 yamtam

Does Bluemix have a firewall that prevents the node-red engine from making outbound HTTPS calls (on port 443) to get the access token? If so you will have to setup your security settings to allow it to call out. This will need to be setup anyway for post-setup communication to work.

hjespers avatar Aug 31 '16 01:08 hjespers

Same issue here, running on node-red 0.14.6 on a raspberry pi 3. Authorize button works, then I copy and paste the PIN. But clicking on Generate Token does absolutely nothing. Can't click Add until token is generated. Tried it on several browsers. Looking behind the scenes, there's a URL being generated in the script in nest.html with a GET method which results in a 404...

https://{my-node-red-server}/nest-credentials/{node-id}/{nest-product-id}/{nest-product-secret}/{nest-authorization-code}/auth

So in my case it's node-red's failure to serve this endpoint which is causing token generation to fail.

JonSilver avatar Sep 27 '16 18:09 JonSilver

@JonSilver are you running on a non-standard node-red port (something other than 1880) or with login credentials? Just wondering why the lop back would fail for you and not me.

hjespers avatar Oct 01 '16 02:10 hjespers

@hjespers No, it's on 1880, and I have only admin credentials, no login on httpNodes. I use https, employing a LetsEncrypt certificate with a full chain cert. At some point in the past year, on another installation and a previous version of your code and node-red, it worked with a seemingly identical setup.

JonSilver avatar Oct 01 '16 07:10 JonSilver

@JonSilver and @hjespers - did you get to the bottom of the Token generation on a Pi 3 ? I appear to have the same issue

Courty

Courty40 avatar Jan 16 '17 16:01 Courty40

No. It happens on one installation and not on another. The bad behaviour on the troublesome installation persists across Node-Red version upgrades. I’ve no idea why. That Pi has no other issues. It doesn’t matter how many times I uninstall the nest plugin and reinstall it. I gave up talking to Nest.

From: Courty [mailto:[email protected]] Sent: 16 January 2017 16:11 To: hjespers/node-red-contrib-nest [email protected] Cc: Jon Silver [email protected]; Mention [email protected] Subject: Re: [hjespers/node-red-contrib-nest] Generate token not working in bluemix (#1)

@JonSilverhttps://github.com/JonSilver and @hjespershttps://github.com/hjespers - did you get to the bottom of the Token generation on a Pi 3 ? I appear to have the same issue

Courty

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHubhttps://github.com/hjespers/node-red-contrib-nest/issues/1#issuecomment-272902755, or mute the threadhttps://github.com/notifications/unsubscribe-auth/AIbAgsyDBBAQKGOTUZ9I3jwwlXhEypkiks5rS5apgaJpZM4FWwq3.

JonSilver avatar Jan 16 '17 16:01 JonSilver

The issues is that bluemix adds a red to the normal node-red url. So normally its http://server:1800/, but bluemix is https://yournode.bluemix.net/red ... the red is not included in the generated URL. I will try to add a permanent fix but for now if you want to get to try a temp fix that will work in bluemix, you can add this line to the package.json to reference my fork: "node-red-contrib-nest":"git://github.com/langanjp/node-red-contrib-nest.git"

langanjp avatar Jun 21 '17 03:06 langanjp